Skip to content

RAG Reranking Pipeline

Purpose

The Reranking Pipeline describes the sequence of steps between primary search and response generation, where candidates from Vector Search or Hybrid Search are re-ordered by a more precise model.

Diagram

flowchart LR
    Q[Query] --> R1[Retrieval: top-100]
    R1 --> RR[Reranker: top-10]
    RR --> P[Prompt Assembly]
    P --> L[LLM]

Parameters

Parameter Purpose
top_k retrieval Number of primary search candidates
top_n rerank Number of documents after re-ranking
batch size Batch size for cross-encoder
timeout Time limit for the stage

Practice

See Also