Skip to content
Ask Sera Search
Ask SeraAnswers from our guides, research and news Search
Learn
Guides
Research
Sectors
Platforms
News
Tools
About

What is dense retrieval?

Dense retrieval finds passages by comparing embeddings of the query and each passage, so it can match text that uses other words for the same meaning.

In short. Dense retrieval is retrieval that compares embeddings of the query and of each passage, instead of matching their words. A model turns each text into a dense vector of numbers, and the system returns the passages whose vectors are closest to the query vector. It can find a passage that shares no words with the query. Keyword methods such as BM25 are called sparse retrieval.

On this page 7 sections

The evidence

  • Tested:

    A dense passage retriever that searched by embeddings alone outperformed a Lucene BM25 system by 9 to 19 percentage points in top-20 passage retrieval accuracy.1arXiv, Apr 10, 2020. EMNLP 2020

  • Observed:

    In the BEIR benchmark of 18 datasets, dense retrieval models were more efficient than reranking models but often performed worse on datasets they were not trained for.2arXiv, Apr 17, 2021

  • Confirmed:

    In OpenAI's example, the passage 'The first lunar landing occurred in July of 1969.' scored 0% keyword similarity and 65% semantic similarity with the query 'When did we go to the moon?'3OpenAI API documentation. Checked Dec 1, 2026

Confirmed by the platformTestedObserved in data

Dense retrieval is the embedding side of AI retrieval. It lets a system find a passage for a question even when the passage uses different words.

#How does dense retrieval work?

Dense retrieval compares vectors instead of words. The Dense Passage Retrieval paper uses a dual-encoder framework. One encoder turns questions into embeddings, and another turns passages into embeddings. The authors trained the encoders on a small number of questions and passages.1

A system embeds every passage in advance and stores the vectors, often in a vector database. At query time, it embeds the query and looks for the closest stored vectors. A similarity measure such as cosine similarity scores how close each one is.

Microsoft's page on relevance in Azure AI Search vector search describes two ways to find the closest vectors. Exhaustive k-nearest neighbors (KNN) scans the whole vector space. Hierarchical Navigable Small World (HNSW) runs an approximate nearest neighbor search over a graph, which is faster. A query parameter, k, sets how many nearest neighbors to return.4

#What is the difference between dense and sparse retrieval?

Sparse retrieval matches the words in the query, and dense retrieval matches meaning. The DPR paper calls sparse vector models such as TF-IDF and BM25 the standard method for passage retrieval in open-domain question answering.1

OpenAI's retrieval guide shows the difference with the query "When did we go to the moon?" The passage "The first lunar landing occurred in July of 1969." scored 0% keyword similarity and 65% semantic similarity. The passage "When I ate the moon cake, it was delicious." scored 40% keyword similarity and 28% semantic similarity. OpenAI computed semantic similarity as cosine similarity between text-embedding-3-small embeddings.3

Dense retrieval can miss exact matches. Anthropic's post on Contextual Retrieval gives the query "Error code TS-999" as an example. An embedding model might find content about error codes in general but miss the exact code, which BM25 finds.5 For this reason, many systems run both in hybrid search.

#How well does dense retrieval work?

Results depend on the data. The DPR paper reports that its dense retriever beat a strong Lucene BM25 system by 9 to 19 percentage points in top-20 passage retrieval accuracy, on a wide range of question answering datasets.1

The BEIR benchmark tested 10 retrieval systems on 18 public datasets that the models had not been trained on. BM25 was a strong baseline. Dense retrieval models were more efficient than reranking models but often performed worse than other approaches.2

Dense retrieval decides which passages match a question by meaning. A page can be retrieved for a question whose exact words it does not contain, if its text answers the same need. OpenAI says semantic search can surface results that share few or no keywords with the query.3

What are vector embeddings? explains how embeddings are made and compared. What is semantic search? compares search by meaning with keyword search.

Read next

Related terms

Questions

Why is it called dense retrieval?

The name contrasts dense representations, the embeddings that a model learns, with sparse vector models such as TF-IDF and BM25 that represent text by its words. The Dense Passage Retrieval paper uses these two terms.

Is dense retrieval the same as semantic search?

Yes, in most systems. Semantic search is the general idea of matching meaning, and dense retrieval is the common way to do it, with embeddings and a nearest-neighbor search. OpenAI describes its Retrieval API as semantic search over vector stores.

Is dense retrieval better than BM25?

It depends on the data. The Dense Passage Retrieval paper beat a BM25 system on question answering datasets. The BEIR benchmark found that BM25 held up well across 18 datasets and that dense models often did worse on data they were not trained for.

About this page

Researched and reviewed by Promptly Found. Reviewed Dec 1, 2026. Next review due Mar 2027.

Notes

  1. 1
    Dense Passage Retrieval for Open-Domain Question AnsweringarXiv · Apr 10, 2020 · Checked Dec 1, 2026 · Paper
  2. 2
  3. 3
    RetrievalOpenAI API documentation · Checked Dec 1, 2026 · Primary source
  4. 4
    Relevance in vector searchMicrosoft Learn · Checked Dec 1, 2026 · Primary source
  5. 5
    Introducing Contextual RetrievalAnthropic · Sep 19, 2024 · Checked Dec 1, 2026 · Primary source
Cite this page
Citation style

Promptly Found. (2026, December 1). What is dense retrieval? https://promptlyfound.com/glossary/dense-retrieval

Revisions 1
First published.