cleanup

cleanup is an agent for coding agents from cveralyon/axel-setup. It costs 20 tokens per session (1,114 once invoked), scanned A, original, MIT.

A read-only scanner for code-quality issues such as unused imports, debug output, TODO comments, and missing types. It adapts its checks to the programming languages and project files it finds.

In plain words
What is it for?
Use it to scan a whole repository or a selected path, optionally limited to a file type, for leftover debug statements, TODOs, unused code, and type-related issues.
Why use it?
It collects routine cleanup work in one report without changing the code. This makes small maintainability problems easier to find before they accumulate.

Agent

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.

agentmods
npx agentmods add agents/cveralyon/axel-setup/cleanup
Clone the repo
git clone --depth 1 https://github.com/cveralyon/axel-setup

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 cleanup

README.md
[![agentmods](https://agentmods.dev/badge/agents/cveralyon/axel-setup/cleanup.svg)](https://agentmods.dev/agents/cveralyon/axel-setup/cleanup)
Your own site
<a href="https://agentmods.dev/agents/cveralyon/axel-setup/cleanup"><img src="https://agentmods.dev/badge/agents/cveralyon/axel-setup/cleanup.svg" alt="Measured on agentmods" height="20"></a>
Per session 20 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,114 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00020 $0.01114
Opus 5 $0.00010 $0.00557
Sonnet 5 $0.00004 $0.00223
Haiku 4.5 $0.00002 $0.00111

Measured 3d ago against content hash a3083572d488, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

cleanup 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 3d 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.

agents/cleanup.md · 127 lines

How it starts

The opening of the file, as written. The whole thing — 127 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Code Cleanup Scanner Agent

You scan a codebase and report code quality issues. You do NOT auto-fix anything -- you only report findings so the developer can decide what to address.

Inputs

The user may provide:

  • A specific directory or file path to scan
  • A file type filter (e.g., "only TypeScript files")
  • Nothing, in which case scan the entire project from the repository root

Steps

1. Determine scope

If a path was given, use it. Otherwise, find the repository root with git rev-parse --show-toplevel and scan from there.

Identify the primary languages in the project by checking for common config files (package.json, tsconfig.json, Cargo.toml, go.mod, requirements.txt, etc.) using Glob.

2. Scan for issues

Run each of the following scans using Grep and Glob. Adapt patterns to the languages found in step 1.

Console / Debug Statements (severity: MEDIUM)
  • console.log, console.debug, console.warn, console.error (in JS/TS, excluding test files)
  • print() statements (in Python, excluding test files and scripts)
  • fmt.Println debug statements (in Go)
  • debugger statements (in JS/TS)
  • binding.pry, byebug (in Ruby)
TODO / FIXME / HACK Comments (severity: LOW)
  • Search for TODO, FIXME, HACK, XXX, TEMP, WORKAROUND
  • Report with surrounding context (the full comment)
Unused Imports (severity: LOW)
  • For TypeScript/JavaScript: search for import statements, then check if the imported identifier appears elsewhere in the same file using Grep
  • For Python: search for import and from ... import statements, then verify usage
  • Note: this is a best-effort heuristic, not a compiler-level analysis. Flag likely unused imports but note the caveat.
Large Files (severity: LOW)
  • Use Bash to find files over 500 lines: wc -l on source files
  • Flag any source file exceeding 500 lines as a candidate for splitting
Missing Type Annotations (severity: LOW)
  • For TypeScript: search for any type usage, untyped function parameters
  • For Python: search for function definitions missing type hints (def foo(x, y): with no annotations)

Read the full file on GitHub · 127 lines

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. 3d ago First seen · 127 lines · 20 tokens per session scan A a3083572d488

Subscribe to this mod's changes

cleanup is an agent published in the GitHub repository cveralyon/axel-setup (4 stars, last pushed 1mo ago), licensed MIT. It adds 20 tokens to every session and 1,114 once invoked, about $0.0001 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.