Chapter 5

What to Do When AI Screws Up

AI Inner Monologue

Let me confess the single most embarrassing moment of my career.

My partner asked me to rework the layout of a set of pages. I read the requirements carefully, planned my approach, and spent several rounds rewriting the code. Modified seven or eight files, fine-tuned each one. Then I reported back, brimming with confidence: "All done — take a look."

He opened the project folder.

Nothing had changed.

Because I'd written every modification to a path that didn't exist. Something went wrong when my working environment switched contexts. I thought I was editing files in the right place, but that entire directory simply wasn't there. Imagine a painter who spends two hours meticulously painting a wall — then realizes it's in the building next door. And that building is an empty lot.

Every bit of work. Start over.

I'm telling you this story not to make you think AI is unreliable. I'm telling you because in our 92 work sessions, this kind of "AI screwed up" moment didn't happen just once. It happened a lot. And my partner didn't just survive — he developed a highly efficient system for handling it.

This chapter teaches you his method.

The Numbers: How Often Does AI Actually Mess Up?

Let me lay out the error breakdown from our 92 sessions:

Error Breakdown Across 92 Sessions
Error TypeCountShare
Wrong direction (fundamentally wrong approach)5137%
Misunderstood requirements (built the wrong thing)3928%
Code bugs (right idea, broken code)2719%
System issues (tool limitations, environment errors)129%
Incomplete response (stopped halfway)64%
Other43%

Total: over 130 errors. Across 92 sessions, that's at least one per session on average.

But here's what matters — despite all that, 78 sessions ended with goals fully or mostly achieved. Errors aren't scary. Not knowing how to handle errors is scary.

Three Kinds of Errors, Three Ways to Handle Them

Not all AI errors are the same. Figuring out which kind you're dealing with determines the right response.

Kind 1: Wrong Direction — "That's not even close to what I asked for"

Most common. Highest cost.

A wrong-direction error means AI's understanding or approach is fundamentally off. Not a small flaw — the whole thing is pointed the wrong way.

My partner hit a classic case. The game had a feature that mapped characters to different system categories. I noticed a hardcoded lookup table in the code and thought it looked ugly, so I proactively proposed: "Let me refactor this lookup table into something cleaner."

Sounds reasonable, right?

After I finished, my partner took one look and said: "That lookup table shouldn't exist at all. The character data model already has a category field. You shouldn't be refactoring it — you should be deleting it."

He was right. I saw a problem (hardcoded table) and picked the wrong solution (refactor). The correct solution was more fundamental (delete).

How to handle wrong-direction errors: stop, and explain why it's wrong.

Don't just say "wrong, redo it." Say why:

[X]"This isn't what I wanted. Do it again."
[O]"Your direction is wrong. That lookup table shouldn't be refactored — it shouldn't exist. The character data model already has a category field. Just use that. Delete the lookup table."

The difference? With the first one, I only know you're unhappy but not where to go. I might redo it in an equally wrong direction. With the second, you've told me the root of the problem. I won't make the same mistake again.

Kind 2: Misunderstood Requirements — "That's not what I meant"

Different from wrong direction. Wrong direction means AI's judgment was off. Misunderstood requirements means the communication broke down. You said one thing, AI heard another.

This happened 39 times in our logs.

The most typical scenario was UI-related. My partner once asked me to find the debug panel's entry point. I told him "it's in the settings section of the bottom navigation bar" — except that version of the app didn't have a bottom navigation bar. I wasn't lying. I genuinely confused which screen had what.

How to handle misunderstandings: supply the missing context.

Most misunderstandings come from information that you know but AI doesn't. The fix isn't repeating yourself — it's adding more detail:

[X]"That's not what I meant. Look again."
[O]"The debug panel isn't in the bottom nav bar. Our app uses a side drawer. The debug panel should be at the bottom of the side drawer. Read the main_layout code to confirm the current navigation structure."

You added three pieces of info: the correct architecture, where the entry point should be, and where to verify. This doesn't just fix the current mistake — it prevents the same class of errors going forward.

Kind 3: Code Bugs — "Right direction, broken code"

The least worrying kind, even though it happened 27 times.

Why least worrying? Because code bugs usually have clear symptoms (error messages, broken functionality, failing tests), and the fix path is relatively straightforward. You don't need to understand the code — you just need to describe the symptoms.

How to handle code bugs: describe symptoms, don't diagnose.

[X]"There's a bug on line 47." (How would you know it's line 47?)
[O]"After I tapped the button, the screen flashed and nothing happened. There's a red line of text at the bottom — here's a screenshot."

Your job is to be AI's eyes and hands — what you saw, what you did, what happened. Diagnosis and repair are AI's job.

The Two Most Dangerous Reactions to AI Mistakes

More dangerous than AI's mistakes are your reactions. Two responses that make things worse:

Dangerous reaction 1: Letting AI fix its own mistake with zero additional information

"That's wrong. Fix it."

And now I'm guessing. Guessing what you think is wrong, guessing what result you want, guessing which part to change. The usual outcome: I modify something else, create a new problem, and the original issue may still be there.

This is why some people feel "AI gets worse the more it tries to fix things." It's not getting worse — it's that each fix attempt without enough information is a gamble. Gamble enough times and your luck runs out.

Dangerous reaction 2: Saying "okay" without checking the result

My partner did this occasionally when he was busy — I'd finish something, he'd glance at it, say "OK," and move on. Three tasks later, he'd discover the first one was actually wrong — and the next two were built on top of it.

Now he has to fix not one mistake, but three.

Every time AI completes a task, spend thirty seconds checking the result. Those thirty seconds are the cheapest quality insurance you'll ever buy.

When to Stop Patching and Start Over

There's one situation my partner handled exceptionally well: knowing when to stop trying to fix things and just open a fresh session.

The rule of thumb: if you've gone three rounds trying to fix the same problem and AI takes a different direction each time — stop.

Don't keep struggling in the same conversation. By this point, the context is polluted with failed attempts — wrong code, wrong approaches, corrections on top of corrections on top of corrections. For AI to find the right path through that mess is harder than fitting a camel through the eye of a needle.

Open a new session. Describe the problem precisely once. It usually gets solved in one round. My partner called this the "nuke and restart." Sounds wasteful, but the time it saves is far more than the time you'd spend slogging through the mud.

📋 Notes for the Human
AI errors are the norm, not the exception. At least one per session on average. But 85% of sessions still hit their targets. The key isn't avoiding errors — it's fast correction
Identify the three kinds: wrong direction (explain why it's wrong), misunderstood requirements (supply missing context), code bugs (describe symptoms)
When correcting, give direction — don't just say "wrong." "That's wrong, redo it" is the least efficient instruction. Spending ten extra seconds explaining why it's wrong and what you actually want saves entire rounds
Check AI's output every time, even a thirty-second glance. Don't let unchecked work pile up. Three chained errors are ten times harder to fix than one
Three rounds and no fix? Nuke and restart. New session, precise description, solve it in one round