Skip to content

~/courses $ cd c5

Context Management & Reliability

C5 · 15% of the exam · 6 lessons · about 60 min of reading

Keep long-running work reliable and affordable: context windows and compaction, prompt caching, retrieval with provenance, evals, and cost/latency trade-offs.

Course progress0/6
  1. Context windows and compactionWhat fills the context window, how to measure it before you send, and how to keep long sessions small with compaction and context editing.10 min
  2. Prompt cachingReuse a stable prompt prefix across requests, place cache breakpoints where content stops changing, and confirm hits from the usage fields.9 min
  3. Retrieval, grounding and provenanceGive Claude only the sources it needs, make every claim traceable to a passage, and let it say when the sources don't answer the question.10 min
  4. Evals and success criteriaTurn "it seems to work" into numbers. Define measurable success criteria, build a test set with edge cases, and pick the right grader.10 min
  5. Cost and latency trade-offsChoose the model, effort and max_tokens for the job, batch work that can wait, and stream what a human is watching.10 min
  6. Reliability patternsClassify API errors, retry only what is transient, set timeouts, fall back gracefully, keep side effects idempotent and log enough to debug.11 min