Skip to content
IJK

Retrieve-Then-Rerank: Bounding the Cost of Cross-Encoders

By IJK ·

What a Hugging Face post says the retrieve-then-rerank pattern is, why cross-encoders are not run over a full corpus and what it does to cost and ranking.

The common production pattern

Because cross-encoders are too expensive to run over a full corpus, the common production pattern is retrieve-then-rerank: a fast embedding model retrieves the top-K candidates (cheap), then a cross-encoder re-orders just those K with high accuracy. [1]

What it does to cost and ranking

The total cost stays bounded while the final ranking is much closer to what an exhaustive cross-encoder pass would produce. [2]

thensoA fast embedding model retrieves the top-KcandidatescheapA cross-encoder re-orders just those Kwith high accuracyTotal cost stays boundedranking close to an exhaustive cross-encoder pass
How does the pattern bound cost?

Sources

  1. The Hugging Face source says: Because cross-encoders are too expensive to run over a full corpus, the common production pattern is retrieve-then-rerank: a fast embedding model retrieves the top-K candidates (cheap), then a cross-encoder re-orders just those K with high accuracy. Introducing the Ettin Reranker Family
  2. The Hugging Face source says: The total cost stays bounded while the final ranking is much closer to what an exhaustive cross-encoder pass would produce. Introducing the Ettin Reranker Family

Editorial (AI-assisted; automatically checked, not human-reviewed). Each statement is linked to its source; check the source before relying on a detail.

  • reranker
  • retrieval
  • cross encoder
  • hugging face