Evaluate ranked search results Added in 6.2.0
Evaluate the quality of ranked search results over a set of typical search queries.
Path parameters
-
Comma-separated list of data streams, indices, and index aliases used to limit the request. Wildcard (
*
) expressions are supported. To target all data streams and indices in a cluster, omit this parameter or use_all
or*
.
Query parameters
-
allow_no_indices boolean
If
false
, the request returns an error if any wildcard expression, index alias, or_all
value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targetingfoo*,bar*
returns an error if an index starts withfoo
but no index starts withbar
. -
expand_wildcards string | array[string]
Whether to expand wildcard expression to concrete indices that are open, closed or both.
-
search_type string
Search operation type
GET /{index}/_rank_eval
curl \
-X GET http://api.example.com/{index}/_rank_eval \
-H "Content-Type: application/json" \
-d '{"requests":[{"id":"string","request":{"query":{},"size":42.0},"ratings":[{"_id":"string","_index":"string","rating":42.0}],"template_id":"string","params":{"additionalProperty1":{},"additionalProperty2":{}}}],"metric":{"":{"k":42.0,"maximum_relevance":42.0}}}'