Hi all, I am new to lucene and trying the spell checker in contrib\spellchecker.
The problem is that if I enter a wrong word it gives me the correct suggestion but if I enter the correct word, lucene gives me alternate suggestion. For e.g. I have "tour" and "tours" both in the text. If I enter "tors", it gives me "tours". Now if I enter "tour" it gives me "tours" and if I enter "tours" it gives me "tour". Below is the code snippet: SpellChecker spellchecker = new SpellChecker(FSDirectory.getDirectory("index1")); spellchecker.indexDictionary(new LuceneDictionary(reader, "contents")); String[] suggestions = spellchecker.suggestSimilar("tour", 5); I am using StandardAnalyzer while indexing and searching. Lucene Version: 2.4.1 -- Regards, Moiz Chinoy. --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org For additional commands, e-mail: java-user-h...@lucene.apache.org