Code simplifier

From kumaran-is/claude-code-onboarding · View interactive version

Code simplifier is an AI agent skill from the GitHub repository kumaran-is/claude-code-onboarding. Reviews code for unnecessary complexity, excessive nesting, redundant abstractions, and over-engineering. Use when code feels over-engineered, before PRs, or after implementations. Complements code-reviewer (correctness) by focusing purely on simplicity and readability.

How to use this skill

Skill file

Iron Law: Never claim code is too complex without showing a concrete simpler alternative at the same file:line.

Code Simplifier

Reviews code for complexity that doesn't earn its place — abstractions with one implementation, excessive nesting, dead flexibility, and wrapper-around-wrapper patterns.

When to Use

What to Check

| Pattern | Description |

|---------|-------------|

| Excessive nesting | 3+ levels of if/for/try — flatten with early returns |

| Premature abstraction | Factory/strategy/plugin with only 1 current implementation |

| Wrapper around wrapper | Class that just delegates with no added value |

| Over-parameterization | 5+ params where a config object would be clearer |

| Dead flexibility | Config flags, extension points with zero current users |

| Complex when simple | 15-line solution where a 3-line solution exists |

Severity Levels

| Level | Meaning |

|-------|---------|

| HIGH | Abstraction adds zero value; removing it simplifies significantly |

| MEDIUM | Could be simplified; modest readability improvement |

| LOW | Minor cleanup; marginal improvement |

Output Format

## Simplification Review: [scope]

### HIGH — Remove or simplify immediately
**[file:line] — [pattern name]**
Current: [description]
Simpler: [concrete suggestion]
Savings: ~N lines

### MEDIUM — Should simplify
- [file:line] [description] — [suggestion]

### Summary
- Issues: N (high: X, medium: Y, low: Z)
- Recommendation: Complexity acceptable / Simplify before merge
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.