Simple NLP: How to use ngram to do word similarity?
- by sadawd
Dear Everyone,
I Hear that google uses up to 7-grams for their own data. I am interested in finding words that are similar in context (i.e. cat and dog) and I was wondering how do I compute the similarity of two words on a n-gram model given that n 2.
Given a sample set like this forexample: (I, love cats), (cats, loves, dogs), (dogs, hate, human)
What is a good way to compare the similarity of this pair (I, cats)?
Also does anyone know of anyway to do levels for NLP?
like: Army-Military-Solider ?