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 Nitin Solanki <ni...@gmail.com> on 2015/01/27 12:06:06 UTC

Stop word suggestions are coming when I indexed sentence using ShingleFilterFactory

Hi,
          I am getting the suggestion of both correct words and misspell
words but not getting, stop words suggestions. Why? Even I am not using
solr.StopFilterFactory.


Schema.xml :

*<field name="gram" type="textSpell" indexed="true" stored="true"
required="true" multiValued="false"/>*

<fieldType name="*textSpell*" class="solr.TextField"
positionIncrementGap="100">
       <analyzer type="index">
        <tokenizer class="solr.StandardTokenizerFactory"/>

        <filter class="solr.ShingleFilterFactory" maxShingleSize="5"
minShingleSize="2" outputUnigrams="true"/>

     </analyzer>
     <analyzer type="query">
        <tokenizer class="solr.StandardTokenizerFactory"/>

        <filter class="solr.ShingleFilterFactory" maxShingleSize="5"
minShingleSize="2" outputUnigrams="true"/>

</analyzer>
</fieldType>

Re: Stop word suggestions are coming when I indexed sentence using ShingleFilterFactory

Posted by Nitin Solanki <ni...@gmail.com>.
Ok.. I got the solution.
Changed the value of maxQueryFrequency from 0.01(1%) to 0.9(90%). It is
working. thanks a lot.

On Tue, Jan 27, 2015 at 8:55 PM, Dyer, James <Ja...@ingramcontent.com>
wrote:

> Can you give a little more information as to how you have the spellchecker
> configured in solrsonfig.xml?  Also, it would help if you showed a query
> and the spell check response and then explain what you wanted it to return
> vs what it actually returned.
>
> My guess is that the stop words you mention exist in your spelling index
> and you're not using the "alternativeTermCount" parameter, which tells it
> to suggest for terms that exist in the index.
>
> I take it also you're using shingles to get word-break suggestions?  You
> might have better luck with this using WordBreakSolrSpellchecker instead of
> shingles.
>
> James Dyer
> Ingram Content Group
>
>
> -----Original Message-----
> From: Nitin Solanki [mailto:nitinmlvya@gmail.com]
> Sent: Tuesday, January 27, 2015 5:06 AM
> To: solr-user@lucene.apache.org
> Subject: Stop word suggestions are coming when I indexed sentence using
> ShingleFilterFactory
>
> Hi,
>           I am getting the suggestion of both correct words and misspell
> words but not getting, stop words suggestions. Why? Even I am not using
> solr.StopFilterFactory.
>
>
> Schema.xml :
>
> *<field name="gram" type="textSpell" indexed="true" stored="true"
> required="true" multiValued="false"/>*
>
> <fieldType name="*textSpell*" class="solr.TextField"
> positionIncrementGap="100">
>        <analyzer type="index">
>         <tokenizer class="solr.StandardTokenizerFactory"/>
>
>         <filter class="solr.ShingleFilterFactory" maxShingleSize="5"
> minShingleSize="2" outputUnigrams="true"/>
>
>      </analyzer>
>      <analyzer type="query">
>         <tokenizer class="solr.StandardTokenizerFactory"/>
>
>         <filter class="solr.ShingleFilterFactory" maxShingleSize="5"
> minShingleSize="2" outputUnigrams="true"/>
>
> </analyzer>
> </fieldType>
>

RE: Stop word suggestions are coming when I indexed sentence using ShingleFilterFactory

Posted by "Dyer, James" <Ja...@ingramcontent.com>.
Can you give a little more information as to how you have the spellchecker configured in solrsonfig.xml?  Also, it would help if you showed a query and the spell check response and then explain what you wanted it to return vs what it actually returned.  

My guess is that the stop words you mention exist in your spelling index and you're not using the "alternativeTermCount" parameter, which tells it to suggest for terms that exist in the index.

I take it also you're using shingles to get word-break suggestions?  You might have better luck with this using WordBreakSolrSpellchecker instead of shingles.

James Dyer
Ingram Content Group


-----Original Message-----
From: Nitin Solanki [mailto:nitinmlvya@gmail.com] 
Sent: Tuesday, January 27, 2015 5:06 AM
To: solr-user@lucene.apache.org
Subject: Stop word suggestions are coming when I indexed sentence using ShingleFilterFactory

Hi,
          I am getting the suggestion of both correct words and misspell
words but not getting, stop words suggestions. Why? Even I am not using
solr.StopFilterFactory.


Schema.xml :

*<field name="gram" type="textSpell" indexed="true" stored="true"
required="true" multiValued="false"/>*

<fieldType name="*textSpell*" class="solr.TextField"
positionIncrementGap="100">
       <analyzer type="index">
        <tokenizer class="solr.StandardTokenizerFactory"/>

        <filter class="solr.ShingleFilterFactory" maxShingleSize="5"
minShingleSize="2" outputUnigrams="true"/>

     </analyzer>
     <analyzer type="query">
        <tokenizer class="solr.StandardTokenizerFactory"/>

        <filter class="solr.ShingleFilterFactory" maxShingleSize="5"
minShingleSize="2" outputUnigrams="true"/>

</analyzer>
</fieldType>