- Day 55: If you cannot trace it, you cannot run it
- Day 56: Evaluate the workflow users see, not just the model
- Day 57: Retrieved content is data, never instructions
- Day 58: Governance is architecture, not a document after launch
- Day 59: Production AI is coordination: data, models, tools, controls, people
- Day 60: From model demos to mission-ready AI systems
Every agent team eventually hits the same moment. A user reports a bad outcome from yesterday, and someone asks whether we can see what it did.
The answer to that question was decided months earlier, when tracing either was or was not built.
Logging the answer is not tracing
A production trace connects the full causal chain for one request, under one ID, navigable end to end. That ID has to survive every hop. Carry it in W3C Trace Context headers and in every queued message and handoff, or you get partial logs instead of a trace.
| Step | What to capture | What it lets you answer |
|---|---|---|
| Input | request, user context, request ID | Can we reproduce it? |
| Retrieval | queries, filters, source IDs, ranks | Was the evidence there, and did it rank? |
| Model call | prompt, response, tokens, model version | What did it actually see? |
| Tool call | tool, arguments, result, duration | What did it do to the world? |
| Handoff | payload passed between agents | Where did context get lost? |
| Decision | output, confidence, owner | Who is accountable? |
What it converts
It turns adjectives into locations. "The model hallucinated" becomes "the 2024 policy entered context at step 3 because the freshness filter was not applied." That points to a different owner and a different fix.
It turns guesses into attribution. The step burning 80% of your tokens becomes visible, and it is rarely the one people predicted.
It turns apologies into answers. When compliance asks why the system approved something, you replay it rather than reconstructing it from memory and hope.
Capture context without capturing everything
Settle one tension before the first trace is stored. Traces are useful in proportion to their detail, and prompts and retrieved documents routinely contain personal data.
Resolve it deliberately by redacting or tokenising sensitive fields, storing references rather than payloads where you can, and setting retention that satisfies both debugging and privacy. This is a design decision, and making it late usually means making it badly, in one direction or the other.
The retrofit trap
Deferred tracing gets added after the incident that needed it. That means debugging that incident blind, and instrumenting a system that is now large, live, and load-bearing.
Instrument on day one, while it is small enough that instrumenting is easy.
Decide what to keep before you need it
Day-one tracing has a cost, because traces carrying prompts and retrieved text are large and keeping all of them is a storage bill. Tail-based sampling on errors and latency misses the failures that matter here, because a confidently wrong answer returns successfully and on time. Keep everything for a window long enough for a user complaint to arrive, then keep errors, slow requests, anything a human touched and a fixed sample of the rest.
About this explainer
- Format
- Explainer
- Level
- Practitioner
- Read
- 2 min read
- Published
- Jul 18, 2026
- Disciplines
Short mental models: one idea, why it matters, what to do about it.
More on these topics
Deep dive · · 7 min read
Every question your AI readiness review asks was answered months ago
The last six days of a sixty-day series, and the pattern is that operability gets bought early or it does not get bought at all.
Explainer · · 2 min read
Real users ask questions your test set never imagined
Offline evals cover the questions you thought of. Production tells you the ones you did not.
Explainer · · 2 min read
Logging the answer tells you almost nothing
A trace that links intent, prompt, retrieval, tools and output is the only thing that makes an AI failure debuggable.
Discussion