Domain 8: Retrieval-Augmented Generation & Knowledge Systems
Retrieval-augmented generation end to end: BM25 and analyzers, embeddings, document ingestion and chunking, vector databases, hybrid search, reranking and RAG evaluation.
Unlock all 8 lessons with Unrolled Pro
Full production code, quantitative capacity math, failure recovery playbooks, and interview coaching.
Lessons
8 lessonsRetrieval I — The Pipeline, the Inverted Index and BM25 from First Principles
Retrieval-augmented generation (RAG) is the pattern behind almost every assistant that answers from a company's own knowledge: search first, then let the model answer from what was found, citing it.
Retrieval II — Analyzers, Speed, Sharding, Permissions and Debugging
Lesson I built retrieval that works on a toy corpus.
Embeddings — Turning Meaning into Geometry
An embedding maps text to a vector so that texts with similar meaning land close together. That one idea fixes BM25's biggest weakness, powers semantic search and recommendations, and underlies every vector database.
Document Ingestion — From Messy Files to Clean, Retrievable Chunks
"Garbage in, garbage out" is truer for RAG than almost anywhere else. If a navigation menu gets indexed, it matches every query. If a fact is split across two chunks, neither chunk answers the question.
Vector Databases — Finding Nearest Neighbours Among Millions
Finding the nearest vectors exactly means comparing the query with every stored vector. That's fine for thousands of vectors and hopeless for hundreds of millions.
Advanced RAG — Hybrid Search, Reranking, Context and Citations
"Basic RAG" — embed the question, take the top 5 chunks, generate — is a demo, not a product.
RAG Evaluation — Measuring Retrieval and Answers Separately
A wrong RAG answer has two possible causes: retrieval never found the right passage, or the model had it and still got the answer wrong.
Bridge: From Answering Questions to Taking Actions
Atlas can now find the right passage and answer from it, with citations and measured quality. But students don't only ask questions.