What problem does it solve? Refactoring often goes wrong when developers mix behavior changes with structural changes, take steps too large to verify, or lack a way to confirm nothing broke. This Skill enforces a disciplined refactoring workflow so every change stays reversible and behavior-preserving. ## Core Features & Use Cases - Pre-flight checks: Requires a verification method (tests, snapshots, or comparison scripts), a clean working tree, and a concrete reason before touching any code. - Small-step discipline: Defines what a valid single step looks like (extract a function, rename a symbol, move a function) and mandates verification after each step instead of batching. - Ordered playbooks: Provides step-by-step sequences for extracting functions, splitting large files, eliminating duplication, and changing interfaces with old/new coexistence. - Stop and rollback rules: Specifies when to revert (verification failing over ten minutes, scope creep, needing a behavior change) and requires separate refactor: commits. - Use Case: When asked to split a 500-line module, the Skill moves code blocks first and verifies, then adjusts naming and interfaces as separate verified steps, committing each with a refactor: message explaining the motivation. ## Quick Start Ask the AI to refactor this module by splitting the large function into smaller ones, verifying behavior after each step and keeping refactoring in separate commits.