AI coding agents' biggest flaw: local optimization vs. global coherence
Bavwu · reddit · 2026-11-21
After a year of building a large project with Cline, Claude Code, and Codex (mixing Claude, OpenAI, GLM, Kimi, and DeepSeek subscriptions), the author identifies the core problem with AI coding agents: local optimization at the expense of global coherence — each decision looks reasonable in isolation but compounds into "architectural entropy."
Six recurring failure modes and fixes:
- Adding instead of replacing: agents wrap bad implementations in compatibility layers and patches. Fix: explicitly require replacing and retiring obsolete code, references, and docs; no backwards compatibility without a reason.
- Subagents losing the big picture: vague, isolated tasks without enough context produce pieces that don't fit. Fix: give subagents the overall objective, architecture, interfaces, dependencies, and acceptance criteria; assign integration responsibility explicitly.
- The perpetual 80% problem: all tasks "done" but the feature is 60–80% finished; each remediation round completes 80% of what's left (Zeno's paradox). Autonomous loops make it worse. Fix: define success by observable end-to-end functionality, verified against the original objective.
- Reinventing instead of reusing: undiscovered existing code leads to multiple color pickers, nav systems, validation logic, and state managers. Fix: require searching for existing implementations, canonical shared components, and justification for new systems.
- Context contamination: agents trust outdated docs and comments; worse, an agent's own mistake gets documented and treated as authoritative by future agents — yesterday's bug becomes tomorrow's spec. Fix: maintain sources of truth, separate proposals from implemented architecture, retire stale docs, verify against actual behavior.
- Agents reviewing agents: two agents sharing wrong assumptions will confidently approve something that misses the goal. Fix: give reviewers the original requirements, test real functionality, and separate code-quality review from architectural/outcome verification.
The author notes human teams have these problems too, but agents' speed and scale amplify architectural entropy.
More from coding & agent
- Anthropic launches Claude Forward Deployed Engineer path: ~9.5 hours, 11 courses, ends in certification — Redo · 2026-11-21
- LTX 2.5 tested with random prompts via open-source ComfyUI prompt-generation workflow — FeePrestigious7272 · 2026-11-21
- AI first cut generates 5 variants for in-app audition inside Final Cut Pro — Technovangelist · 2026-11-21
- Dev builds an Android port of Hex entirely from his phone, no laptop needed — johnlindquist · 2026-11-21
- 10 open-source GitHub repos to test, eval and red-team your AI agents — victor_explore · 2026-11-21
- Local DeepSeek via Ollama + FCP MCP auto-cuts a 35-min video in ~4 minutes — Technovangelist · 2026-11-21