Hybrid Search

Definition

Hybrid search combines two or more retrieval signals — most commonly sparse (lexical/term-based) and dense (semantic/embedding-based) — to produce results that outperform either approach alone.

The intuition: sparse retrieval excels at exact keyword matching; dense retrieval excels at semantic understanding. Their failure modes are largely complementary.

Why Combine?

Retrieval TypeStrengthsWeaknesses
Sparse (BM25/SPLADE)Exact terms, proper nouns, codesVocabulary mismatch, no synonyms
Dense (Bi-Encoder)Semantics, paraphrases, intentWeak on rare terms, slower
HybridBest of bothMore complex, harder to tune

Fusion Strategies

Reciprocal Rank Fusion (RRF)

Most common, parameter-free:

RRF_score(d) = Σ 1 / (k + rank_i(d))

where k=60 is a constant that smooths rank differences.

Advantages: No score normalization needed, robust, no training required.

Linear Score Combination

final_score = α × sparse_score + (1 − α) × dense_score

Requires score normalization (scores from different systems aren’t comparable).

Re-ranking

Retrieve N candidates from each system → merge → re-rank with Cross-Encoder.

Common Implementations

SPLADE + Bi-Encoder

  • SPLADE for learned sparse retrieval (term expansion)
  • Bi-Encoder (e.g., sentence-transformers) for dense semantic
  • Fusion: RRF or learned combiner

BM25 + Dense

  • BM25 for lexical baseline (no ML required)
  • Dense encoder for semantic lift
  • Popular in production (Elasticsearch, OpenSearch)

Vespa Hybrid

Implementation in Elasticsearch

# Two-phase: BM25 + ELSER (sparse) or BM25 + dense
GET /products/_search
{
  "query": {
    "bool": {
      "should": [
        {"match": {"text": "query"}},           # BM25
        {"text_expansion": {                     # ELSER sparse
          "ml.tokens": {"model_id": ".elser_model_1", "model_text": "query"}
        }}
      ]
    }
  }
}

Wormhole Vectors as Hybrid Bridge

Trey Grainger’s Wormhole Vectors concept extends hybrid search by identifying vectors that bridge multiple retrieval spaces (sparse, dense, behavioral). A document traverses from one space to another through these “wormhole” connections.

People

Semantic Boosting

Semantic Boosting is a two-phase alternative to RRF/RSF fusion: run vector search first, inject the results as boost clauses into a final lexical query. The output comes entirely from the lexical engine, so faceting, highlighting, and pagination work natively without extra merging.