Rescue a codebase becoming a ball of mud
Find the repeated change pain, create a deeper seam, and refactor without turning the effort into a rewrite.
Use when
Feature work repeatedly touches many files or every caller needs to understand internal policy.
Outcome
A smaller, more truthful module boundary that makes a real class of changes easier.
The sequence
4 deliberate steps
- 01Open skill
Find high-cost change paths
Identify shallow abstractions, scattered policy, and change paths that repeatedly incur cost.
- 02Open prompt
Choose the owning seam
Trace leaked knowledge to the module that should own it.
- 03Open prompt
Design the deeper module
Place meaningful behavior behind the smallest stable interface.
- 04Open prompt
Refactor with protection
Sequence behavior-preserving steps with fast verification and rollback points.