You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Alessandro Benedetti <ab...@apache.org> on 2016/07/04 13:12:39 UTC

Re: Spell check suggestions because of case

Hi Kalpana,
can you explain better ?
In your index you have "diabetes" .
Which suggestion you would prefer to see ?
Seems not ab-normal to me.

Cheers

On Wed, Jun 29, 2016 at 9:18 PM, Kalpana <ks...@portalsolutions.net>
wrote:

> Hello
>
> I am getting suggestions for Diabetes as diabetes - even though it brings
> the same results for both. I used the case filter to no use.
>
> Solrconfig
>   <searchComponent name="spellcheck" class="solr.SpellCheckComponent">
>
>         <lst name="spellchecker">
>         <str name="name">default</str>
>         <str name="classname">solr.IndexBasedSpellChecker</str>
>         <str
> name="lookupImpl">org.apache.solr.spelling.suggest.tst.TSTLookup</str>
>     <str name="field">spell</str>
>         <str name="buildOnCommit">true</str>
>     <str name="spellcheckIndexDir">spellchecker</str>
>         </lst>
> </searchComponent>
>
> Schema
>
> <field name="spell" type="textSpell" indexed="true" stored="true"
> multiValued="true" />
> <field name="title_t" type="text_general" indexed="true" stored="true"
> required="false" />
> <field name="description_t" type="text_general" indexed="true"
> stored="true"
> required="false" />
> <field name="health_content_t" type="text_general" indexed="true"
> stored="true" required="false" />
>
> <copyField source="health_content_t" dest="spell" />
> <copyField source="title_t" dest="spell" />
> <copyField source="description_t" dest="spell" />
>
> <fieldType name="textSpell" class="solr.TextField"
> positionIncrementGap="100">
>                         <analyzer type="index">
>                                 <tokenizer
> class="solr.StandardTokenizerFactory"/>
>                                 <filter class="solr.StopFilterFactory"
> ignoreCase="true"
> words="stopwords.txt"/>
>                                 <filter
> class="solr.StandardFilterFactory"/>
>                                 <filter
> class="solr.LowerCaseFilterFactory" />
>                                 <filter
> class="solr.RemoveDuplicatesTokenFilterFactory"/>
>                         </analyzer>
>                         <analyzer type="query">
>                                 <tokenizer
> class="solr.StandardTokenizerFactory"/>
>                                 <filter class="solr.SynonymFilterFactory"
> synonyms="synonyms.txt"
> ignoreCase="true" expand="true"/>
>                                 <filter class="solr.StopFilterFactory"
> ignoreCase="true"
> words="stopwords.txt"/>
>                                 <filter
> class="solr.StandardFilterFactory"/>
>                                 <filter
> class="solr.LowerCaseFilterFactory" />
>                                 <filter
> class="solr.RemoveDuplicatesTokenFilterFactory"/>
>                         </analyzer>
> </fieldType>
>
> Any help is greatly appreciated
>
> Thank you!
>
>
>
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/Spell-check-suggestions-because-of-case-tp4285027.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>



-- 
--------------------------

Benedetti Alessandro
Visiting card : http://about.me/alessandro_benedetti

"Tyger, tyger burning bright
In the forests of the night,
What immortal hand or eye
Could frame thy fearful symmetry?"

William Blake - Songs of Experience -1794 England

Re: Spell check suggestions because of case

Posted by Kalpana <ks...@portalsolutions.net>.
Hello

Thanks for your reply. When I search for Diabetes I get the results back and
also suggestion for diabetes - which is just a lower case version of
Diabetes. This is true for any search words. When I type in Health - I get
results back and also suggestion for health.

I have applied the necessary filters in both analyzers, index and query.

Thanks again
Kalpana



--
View this message in context: http://lucene.472066.n3.nabble.com/Spell-check-suggestions-because-of-case-tp4285027p4285709.html
Sent from the Solr - User mailing list archive at Nabble.com.