CourseAI System Design: The Complete Course · Module 6: Retrieval Architecture · part 41 of 107
Part 41 · Module 6: Retrieval Architecture

Lesson 1: Retrieval's core pipeline, decided by the numbers

31 min read·
Module 6 · Lesson 1 · About 55 minutes · Needs: Module 3 lesson 3 (vector index sizing), Module 3 lesson 5 (the latency budget) and Module 5 lesson 1 (ingestion)

The situation

Week 6, Monday 7 December 2026. Retrieval decides what Ask's model sees. A Tallis employee, t-tallis-u035, asks golden question G028: "How many days of annual leave do I get?" The right document is the 2026 policy, t-tallis-d002: 30 days. Its superseded 2025 twin, t-tallis-d001, says 29. Gareth wants every stage of the retrieval hop justified by a number, inside its 280 ms (Module 3 lesson 5).

Six stages inside 280 ms Ask's retrieval hop for G028 Active flow Background or async 1 Processing step number Client question G028 Retrieval Pipeline, 280 ms at p95 embed section 3 vector BM25 fuse section 5 rerank section 6 Prompt top 3 to prompt 1 2 3 4 5 Built offline (Ingestion) FAISS, rank_bm25 chunks section 2 store section 4
Ask's retrieval hop has 280 ms at p95 (Module 3 lesson 5) to turn Tallis's question (green, user text) into three chunks for the prompt, and six decisions shape the stages inside it: chunks and store are built offline (dashed), the blue stages run on every question. Numbers give the order.

The rest of this course is yours to keep

This course is bought on its own, once, and stays readable afterwards, including the parts added to it later.

Or open everything with a plan