Using AI to write better code more slowly
The author argues against the common perception that AI coding tools are only good for rapidly generating low-quality "slop." Instead, they advocate for a methodical approach using multiple LLMs to rigorously find and fix bugs, significantly improving code quality, albeit at a slower pace. This counter-intuitive method prioritizes deep codebase understanding and long-term health over immediate velocity, offering a "super-powered" way to achieve careful, quality-obsessed development.
The Lowdown
The article challenges the prevailing notion that AI's primary utility in coding is to churn out vast quantities of low-quality code quickly. Author Nolan Lawson proposes an alternative: leveraging AI to meticulously craft high-quality code, even if it means slowing down the development process. He suggests that by employing LLMs in a disciplined manner, developers can significantly enhance code integrity and deepen their understanding of complex systems.
- Reframing AI's Role: Disputes the "slop cannon" perception of AI coding, advocating for its use in generating high-quality code deliberately.
- Multi-Agent Bug Detection: Proposes using a "Claude skill" that integrates multiple LLMs (e.g., Claude, Codex, Cursor Bugbot) to identify and rank bugs in pull requests, greatly reducing false positives.
- Comprehensive Bug Definition: Extends the definition of "bugs" beyond mere functional errors to include violations of principles like KISS and DRY, inaccessible HTML, and inefficient SQL queries.
- Quality-Centric Workflow: Describes a workflow where critical and high-priority bugs are addressed first with AI assistance, while lower-priority issues are weighed against effort, and fundamentally flawed approaches are abandoned.
- Codebase Health Over Speed: Acknowledges that this method may not boost immediate velocity; instead, it often uncovers pre-existing bugs, leading to deeper codebase understanding and overall improvement, akin to a "super-powered" methodical programming style.
- Target Audience: Encourages developers who rely on agents for large, complex PRs to adopt this slower, quality-focused approach, promoting careful, methodical, and quality-obsessed coding.
Ultimately, the piece argues for a shift in mindset regarding AI in development—from a tool for sheer output to one for profound quality assurance and continuous learning. By embracing a slower, more deliberate application of AI, developers can foster healthier codebases and elevate their craft, focusing on robust solutions rather than just rapid deployment.