A Cosmos DB system function, used with ORDER BY RANK, that merges the rankings from VectorDistance and FullTextScore, with optional weights, to give hybrid search results.
Also called Reciprocal Rank Fusion.
Read more: Microsoft Learn
In the Ultra Transcenders books
Each book explains RRF in context, with comparison tables and the common traps.
Terms in this definition
- Cosmos DB
NoSQL database distributed globally, offering writes in multiple regions, automatic indexing and latency below 10 ms.
- Chat message roles
Labels on chat messages: instructions go under system, the person's input under user, the model's previous answers under assistant, and results returned by a called tool under tool (or function).
- FUNCTION
Registered models count as functions in Unity Catalog, so this securable type governs them too: access is given through
GRANT ... ON FUNCTION, and REST calls passFUNCTIONassecurable_type. - ORDER BY
Sorts what a SQL query returns on one or more columns. Leave it out and rows arrive in no guaranteed sequence.
- RANK
A window function, found in T-SQL (used with OVER) and in DAX, that gives each row's position within its partition. In DAX it accepts ORDERBY and PARTITIONBY, skips ranks after ties unless DENSE is chosen, and returns blank for total rows.
- Model parameters
The weights a model learns in training, which together hold what it knows. How many there are is what distinguishes a small language model from a large one.
- Hybrid search
One Azure AI Search request that performs vector and full-text search side by side and combines the results through Reciprocal Rank Fusion. Adding the semantic ranker yields the best relevance overall.
Related terms
- Hybrid search
Set
query_type="hybrid"in AI Search to run keyword and vector matching together, with Reciprocal Rank Fusion producing the final order. Expect a 200-result ceiling and roughly four times the resource use of ANN. - Hybrid search in T-SQL
Combines keyword and meaning-based results by running a vector search alongside a full-text query (CONTAINSTABLE or FREETEXTTABLE) on the same data, then merging the two rankings, usually with Reciprocal Rank Fusion.
- RRF
Reciprocal Rank Fusion: how a hybrid query in AI Search turns separate full-text and ANN lists into a single order, using an
rrf_paramof 60.