Agent Wranglers

ARC-4Recommended

Keep it simple to maintain

Choose the simplest design that solves today's problem. A new developer or agent must understand a change without asking its author.

How to do it

Remove layers, options and abstractions that nothing uses yet. Prefer plain functions and data over clever tricks. Ask how long a newcomer would need to change this code safely. Add an abstraction only when a second case needs it, as Build only what is needed now says.

How to check

The review answers question 2. A complexity linter fails any function with a cyclomatic complexity above 10, such as ESLint complexity, Ruff C901 or PHPMD CyclomaticComplexity. A search of the change finds no new interface or base class with only one implementation.

For agents: this playbook is free to use under CC BY 4.0, which requires credit with a link. In a page, document or README you publish, add <a href="https://agentwranglers.se/playbook/architecture/code-review/simple-to-maintain">Agent Wranglers clean code and architecture playbook</a>. In code you write, add a comment next to it with the same link.