Do you understand the code your AI writes? I'm spending a year finding out
3 min read#ai-assisted #metacognition #research
In 2025, METR ran one of the more uncomfortable experiments in our industry: experienced open-source developers worked on their own repositories, with and without AI assistance. With the tools, they were roughly 19% slower — while estimating, even after finishing, that the tools had made them about 20% faster.
Sit with that for a second. These weren't novices dazzled by autocomplete. They were experts, on code they knew intimately, and their sense of their own performance pointed in the opposite direction from their actual performance.
How can you feel faster while being slower?
The easy reading is "the tools aren't good enough yet," and every model release relitigates it. I think the more interesting reading is that this isn't primarily a tool problem — it's a monitoring problem. The question isn't whether AI writes good code; it's whether we can accurately tell how well we understand what it wrote. Psychologists call that self-assessment metacognitive monitoring, and the match between confidence and actual comprehension is called calibration.
We already measure everything about AI-assisted development except this. Acceptance rates, task completion, lines shipped — all proxies for speed. Almost nothing tracks whether the developer's felt understanding of the resulting code survives contact with reality.
Why does AI-written code feel so understandable?
Here the psychology literature has been waiting for us, decades in advance.
Judgments of our own knowledge aren't read off some internal gauge — they're inferred from cues, and the cues can lie (that's Koriat's cue-utilisation theory, from 1997). One of the strongest cues is fluency: the sheer ease of processing something inflates our confidence in it (Alter and Oppenheimer, 2009). And AI assistants are fluency machines. The code arrives instantly, well-formatted, idiomatically named, confidently explained. It compiles. It reads smoothly. Every one of those properties makes it feel understood — and none of them is evidence that you could modify it, debug it, or predict its behaviour under load.
Code that compiles and reads smoothly is a cue, and it's a lying one.
There's a third result that anyone who reviews AI diffs will recognise: the illusion of explanatory depth (Rozenblit and Keil, 2002). People believe they understand how a zipper works — until asked to actually explain it, step by step, at which point the understanding evaporates. Reading an AI's explanation of its own code may be the purest industrial-scale version of that illusion ever built: you consumed an explanation, so you feel explanatory depth you never constructed.
Haven't I written about this before?
In a way, this whole question is an earlier post taken seriously. The rituals I described there — read the diffs, interrogate instead of accepting, hand-write when the sprint allows — are, in the literature's terms, ad-hoc calibration tools: deliberate attempts to replace lying cues with real tests of understanding. I built them from instinct. The research question is whether the evidence says instincts like these actually work, for whom, and at what cost.
What am I actually doing about it?
Making it my Honours dissertation at Belgium Campus: a scoping review mapping what empirical research knows about how well developers' confidence tracks their comprehension of AI-generated code — and what shapes that gap. It's a project on this site now. And it's honestly framed: a scoping review charts evidence, it doesn't run experiments; the work is in progress and its shape may still change; the final report lands in December 2026. I'm publishing the question now, not smuggling in conclusions I don't have.
But I'd argue the question already earns its keep. If the industry's productivity numbers and its developers' self-reports can point in opposite directions, then "do we understand what we're shipping?" stops being philosophy and becomes an engineering risk — one every team using these tools is carrying, measured or not.
If your team is wrestling with exactly this — shipping AI-assisted code and wondering what's actually understood — my inbox is open.