Code Quality

Code Quality skills for your AI agent.

Five skills for the code itself, at the level of files, functions and names rather than systems. Clean Code supplies the readability rules — intention-revealing names, functions that do one thing, error handling that doesn’t bury the logic. Refactoring supplies the named, behavior-preserving transformations and the discipline of keeping tests green between steps. Software Design aims at complexity, judging modules by how much they hide behind how small an interface. Legacy Code handles the case where there are no tests to protect anything. Pragmatic Programmer covers the habits underneath all of it: DRY as a rule about knowledge, orthogonality, tracer bullets.

This is the category that changes agent output most directly, because agents write code constantly and default to whatever compiles. With these loaded you get names that survive review, a long function split with a named refactoring rather than an ad-hoc rewrite, characterization tests before anyone touches the frightening module, and an argument — sometimes a pushback — when a proposed split would spread complexity rather than reduce it.

5 skills Updated Free & MIT-licensed

Which code quality skill should I install first?

Ask what is wrong with the file actually open in front of you. No tests, and nobody left on the team wrote it → Legacy Code first, always: it finds the seams and writes characterization tests that pin current behavior before anything moves. Tests exist and the structure is wrong — a conditional that has grown a branch every quarter, a god class → Refactoring, which names the smell, picks the matching transformation like Extract Method or Replace Conditional with Polymorphism, and keeps the tests green between each step. The structure is fine and the prose isn’t, with names like data2 and eighty-line functions → Clean Code. Every new feature touches six files, or an interface has more parameters and special cases than the implementation behind it saves you → Software Design, which treats interface-to-implementation ratio as the primary signal. And when the problem is habits rather than any one file — the same knowledge duplicated in three places, modules that break each other on every change, a new system you want proved end to end before filling it in → Pragmatic Programmer.

The pairing that does the most work is Clean Code with Refactoring: one names what good looks like, the other performs the surgery safely. If the code has no tests, put Legacy Code in front of both — everything else assumes a safety net you don’t have yet.

All 5 Code Quality skills

Clean Code

Clean Code — Robert C. Martin

Clean Code is a free AI agent skill built on Robert C. Martin's book. It gives your agent the rules that make code readable — intention-revealing names, functions that do one thing, error handling that doesn't obscure logic — and applies them while it writes and reviews, not in a cleanup pass afterwards.

  • Meaningful Names
  • Small Functions
  • Comments Are a Failure

Try “Review this module for Clean Code violations and suggest refactors using clean-code skill”

Pragmatic Programmer

The Pragmatic Programmer — Andrew Hunt & David Thomas

Hunt and Thomas's The Pragmatic Programmer is about the craft habits that outlast any framework, and this free skill hands them to your agent: DRY applied to knowledge rather than characters, orthogonal design, tracer bullets that prove a path end to end, and contracts that state what a function actually promises.

  • DRY Principle
  • Orthogonality
  • Tracer Bullets

Try “Identify DRY violations across these modules and suggest consolidation using pragmatic-programmer skill”

Refactoring

Refactoring — Martin Fowler

Install this free skill and your agent stops improvising structural changes. It works from Martin Fowler's catalogue instead — naming the smell it sees, picking the matching transformation, and applying it in steps small enough to keep the tests green, so behaviour never changes while the design does.

  • Code Smells
  • Extract Method/Class
  • Replace Conditional with Polymorphism

Try “Identify code smells in this module and suggest specific refactorings using refactoring-patterns skill”

Software Design

A Philosophy of Software Design — John Ousterhout

One target drives everything in John Ousterhout's A Philosophy of Software Design: reducing complexity. This free skill points your agent at it too, arguing for deep modules behind simple interfaces, for hiding information rather than passing it around, and for spending design effort now instead of paying interest later.

  • Deep vs Shallow Modules
  • Information Hiding
  • Strategic vs Tactical Programming

Try “Evaluate whether these modules are deep or shallow and suggest improvements using software-design-philosophy skill”

Legacy Code

Working Effectively with Legacy Code — Michael C. Feathers

Code without tests is the case Michael Feathers wrote a book about, and this free skill is your agent's procedure for it: find the change points, find the seams, break the dependencies, pin current behaviour with characterization tests — and only then change anything.

  • The Change Algorithm
  • Seams
  • Characterization Tests

Try “Get this class with a hard-wired database connection under test using working-with-legacy-code skill”

npx skills add wondelai/skills --all --global

This skill is compatible with Claude, Claude Code, Claude Cowork, Codex, Cursor, OpenClaw, Hermes Agent, and other agentskills.io-compatible agents.

Frequently asked questions

Clean Code and Software Design disagree about function length. Which one wins?

Neither, and that’s deliberate. Clean Code argues functions should be small and do one thing. Ousterhout argues that splitting purely for brevity creates shallow modules and spreads complexity across more places than it removes. Installed together, they’ll disagree over a long-but-cohesive function — and you’ll get the complexity argument stated rather than a rule applied silently. If your team has settled the question, say so in the prompt and your agent follows your convention.

Do these apply to code my agent writes, or only to code review?

Both, and the writing side is where you feel it most. Skills load when a task calls for them, so they shape new code as it’s produced — naming, function boundaries, error handling — rather than waiting for a cleanup pass. The review path is still worth using explicitly: point the agent at a module and ask for violations, and you’ll get named smells and specific transformations instead of general remarks about readability.

Some of these books are decades old. Are they still right for AI-written code?

The failure mode they address got more common, not less. Generated code compiles, passes, and reads like nobody expected to maintain it — which is precisely the problem Fowler, Martin and Feathers were writing about. The parts that dated are stylistic and language-specific; the parts that matter here are about naming, coupling and safe change, and those don’t care who typed the code. Treat the contested positions as informed opinion to argue with.

How is this different from the Improve Code Quality journey?

The journey takes a vibe-coded prototype to production by running these skills plus others in a fixed order, with a decision question at each phase and a written artifact you keep. Installing skills individually is for the narrower job — this one module, this pull request, this untested file you have to change on Tuesday. Same frameworks, different unit of work: a program versus a single tool.

Work with us

We build the skills you already use. Now we’ll build yours.

Custom skills · Subagents · MCP integrations — shipped to production, not demoed.

Sprints from $3K · shipped to production, or you don’t pay the final milestone.