Re: [SolrNet] Problems with Configuration + Usage of SpellCheck

86 views
Skip to first unread message
Message has been deleted

Mauricio Scheffer

unread,
May 24, 2013, 4:56:25 PM5/24/13
to sol...@googlegroups.com
Hi Lin,

Did you build the dictionary? e.g. solr.BuildSpellCheckDictionary(); or see http://wiki.apache.org/solr/SpellCheckComponent#Building_on_Commits

Cheers



--
Mauricio


On Wed, May 22, 2013 at 6:19 AM, Lin Daiyu <daiy...@googlemail.com> wrote:

Hello,

I'm trying to use the SpellCheckComponent in SolrNet but results.SpellChecking is everytime empty although there should be some results.

 

// part of my program

var results = solr.Query("shop dresd", new QueryOptions

            {

                SpellCheck = new SpellCheckingParameters { Collate = true }

            });

 

foreach (var sc in results.SpellChecking)

{

     Console.WriteLine("Query: " + sc.Query);

     foreach (var s in sc.Suggestions)

     {

         Console.WriteLine("Suggestion: {0}", s);

     }

}

 

// ouput of the request-uri http://10.10.30.30:8080/solr/select?q=dresd&spellcheck=true&spellcheck.collate=true

 

<response>
<lst name="responseHeader">
<int name="status">0</int>
<int name="QTime">39</int>
<lst name="params">
<str name="spellcheck">true</str>
<str name="q">dresd</str>
<str name="spellcheck.collate">true</str>
</lst>
</lst>
<result name="response" numFound="4" start="0">
<doc>
<str name="cp_id">C04</str>
<str name="cp_name">Shopping in dresden</str>
<str name="cp_lat">51.044043</str>
<str name="cp_lon">13.735276</str>
<str name="cp_rad">3</str>
<long name="_version_">1433768477762519040</long>
</doc>
<doc>
<str name="cp_id">C06</str>
<str name="cp_name">TU Dresden</str>
<str name="cp_lat">51.02697</str>
<str name="cp_lon">13.72818</str>
<str name="cp_rad">4</str>
<long name="_version_">1433768477769859072</long>
</doc>
<doc>
<str name="cp_id">C07</str>
<str name="cp_name">Schlösser dresdens</str>
<str name="cp_lat">51.06831</str>
<str name="cp_lon">13.77844</str>
<str name="cp_rad">4</str>
<long name="_version_">1433768477774053376</long>
</doc>
<doc>
<str name="cp_id">C03</str>
<str name="cp_name">Museums of Dresden</str>
<str name="cp_lat">51.053802</str>
<str name="cp_lon">13.735114</str>
<str name="cp_rad">2</str>
<long name="_version_">1433768477758324736</long>
</doc>
</result>
<lst name="spellcheck">
<lst name="suggestions"/>
</lst>
</response>

 

I'm using:

Debian 6

Java Version 1.6.0_18

Solr 4.2.1

 

I have attached the config-files as reference.

 

Do I miss something? Is the configuration correct so far? Any suggestions are welcome.

Thank you!
Lin

 

--
You received this message because you are subscribed to the Google Groups "SolrNet" group.
To unsubscribe from this group and stop receiving emails from it, send an email to solrnet+u...@googlegroups.com.
To post to this group, send email to sol...@googlegroups.com.
Visit this group at http://groups.google.com/group/solrnet?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Lin Daiyu

unread,
Jun 11, 2013, 4:35:48 AM6/11/13
to sol...@googlegroups.com
Hi Mauricio,
 
Yes, I have built the dictionary.
I tried a lot to get it work properly. But it seems that the SpellChecker doesn't "like" the language settings of the fieldType text_de.
Is there any way to get both work correct?
 
Lin

Mauricio Scheffer

unread,
Jun 11, 2013, 3:53:03 PM6/11/13
to sol...@googlegroups.com
The XML response you posted on the first message doesn't have any spellcheck response, so the problem is with your solrconfig.xml.
Double-check the SpellCheckComponent config ( http://wiki.apache.org/solr/SpellCheckComponent ), or post to the Solr mailing list ( http://lucene.apache.org/solr/discussion.html ).

Cheers
Reply all
Reply to author
Forward
0 new messages