The Library Card: Retrieval
By the end you'll be able to
- Explain retrieval-augmented generation: find relevant passages, place them on the desk, answer from them.
- Explain why retrieval reduces — but does not eliminate — fabrication.
- Evaluate a cited answer by checking the passage actually supports the claim.
- Predict
- Retrieve
- Decide
- Field note
⚡ 30-second warm-up — From Lesson 2: why does a thinly covered topic get a confident-sounding answer anyway?
The model doesn't know it's guessing — thin data still produces a fluent, plausible-sounding pattern. Today's lesson gives it a way to answer from something other than that frozen diet.
Same question about your workplace's leave policy: one assistant invents a plausible answer, another quotes clause 4.2 correctly. Same model underneath — find out what changed.
Start with two answers
You ask two AI systems the same question about your organisation's leave policy. One produces a smooth, generic-sounding policy that isn't yours. The other quotes your actual handbook, clause and all. Both are built on similar underlying models.
Commit to a prediction
What did the second system do differently?
This lesson changes one thing: you'll stop treating "cited" as a synonym for "verified", and start seeing retrieval as look-it-up-then-answer — genuinely better, and still only as good as what was fetched and how faithfully it was summarised.
Discover the mechanism
Retrieval-augmented generation bolts a search step onto the pipeline. Your question is placed on the meaning-atlas (Lesson 7); the system finds stored passages sitting nearest to it — matching meaning, not just keywords; the top passages are loaded onto the desk (Lesson 10) alongside an instruction like "answer only from these sources"; then normal generation runs (Lesson 9).
The gains are real: current information beyond training day, private knowledge the model never saw (Lesson 2's gap, partly closed), and checkable citations. The limits are structural: if search fetches the wrong passages, the answer is confidently wrong with confident citations; if the passages don't fully answer, the model may blend quoted fact with plausible filler.
Retrieval moves the trust question — from "does the model know?" to "did the search find the right thing, and did the write-up stay faithful to it?"
real systems chunk documents, rank by hybrid keyword-and-meaning search, and increasingly treat live web search as retrieval over an uncurated library — mechanics this lesson's Go deeper opens up.Instead of answering from general education (training), they fetch the three most relevant pages, spread them on the desk, and write from those pages — able, now, to cite. The answer is only as good as the pages fetched and the honesty of the write-up.
- General education = trained weights. The library = your document store, or the live web.
- Fetching relevant pages = embedding-based search (Lesson 7's atlas at work). Spreading pages on the desk = injecting passages into context (Lesson 10).
- Where it breaks: a human assistant notices contradictions across whole documents; retrieval fetches fragments by similarity, which can miss a crucial clause on an unlike-sounding page — and a citation proves only that a passage was fetched, not that the sentence in front of you faithfully represents it.
Build a librarian yourself
Conceptual illustration — a 12-document toy policy library, deterministic. Question: "How many days of carer's leave do I get?" Toggle retrieval, choose how many passages to fetch, and try planting an outdated document.
Back to your Lesson 2 note
In Lesson 2 you wrote about the model's data diet and its gaps. Now: what changes when search is added? Retrieval doesn't erase the frozen diet — it adds a second, checkable source alongside it. The trust question moves from "was this in the diet?" to "was the right document fetched, and does the answer faithfully reflect it?" Worth returning to this again once Lesson 18 asks what a badly curated library can do to fairness.
Where this bites at work
Luka's grants workspace answers from each funder's current guidelines instead of pattern-memory — and his clients learn to click through citations after a real incident: an acquittal drafted against a superseded reporting template that was still sitting in the shared drive.
The fix wasn't distrusting the tool — it was curating the library and checking the citation's date, every time, on anything that mattered.
"If it gives a citation, it's verified" is the misconception to retire. A citation is a pointer, not a proof — the passage may be outdated, misrepresented, or merely nearby-in-meaning rather than actually relevant.
Now make the call
A colleague is about to submit Luka's acquittal, and the assistant has cited a reporting template for the figures. What does Luka do?
Try asking it to double-check its own citation too — worth seeing that its "yes, that's correct" is just another generated line, not a lookup.
Apply it to your work
Next time an AI answer includes a citation, click through and confirm the passage actually says what the answer claims — and check its date. Use the fact-check checklist for anything going out under your name.
Prove it to yourself
Two quick questions — untimed, retryable, and they count toward ★ Mastered (completed + decision + self-check all correct). This is what defeats the feeling of "that made sense" evaporating by next week.
Explain it in your own words
Two or three sentences for a colleague. Then compare against the rubric — it checks ideas, not wording, and only you see your note.
✓ Lesson 13 stamped: Citation Checker
You planted an outdated document and watched a confident, correctly-formatted, wrong citation come out the other end. Lesson 14 asks: what if the machine could also act, not just answer?
Evidence & review — how we know what this lesson claims
| Claim | Type | Basis | Review risk |
|---|---|---|---|
| Retrieval-augmented generation fetches passages via similarity search, places them in context, then generates conditioned on them | How it works | Architecture / primary research literature | Low |
| Retrieval reduces but does not eliminate fabrication | How it works | Primary research literature | Low–Medium |
| A citation indicates a passage was fetched, not that the generated claim faithfully represents it | How it works | Architecture documentation, stated explicitly | Low |
| Specific RAG implementations, chunking and ranking methods vary by product | Product behaviour | Provider documentation | High — reviewed quarterly |
| The build-a-librarian demo | Teaching device | Deterministic toy document store, labelled illustrative | Medium |
| The research-assistant-with-library-card analogy | Useful mental model | Limits stated in the lesson | Low |
Concept review due: January 2027. Product-behaviour claims: quarterly.
Where you are in the machine
The machine can now read trusted pages, not just recall patterns. Select any layer for its role, lessons and your live progress.
The machine, bottom to top: training data (2) → token pieces (3) → prediction engine (1, 4–9) → the desk (10–11) → senses (12) → live knowledge (13) → tools (14) → memory (15) → agent loops (16) → human judgement (17–21).
Next: giving it hands
Reading trusted pages is one thing. What if the machine could also do things — check a calendar, run a calculation, send a message? Enter tools.