Try here: http://www.lucidimagination.com/blog/2009/09/08/auto-suggest-from-popular-queries-using-edgengrams/
<http://www.lucidimagination.com/blog/2009/09/08/auto-suggest-from-popular-queries-using-edgengrams/>For the infix-type match you're using, you might not want the "edge" version of ngram... Best Erick On Mon, Oct 25, 2010 at 8:16 AM, abhayd <ajdabhol...@hotmail.com> wrote: > > hi > I was looking into using solr suggester component as described in > http://wiki.apache.org/solr/Suggester > > I have a file which has words, phrases in it. > > I was wondering how to make following possible. > > file has > ------------- > rebate form > form > > when i look for "form" or even "for" i would like to have rebate form to be > included too. > I tried using > <str > > name="lookupImpl">org.apache.solr.spelling.suggest.jaspell.JaspellLookup</str> > but no luck, wiki suggests some one liner change to get fuzzy suggestions. > But not sure whats that one liner change would be > > Also wiki suggests "* If you want to use a dictionary file that contains > phrases (actually, strings that can be split into multiple tokens by the > default QueryConverter) then define a different QueryConverter " > but i dont see the desired result > here is my solrconfig.xml > > <searchComponent class="solr.SpellCheckComponent" name="suggest"> > <lst name="spellchecker"> > <str name="name">suggest</str> > <str name="classname">org.apache.solr.spelling.suggest.Suggester</str> > <!-- > <str > name="lookupImpl">org.apache.solr.spelling.suggest.tst.TSTLookup</str> > --> > > <str > > name="lookupImpl">org.apache.solr.spelling.suggest.jaspell.JaspellLookup</str> > <str name="sourceLocation">american-english.txt</str> > <str name="field">name</str> <!-- the indexed field to derive > suggestions from --> > <float name="threshold">0.005</float> > <str name="buildOnCommit">false</str> > <queryConverter name="queryConverter" > class="org.apache.solr.spelling.MySpellingQueryConverter"/> > </lst> > </searchComponent> > <requestHandler class="org.apache.solr.handler.component.SearchHandler" > name="/suggest"> > <lst name="defaults"> > <str name="spellcheck">false</str> > <str name="spellcheck.dictionary">suggest</str> > <str name="spellcheck.onlyMorePopular">true</str> > <str name="spellcheck.count">5</str> > <str name="spellcheck.collate">true</str> > </lst> > <arr name="components"> > <str>suggest</str> > </arr> > </requestHandler> > -- > View this message in context: > http://lucene.472066.n3.nabble.com/solr-1-4-suggester-component-tp1766915p1766915.html > Sent from the Solr - User mailing list archive at Nabble.com. >