I want to use the same option in solr for multi keyword. But this does not work right
I have set the synonym "multi word" in the synonym.txt for "multerm". And I hope the solar "field:" creates query-phrases for multi-word "~ 0" but "multitrum" like "field: multi". Area:. Duration "then it can not find intimacy for multi-term synonyms
The best way to search multi-term options in any one Solr please help me please <~
Here's how I handle multi-word synonyms in my schema.xml, like the fieldType definition:
& lt; filter class = "solr.SynonymFilterFactory" Synonyms = "synonyms.txt" ignoreCase = "true" of extension = "true" tokenizer = "solr.keywordtookenfactory" /> gt; & lt; FieldType name = "custom" _text_general "class =" solr.TextField "positionIncrementGap =" 100 "& gt; & lt; Analyzer Type =" Index "& gt; & lt; tokenizer class =" solr.StandardTokenizerFactory "/> gt; & lt; filter class = "Solr.StopFilterFactory" ignoreCase = "true" word = "stopwords.txt" enablePositionIncrements = "true" /> < Fi Lter class = "solr.LowerCaseFilterFactory" /> & Lt; Filter class = "solr.SnowballPorterFilterFactory" language = "English" /> & Lt; / Analyzer & gt; & Lt; Analyzer type = "query" & gt; & Lt; Tokenizer class = "solr.StandardTokenizerFactory" /> & Lt; Ignore filter class = "solr.StopFilterFactory" = "true" word = "stopwords.txt" enabledPosignIncreates = "true" /> & Lt ;! - We will use synonyms only at index time to keep the query intensively & lt; Ignore filter class = "solr.SynonymFilterFactory" synonyms = "synonyms.txt" = "true" detailed = "true" /> - & gt; & Lt; Filter class = "solr.LowerCaseFilterFactory" /> & Lt; Filter class = "solr.SnowballPorterFilterFactory" language = "English" /> & Lt; / Analyzer & gt; & Lt; / FieldType & gt; Note the couple of things:.
- I'm just using synonyms in index time, to keep questions fast
- I added KeywordTokenizerFactory, this whole field considers this as a token , And multi-word synonyms do not divide
- I have expanded = "true". If the extension is true, then synonyms for synonyms will be expanded for synonyms. If this is incorrect, then all the same synonyms will be less in the list first.
- The query timeline is commented on.
No comments:
Post a Comment