1---2name: overhaul3description: Plan and execute a cautious, multi-step improvement effort for a repository or major subsystem. Use when the user asks for a broad cleanup, modernization, technical debt pass, large refactor, or coordinated improvement across architecture, tests, docs, performance, reliability, and maintainability.4---56# Overhaul78## Input910- A whole repository, platform, major subsystem, or long-running improvement program.11- Use explicit input first; otherwise infer from context, recent edits, selected files, or branch.12- Safest default: plan first and get user signoff before broad edits.1314## Workflow15161. **Define the target**. Identify goals, scope, constraints, non-goals, and whether behavior changes are allowed.172. **Baseline first**. Find available commands and run safe checks where practical: tests, build, typecheck, lint, performance or deploy checks. Record failures before changing code.183. **Map the system**. Identify entry points, core modules, data flow, external dependencies, deploy path, and docs that matter for the requested scope.194. **Find leverage**. Rank issues by user impact, correctness risk, maintenance cost, performance impact, and confidence. Separate observed facts from guesses.205. **Propose a wave plan**. Break work into reviewable chunks with explicit scope, validation, risks, and expected outcome for each chunk.216. **Get signoff**. Before editing, ask the user to approve the plan and choose execution style: validate after each major chunk or proceed through the approved plan and report at the end.227. **Execute in chunks**. For each approved chunk: inspect, edit narrowly, validate, document relevant changes, and summarize what changed.238. **Reassess between chunks**. Pause for user validation when requested, when risk increases, or when the plan needs to change.249. **Close the loop**. Re-run relevant checks, summarize completed work, behavior changes, docs changes, remaining risks, and follow-up work.2526## Output2728- Baseline checks and measurements29- System map30- Prioritized findings and risks31- Approved wave plan32- Per-chunk validation results33- Behavior changes, if any, called out explicitly34- Documentation updated or gaps identified35- Remaining risks and follow-ups3637## Examples3839- `overhaul this app without changing behavior`40- `plan a technical debt cleanup for this repo`41- `modernize this subsystem, but ask before each big chunk`42- `review the platform and propose a multi-step improvement plan`4344## Guardrails4546- Do not treat overhaul as permission for a rewrite. Preserve behavior unless the user explicitly approves behavior changes.47- Do not start broad edits before baseline, system map, plan, and user signoff.48- Do not bundle unrelated risky changes into one diff.49- Do not optimize from vibes; tie performance work to measurements or a clearly stated hypothesis.50- Ask before removing behavior, APIs, config, migrations, or docs that may be intentional.51- Use `review`, `refactor`, `test`, `document`, `deploy`, or `second-opinion` as follow-up modes when a chunk needs that sharper workflow.