#community-help

Order and Meaning in Returned Highlight Fields

TLDR SamHendley was unclear about the order of returned highlight fields. Jason clarified that fields with better matches show up earlier and that they will switch to the highlight object soon.

Powered by Struct AI
6
10mo
Solved
Join the chat
Nov 17, 2022 (10 months ago)
SamHendley
Photo of md5-a9a351e11d64f05b41fec183816a0cda
SamHendley
07:58 PM
Is there any meaning in the order of highlight fields returned? They seem to change order from run to run (though that might be a change in 0.24.0.rcn34).
Jason
Photo of md5-8813087cccc512313602b6d9f9ece19f
Jason
08:23 PM
Do you mean the highlight key or the highlights (plural) key?
SamHendley
Photo of md5-a9a351e11d64f05b41fec183816a0cda
SamHendley
08:24 PM
Sorry the highlights returned with a search
Jason
Photo of md5-8813087cccc512313602b6d9f9ece19f
Jason
08:24 PM
If it’s the latter, the fields that have a better match show up earlier in the highlights array
08:24
Jason
08:24 PM
We’ll eventually be switching to the highlight object, since that’s the new structure that supported nested fields
SamHendley
Photo of md5-a9a351e11d64f05b41fec183816a0cda
SamHendley
08:25 PM
👍