我正在尝试在solr中实现spellCheck。从solr iterface我能够看到整理但是通过使用solr net 整理始终为null 。我正在使用的solrconfig和模式文件已附加。
Here is the request handler and search component congiguation:
<searchComponent name="spellcheck" class="solr.SpellCheckComponent" >
<str name="queryAnalyzerFieldType">text_spell</str>
<lst name="spellchecker">
<str name="name">default</str>
<str name="field">textspell</str>
<str name="classname">solr.DirectSolrSpellChecker</str>
<str name="distanceMeasure">internal</str>
<float name="accuracy">0.5</float>
<int name="maxEdits">2</int>
<int name="minPrefix">1</int>
<int name="maxInspections">5</int>
<int name="minQueryLength">4</int>
<float name="maxQueryFrequency">0.01</float>
<!--<float name="thresholdTokenFrequency">.01</float>-->
</lst>
<!-- a spellchecker that can break or combine words. See "/spell" handler below for usage -->
<lst name="spellchecker">
<str name="name">wordbreak</str>
<str name="classname">solr.WordBreakSolrSpellChecker</str>
<str name="field">textspell</str>
<str name="combineWords">true</str>
<str name="breakWords">true</str>
<int name="maxChanges">10</int>
</lst>
</searchComponent>
<requestHandler name="/select" class="solr.SearchHandler">
<!-- default values for query parameters can be specified, these
will be overridden by parameters in the request
-->
<lst name="defaults">
<str name="df">spellcheck</str>
<str name="spellcheck.dictionary">default</str>
<!--<str name="spellcheck.dictionary">wordbreak</str>-->
<str name="spellcheck">on</str>
<str name="spellcheck.extendedResults">false</str>
<str name="spellcheck.count">1</str>
<str name="spellcheck.alternativeTermCount">5</str>
<str name="spellcheck.maxResultsForSuggest">5</str>
<str name="spellcheck.collate">true</str>
<str name="spellcheck.maxCollations">1</str>
<str name="spellcheck.maxcollationtries">3</str>
<str name="spellcheck.maxCollationEvaluations">3</str>
<str name="spellcheck.collateextendedresults">true</str>
<str name="spellcheck.collatemaxcollectdocs">10</str>
</lst>
<arr name="last-components">
<str>spellcheck</str>
</arr>
</requestHandler>
[solr net][1]
[solr interface][2]
[1]: https://i.stack.imgur.com/uj4vE.png
[2]: https://i.stack.imgur.com/jLL8w.png