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.
npx skills add ArdurAI/ardur-agent --skill refactor-without-breakinggit clone --depth 1 https://github.com/ArdurAI/ardur-agentWrote 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.
[](https://agentmods.dev/skills/ardurai/ardur-agent/refactor-without-breaking)<a href="https://agentmods.dev/skills/ardurai/ardur-agent/refactor-without-breaking"><img src="https://agentmods.dev/badge/skills/ardurai/ardur-agent/refactor-without-breaking/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.
<a href="https://agentmods.dev/skills/ardurai/ardur-agent/refactor-without-breaking"><img src="https://agentmods.dev/badge/skills/ardurai/ardur-agent/refactor-without-breaking.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00022 | $0.01167 |
| Opus 5.5 | $0.00009 | $0.00467 |
| Sonnet 5.5 | $0.00004 | $0.00233 |
| Haiku 4.5 | $0.00002 | $0.00117 |
Grade A, and why
refactor-without-breaking 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 1mo 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.
How it starts
The opening of the file, as written. The whole thing — 115 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Refactoring without breaking things
Refactoring means changing the structure of code without changing what it does. The discipline that makes it safe is keeping those two things — structure and behavior — strictly separate, and proving behavior is unchanged after every step. If you cannot tell whether behavior changed, you are not refactoring; you are rewriting and hoping.
The one rule
Never change behavior and structure in the same commit. A commit either:
- changes behavior (tests change, output changes) and leaves structure as-is, or
- changes structure (moves, renames, extracts) and every test passes before and after, unchanged.
When the two are mixed and something breaks, you cannot tell which change broke it. Keeping them separate means a green test suite after a structural commit is a real guarantee, and a failing one points at exactly the move you just made.
1. Lock in current behavior first
Before changing any structure, make sure the current behavior is covered.
- Run the existing tests. Note what passes. That green is your reference point — you are going to preserve it exactly.
- Find the gaps. The code you are about to move is only as safe as its test coverage. If a branch you will touch is untested, it can break silently.
- Write characterization tests for uncovered behavior: tests that assert
what the code currently does, even if that behavior is ugly or arguably
wrong. You are not fixing it now; you are pinning it so you notice if a
refactor changes it. See
@./characterization.mdfor how to write tests for code you do not fully understand yet. - Resist fixing bugs you find. Note them. A bug fix is a behavior change and belongs in its own commit, after the refactor, when you can see it clearly.
2. Refactor in small steps
Small enough that each step is obviously correct and easy to revert.
- Make one structural change: extract a function, rename a variable, inline a helper, move a type to another module, replace a magic number with a named constant.
- Run the full test suite. It must be exactly as green as before — same tests passing, none newly failing, none newly skipped.
- Commit. A passing structural commit is a safe point you can return to.
- Repeat.
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.
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.
- 1mo ago First seen · 115 lines · 22 tokens per session scan A 33d2da6d417c
refactor-without-breaking is a skill published in the GitHub repository ArdurAI/ardur-agent (2 stars, last pushed yesterday), licensed Apache-2.0. It adds 22 tokens to every session and 1,167 once invoked, about $0.0001 per session on Opus 5.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.
Other skills, from other repositories
review-duo
Review a defined code change with two Thread members independently checking standards, quality and requirements. Applies to the initiator and invited reviewer through the final report; excludes solo review, undefined scope and implementation-only requests.
Read-only review
Review the selected implementation and report correctness, security, and maintainability findings. Do not modify workspace files.
security-audit
Perform a security audit on code, checking for common vulnerabilities including injection, auth bypass, secrets leakage, and unsafe dependencies.
issue
Use when starting a chain from a GitHub issue — turning an issue URL or number into a triaged, planned, dispatched, and reviewed pull request. Classifies the thread (bug → root-cause discipline, feature → plan chain, question → drafted reply), synthesizes a spec from the issue's own acceptance criteria, then runs the…
link-check
Verify @file references in AIWG skills and agents against the linking contract — per-file or corpus-wide, with optional auto-fix.
member-studio
Use to create a Rovai member or revise and confirm the unsaved identity card and avatar for that creation. Exclude profile questions, edits to existing members, and character or avatar designs without roster creation.