Retrieval quality · about 20 minutes of study

Reranking

A reranker scores a smaller candidate set against the query to improve ordering after retrieval. Better ordering can improve evidence quality, at additional compute cost.

Before you start: Review Hybrid search first. Python-like examples use variables, lists and functions.

Guided concept walkthrough

Follow the mechanism

Retrieve

Build a broad candidate set.

1 / 4

A conceptual animation, not a live model trace. Play advances every five seconds and stops at the final stage.

Start with an everyday explanation

A librarian first brings twenty possible books, then reads their summaries with your question to choose the best three.

See a concrete example

If retrieval takes 30 ms and reranking adds 60 ms in a hypothetical workload, pre-generation latency rises from 30 to 90 ms. Quality improvement must justify that budget.

A claim to question

A cross-encoder is not always faster or better for every domain and candidate set.

Try before revealing the answer

Choose between reranking 20 and 100 candidates under a 150 ms retrieval budget. State what you must measure.

Show the worked answer

Measure recall of each candidate set, reranker batch latency, final answer quality and p95/p99 under load. Do not select solely from average single-request timings.

Now explain the idea to someone else using your own example. If you cannot explain a stage, revisit it before moving on.

Your explanation and revision notes

Loading local notes…

Read the primary reference

Sentence-BERT: bi-encoder and cross-encoder comparison

The explanation and exercises are original teaching material. The linked source provides background; examples and assumed numbers here are not claims about a particular company.