fixing a few bugs on the tagsimilarities