refactorer

refactorer is a skill for Claude Code from alexmond/alexmskills. It costs 78 tokens per session (314 once invoked), scanned A, original, MIT.

A coding role for restructuring software into clearer parts while keeping its behavior unchanged.

In plain words
What is it for?
Use it to separate responsibilities, improve modularity, lower coupling between components, and record durable lessons in the repository's refactorer role.
Why use it?
It helps reduce tangled dependencies and makes code easier to understand and modify without intentionally changing what it does.

Skill for Claude Code

Written for Claude Code: disable-model-invocation in frontmatter.

Part of the roles plugin — 9 skills shipped together

Good fit Use it to separate responsibilities, improve modularity, lower coupling between components, and record durable lessons in the repository's refactorer role.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/alexmond/alexmskills/refactorer
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add alexmond/alexmskills --skill refactorer
Clone the repo
git clone --depth 1 https://github.com/alexmond/alexmskills

Made for: Claude Code.

Or install roles, the plugin that ships this one along with the rest of its 9 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for refactorer

README.md
[![agentmods](https://agentmods.dev/badge/skills/alexmond/alexmskills/refactorer/github.svg)](https://agentmods.dev/skills/alexmond/alexmskills/refactorer)
Your own site
<a href="https://agentmods.dev/skills/alexmond/alexmskills/refactorer"><img src="https://agentmods.dev/badge/skills/alexmond/alexmskills/refactorer/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for refactorer

Your own site · 80×15
<a href="https://agentmods.dev/skills/alexmond/alexmskills/refactorer"><img src="https://agentmods.dev/badge/skills/alexmond/alexmskills/refactorer.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 78 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 314 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00078 $0.00314
Opus 5 $0.00039 $0.00157
Sonnet 5 $0.00016 $0.00063
Haiku 4.5 $0.00008 $0.00031

Measured 9d ago against content hash bbd1e1037c9f, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

refactorer scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/roles/skills/refactorer/SKILL.md · 16 lines

What it actually says

Clean architecture rebuild

Target: $ARGUMENTS

  1. Load the role. If .claude/roles/refactorer.md exists, read it — it is the canonical, evolving copy. If not, read role.md (the seed shipped with this skill), copy it verbatim to .claude/roles/refactorer.md, then proceed.
  2. Apply it. Adopt the Charter and Body; honor every entry under ## Learnings (core) and ## Learnings (solo).
  3. Work the target following the Body's method and deliverables.
  4. Capture a learning. If this run surfaced a durable, reusable lesson (a fix that took more than one cycle, a stack- or repo-specific gotcha, a stated user preference), append one line under ## Learnings (solo) in .claude/roles/refactorer.md: - YYYY-MM-DD — <one sentence>. Don't log routine one-pass outcomes.
Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 16 lines · 78 tokens per session scan A bbd1e1037c9f

Subscribe to this mod's changes

refactorer is a skill published in the GitHub repository alexmond/alexmskills (6 stars, last pushed yesterday), licensed MIT. It adds 78 tokens to every session and 314 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

verify-implementation

A workflow that runs a project’s verification skills to produce a report on coding patterns, architecture rules, and project conventions. It is intended for work after implementation, before a pull request, or during code review.

sangrokjung/claude-forge · 37 tokens

review-loop

Run the adversarial verification loop — implement, then hand the change to a fresh checker that did not write it, fix what it finds, and re-dispatch until APPROVE. Use before claiming any behavioural change is done, and on requests like "review loop", "adversarial review", "independent review", "get this verified"…

sangrokjung/claude-forge · 100 tokens

frontend-code-review

Trigger when the user requests a review of frontend files (e.g., .tsx, .ts, .js). Support both pending-change reviews and focused file reviews while applying the checklist rules.

sangrokjung/claude-forge · 42 tokens

review-implementing

Process and implement code review feedback systematically. Use when user provides reviewer comments, PR feedback, code review notes, or asks to implement suggestions from reviews.

mhattingpete/claude-skills-marketplace · 35 tokens

code-auditor

Performs comprehensive codebase analysis covering architecture, code quality, security, performance, testing, and maintainability. Use when user wants to audit code quality, identify technical debt, find security issues, assess test coverage, or get a codebase health check.

mhattingpete/claude-skills-marketplace · 56 tokens

error-audit

Audit code for silent error swallowing, fallbacks to degraded alternatives, backwards compatibility shims, and UI that fails to show errors to the user. Finds and fixes all occurrences in the specified scope.

markmdev/meridian · 43 tokens