Readonly documentThe document returned from the findAndRerank query.
If a projection was applied, this will reflect only the projected fields.
Readonly scoresThe set of scores used during the hybrid search and reranking process.
For collections, keys may include:
$vector: the score from the vector similarity search$lexical: the score from the lexical similarity search$reranker: the score from the reranking stepThis will be an empty object unless includeScores: true was set on the cursor.
Overview
Represents a single document returned from some generic
findAndRerankoperation on the Data API. This is the individual item type emitted by a FindAndRerankCursor.Each result contains:
includeScoreswas set on the cursor).Reranking
When hybrid search is performed using the
$hybridoperator, the Data API returns candidate documents based on vector and/or lexical similarity, before reranking them using a reranking model.If
includeScoreswas enabled when the cursor was created, then the scores from each stage of the ranking pipeline will be included in thescoresobject for every result.Example
See
FindAndRerankCursor