-->

Including multi-word stopwords in Solr

2019-09-07 03:23发布

问题:

Is it possible to include multi-word stopwords in stopfilterfactory of Solr? If yes, kindly tell me the way.

Right now first I am putting all the multiple-word stopwords in synonyms.txt file and then using one synonym for all these words in stopwords.txt, but its not working.

回答1:

I give a try this kind of a syntax

stopwords.txt

stop word
more long stop word

and it looks like it working. Check out my test case here - https://github.com/MysterionRise/information-retrieval-adventure/blob/master/lucene5/src/main/scala/org/mystic/SynonymsAndStopwords.scala