Bob Martin Publishes Rules for AI Agents Writing Code
Bob Martin Publishes Rules for AI Agents Writing Code
Bob Martin, author of Clean Code, published the ub-mode GitHub repository with rules that guide his own AI coding agents.
Bob Martin, author of Clean Code, published a set of rules that guide his own AI coding agents.
Key points:
- A check that only hides a failure without fixing its root cause cannot be considered a fix.
- If a test continues to pass even when all functions return nothing, the test should be discarded.
- Code changes should be minimal, but sufficient to solve the task.
- Before modifying code, write a test that exposes the existing bug.
Installing this skill can help prevent AI agents from hiding errors and avoid situations where passing tests create a false impression of working code.
Installation prompt:
Install the ub-mode skill from the unclebob/ub-mode GitHub repository into my skills folder and use the /ub-mode command on the next code change. If crapper, dryer, or mutator are not installed, skip the corresponding steps.
Why it matters
AnalysisThe rules target a common failure mode in AI-assisted coding: tests that pass for the wrong reason and make broken code look healthy.
Discuss in community
Share your questions and insights with developers
Related in Ecosystem
Practical guides, core terminology, and agent skills
Bob Martin publishes coding rules for AI agents
Uncle Bob’s ub-mode skill sets guardrails for AI coding agents, requiring minimal changes, real tests, and root-cause fixes.
Open-source project with 74 skills for game development
A GitHub open-source project called awesome-gamedev-agent-skills brings together 74 skills for Unity, Godot, Unreal Engine and other game engines, with automatic skill selection and support for Claude Code and Codex.
Claude Code Projects: How a Single AI Orchestrates a Team of Autonomous Agents
A deep dive into Claude Code Projects: Coordinator and Threads architecture, parallel branches, shared memory via MEMORY.md, and cloud agent management.
Working with Git via Claude Code: A Beginner's Guide
A complete hands-on guide to Git integration in Claude Code: smart staging, automated commit messages, merge conflict resolution, GitHub CLI, and safety guardrails.
AI Agents (Autonomous Agents)
Software systems based on LLMs that can autonomously perceive the state of the environment, decompose complex goals, invoke external tools, and iteratively correct their own mistakes.
AI Slop: Codebase Contamination
A systemic phenomenon of codebase degradation due to the mass addition of low-quality, verbose, overly complex, or duplicated code generated by language models without architectural oversight.