Re: Flatten term frequency

2018-11-29 Thread Vincenzo D'Amore
Hi, an update: I've found another alternative while reading the valuable post written by Doug. In short, I should split the field "title" in two fields: title_notf and title_phrase. title_notf is without term frequency (with omitTermFreqAndPositions=true) for matching queries and title_phrase with

Re: Flatten term frequency

2018-11-29 Thread Vincenzo D'Amore
Yep, that makes sense. And given that an omitTermFreq parameter does not exist, if I use omitTermFreqAndPositions then phrase queries won't work. So it seems there are no chances, the only way is write own similarity class. On Thu, Nov 29, 2018 at 4:15 PM Alexandre Rafalovitch wrote: > You are t

Re: Flatten term frequency

2018-11-29 Thread Alexandre Rafalovitch
You are trying to use this in the field list, but the documentation only talks about this being valid in the query clause itself. Which perhaps makes it a bit less useful for your case, but does not look like a bug. Regards, Alex. On Thu, 29 Nov 2018 at 10:06, Vincenzo D'Amore wrote: > > Hi th

Re: Flatten term frequency

2018-11-29 Thread Vincenzo D'Amore
Hi thanks for your prompt reply :) I thought the constant score should be the easiest way, unexpectedly when I tried to specify constant score in qf field an exception has been raised. So I've configured the constant score into solrconfig.xml file : combiField edis

Re: Flatten term frequency

2018-11-29 Thread Doug Turnbull
I think the similarity way (setting k1 to 0) or a constant score query are probably the best ways. Omitting term freqs and position will also remove positions meaning phrase queries won’t work. This blog article might be useful for your use case. I discuss a similar prob. https://opensourceconnec

Re: Flatten term frequency

2018-11-29 Thread Alexandre Rafalovitch
Perhaps constant score would be useful here: http://lucene.apache.org/solr/guide/7_5/the-standard-query-parser.html#constant-score-with Also, all the options like omitTermFreqAndPositions are described here: http://lucene.apache.org/solr/guide/7_5/field-type-definitions-and-properties.html#field-

Flatten term frequency

2018-11-29 Thread Vincenzo D'Amore
Hi all, I have a relevancy problem, I suppose to know a solution for this problem but I would like to know if in your experience there is a better one. For example I have two documents which have the "termA" in their field "title", the former has the "termA" repeated more times but the latter has