2-phase sorting/bucketed sorting

Hi,

i need to do the following, but i've no idea where to hook in.

I'm sorting results using a custom native plugin (weighting various attributes and ranking criteria like document age, keyword relevancy, geo info, etc). That works great.

However, the issue is that we have "contributors" and we'd like to somewhat mix the results, such that every contributor within the result set gets a fair space, while respecting the calculated score of the native plugin and without having clusters (mass of items of same contributor next to each other).

So, i thought about a 2-phase sorting approach. 1st-phase builds up a sorted bucket for every contributor (probably size limited respecting from/size) and in a 2nd-phase it picks up results from these buckets, each with a certain probability. 1-phase could be done in the native plugin, but i've no idea how to get ES to do a 2-nd phase.

Maybe you know where to hook in or how to solve this using a completly different approach.

Thanks in advance
Benjamin

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.