We are using relevance tuning to enhance various search fields. We have a text type field, made up of several arrays of charts. In this case, we can enhance or reduce the weight of the search when one of the elements of the array is "inoffer", both positively and negatively.
To do the test, we can lower the score of a product when it is on sale, which is perfect, it works as we expected.
We have the problem in the next field, "priority" of type number. This contains the priority of a product. The priority values go from -99 to 100. What we want is that when the priority is -99, apply a negative boots to obtain less score. No matter what type of WEIGHT set, the score is never modified. We have even tried changing the priority to text. Nothing works, neither positive nor negative.
The only way for this field to affect the score is to use a function, but what we want is to apply a specific value.
We have done one more test, we have a name field of type text that contains the name of the product. In this case when there is a match with the name, a positive weight causes a higher score, but a negative weight has no effect on the score. Does not matter if we enable or not the search this field
I do see that we don't state that explicitly in the boosts guide, and we have a known issue that the UI allows you to enter in negative numbers. Sorry for the confusion, we're on it.
However, even without negative boosts, I think you could accomplish what you want. Perhaps an Exponential Proximity boost on your priority field would do the trick?
Same known issue, I'm afraid. Legal weights are between 1 and 10. No negatives.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.