fix bug in wordsimilarity