go-simplify
Installation
SKILL.md
Go Simplify
Audit a Go codebase for three classes of excess — over-design, over-optimization, and over-defensive coding — and safely slim it down. Two deliverables: the applied behavior-neutral cleanups, and a written list of findings deliberately left alone.
Rules (non-negotiable, in this order)
- Never break the exported API. Change unexported internals only; even a dead exported symbol goes into the report, not the diff. If the repository ships a check such as
make api-compat, it must run before you finish. - Satisfy the tests. The test suite is this skill's safety net, not an obstacle — see "Test-vetoed findings" below.
- Zero behavior change. That includes behavior on invalid input: turning code that silently ignores a nil option into code that panics is a bug you introduced.
- A scan result is a hypothesis, not a fact. Every "dead code" claim produced by a subagent or a first-pass scan must be verified by reading the source yourself, one finding at a time, before you touch anything. In practice roughly 5% of "dead code" claims are wrong.
Test-vetoed Findings
A failing test means the "dead code" claim was wrong. Roll that change back immediately, record it
in the legitimate-defense list, and move on. Never adjust the test to accommodate the cleanup. Two
worked cases are in references/review-guardrails.md; read them before deleting any unexported
identifier.