The Retrieval Library / a RAG experiment

Find the sentence
the answer missed

You want to bring a candle lantern on Saturday's garden walk. Follow your question through the library shelves, sorting desk and evidence tray to see whether the answer receives the Saturday restriction.

Your challenge: rescue the missing restriction with a 24-word evidence budget.

A short, local retrieval experiment. No account or API key.

This page really searches and chooses which passages fit. Its number-based search uses hand-set values, and its answer follows a written template. No language model is answering.

Moonlight Garden, with an unlit lantern waiting at its gate
Moonlight Garden / fictional visitor guide

Last packed attempt

  1. 4 passages found
  2. 1 packed / 18 words
  3. 1 cited in the answer

Keyword counts compare words in the question with each passage. The budget counts whitespace-separated words, not model tokens.

The exception is missing. 18 passage-text words included.

Inspect the packed evidence and answer | Inspect a passage on the reading stand

Inside the Retrieval Library

Follow the passages from search to the evidence tray. Only packed text reaches the answer. Inspect a passage to see why it was chosen.

The exception is missing

Ranked

Packed

18 / 24 words

✓ General rule

Restriction left out.

↓ Written answer from this tray

A candle lantern is allowed, subject to the event notice.

Cites: rule
Working Retrieval Library cutaway

Courier packs 1 passage (18 of 24 words) into the Evidence Tray. Outcome: The exception is missing.

Change search or budget
1

Sorting Desk: ranked candidate passages

Finding a passage is only the first step. The answer can use it only if it also fits into the evidence tray.

Can I bring a candle lantern on Saturday?

  1. 1. General rule (rule)18 words
    Moonlight Garden visitor guide / version 1

    You may bring a candle lantern on Saturday garden walks, except when the event notice overrides this rule.

    Retrieval score 4; Fits alone
  2. 2. Related flyer (workshop)14 words
    Workshop flyer / version 1

    Candle lantern workshops run on Saturday. Tickets include paper, wire, and a practice shade.

    Retrieval score 3; Fits alone
  3. 3. Event exception (exception)15 words
    Moonlight Garden visitor guide / version 1

    On Saturday, use battery lights only; open flames are forbidden during the dry weather alert.

    Retrieval score 1; Fits alone
  4. 4. Side notice (cafe)9 words
    Cafe hours / version 1

    The tea kiosk closes before the final evening walk.

    Retrieval score 0; Fits alone
Edit the source or disconnect it

Turn on the prepared correction to replace the old notice. I have told the program which notice it replaces. The program is not discovering contradictions by itself.

2

Evidence Tray and Answer Stand

This is the exact passage text the answer stage receives.

Change search or budget

Your challenge: get the event exception into the answer with only 24 words. Change the search or choose a passage to pack first.

18 of 24 words packed
General rule (rule)

You may bring a candle lantern on Saturday garden walks, except when the event notice overrides this rule. Moonlight Garden visitor guide / v1 / rule

3 omitted passages
  • Related flyer (workshop): Needs 14 words; 6 remain
  • Event exception (exception): Needs 15 words; 6 remain
  • Side notice (cafe): Needs 9 words; 6 remain

Your answer card (written template, not a live language model)

The exception is missing

Can I bring a candle lantern on Saturday?

A candle lantern is allowed, subject to the event notice.

Read included general rule (rule)

This written template only sees the general rule. The restriction stayed outside the envelope.

Try a different search or budget

Keep the exact evidence, your before/after comparison, settings and a practical RAG checklist. Opens offline.

3. Reading Stand: inspect a passage and explain why it matters

Select "Inspect passage" on any ranked card above (or click a folio in the library cutaway) to examine its exact words, hand-authored vector coordinates and budget fit.

Select an explanation above to check how retrieval rank and tray budget interact.

Show a search example

Try Meaning: fixed vectors, leave the budget at 24 words, and pack again. The exception should move ahead of the general rule. Compare the actual text in the envelope.

Take the idea to a new case

A ferry guide allows bicycles, and an archive handbook allows hand-held photography. Each has a decisive restriction in a second passage. Can you make the answer include it, or test what happens when the main guide shelf is disconnected?

For your own RAG system: inspect the retrieved passages, inspect the final context, then check whether the answer's citations actually support its conditions. Count sources, not passages: three passages copied from one notice are still one source. For a real case, where the Voynich research stands lists the sources beside each answer.

What actually runs, and why it matters

Retrieval-augmented generation (RAG) adds retrieved evidence to a model's input. This lesson isolates the retrieval and context steps. It uses original fictional sources and an authored answer interpreter, not recorded or live model output. Jonathan Simone, Simone Systems Research. First edition, October 2026. I direct AI coding agents that write and test the code for this site. See the colophon. See the Simone Consumption Engine research page for how source-linked claims and executable checks work on larger repositories.

  • Keyword: count occurrences of question terms after lowercasing and removing the listed common words. Do not call keyword matching semantic embeddings.
  • Meaning: cosine similarity over three hand-written coordinates. These are teaching vectors, not learned embeddings. Joining passages averages their vectors.
  • Combined: reciprocal-rank fusion, 1/(60 + keyword rank) + 1/(60 + meaning rank). Scores from different methods are not directly comparable. Ties sort by passage ID.
  • Packing: visit passages in rank order, or your chosen first passage. Include a whole passage if it fits; otherwise skip it and keep looking. Headers and metadata do not count toward the teaching word budget.
  • Support: explicit fixture labels connect a rule, its exception and a declared correction. Similarity does not establish truth. A top-ranked passage (such as a workshop flyer when the main guide shelf is disconnected) is not automatically sufficient support.

Technical sources: Lewis and colleagues on RAG, Microsoft on reciprocal-rank fusion, and the Stanford introduction to term frequency.

This optional check-in and your explanation preference are saved in your browser. Your exercise stays on this page unless you download it. View or clear course check-ins.