liveBook · Manning

Hybrid search

As explained in Context Engineering

Hybrid retrieval combines keyword-based and semantic retrieval to find relevant information.

Hybrid search combines sparse keyword retrieval with dense embedding-based retrieval. It balances exact-term precision with semantic recall, making it useful for heterogeneous corpora containing both reference data and descriptive content. section 3.2.4

Rank fusion in hybrid RAG

Reciprocal rank fusion (RRF) combines lexical and vector result lists using their positions, so scores from different backends do not need calibration. A document ranked highly by both lists can outrank one ranked first in only one list. section 3.4

Dense-and-sparse fusion pairs embedding search with BM25 lexical ranking. Such retrieval workflows are typically static; complex multi-step goals or ambiguous questions motivate systems that choose retrieval tools dynamically. section 3.4

How Context Engineering covers it

How deep it goes
Defines sparse and dense retrieval, describes their fusion with BM25, and explains rank fusion without detailing implementation code.
Examples
Pairs embedding search with BM25 and illustrates fusion through RRF rankings across lexical and vector results.
What you can do after
Configure hybrid RAG by pairing embedding search with BM25 and fusing ranked results with RRF.
How it connects
Connects sparse retrieval, dense retrieval, BM25, reciprocal rank fusion, RAG, and agentic RAG.

Also explained in

Compare how 15 books explain hybrid search →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Context Engineering. The section links point to the parts of the book it draws on.