1. config schema.xml
<fieldtype name="text_ch" class="solr.TextField"> <analyzer type="index"> <tokenizer class="org.lionsoul.jcseg.analyzer.JcsegTokenizerFactory" mode="complex"/> </analyzer> <analyzer type="query"> <tokenizer class="org.lionsoul.jcseg.analyzer.JcsegTokenizerFactory" mode="complex"/> <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/> </analyzer> </fieldtype>
2. modify synonyms.txt add synonyms what you wanted
电脑,笔记本,苹果 维修,修理,检修
Preferences
http://ju.outofmemory.cn/entry/100831
http://elastos.org/redmine/boards/22/topics/265