Skip to main content
Interactive 3D/Hybrid Search: Dense + Sparse Retrieval
Controls
Query Type
BM25 Weight0.50
dense onlybm25 only
Dense weight: 0.50
RRF k constant60
1100
Higher k → less aggressive rank fusion
Display
Result Source
BM25 only
Dense only
Both (best)
RRF (Reciprocal Rank Fusion) combines ranked lists without needing score normalization. score = 1/(k+rank_bm25) + 1/(k+rank_dense).

Hybrid Search: Dense + Sparse Retrieval - Interactive Visualization

BM25 excels at exact keyword matches but misses semantic meaning. Dense embedding search understands semantics but fails on rare terms and proper nouns. Hybrid search combines both via Reciprocal Rank Fusion (RRF), consistently outperforming either alone. This demo shows which results come from each method and how RRF merges the rankings.

  • BM25 results: exact term frequency and inverse document frequency scoring shown per result
  • Dense retrieval results: cosine similarity to query embedding ranked separately
  • RRF merging: 1/(k + rank) scores from both lists summed and re-sorted into final ranking
  • Unique hits: results that only BM25 or only dense retrieval finds, highlighted in the merge

Part of the EngineersOfAI Interactive 3D - free interactive visualizations covering every major concept in machine learning and AI engineering. Hover any element for a plain-English explanation. No code required.