can i use IDF boost modifier without using IDF?

in my use case i’d like to have a custom mathematical expression telling manticore how to calculate result weights. in the text search queries i’d like to present few alternatives that should be ranked differently.

example:

select *,weight() from tab where match(' ( car^2 | automobile^0.1 ) blue* ') OPTION ranker=expr('....');

at the same time i do not want to use IDF weights which will depend on frequency of each term across the whole index. in my ordering - no matter if word car is very common or very rare - result having text ‘car blue’ should be always ranked above ‘automobile blue’.

can this be done with custom ranking expression?

thank you!

It’s not possible currently with the OOTB syntax. The IDF boost modifier ^ is used only with IDF.

However it may be done with help of a custom ranking plugin - Manticore Search Manual: Extensions > UDFs and Plugins > Plugins > Ranker plugins

thank you for the answer!