Prioritizing search results in Solr that start with the search string

2020-02-09 Thread Yirmiyahu Fischer
Posted a bounty on the question https://stackoverflow.com/questions/59811749/prioritizing-search-results-in-solr-that-start-with-the-search-string Would appreciate some input.

Re: Prioritizing search results in Solr that start with the search string

2020-02-09 Thread Erick Erickson
Have you thought about EdgeNgramTokenFilter? You’d have to use KeywordTokenizer on a text type rather than a string. The idea would be to enforce some reasonable length limit on the input, say 16 characters (straw man). This is on the _index_ side. Then for querying, do not use EdgeNgramTokenFi

Re: Solr Analyzer : Filter to drop tokens based on some logic which needs access to adjacent tokens

2020-02-09 Thread Emir Arnautović
Hi Pratik, You might be able to do some of required things using PatternReplaceChartFilter, but as you can see it does not operate on tokens level but input string. Your best bet is custom token filter. Not sure how familiar you are with how token filters work, but you have access to tokens fro