ca-refactor
Restructure code with behavioral parity proven through unmodified pre-existing tests, then refactor. No behavior change.
npx skills add arbiterForge/codeArbiter --skill ca-refactor --agent codex
Same command for any agent — swap --agent for claude-code, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# $ca-refactor — behavior-preserving restructure The only permitted entry to refactor work. A refactor that cannot prove parity through unmodified pre-existing tests is a feature change in disguise and routes to `$ca-feature`. Two required parts: the **surface** (exact files, functions, classes, or methods — vague surfaces like "the auth module" are rejected) and the **motivation** (why the restructure is worth doing). ## Flow Routes to the `refactor` skill — six phases: 1. **Surface identification** — lock the exact files, symbols, and public signatures. 2. **Parity coverage proof** — demonstrate pre-existing tests already cover the named surface, with at least one direct test per public method. 3. **Red parity tests (conditional)** — if the refactor exposes a new test seam, route to `tdd` Phase 1 to write failing tests pinning the seam's contract first. 4. **Implementation** — apply the restructure mechanically within the surface table; no new behavior, branches, error paths, or side effects. 5. **Parity verification** — the full pre-existing suite passes with zero edits to any pre-existing test file. 6. **Lint / coverage gate** — lint, type-check, and coverage clear; surface cov
- Flow
- Routes to
- When NOT to use
- Hard gate
What does the ca-refactor skill do?
Restructure code with behavioral parity proven through unmodified pre-existing tests, then refactor. No behavior change.
How do I install it?
Run `npx skills add arbiterForge/codeArbiter --skill ca-refactor --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From arbiterForge/codeArbiter, a repository with 138 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
