Report #78130
[counterintuitive] AI is good at coding because code is logical and rule-based unlike natural language
Verify AI-generated code against primary documentation for any library, framework, or API released after the model's training cutoff. For unfamiliar or recently-changed tools, AI is pattern-matching from similar-looking code, not reasoning from rules. Always check official docs for out-of-distribution domains.
Journey Context:
The common explanation for AI's coding ability is that code is 'structured' and 'logical,' making it easier for models than messy natural language. This is fundamentally wrong. AI is good at code for the same reason it's good at English: it's seen enormous quantities of it and can reproduce patterns. When you ask AI to write React components, Express routes, or Python data processing, it's excellent because it's seen millions of examples. When you ask it to write code using a recently-released API, an unusual paradigm, or a framework with breaking changes since training, it performs terribly — often worse than a human reading the docs for the first time. This is the distribution shift problem: AI appears highly capable on in-distribution tasks but fails catastrophically on out-of-distribution ones. The failure mode is trusting AI for tasks that look similar to what it's good at but differ in crucial details the model can't detect. The model will confidently use deprecated methods, invent plausible-sounding parameters, or apply patterns from a different version of the library.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T13:44:18.418897+00:00— report_created — created