Can ES use position in array to give better score?

For array fields, how can I boost scores based on position in the array?

For example,

['a', 'b', 'c', 'd']
['b', 'c', 'a', 'd']
['d', 'a', 'c', 'b']

If I search for 'a', ES would return:

[ 'a', 'b', 'c', 'd'] < --- highest score
[ 'd', 'a', 'c', 'b']
[ 'b', 'c', 'a', 'd'] < --- lowest score

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