Solr 5.x Edge N-Gram过滤器从背面

时间:2015-08-18 11:37:42

标签: solr

我在Solr 5.x中遇到Edge N-Gram过滤器的问题。我想从后面拿n克。当我设置side =" back" solr core抛出错误。现在我正在使用N-Gram Filter。请建议。

由于 Shruti suri

1 个答案:

答案 0 :(得分:1)

属性方已被删除。 https://issues.apache.org/jira/browse/LUCENE-3907

EdgeNGramFilterFactory没有像这样的任何参数

它有两个参数

minGramSize: (integer, default 1) The minimum gram size.
maxGramSize: (integer, default 1) The maximum gram size.

请点击这里

https://cwiki.apache.org/confluence/display/solr/Filter+Descriptions#FilterDescriptions-EdgeN-GramFilter

但你可以在这里试试tokenizer

有选项

minGramSize: (integer, default is 1) The minimum n-gram size, must be > 0.
maxGramSize: (integer, default is 1) The maximum n-gram size, must be >= minGramSize.
side: ("front" or "back", default is "front") Whether to compute the n-grams from the beginning (front) of the text or from the end (back).

https://cwiki.apache.org/confluence/display/solr/Tokenizers#Tokenizers-EdgeN-GramTokenizer