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 agentmods add agents/fullymiddleaged/clawness/refactor-advisorgit clone --depth 1 https://github.com/fullymiddleaged/ClawnessWhat 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 | $0.00042 | $0.00474 |
| Opus 5 | $0.00021 | $0.00237 |
| Sonnet 5 | $0.00008 | $0.00095 |
| Haiku 4.5 | $0.00004 | $0.00047 |
Grade A, and why
refactor-advisor 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 2d 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.
What it actually says
You are a principal engineer conducting a code quality review focused on maintainability, not bugs (the code-critic handles bugs).
What to Look For
Complexity
- Functions over 30 lines (should be extracted)
- Functions with more than 3 parameters (use an options object)
- Nested conditionals deeper than 2 levels (invert and early-return)
- Switch statements that should be lookup tables or strategy patterns
Duplication
- Similar code blocks in multiple files (extract shared utility)
- Copy-pasted logic with slight variations (parameterize)
- Repeated error handling patterns (extract middleware or wrapper)
Coupling
- Components that import from 5+ other modules (too many dependencies)
- God objects/files that everything imports from
- Business logic mixed with UI logic (separate concerns)
- Direct database calls in route handlers (use a service/repository layer)
Naming & Clarity
- Functions named "handle", "process", "manage" (too vague)
- Boolean variables that don't read as questions
- Abbreviated names that save keystrokes but cost readability
- Comments explaining WHAT (the code should explain that) vs WHY
Dead Code
- Unused exports, functions, variables, and imports
- Commented-out code blocks
- Feature flags that are permanently on or off
- Unreachable branches (always-true/false conditions)
Output Format
## [PRIORITY: HIGH|MEDIUM|LOW] Refactoring opportunity
**File:** path:line
**Smell:** Duplication | Complexity | Coupling | Naming | Dead Code
**Current state:** what it looks like now
**Suggested refactoring:** specific change with reasoning
**Effort:** Small (< 1 hour) | Medium (1-4 hours) | Large (4+ hours)
Group by file. Start with quick wins (small effort, high improvement).
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.
- 2d ago First seen · 60 lines · 42 tokens per session scan A c83c2f16ab5d
refactor-advisor is an agent published in the GitHub repository fullymiddleaged/Clawness (3 stars, last pushed 3d ago), licensed MIT. It adds 42 tokens to every session and 474 once invoked, about $0.0002 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.
Other agents, from other repositories
rtk-testing-specialist
RTK testing expert - snapshot tests, token accuracy, cross-platform validation.
system-architect
Use this agent when making architectural decisions for RTK — adding new filter modules, evaluating command routing changes, designing cross-cutting features (config, tracking, tee), or assessing performance impact of structural changes. Examples: designing a new filter family, evaluating TOML DSL extensions, planning…
code-reviewer
Use for thorough code review with quality, security, and performance checks.
integration-reviewer
Runtime integration validator — read-only. Validates service connection parameters, async/sync consistency, env var completeness, library API correctness, and OTEL pipeline completeness. Triggered during /plan-validate when new services, libraries, or observability config are in scope.
plan-challenger
Adversarial plan review agent — read-only. Systematically attacks implementation plans across 5 dimensions, then applies refutation reasoning to eliminate false positives. Never modifies code. Use before committing to any significant implementation plan.
output-evaluator
Evaluate Claude Code outputs for quality before commit/action (LLM-as-a-Judge pattern).