给solr加spell check
来源:互联网 发布:mysql unique查询 编辑:程序博客网 时间:2024/05/19 23:16
在schema.xml中添加如下内容:
<!-- A copied field for spellcheck. As it has the same stuff as the above _text_, you can use the _text_ for spellcheck in this case. But creating another dedicated copied field for spellcheck has more flexibility. -->
<field name="spell" type="text_general" indexed="true" stored="false" multiValued="true"/>
<copyField source="*" dest="spell"/>
同时在solrconfig.xml的<searchComponent name="spellcheck" class="solr.SpellCheckComponent"></searchComponent>中添加一下内容
<lst name="spellchecker">
<str name="name">indexbasedchecker</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>
- 给solr加spell check
- [solr] - spell check
- [solr] - spell check
- Spell Check
- spell check investigation
- solr spell拼写检查
- Peter Novig Spell Check http://norvig.com/spell-correct.html
- POJ 1035 Spell Check 字符串处理
- VIM学习笔记 拼写检查(Spell Check)
- vim Linux environment cannot add words for spell check
- Visual Assist X设置-去除spell check错误的下划线
- listView加check box 问题
- onsubmit="return check() 给form加onsubmit 验证所有表单后再提交,可以用返回false 来阻止submit提交
- 给LISTVIEW加背景图
- 送信给加西亚
- 给网站加搜索引擎
- 给网站加搜索引擎
- 给网页加背景音乐
- 页面渲染
- 为什么HDFS一个块的大小是64MB
- C++primer习题答案中关于迭代器使用的一个错误
- HIVE 调优方法大全
- 黑马程序员--JAVA中的多线程
- 给solr加spell check
- 用HttpClient下载img
- Android&iOS崩溃堆栈上报
- RPM 打包技术与典型 SPEC 文件分析
- Android Studio在Ubuntu14.04下的安装与测试
- Codevs 无限网络发射器选址
- 30多条mysql数据库优化方法,千万级数据库记录查询轻松解决
- navTabPageBreak注意事项以及调试步骤
- 怎么解决alm跑条问题