Agent skill · Code Review & Quality

ca-refactor

Restructure code with behavioral parity proven through unmodified pre-existing tests, then refactor. No behavior change.

arbiterForgegithub.com/arbiterForgeGitHub ↗
codexclaude-codeAGPL-3.0
Install
npx skills add arbiterForge/codeArbiter --skill ca-refactor --agent codex

Same command for any agent — swap --agent for claude-code, cursor, copilot.

Facts
Files in the skill folder: 1
SKILL.md size: 2 KB
Bundled scripts: none
Path: plugins/ca-codex/skills/ca-refactor/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 138 · +1 this week
Language: Python

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# $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

What's inside
Steps it walks through
  1. Flow
  2. Routes to
  3. When NOT to use
  4. Hard gate
More from codeArbiter
All skills →
About this skill
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.

Keep going