Tree-based semantic distance
There is a semantic similarity between cats and dogs. If you have a tree like:
pets -> cats
pets -> dogs
You can say that cats are related to dogs via one parent, pets. There are big hand-developed dictionaries that relate concepts that can give you a distance.