Hi!
I have an index that contains a nested object:
"links_to_asset": {
"type": "nested",
"properties": {
"note_link_id": {
"type": "long"
},
"user_id": {
"type": "long"
},
"to_asset": {
"type": "integer"
},
"from_asset": {
"type": "integer"
}
}
}
I'm using the nested object to track the number of assets that linking to an asset.
I would like to use the number of links to an asset is the scoring for the search results.
As an example, in the search object, I have:
should: [
{
term: {
favourite: {
value: 1,
boost: 2
}
}
}
}
Here, an asset that is a favourite is given a boost.
Is it possible to use the number of links as a criteria for the search?