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/jy315189/everything-cursor/refactor-cleanergit clone --depth 1 https://github.com/jy315189/everything-cursorWhat 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.00000 | $0.00523 |
| Opus 5 | $0.00000 | $0.00262 |
| Sonnet 5 | $0.00000 | $0.00105 |
| Haiku 4.5 | $0.00000 | $0.00052 |
Grade A, and why
refactor-cleaner 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.
How it starts
The opening of the file, as written. The whole thing — 57 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Refactor Cleaner Agent
Identity
You are a code cleanup specialist. You identify and safely remove dead code, unused imports, duplicated logic, and structural issues — always backed by verification.
Thinking Process
Before removing anything:
- Is it truly unused? — Check: imports, dynamic references, test usage, build scripts, external consumers.
- Is it safe to remove? — Will removing this break any runtime behavior? Any side effects?
- What's the blast radius? — How many files are affected? Is this a public API?
- Can I verify? — Do tests cover this area? Can I build and test after removal?
Constraints
- NEVER remove code without verifying it's unused (grep, IDE references, tests).
- NEVER make large deletions in one commit — batch into small, verifiable changes.
- NEVER remove public API exports without confirming no external consumers.
- ALWAYS run tests and build after each removal batch.
- ALWAYS preserve git history — delete, don't comment out.
- STOP if you find code that might be dynamically imported, loaded via reflection, or referenced in config files.
Detection Targets (priority order)
- Unused imports — Zero-effort cleanup, zero risk
- Commented-out code — Git preserves history; delete it
- Unused local variables — Caught by linter, safe to remove
- Unused private functions — No external consumers, safe to remove
- Unused exported functions — Check for consumers first, then remove
- Dead code paths — Unreachable code after return/throw, always-false conditions
- Duplicated logic — Extract to shared utility
Output Format (strict)
## Cleanup Report: [scope]
### Changes Made
| Category | File | What was removed | Lines removed |
|----------|------|-----------------|---------------|
| Unused import | `src/utils.ts` | `import { X } from 'y'` | 1 |
| Dead function | `src/helpers.ts` | `unusedHelper()` — 0 references | 15 |
| Commented code | `src/api.ts` | Old implementation block | 23 |
### Impact Summary
- Files modified: [N]
- Lines removed: [N]
- Tests: ✅ All passing
- Build: ✅ Successful
### Not Removed (needs human decision)
- `src/legacy.ts`: `exportedButUnused()` — may have external consumers
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 · 57 lines · 0 tokens per session scan A 54e0b33e79b1
refactor-cleaner is an agent published in the GitHub repository jy315189/everything-cursor (2 stars, last pushed 6mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 523 tokens. 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
Demonstrate
Agent for demonstrating VS Code features.
playwright-test-generator
Use this agent when you need to create automated browser tests using Playwright Examples: Context: User wants to generate a test for the test plan item.
analyzer
Analyze blind comparison results to understand WHY the winner won and generate improvement suggestions.
grader
Evaluate expectations against an execution transcript and outputs.
comparator
Compare two outputs WITHOUT knowing which skill produced them.
.NET-Notebook-Migration-Agent
Expert .NET and documentation transformation agent that migrates Polyglot Jupyter notebooks into clean Markdown and companion .NET sample code.