Back
advanced
Advanced RAG & Context

Re-ranking and Hybrid Search

Improve RAG retrieval quality by combining vector search, keyword search, and reranking

25 min read· RAG· Re-ranking· Hybrid Search· Retrieval

Re-ranking and Hybrid Search

Vector search is good, but not enough.

Hybrid search combines semantic similarity with keyword matching, then reranking chooses the best final evidence.

Retrieval stages

text
query -> dense search + keyword search -> merge -> rerank -> top context

Why hybrid helps

ProblemHybrid benefit
exact product nameskeyword search catches them
synonymsvector search catches meaning
acronymskeyword plus metadata helps
noisy top-kreranker improves ordering

Reranking

A reranker scores query-document pairs more carefully than the first retriever.

It is slower, so use it on the top 20-100 candidates, not the whole corpus.

Production tips

  • keep source diversity
  • filter by permissions first
  • log retrieval scores
  • evaluate recall before generation
  • tune top-k separately for search and rerank

Knowledge check

Q1: Why use reranking after retrieval?

The first retriever is fast; the reranker is more precise.

Q2: What does hybrid search combine?

Dense semantic retrieval and sparse keyword retrieval.