Your GPS says turn left. A stranger on the corner says turn right.

If you trust the stranger, you get lost.

Not because the GPS was wrong. Because you let a guess overrule a map.

I did that to Claude last week. I let a guess overrule a map. It went from finding ninety-five out of every hundred dead things to only forty.

What I was building

We built a tool that finds dead code. Dead code is code nobody uses but that still sits in the project.

The tool works by building a graph. The graph knows every call in the code. Function A calls function B. File X imports file Y. It doesn't guess. It reads the real structure.

On a real project, the tool found ninety-five out of every one hundred dead things. That's good.

The "smart" idea

I wanted to be safe. So I added a step.

After the tool flagged something as dead, I told Claude to double-check. "Before you say it's dead, search the whole codebase for the name. If the name shows up anywhere, it's probably alive."

It sounded careful. It sounded smart. It sounded like what a good engineer would do.

It was wrong.

What happened

The tool went from finding ninety-five out of a hundred to forty out of a hundred.

Same tool. Same code. Same task. The only change was the double-check.

I was making the answers worse by checking them.

Why

Grep searches for words. It finds any time the word shows up. It does not care what the word means.

So if I grep for hasRole, I get:

None of those are real calls. They're the word showing up in text.

But Claude sees matches. Claude thinks, "the name appears six times. Must be alive." And marks the code as alive.

So real dead code got pardoned. Because a weaker tool found word soup and spoke louder than the graph.

The rule

Don't check a precise tool with a less precise one.

The graph is precise. It sees calls. It cannot be fooled by a comment.

Grep is fuzzy. It sees words. It can be fooled by anything.

When you ask the fuzzy one to approve the precise one's answer, the fuzzy one wins. Even when it shouldn't.

The fix

We removed the double-check. We told Claude to trust the graph.

It went back to finding ninety-five out of a hundred.

One line removed. More than half the dead code back.

How we actually check

If we want to be sure something is dead, we use a scream test.

Here is how it works. The graph flags a function as dead. Instead of grepping for the name, we actually delete the function. Then we run the tests.

If the tests pass, the code was dead. Nothing called it. Removing it changed nothing.

If the tests fail, the code is screaming at us. It wasn't dead. We put it back.

That is a real check. Running the code is stronger than reading it. Grep only reads. Tests actually run.

If you are going to verify, use something stronger than the thing you are verifying. Not something weaker.

What I learned

Double-checking feels safe. It isn't always.

A check from a weaker tool is not a check. It's a downgrade.

Try it

Install the tool:

npm install -g @supermodeltools/cli

Find dead code in your project:

supermodel dead-code

You get a list of functions the graph thinks are dead. Run a scream test on any of them. Delete it. Run your tests. See what happens.