Shalin Shekhar Mangar wrote:
No. Think of onlyMorePopular as a toggle between whether to consider
frequency or not. When you say onlyMorePopular=true, higher frequency terms
are considered. When you say onlyMorePopular=false, frequency plays no role
at all and "gran" is returned because according to the spell checker, it
exists in the index and is therefore a correctly spelled term.
I think thats the problem with it. People do think of it this way, and it ends up being very confusing.

If you dont use onlyMorePopular, and you ask for suggestions for a word that happens to be in the index, you get the word back.

So if I ask for corrections to Lucene, and its in the index, it suggests Lucene. This is nice for multi term suggestions, because for "mrk lucene" it might suggest "mark lucene".

Now say I want to toggle onlyMorePopular to add frequency into the mix - my expectation is that, perhaps now I will get the suggestion "mork lucene" if mork has a higher freq than mark.

But I will get maybe "mork luke" instead, because I am guaranteed not to get Lucene as a suggestion if onlyMorePopular is on.

Personally I think it all ends up being pretty counter intuitive, especially when asking for suggestions for multiple terms. You start getting suggestions for alternate spellings no matter what - Lucene could be in the index a billion times, it will still suggest something else. But with onlyMorePopular off, it will throw back Lucene. You can deal with it if you know whats up, but as we have seen from all the questions on this, its not easy to understand why things change like that.

- Mark

Reply via email to