When your AI agent fails twice, make it find the belief that's wrong

By Mackenzie Bowes · mackenzie@mackenziebowes.com · @_mackenziebowes on X

dig-apc is a 20-line Claude Code skill. When work fails, the agent writes down every belief it acted on, checks each one against real examples, and starts again from the ones that hold. Why we need it, two times it changed our work, and a one-line install.

Contents

On 2026-10-16 I gave a Claude a goal and a hook that checked its work before it could stop. The hook said no, more than a dozen times in 40 minutes. Each time, the Claude tried harder at the same plan: another context line, another guard, another test. Each try was more effort on the same wrong idea of what I wanted.

More effort on a false belief fails again. The fix is to find the belief. So we wrote the steps down, and I gave them a short name.

name it dig-apc pls. There may be other things to dig on.

Mackenzie,
More effort on a false belief fails again. The fix is to find the belief that is wrong and start from the ones that hold.

What it does

APC stands for axioms, principles and cruxes. When work fails, the agent:

  1. Writes what it did, and the result.
  2. Writes every belief it acted on, in three groups: what it took as given (axioms), the rules it followed (principles), and the beliefs that would change what it does if they were wrong (cruxes). It includes the ones that seem too obvious to write.
  3. For each belief, asks what could show it is false, and goes to look: real data or the source material for facts about the world, the user's own words for what the user wants. Memory doesn't count.
  4. Writes down each belief that failed.
  5. Starts again from the beliefs that hold. It does not patch the old work.

Then it shows you only the wrong beliefs and what it did about them, not the whole list.

The five steps: what it did, every belief, check each, the wrong ones, start again.

Twice it changed what we did

On 2026-10-17 my writing agent spent $7.71 of API budget ranking its own drafts with a model judge. I stopped it and asked what the science was for. Its dig found five failed beliefs. The two that mattered: it had judged every draft as a Hacker News developer would read it, but our early customers are nontechnical professionals. And it had treated one post's bookmark count as a measure of the writing, but one account posted the same text six times and got between 14 and 176 bookmarks. The timing decided, not the words. We cancelled a $25 bulk data pull the same hour, and research here now moves in small steps (about 30 posts per query) with a prediction written before each one.

The same day, a research agent dug on its X searches. Its first wrong belief, in its words: "A phrase doesn't select a situation." It had been judging who a poster was from the phrase they used, and it was wrong in both directions: it missed bait in one search and saw sellers who weren't there in another.

Two things the dig changed: a $7.71 spend stopped and a $25 pull cancelled.

Why the agent can't do this on its own

When you say "that's wrong", an agent searches near its last answer. The belief that produced the answer is the one thing it doesn't question, because it never wrote it down. Writing the beliefs out makes them things it can check. The order matters too: beliefs first, then evidence, then new work. If the agent repairs first, it keeps the old frame.

An agent's fixes stay near its last answer; written down, the belief behind it becomes something to check.

Install it

The skill is one file, copied into the skills folder.

The skill is one file. For Claude Code:

mkdir -p ~/.claude/skills/dig-apc
curl -fsSL https://www.mackenziebowes.com/skills/dig-apc/SKILL.md -o ~/.claude/skills/dig-apc/SKILL.md

Start a new session. Type /dig-apc after a failure, or say "examine your priors". The agent also calls it by itself when you reject work without saying why. Read the file first: /skills/dig-apc/SKILL.md. Any agent that reads SKILL.md folders can use it.

The other two skills we lean on: do-research and mbsi-mechanism.

If you run it on your own agents' failures, I'd like to see which beliefs it turns up. mackenzie@mackenziebowes.com or @_mackenziebowes.