0

I want to include start and end offset of matched term in search query using elasticsearch.

I am currently using search-highlight plugin in elasticsearch to retrieve position of matched term in result.
However, I want to include the position of matched term in the query, too. For example with this document indexed: "fox", and with this query: "fox is a fox". The expected result of matched terms in query would be [0,3] and [9, 12].
Any help would be helpful!

0 Answers0