Skip to content
ImagineWorld

Course Correction

node_idnode-book_agentic-spec-driven-development_chapter-12-course-correction
node_typechapter-node
schema_profileworld.chapter_node.v1
statusactive
entropyhigh
manifoldworld
domainimagineworld.net
authorityinforms
layercorpus
chapter_num12
chapter_titleCourse Correction
governed_byCORPUS
constitutional_citationCONSTITUTION
local graph

The previous chapter dealt with errors AI makes — hallucinations, contradictions, claims past the edge of what AI knows. The guards there work by checking AI’s output against the project’s recorded truths. But there is another source of inconsistencies, one not caused by AI but by you and your team. Some are mistakes — facts recorded incorrectly to begin with. Others are drifts — facts that were right at the time but have since been overtaken by a market shift, a new discovery, a change of plans, or a regulatory or vendor-policy change. Until recently, peer review was the only remedy, and it has its limits. Agentic AI changes that.

Nothing in the previous chapter’s methods — the polygraph in manual and automatic modes, the Devil’s Advocate — restricts them to AI’s work. You can run them on your own input too, and put yourself under the same scrutiny.

The automatic polygraph already does. It guards files, not authors. Every write into a guarded file goes through the same check, whether the content came from AI or from you typing by hand. The protocol does not ask who wrote the content. It asks whether the content is consistent with what the project has already recorded. All finding categories apply — direct contradictions, duplicates, vocabulary mismatches, broken references, scope drift, rationale conflicts — and if any surface, you triage them exactly as you would for an AI-produced draft.

The manual polygraph and the Devil’s Advocate are equally easy to point at your own writing. Open a clean session, hand AI the new fact and the existing ground truths, and ask the same questions you would ask about an AI draft. Does this contradict anything we already know? Which parts of it trace to recorded material, and which are assumptions carried in from outside? The instruments do not change. All you add is the habit of pointing them at yourself.

There is no point in working a separate example here. Treat your own words the way you treat AI’s, and you will catch human errors with the same instruments that catch the machine’s.

A ground truth is not a standalone fact. Once recorded, the truth becomes woven into AI’s reasoning on every turn that touches it. Drafts cite it. Downstream content assumes it. The polygraph and the Devil’s Advocate both treat it as a fixed point of reference. Past artifacts produced while the truth was in force will still reference it.

Ground truths go bad. A fact recorded six months ago can turn out wrong for any of the reasons named at the start of this chapter — a recording mistake, a market change, a superseding discovery, a pivot, a turn in regulation or vendor policy, a strategic decision that invalidated something you had treated as fixed. Mistakes and drifts alike are part of running any real project, and the response is the same: modify or remove the broken ground truths.

Updating a ground truth is never a local change. Anything that cited or assumed the old version — the drafts, the decisions, the downstream artifacts, the rationales those rest on — is now suspect. And no general procedure exists for finding what depended on it: the dependencies are diffuse, scattered across drafts and decisions you may not remember making.

There is a recipe. It is expensive — in money, in time, and in effort. A full walk-through would be a chapter of its own, and the worked example would add length without earning it. The outline below carries enough detail that you can run it in your own project when the moment comes.

  1. Back up the project. Snapshot the current state outside the project tree, or commit it to version control. Either route is fine. The point is a clean restart you can fall back to if the update goes sideways and you decide to start over.

  2. Capture the intent in a file. Write down what you want to change and why, in a new file dedicated to this update — the intent file. Keep it outside any guarded registry for now; it is a working document, not a source of truth.

  3. Run the analysis in a new session. Hand AI the intent file together with the project’s recorded ground truths. Ask it to surface both conflicts (the polygraph’s question) and assumptions (the Devil’s Advocate’s question). The output is a findings file with one row per issue, each tagged as open. Two states — open and closed — are enough for this loop; a large project may justify a richer workflow with a broader set of states (open, dismissed, accepted, deferred, resolved, etc.).

  4. Gut-check the result. Read the findings against the change you set out to make. If the analysis convinces you the change is the wrong move, stop: restore from the backup, restate the intent, and start over from Step 2.

  5. Address the issues one at a time. Walk down the list. For each row, decide what alteration you want to make — to a ground truth, to the change itself, or to a downstream consequence — and append your decision to the bottom of the intent file. Mark the issue closed when you are done with that row. Use AI to think through individual rows as much as you find useful.

  6. Re-run the analysis. Your intent file is much larger now. Go back to Step 3 in a fresh session. AI processes the original intent together with the accumulated alterations and flags whatever new issues the additions raise. If the findings shrink with each pass, you are converging on a coherent change. If they grow, the change is fighting the project.

  7. One more pass in a fresh session. Once the analysis comes back clean, run it once more in a new session. AI’s outputs are probabilistic; a fresh attention pass occasionally catches what earlier passes missed.

  8. Apply the accumulated changes. In a new session, hand AI the final intent file and ask it to apply the changes across the project in a single sweep. This is not a row-by-row edit — the guarded protocol will fight you if you try to land contradictory or incomplete updates one at a time. If the guards block more than they help for this particular change, the option of last resort is to clone the project into an unguarded copy (without CLAUDE.md), land the changes there, and then copy the modified files back manually. Be careful with that route: you are turning off the safety rails for the duration of the work, and the cost of a mistake while they are off is exactly the cost the guards exist to prevent.

