sweep

sweep is a skill for Claude Code, Codex from dkstm95/hope. It costs 71 tokens per session (630 once invoked), scanned A, original, MIT.

A maintenance command for applying behavior-preserving cleanup to a codebase and the files that directly support it.

In plain words
What is it for?
Removing dead code, simplifying implementation, and updating directly related tests, configuration, build files, documentation, comments, examples, generated files, or assets.
Why use it?
It helps make code easier to maintain without changing how the software works. It only starts after you explicitly invoke the Hope Sweep command.

Skill for Claude CodeCodex

Part of the hope plugin — 6 skills shipped together

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 skills/dkstm95/hope/sweep
Any agent
npx skills add dkstm95/hope --skill sweep
Clone the repo
git clone --depth 1 https://github.com/dkstm95/hope

Made for: Claude Code, Codex.

Or install hope, the plugin that ships this one along with the rest of its 6 skills.

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 sweep

README.md
[![agentmods](https://agentmods.dev/badge/skills/dkstm95/hope/sweep.svg)](https://agentmods.dev/skills/dkstm95/hope/sweep)
Your own site
<a href="https://agentmods.dev/skills/dkstm95/hope/sweep"><img src="https://agentmods.dev/badge/skills/dkstm95/hope/sweep.svg" alt="Measured on agentmods" height="20"></a>
Per session 71 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 630 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.00071 $0.00630
Opus 5 $0.00036 $0.00315
Sonnet 5 $0.00014 $0.00126
Haiku 4.5 $0.00007 $0.00063

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

Security

Grade A, and why

sweep 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 4d 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.

plugins/hope/skills/sweep/SKILL.md · 68 lines

How it starts

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

Hope Sweep

Use the active host session to apply proven, behavior-preserving maintenance to operating code and its directly supporting material.

Read ../../references/code-maintenance.md before inspecting the target. Read ../write/references/writing-standard.md before drafting user-facing language.

Require explicit invocation

Start only after the person explicitly invokes $hope:sweep in Codex, /hope:sweep in Claude Code, or the host's namespaced Hope Sweep command.

Do not infer Sweep from a request to inspect a project, suggest improvements, choose the next task, review work, fix a bug, or clean up code. A follow-up such as “do that” is not an explicit invocation.

If an implicit selection reaches this Skill, stop before inspecting or editing the target and continue the underlying request through the ordinary workflow.

Bind the target

Use the named repository or, when none is named, the current repository. The whole repository is the default; narrow it only when the person names a smaller scope.

Include operating code and only the tests, configuration, build logic, documentation, comments, examples, generation, and assets that directly support it. Record the current revision and working-tree state, and preserve unrelated changes and project instructions.

Explicit invocation authorizes reversible local edits inside this boundary. It does not override host permissions or authorize commits, pushes, pull requests, or merges.

Apply proven cleanup

Follow the maintenance guidance to trace active consumers and form a candidate frontier: evidence-backed cleanup opportunities whose prerequisites have been inspected. Resolve each candidate by applying it, rejecting it when the evidence does not prove safety, or leaving it outside the bound target. Inspect only enough surrounding evidence to resolve the frontier; Sweep does not require a complete file or category inventory.

Apply proven changes in small coherent batches. Do not fix or report suspected bugs, customer-visible or public-contract changes, product or compatibility decisions, or uncertain removals. Leave those signals outside Sweep without turning them into recommendations or follow-up tasks.

Read the full file on GitHub · 68 lines

Files

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.

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. 4d ago First seen · 68 lines · 71 tokens per session scan A 0f05e084f0e0

Subscribe to this mod's changes

sweep is a skill published in the GitHub repository dkstm95/hope (8 stars, last pushed 3d ago), licensed MIT. It adds 71 tokens to every session and 630 once invoked, about $0.0004 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.

Related

Other skills, from other repositories

figma-design-system-to-design-md

Figma design system to design.md — Extract Figma design system into a structured design.md. Use when user says 'generate design.md', 'extract design system', 'design tokens to markdown', 'create design doc from Figma', 'Figma design system to design.md', or wants to document their design system from token files and…

albertzhangz10/figma-design-system-to-design-md · 78 tokens

claude-code-session-broker

Use when running Arcgentic V2 in Claude Code and fixed Planner, Developer, and Auditor role sessions must be coordinated through a broker.

Arch1eSUN/Arcgentic · 35 tokens

arcgentic

Use when the user says Arcgentic, asks to use Arcgentic, or wants an idea taken through a complete plan → development → self-audit → external audit workflow in Codex.

Arch1eSUN/Arcgentic · 43 tokens

verify-gates

Runs the mechanical quality gates that the arcgentic state machine requires for state transitions. Invoked indirectly by transition.sh OR directly by orchestrator agent before declaring a state transition. Use when about to call transition.sh OR when manually verifying that a round artifact meets the gate criteria.…

Arch1eSUN/Arcgentic · 75 tokens

session-mode

Use when a project has not yet stored session mode, when a user asks for complete arcgentic workflow execution, or when role identity handoff prompts are needed.

Arch1eSUN/Arcgentic · 36 tokens

cross-session-handoff

Read, write, snapshot, and lock .arcgentic/state.yaml across planner, dev, audit, and optional test sessions.

Arch1eSUN/Arcgentic · 31 tokens