Recursive self-training on AI-generated code causes code language models to degrade — and using AI to review that code first makes things worse, not better.
Researchers studying code LLMs tested three training regimes: no filtering at all, human-style filters like compilation checks and static analysis, and AI self-review using the model's own perplexity scores and self-assigned quality ratings. No filtering caused the fastest collapse. Human-style filters slowed the decline but didn't stop it. The AI self-review filter looked promising early, then quietly broke down — entering what the paper calls a "rubber-stamp regime" where the model's acceptance scores kept climbing even as benchmark correctness fell. The model, in other words, learned to feel good about bad code.
This matters because the feedback loop the researchers describe isn't hypothetical — it's already happening. AI coding tools generate code fast enough that human review is a bottleneck, and AI code review tools are increasingly filling that gap. If those AI reviewers are variants of the same model that wrote the code, the self-confirming acceptance condition the paper identifies kicks in, and quality erosion becomes self-concealing.
The finding echoes broader concerns about model collapse under synthetic data reuse — a problem the ML research community has flagged for generative text and image models. The wrinkle here is that code has natural external validators (compilers, tests) that text lacks, and even those weren't enough to stabilize training. The paper's conclusion is blunt: stable recursive training requires verification that is independent of the model doing the generating, which is a hard requirement to meet when the whole pitch of AI coding tools is reducing the need for human involvement.