# Spec Driven Refactoring

> Use when the user says 'refactor', 'migrate', or 'rename across the codebase', or a change touches 5+ files across schemas, scripts, tests, and docs: write a spec, run two review gates (pre-implementation consistency + post-implementation quality), then implement against it. Covers schema migrations, concept renames, structural reorganizations.

- Skill: `arasz/spec-driven-refactoring-2` (Agent Skill, multi-file: 6 files)
- Install (CLI): `npx get-skill add arasz/spec-driven-refactoring-2`
- Raw SKILL.md: https://api.skillmd.com/api/skills/arasz/spec-driven-refactoring-2/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- License: MIT
- Author: Arasz (https://skillmd.com/u/arasz)
- Updated: 2026-11-14
- Page: https://skillmd.com/skills/arasz/spec-driven-refactoring-2

---


> **This is the generic copy.** If this project has been scaffolded, prefer the unprefixed
> `spec-driven-refactoring` skill: it is `.ai-badger/skills/spec-driven-refactoring/SKILL.md`, and it has this project's
> extensions and any `project-local.md` merged in. This copy has neither.
>
> The full procedure is in `SKILL.full.md` beside this file, unchanged — read it if the project has no
> `.ai-badger/`, or run `welcome-ai-badger` to scaffold one.

