text_general field tweak

This commit is contained in:
www
2020-12-12 10:14:36 +00:00
parent a5bf374b42
commit a1fd039712

View File

@@ -286,6 +286,15 @@
</analyzer> </analyzer>
</fieldType> </fieldType>
<dynamicField name="*_tkn" type="text_tkn" indexed="true" stored="true"/>
<fieldType name="text_tkn" class="solr.TextField" positionIncrementGap="100">
<analyzer>
<tokenizer class="solr.StandardTokenizerFactory"/>
<filter class="solr.LowerCaseFilterFactory"/>
</analyzer>
</fieldType>
<!-- A general text field that has reasonable, generic <!-- A general text field that has reasonable, generic
cross-language defaults: it tokenizes with StandardTokenizer, cross-language defaults: it tokenizes with StandardTokenizer,
removes stop words from case-insensitive "stopwords.txt" removes stop words from case-insensitive "stopwords.txt"
@@ -294,7 +303,7 @@
--> -->
<fieldType name="text_general" class="solr.TextField" positionIncrementGap="100" multiValued="true"> <fieldType name="text_general" class="solr.TextField" positionIncrementGap="100" multiValued="true">
<analyzer type="index"> <analyzer type="index">
<tokenizer class="solr.NGramTokenizerFactory" minGramSize="3" maxGramSize="7" /> <tokenizer class="solr.NGramTokenizerFactory" minGramSize="3" maxGramSize="17" />
<filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" /> <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" />
<!-- in this example, we will only use synonyms at query time <!-- in this example, we will only use synonyms at query time
<filter class="solr.SynonymGraphFilterFactory" synonyms="index_synonyms.txt" ignoreCase="true" expand="false"/> <filter class="solr.SynonymGraphFilterFactory" synonyms="index_synonyms.txt" ignoreCase="true" expand="false"/>
@@ -303,9 +312,10 @@
<filter class="solr.LowerCaseFilterFactory"/> <filter class="solr.LowerCaseFilterFactory"/>
</analyzer> </analyzer>
<analyzer type="query"> <analyzer type="query">
<tokenizer class="solr.NGramTokenizerFactory" minGramSize="3" maxGramSize="7"/> <tokenizer class="solr.NGramTokenizerFactory" minGramSize="3" maxGramSize="17"/>
<filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" /> <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" />
<filter class="solr.SynonymGraphFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/> <filter class="solr.SynonymGraphFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
<filter class="solr.FlattenGraphFilterFactory"/>
<filter class="solr.LowerCaseFilterFactory"/> <filter class="solr.LowerCaseFilterFactory"/>
</analyzer> </analyzer>
</fieldType> </fieldType>