One technique that works well is to use copyField to end up with two indexed fields, one with synonyms, one without. Then you can qf=title^5 title_with_synonyms^1 with edismax and weight the “exacter” field higher than one with synonyms.
— Erik Hatcher, Senior Solutions Architect http://www.lucidworks.com <http://www.lucidworks.com/> > On Nov 30, 2015, at 8:36 PM, Brian Narsi <bnars...@gmail.com> wrote: > > I am using edismax with mm=1 and qs=6 > > I have a field type with synonyms attached to it. > A sample synonym is: > > toothbrush tbrush > > For the following data: > > 1) Phillips toothbrush > > 2) Oral-B tbrush > > 3) Phillips Sonicare toothbrush > > > If a user searches for > > q = tbrush > > I am getting > > 1), 3), 2) > > i.e. the one with exact synonym match is last > > If a user searches for > > q = toothbrush > > Result is > > 2), 1), 3) > > i.e. one with exact match is not first > > > So > > 1) I need the exact matches to be first and then the other matches (because > of being a synonym) > > 2) If a user searches for Phillips Sonicare toothbrush; I need the results > in the following order 3), 1), 2) i.e. most relevant results should be > higher > > What changes do I need to make in order to accomplish this? > > Thanks in advance,