> ## Documentation Index
> Fetch the complete documentation index at: https://docs.peec.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# How AI search chooses passages — retrieval, reranking, generation

> Peec's reranker guide (Aug 2026) — AI answers run query fan-out, hybrid retrieval merged with RRF, a reranker sieve, then generation; each stage fails differently, so diagnose the stage first.

AI search picks sources through a pipeline, and each stage fails differently. Peec's reranker guide ([full guide](https://peec.ai/blog/rerankers-for-geo-aeo-how-ai-search-chooses-passages-and-sources), Aug 2026) describes the common documented pattern:

1. **Query planning:** the prompt is rewritten and split into several searches — see [What is a query fan-out](/research/what-is-a-query-fanout).
2. **Retrieval (wide net):** keyword search (BM25) and vector search run together; result lists merge via Reciprocal Rank Fusion, rewarding documents that rank well in both. OpenAI's documented File Search works this way (800-token chunks, 400 overlap, hybrid search, optional reranker).
3. **Reranking (fine sieve):** a cross-encoder-style model reads each candidate passage against the query and re-scores the shortlist. Your page is often scored as *passages*, not one URL — a strong page can contain a weak candidate passage, which is why page-level SEO metrics cannot explain every citation win or loss.
4. **Generation:** the LLM writes from the surviving passages and may cite some.

The diagnostic rule (Aug 2026): **not retrieved** → indexing, coverage, authority, or freshness problem; **retrieved but losing** → answer shape or passage relevance; **strong passage but no citation** → source quality, diversity rules, or generation-stage behavior. Fix the failed stage first — rewriting a paragraph for the reranker cannot fix a page that was never retrieved. What to actually write once diagnosed: [Answer shape for AI citations](/research/answer-shape-for-ai-citations).

**Source:** [Rerankers for GEO/AEO: How AI search chooses passages and sources](https://peec.ai/blog/rerankers-for-geo-aeo-how-ai-search-chooses-passages-and-sources), Peec (Metehan Yesilyurt), Aug 2026.
