AI MOOC
✦ Grow togetherInvite 3 friends, earn 1 month of membership · Up to 12 monthsInvite friends →

Library / My reading notes

Prepare sources with audience, conditions and versions

Create traceable records and prevent stale versions and audience mismatches.

Back to the RAG course plan: Build a searchable, cited RAG knowledge base

Chapter 2 / 8 · Read and take notes

Create traceable records and prevent stale versions and audience mismatches.

Understand the method

Inspect documents.json. id supports citations; version identifies revisions; status controls current candidates; audience describes applicability; title aids retrieval; text preserves the rule. A travel heading alone does not establish intern eligibility.

P1 covers staff lodging; P2 covers intern travel approval. Preserve the cap together with audience, nightly unit and invoice condition. Extracting only the number can produce a false conclusion even with a valid citation ID. Meaning comes before brevity.

P1-old intentionally carries the archived cap. Keep it to test version filtering. Real corpora contain history: retrieve current records while retaining archives for audit. Updating a title without rebuilding the index leaves stale evidence in circulation.

For PDFs, pages and tables, inspect extraction: repeated headers, detached table labels, image-only scans and broken conditions. Compare a small sample with the original. Fix extraction failures before indexing instead of blaming the model for missing text.

The CLI audience parameter demonstrates applicability only. Production authorization must use trusted identity and enforce access at retrieval; a user-provided staff value is not access control. The lab corpus is public teaching data.

Record each source change, version, effective date and reviewer. Track corpus and code versions separately: answers may change when only the data changes. Reproducibility requires both.

  1. 1Inspect
  2. 2Conditions
  3. 3Version
  4. 4Filter

Included material

Fields: id=P1, version=v1, status=current, audience=staff.
The supplied Chinese text keeps audience, nightly cap and invoice condition in one record.

Work through the steps

  1. Check all seven records and identify the archive.
  2. Identify audience, amount, unit and condition in P1.
  3. Create an incomplete copy lacking audience and document why ingestion should reject it.

Worked example

Source checklist: P1 staff, CNY400/night, invoice, current v1; P2 interns, cap unspecified, prior approval, current v1; P1-old archived v0. Do not merge these into a cap for everyone.

Your exercise

Tabulate P5 and write one question it cannot answer. Explain why the archive stays in the file but is excluded from current answers.

Check before delivery

  • Preserve audience, units and conditions.
  • Distinguish applicability filtering from authorization.
Finish the exercise, then view the reference

P5 supports a seven-day booking window and releasing cancelled slots, not a fine. Filter archives out of current retrieval while retaining them for version review.

An original course with teaching exercises. Reading records, practice outcomes and independent certification are distinct.

References and further reading

The lessons are original. The following sources are provided under their respective permissions.

Article / guide

Prompt Engineering Guide

DAIR.AI · en/zh

MIT

License checked. This entry links to the original; the book text is not mirrored.

License checked: 2026-10-16 · Pinned 57673726
Article / guide

RAG and Vector Databases

Microsoft · en/zh

MIT

License checked. This entry links to the original; the book text is not mirrored.

License checked: 2026-10-16 · Pinned d45da912
Whitepaper / report

NIST AI 600-1: Generative AI Profile

NIST / Autio et al. · en

NIST Technical Series reprint policy

Original PDF provided under the institution’s reprint policy.

License checked: 2026-10-16
Article / guide

Ollama Chat API

Ollama · en

Official documentation link; no full-text reproduction

Original link only; full text is not mirrored.

License checked: 2026-10-20