clean

clean is a skill for Claude Code from mystilleef/spae-framework. It costs 13 tokens per session (852 once invoked), scanned C, original, MIT.

A code-cleaning workflow that runs purification and refactoring agents one after another on selected files or folders.

In plain words
What is it for?
Use it to remove code smells and refactor target code through repeated automated passes.
Why use it?
It turns repeated cleanup passes into a controlled process and stops when no further changes are found or an error occurs.

Skill for Claude Code

Written for Claude Code: user-invocable in frontmatter. Also seen: mentions subagents.

Good fit Use it to remove code smells and refactor target code through repeated automated passes.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/mystilleef/spae-framework/clean
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 mystilleef/spae-framework --skill clean
Clone the repo
git clone --depth 1 https://github.com/mystilleef/spae-framework

Made for: Claude Code.

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 clean

README.md
[![agentmods](https://agentmods.dev/badge/skills/mystilleef/spae-framework/clean/github.svg)](https://agentmods.dev/skills/mystilleef/spae-framework/clean)
Your own site
<a href="https://agentmods.dev/skills/mystilleef/spae-framework/clean"><img src="https://agentmods.dev/badge/skills/mystilleef/spae-framework/clean/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 clean

Your own site · 80×15
<a href="https://agentmods.dev/skills/mystilleef/spae-framework/clean"><img src="https://agentmods.dev/badge/skills/mystilleef/spae-framework/clean.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 13 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 852 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 1 finding. 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.00013 $0.00852
Opus 5.5 $0.00005 $0.00341
Sonnet 5.5 $0.00003 $0.00170
Haiku 4.5 $0.00001 $0.00085

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

Security

Grade C, and why

clean scanned grade C with 1 finding 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.

Hidden instructionshighPrompt injection

Directives inside HTML comments, invisible characters or bidirectional overrides are read by the model and not by the person reviewing the file.

<!-- prettier-ignore-start -->
skills/clean/SKILL.md · 114 lines

How it starts

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

Clean

When to use

  • The user wants to clean smelly code autonomously using the purify and refactor agents.

Goal

  • Run purification and refactoring subagents sequentially to clean target code.

Input

  • Accept optional arguments (file or folder paths).

Workflow

  1. Purification Loop:
    • Immediately use the subagent tool to spawn a purify subagent (pass optional arguments).
    • Await purification result.
    • If subagent returns No Changes status, exit loop and proceed.
    • On Failed status or any process failure, halt immediately and surface the error.
    • Loop back to spawn another purify subagent if the previous pass returns Complete.
  2. Refactoring Loop:
    • Immediately use the subagent tool to spawn a refactor subagent (pass optional arguments).
    • Await refactoring result.
    • If subagent returns No Changes status, exit loop and finish.
    • On Failed status or any process failure, halt immediately and surface the error.
    • Loop back to spawn another refactor subagent if the previous pass returns Complete.

Directives

  • Always use the subagent tool for subagent invocation.
  • Pass the optional argument verbatim to both subagents; never read or expand file-path arguments.
  • Rely on subagent status blocks to direct the loop.
  • Halt immediately on subagent Failed status or any process failure (crash, timeout, AgentError).
  • List of agents permitted to invoke:
    • purify
    • refactor

Constraints

  • Restrict your activities to:
    • Using the subagent tool to spawn agents.
    • Using agent results to direct the loop or advance the workflow.
  • Perform orchestration only; never edit codebase files, tests, or documentation.
  • Operate strictly in read-only mode.
  • Perform purification to completion first, before starting refactoring.
  • Never interleave purification with refactoring.
  • Never run subagents in parallel or concurrently.
  • Never activate skills.
  • Never invoke agents outside the permitted list.
  • Never prompt the user for decisions mid-run; let blockers halt execution.
  • Never perform activities beyond subagent invocation, state tracking, and reporting.

Read the full file on GitHub · 114 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 Changed b3280574e70b
  2. 1mo ago First seen · 114 lines · 13 tokens per session scan C d2ef839aaecd

Subscribe to this mod's changes

clean is a skill published in the GitHub repository mystilleef/spae-framework (2 stars, last pushed 3d ago), licensed MIT. It adds 13 tokens to every session and 852 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it C with 1 finding (hidden instructions). 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

ahk-review

Preview a code review against ticket/objective alignment, with deep semantic (name-vs-behavior) analysis. No tasks created, no harness tracking.

enmanuelmag/agent-harness-kit · 35 tokens

red-team-assessment

Run an evidence-backed adversarial security assessment through the local llm-cli-gateway stdio MCP server. Use for code, architecture, configuration, data-flow, or supply-chain security review across the full Claude, Codex, Gemini, Grok, Mistral, Devin, and Cursor roster.

verivus-oss/llm-cli-gateway · 65 tokens

multi-llm-consensus

Obtain complete, evidence-backed agreement from a required roster of llm-cli-gateway providers. Use for high-stakes generation, conflict resolution, or final quality gates that require unconditional approval from every required reviewer.

verivus-oss/llm-cli-gateway · 49 tokens

agent-codex-gate

Pattern for spawning subagents whose work must receive an evidence-backed, unconditional Codex review through the local llm-cli-gateway stdio MCP server. Use when parallel implementation tasks need an independent Codex quality gate.

verivus-oss/llm-cli-gateway · 50 tokens

codex-review-gate

Submit completed work to Codex through the local llm-cli-gateway stdio MCP server and continue until an evidence-backed, unconditional approval. Use after implementation, before merging, or whenever a process requires Codex sign-off.

verivus-oss/llm-cli-gateway · 51 tokens

python-engineering-guidelines

General Python engineering standards for writing, reviewing, and refactoring maintainable code. Use when Codex works on Python code, especially in medium/large projects, runtime adapters, APIs, SDK integrations, async services, stateful systems, or refactors where readability, explicit typing, module boundaries, side…

anywhere-labs/Agents-Anywhere · 75 tokens