On Jul 15, 2008, at 3:49 PM, Ryan McKinley wrote:

Hi-

I'm messing with spellchecking and running into behavior that seems peculiar. We have an index with many words including:
"swim" and "slim"

If I search for "slim", it returns "swim" as an option -- likewise, if I search for "slim" it returns "swim"

why does it check words that are in the dictionary? This does not seem to be the behavior for IndexBasedSpellChecker.

I think it can depend on your options, but there are reasons to check even if a word is in the dictionary (although w/ FileBased, it's not as obvious.) Namely, there can be "better" spellings available. The strange thing is, I believe, the Lucene Spell checker should be handling this, but your not the first to report the oddity.



- - - -

Perhaps the FileBasedSpellChecker should load the configs at startup. It is too strange to have to call load each time the index starts. It should just implement solrCoreAware() and then load the file at startup.

agreed, but there is a problem in Solr, AIUI, with regards to when the readers are available and when inform() gets called. The workaround is to have a warming query, I believe.



thanks
ryan

Reply via email to