Exploiting hierarchical domain structure to compute similarity | Synapse