Right now it returns matched text between <em> tags. Instead would it be possible to return it as start and end postion value pairs in a given field. We can convert the current output in that format but wanted to know if there are customization options in the service itself.
We are finding that consuming the current format is not very useful (<em> means italics, we want to show matched text in bold and in different color) and quite heavy to render (having html controls rather than native). We are currently looking to parse the string and finding start/end index manually which beats the purpose of the highlighting feature.
You can specify highlightPreTag and highlightPostTag in a search query to customize the tags. Please see the documentation below for more details.
How do we specify the hit highlight length? The search text returned is too much.