What do you do when conflicts have already worked their way into the project files? The methods so far assumed a clean baseline to compare new input against. Sometimes your baseline is far from clean. Truths and decisions across the files contradict each other, and no single fact stands out as the cause. Reviewing everything by hand is not feasible on a project of any size that matters.

The first instinct is to hand the whole project to AI and ask it to flag every cross-file inconsistency. On a tiny project that may produce a usable list. On a real project, the request produces noise. Every minor wording variation surfaces as a finding. The contradictions that matter get buried or missed entirely. The signal-to-noise ratio collapses.

What you need is order. The checks have to be scoped narrowly enough that AI can run them reliably, and structured so that nothing important falls through. That is the full audit.

Start by deciding what to look for. The unit of audit is usually a decision, not a truth. Truths are facts the project has recorded about the world. Decisions are choices the project has made about how it operates. Decisions cause downstream contradictions when they are inconsistent across files.

Pick one type of decision at a time. The narrower the type, the more reliably AI can extract it. A few examples of what one type looks like:

All decisions about how financial transactions are stored - schema, immutability,
audit trail, retention period.
All decisions about how a user is authenticated across the product.
All decisions about error handling - what is logged, what surfaces to the user,
what blocks versus what retries.
All decisions about pricing and billing - tiers, discounts, prorations, refund
handling.
All decisions about jurisdiction and governing law across a set of contracts.
All decisions about how a clinical study handles participant dropouts.
All decisions about brand voice.
All decisions about access control - who can read, who can write, who can
administer.

Ask AI to walk the project files and pull every decision of the chosen type into a findings file, one row per decision, each row tagged open. A file is necessary because the list will be longer than you expect; held in a chat thread, a list that long collapses back into the noise you set out to avoid.

Once one type is audited end to end, move to the next.

Open a new session. Tell AI to pick the first decision marked open from the findings file. Have AI validate that decision against every other file in the project — a full polygraph if you want all finding categories, a narrow subset (contradictions and rationale conflicts, say) if you want a faster pass. Any conflicts go into a separate conflicts file for later handling. When the validation is done, the row flips from open to analyzed.

Then repeat. A fresh session for each row, or a long-running session if your tool’s context window can hold the work without losing attention to the earlier rows. The point is that each decision gets its own clean validation, against the whole project, in isolation from the others.

Keep going until no open decisions remain.

What you have at the end is a list of decisions the project does not hold consistently. From here, the work is mostly manual. You read the conflicts file, decide which version of each decision the project should keep, correct the others, and update the related ground truths as necessary. There may be ways to automate parts of this for your particular project — a script that rewrites every reference to a deprecated field name, a sub-agent that lands a known fix across a known set of files — but the call about which version is correct is yours.

The audit is slow and tedious. You do not run it daily, or even weekly. You run it at milestones — the points where the cost of an unresolved contradiction is about to multiply. Before a product specification ships to development. Before a contract package goes out for signature. Before a research write-up is submitted for review. Before a policy draft is enacted. Before a marketing brief is handed to the agency. Before an investor deck leaves your hands. The rule: run the audit any time the artifacts in your project are about to land in front of people who cannot afford to chase ambiguities back to you.

Validating ground truths, updating them, and running the full audit are mechanical, repeatable work that does not require live interaction — exactly what sub-agents are good at.

Most agentic AI tools support sub-agents — fresh contexts spawned from the main session, each with its own attention pass over a narrow task, each returning a short summary.

The challenge is to automate those processes for your projects using sub-agents. When done right, the only manual work that remains is applying your judgment.

Once the chain works end to end, it becomes cheap enough to run more often.