काम नहीं कर रहा है मैंने उदाहरण के साथ समाधान स्थापना कॉन्फ़िगरेशन के लिए वर्तनी जांचकर्ता स्थापित किया है जो सौर के साथ आता है। मैंने यहां वर्तनी जांचकर्ता के लिए उनके निर्देशों का पालन किया है: [http://wiki.apache.org/solr/SpellCheckComponent ][1]सोलर - उदाहरण वर्तनी परीक्षक
मेरी समस्या यह है कि इसका पालन करने के बाद भी मैं इसे अभी भी काम नहीं कर सकता?
प्रतिक्रिया जब मैं निर्माण (http: // localhost: 8983/Solr/वर्तनी q = : & spellcheck.build = सच & spellcheck.q = delll% 20ultrashar & वर्तनी जाँच = true)
लगता है इस प्रकार है: & spellcheck.q = delll + & वर्तनी जाँच ultrashar = सच 01,232,249:
<response>
<lst name="responseHeader">
<int name="status">0</int>
<int name="QTime">14</int>
</lst>
<str name="command">build</str>
<result name="response" numFound="17" start="0">
...
</result>
<lst name="spellcheck">
<lst name="suggestions"/>
</lst>
</response>
और जब मैं http://localhost:8983/solr/spell?q=साथ क्वेरीspellcheck.extendedResults = सच
मैं निम्नलिखित प्रतिक्रिया
<response>
<lst name="responseHeader">
<int name="status">0</int>
<int name="QTime">1</int>
</lst>
<result name="response" numFound="17" start="0">
...
</result>
<lst name="spellcheck">
<lst name="suggestions">
<bool name="correctlySpelled">false</bool>
</lst>
</lst>
</response>
क्या देता है? क्या मैं अपनी schema.xml में कुछ याद कर रहा हूँ?
Schema.xml यहाँ है: http://www.developermill.com/schema.xml
solrConfig.xml यहाँ है: http://www.developermill.com/solrconfig.xml
उदाहरण फ़ाइलों के लिए केवल परिवर्तन solrconfig.xml में निम्नलिखित के अलावा था:
<searchComponent name="spellcheck" class="solr.SpellCheckComponent">
<lst name="spellchecker">
<!--
Optional, it is required when more than one spellchecker is configured.
Select non-default name with spellcheck.dictionary in request handler.
-->
<str name="name">default</str>
<!-- The classname is optional, defaults to IndexBasedSpellChecker -->
<str name="classname">solr.IndexBasedSpellChecker</str>
<!--
Load tokens from the following field for spell checking,
analyzer for the field's type as defined in schema.xml are used
-->
<str name="field">spell</str>
<!-- Optional, by default use in-memory index (RAMDirectory) -->
<str name="spellcheckIndexDir">./spellchecker</str>
<!-- Set the accuracy (float) to be used for the suggestions. Default is 0.5 -->
<str name="accuracy">0.7</str>
<!-- Require terms to occur in 1/100th of 1% of documents in order to be included in the dictionary -->
<float name="thresholdTokenFrequency">.0001</float>
</lst>
<!-- Example of using different distance measure -->
<lst name="spellchecker">
<str name="name">jarowinkler</str>
<str name="field">lowerfilt</str>
<!-- Use a different Distance Measure -->
<str name="distanceMeasure">org.apache.lucene.search.spell.JaroWinklerDistance</str>
<str name="spellcheckIndexDir">./spellchecker</str>
</lst>
<!-- This field type's analyzer is used by the QueryConverter to tokenize the value for "q" parameter -->
<str name="queryAnalyzerFieldType">textSpell</str>
</searchComponent>
<!--
The SpellingQueryConverter to convert raw (CommonParams.Q) queries into tokens. Uses a simple regular expression
to strip off field markup, boosts, ranges, etc. but it is not guaranteed to match an exact parse from the query parser.
Optional, defaults to solr.SpellingQueryConverter
-->
<queryConverter name="queryConverter" class="solr.SpellingQueryConverter"/>
<!-- Add to a RequestHandler
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
NOTE: YOU LIKELY DO NOT WANT A SEPARATE REQUEST HANDLER FOR THIS COMPONENT. THIS IS DONE HERE SOLELY FOR
THE SIMPLICITY OF THE EXAMPLE. YOU WILL LIKELY WANT TO BIND THE COMPONENT TO THE /select STANDARD REQUEST HANDLER.
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-->
<requestHandler name="/spellCheckCompRH" class="solr.SearchHandler">
<lst name="defaults">
<!-- Optional, must match spell checker's name as defined above, defaults to "default" -->
<str name="spellcheck.dictionary">default</str>
<!-- omp = Only More Popular -->
<str name="spellcheck.onlyMorePopular">false</str>
<!-- exr = Extended Results -->
<str name="spellcheck.extendedResults">false</str>
<!-- The number of suggestions to return -->
<str name="spellcheck.count">1</str>
</lst>
<!-- Add to a RequestHandler
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
REPEAT NOTE: YOU LIKELY DO NOT WANT A SEPARATE REQUEST HANDLER FOR THIS COMPONENT. THIS IS DONE HERE SOLELY FOR
THE SIMPLICITY OF THE EXAMPLE. YOU WILL LIKELY WANT TO BIND THE COMPONENT TO THE /select STANDARD REQUEST HANDLER.
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-->
<arr name="last-components">
<str>spellcheck</str>
</arr>
</requestHandler>
क्या आप यहां अपने 'solrconfig.xml' और 'schema.xml' के प्रासंगिक हिस्सों को पेस्ट कर सकते हैं? – javanna
यहां दोनों के लिंक हैं। यहाँ वर्ण सीमा पेस्ट करने के लिए थोड़ा है। http://www.developermill.com/solrconfig.xml http://www.developermill.com/schema.xml -> मैंने जो परिवर्तन किया था वह solrconfig.xml था जो < searchComponent name = "spellcheck" class = "solr.SpellCheckComponent"> नीचे –
पर दाएं मैंने देखा कि लिंक 'solrconfig.xml' आपके प्रश्न में चिपका हुआ एक से अलग है। कौन सा एक आप प्रयोग कर रहें है? हो सकता है कि आपको सिर्फ उस प्रश्न में ही रहना चाहिए। – javanna