Tweaking BM25 parameters efficiently

(Adrien Ecoffet) #1

Hi all,

I am trying to tweak the parameters of the BM25 similarity module. I am
evaluating the quality of the results using an NDCG-like metric, and would
like to iterate through several values of k1 and b in order to find the
ones that maximize this score.

Unfortunately, because this is set at the index settings level, it is hard
to iterate through these values. Because my index is very large, I would
like to avoid having to reindex for each possible set of values (reindexing
time can take about an hour). I tried closing the index and updating the
settings, but it is unclear to me whether this is actually taking immediate
effect. Of course the ideal situation would be a query-time parameter.

Is there any efficient way to iterate through many possible BM25 parameter
values on a large index?

Thank you!

You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
To view this discussion on the web visit
For more options, visit

Passing varied parameters to BMI25 instead of 1 set
(system) #2