# What is reranking in search and RAG?

> Reranking reorders the top results of a first search with a more precise model. In Anthropic's tests, it helped cut retrieval failures by 67%.

Canonical: https://promptlyfound.com/glossary/reranking
Updated: 2026-11-20

## Short answer

Reranking is **a second retrieval step that puts the first results in a new order with a more precise model**. A fast first search returns a list of candidates, and a slower model scores each candidate against the query. A reranker can only reorder what the first search found, so a page has to reach the candidate list before reranking can help it.

## Key findings

- Microsoft's semantic ranker in Azure AI Search reranks only the top 50 results of the first search. Microsoft says it cannot rerun the query over the entire index. [1]
- Microsoft says the semantic ranker uses multilingual deep learning models adapted from Microsoft Bing. [1]
- In Anthropic's tests, reranking the top 150 retrieved chunks down to 20, on top of contextual embeddings and contextual BM25, cut the top-20 retrieval failure rate by 67%, from 5.7% to 1.9%. [2]
- A BERT model used to rerank passages took the top place on the MS MARCO passage retrieval leaderboard, 27% better (relative) in MRR@10 than the previous best system. [3]

A reranker decides which retrieved passages a language model reads, and it can only reorder what the first search found. In Anthropic's tests, adding reranking to its contextual retrieval method cut the share of relevant chunks missing from the top 20 from 5.7% to 1.9%.

Reranking is a second step in a search system. The first step searches the whole index quickly and returns a list of candidates. The second step scores each candidate again with a slower, more precise model and puts the list in a new order.

## How reranking works

[Anthropic's post on Contextual Retrieval](https://www.anthropic.com/news/contextual-retrieval) lists the steps. The system retrieves the top candidate chunks (Anthropic used 150), passes each one with the user's query through a reranking model, scores each chunk for relevance, and keeps the top results (Anthropic kept 20). Only those reach the language model. Anthropic says reranking adds latency because it is an extra step at run time.[2]

[Microsoft's documentation of semantic ranking in Azure AI Search](https://learn.microsoft.com/en-us/azure/search/semantic-search-overview) describes the same design. The first ranking comes from BM25 keyword scoring or from Reciprocal Rank Fusion over a hybrid search. The semantic ranker then rescores the top 50 results with multilingual deep learning models adapted from Microsoft Bing. Each result gets a score from 4 (highly relevant) to 0 (irrelevant).[1]

Developer tools expose the same step. [OpenAI's retrieval guide](https://developers.openai.com/api/docs/guides/retrieval) lets file search set a `ranker` and a `score_threshold`, and a higher threshold limits results to more relevant chunks.[4]

The approach has a research record. [Passage re-ranking with BERT](https://arxiv.org/abs/1901.04085), published in January 2019, used BERT to rerank passages for a query. It took the top place on the MS MARCO passage retrieval leaderboard, 27% better (relative) in MRR@10 than the previous best system.[3]

## Reranking in AI search

Retrieval-augmented generation passes only a few retrieved passages to the model, so the reranker decides which candidates the model reads. In Anthropic's tests, adding reranking to contextual embeddings and contextual BM25 cut the share of relevant chunks missing from the top 20 from 5.7% to 1.9%, a 67% reduction.[2] [What is retrieval-augmented generation (RAG)?](https://promptlyfound.com/ai-search/rag) covers the full pipeline.

AI search products publish less detail. [Google's guide to generative AI features](https://developers.google.com/search/docs/fundamentals/ai-optimization-guide) says they rely on its core Search ranking systems to retrieve pages from its index, and does not describe a separate reranking step.[5] Microsoft says the technology in its semantic ranker comes from Bing.[1]

## What it means for a page

Microsoft says its semantic ranker cannot find results outside the initial set.[1] So a page has to be retrieved by the first search, through its keywords or its meaning, before a reranker can move it up. [What is semantic search?](https://promptlyfound.com/ai-search/semantic-search) explains how the first search matches pages.

Microsoft also says the semantic ranker works best on content that is information-rich and written as prose, and that it extracts captions and answers verbatim. If the results contain no answer-like text, it produces no answer.[1] [How to write content that AI search can cite](https://promptlyfound.com/geo/content-for-ai-citations) covers how to write passages that answer a question directly.

## Sources

1. Semantic ranking in Foundry IQ (Azure AI Search). Microsoft Learn. https://learn.microsoft.com/en-us/azure/search/semantic-search-overview
2. Introducing Contextual Retrieval. Anthropic, 2024-09-19. https://www.anthropic.com/news/contextual-retrieval
3. Passage re-ranking with BERT. arXiv, 2019-01-13. https://arxiv.org/abs/1901.04085
4. Retrieval. OpenAI API documentation. https://developers.openai.com/api/docs/guides/retrieval
5. Optimizing your website for generative AI features on Google Search. Google Search Central, 2026-07-10. https://developers.google.com/search/docs/fundamentals/ai-optimization-guide

---

This is a plain-text copy of https://promptlyfound.com/glossary/reranking from Promptly Found. The web page is the canonical version and includes the charts.
