What is MRR (Mean Reciprocal Rank)?

MRR (Mean Reciprocal Rank) is a ranking and retrieval metric averaging, over all queries, the reciprocal rank of the first relevant result; a first relevant result at rank one scores 1, at rank two 0.5.

Unlike Normalised Discounted Cumulative Gain, which weighs all relevant results by relevance and position, MRR looks only at the first relevant result. MRR therefore suits cases where one correct result usually suffices.

Topic
Evaluation and quality

How MRR (Mean Reciprocal Rank) works

  1. Relevant documents or chunks are labelled for each evaluation query.
  2. The system returns a ranked result list per query.
  3. The first relevant result's rank is found and inverted; with none in the top k, the score is zero.
  4. The average over all queries is MRR; MRR@10 means only the top 10 results count.

In more detail

The formula and sensitivity to the top ranks

MRR is the mean, over all queries, of the reciprocal rank of the first relevant result, with the term set to 0 if none appears within the cut-off k. This reciprocal curve is steep at the top: moving a hit from rank 2 to rank 1 adds 0.50 to its term, while moving from rank 10 to rank 5 adds only 0.10.

The binary relevance assumption, ties and suitable tasks

MRR assumes binary relevance (a result is either relevant or not) and evaluates a single answer per query. It is therefore well suited to navigational search, FAQ lookup and single-fact QA, but blind to whether a second or third supporting chunk was also retrieved or to ties in ranking scores unless tie-breaking is specified.

Unanswerable queries and companion metrics

In retrieval evaluation, reporting only a single aggregate MRR score across queries can hide regressions on tail queries or non-relevant queries where the ground truth has no answer (which are typically excluded or handled separately). Pairing MRR@10 with Recall@k, nDCG@10 and latency and throughput budgets gives a balanced view for reranker selection.

Commonly confused terms

TermHow it differs
MAP (mean average precision)MAP (Mean Average Precision) averages precision at every relevant document retrieved across the whole list, reflecting recall of multiple relevant items, whereas MRR stops measuring as soon as the very first relevant item appears.
Recall@k and hit rateRecall@k (or Hit Rate@k) measures whether relevant items appear within the top k regardless of whether they sit at rank 1 or rank k, whereas MRR@k heavily rewards placing the first relevant item at rank 1 (score 1.0) over rank 2 (0.5) or rank 10 (0.1).

Why MRR (Mean Reciprocal Rank) matters for on-premises AI

In RAG, the first few chunks in context shape answer quality; a lower-ranked relevant chunk is more likely missed. A database systems encyclopedia defines MRR as the average over queries of the reciprocal rank of the first correct answer. An early paper on language model passage reranking reports a 27% relative MRR@10 gain over the previous best on a large passage benchmark; the metric is common for comparing rerankers. Example calculation: if the first relevant results for three queries sit at ranks 1, 2 and 4, MRR is (1 + 0.5 + 0.25) divided by 3, about 0.58.

ON-PREMISES EXAMPLE

A publisher compares a new reranker for its editorial archive search with the old one by MRR@10 on validation queries, going live only if it improves.

Common questions

How does MRR differ from nDCG?

MRR looks only at the first relevant result's rank. nDCG weighs all relevant results by relevance and position.

When does MRR fall short?

When a query needs several relevant results, as in RAG questions answered from several chunks. Track metrics such as nDCG too.

Sources

In the glossary: Glossary, M to Q

What does this term mean for your infrastructure?

We can work out together in a technical assessment how it maps onto your data, hardware and security requirements.

Request a technical assessment →

This site sets no cookies. Visitor numbers are counted in aggregate using a cookieless method that does not identify anyone. See the Privacy Policy for details.