Retrieval-Augmented GenerationRAGRAG Interview Concepts

What is hybrid retrieval?

Hybrid retrieval combines dense semantic search and sparse keyword search so the system can benefit from both meaning-based matching and exact term matching.

Instead of asking "Should I use vectors or BM25?", hybrid retrieval says: use both, then combine the results.

Why combine them?

Dense retrieval is good at meaning.

Example:

Query: "How can I get my money back?"

Document: "Customers may request a refund within 30 days."

Even though the wording differs, embeddings can match the meaning.

Sparse retrieval is good at exact terms.

Example:

Query: "ERR_AUTH_401"

A BM25-style retriever can quickly find documents containing that exact error code.

Hybrid retrieval helps when your users ask both kinds of questions.

Typical flow

User query ↓ Run dense retrieval ↓ Run sparse retrieval ↓ Combine the two result lists ↓ Optional reranking ↓ Send best chunks to the LLM

For example:

Dense results:

  1. Chunk A
  2. Chunk C
  3. Chunk D

Sparse results:

  1. Chunk B
  2. Chunk A
  3. Chunk E

The system then fuses these rankings into one final list.

How are the results combined?

Common approaches include:

  • Reciprocal Rank Fusion (RRF)
  • Weighted score fusion
  • Relative score normalization
  • Rank-based fusion
  • Reranking after combining candidates

The important point is that dense and sparse systems often produce scores on different scales, so blindly adding raw scores is usually not ideal.

That is why rank-based methods such as RRF are popular.

Example

Suppose the query is:

"How do I fix ERR_AUTH_401 when login tokens expire?"

Dense retrieval may find:

"Authentication failures can happen when access tokens are no longer valid."

Sparse retrieval may find:

"ERR_AUTH_401: token expired."

The sparse result catches the exact error code, while the dense result captures the broader meaning.

Together they give the system stronger evidence than either retriever alone.

Does hybrid retrieval always improve results?

Not automatically.

It adds:

  • More retrieval work
  • More latency
  • More tuning
  • A fusion step

If dense retrieval already performs extremely well for your dataset, the extra complexity may not be worth it.

Use hybrid retrieval when evaluation shows that semantic search misses important exact matches or lexical search misses paraphrased questions.

Interview takeaway

Hybrid retrieval combines dense vector search with sparse lexical search such as BM25. Dense retrieval captures semantic meaning, while sparse retrieval captures exact words, identifiers, and rare terms. Their result lists are fused, often followed by reranking, to improve retrieval robustness.

#what is hybrid retrieval#hybrid retrieval RAG#BM25 vector search hybrid#dense sparse retrieval combination#RAG hybrid search#rag#hybrid-retrieval#dense-retrieval#sparse-retrieval#bm25

Learning Sequence

Retrieval-Augmented Generation Curriculum

37% Completed
Up NextRAG

If you are using BM25 + vector search, how do you combine the results?

Explore Related Questions

Deepen your understanding across related Retrieval-Augmented Generation topics.

Machinoai Logo
Machinoai

Your edge in the AI era. Deep dives into machine learning concepts, paper explainers, verified industry jobs, and developer tools.

© 2026 Machinoai. All rights reserved.