EngramGraph: Skill for Claude Code

.agents/skills/sweep/SKILL.md

sweep is a skill for Claude Code from AsiaOstrich/EngramGraph. It costs 77 tokens per session (1,180 once invoked), scanned A, original, MIT.

A codebase cleanup scanner that finds leftover debugging output, debugger statements, TODO-style markers, and some TypeScript type issues. It can automatically remove selected safe patterns, such as console logging and debugger statements.

In plain words
What is it for?
Use it before commits or during reviews to scan selected paths, exclude test files, generate a report, or fix supported debug artifacts.
Why use it?
It helps catch development-only code and visible maintenance markers before they reach production or a code review. Findings that are not safe to change are reported rather than modified.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: installed under .agents/ (shared by several agents).

This is AsiaOstrich/EngramGraph's own configuration. It tells Claude Code how to work on EngramGraph itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything EngramGraph configures →

Reuse

Borrowing it

Nothing to install: this file belongs to AsiaOstrich/EngramGraph. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/AsiaOstrich/EngramGraph/main/.agents/skills/sweep/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/AsiaOstrich/EngramGraph

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 sweep

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

Your own site · 80×15
<a href="https://agentmods.dev/skills/asiaostrich/engramgraph/sweep"><img src="https://agentmods.dev/badge/skills/asiaostrich/engramgraph/sweep.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 77 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,180 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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.00077 $0.01180
Opus 5.5 $0.00031 $0.00472
Sonnet 5.5 $0.00015 $0.00236
Haiku 4.5 $0.00008 $0.00118

Measured 14d ago against content hash 0ac342d2dea9, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, 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 14d 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/skills/sweep/SKILL.md · 147 lines

How it starts

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

Sweep Assistant | 掃碼助手

Language: English | 繁體中文

Scan the codebase for debug artifacts, code quality issues, and technical debt markers. Optionally auto-fix safe patterns (console.log, debugger statements).


Scan Patterns | 掃描模式

Pattern ID Label Auto-fixable Description
console-log console.log / console.debug / console.trace ✅ Yes Debug output left in production code
debugger debugger statement ✅ Yes Debugger breakpoints left in code
todo-fixme TODO / FIXME / HACK / XXX ❌ Report only Technical debt markers
ts-any TypeScript any type ❌ Report only Type safety violations

Usage | 使用方式

/sweep                        # Scan current directory, report findings
/sweep --fix                  # Scan and auto-fix fixable patterns
/sweep --report               # Scan and save report to .uds/sweep-report.json
/sweep --path src/            # Scan specific directory
/sweep --exclude "**/*.test.ts"  # Exclude patterns (glob)

Workflow | 執行工作流程

Step 1: Discover Files

Use Glob tool to find all source files under the target path. Default excludes: node_modules/, dist/, .git/, *.min.js, coverage/.

Step 2: Scan Each Pattern

For each pattern, use Grep to find matches across all files. Collect findings: { file, line, column, pattern_id, label, fixable, content }.

Step 3: Report Findings

Output a structured summary:

📊 Sweep Results
─────────────────────────────────────
console-log:   12 findings  (auto-fixable)
debugger:       2 findings  (auto-fixable)
todo-fixme:    28 findings  (report only)
ts-any:         5 findings  (report only)
─────────────────────────────────────
Total: 47 findings  |  Fixable: 14

Step 4: HITL Gate (if --fix and findings > 20)

If --fix flag is set AND total fixable findings exceed 20: Pause and require explicit user confirmation before applying fixes. Show the list of files that will be modified.

Read the full file on GitHub · 147 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. 14d ago First seen · 147 lines · 77 tokens per session scan A 0ac342d2dea9

Subscribe to this mod's changes

sweep is a skill published in the GitHub repository AsiaOstrich/EngramGraph (3 stars, last pushed today), licensed MIT. It adds 77 tokens to every session and 1,180 once invoked, about $0.0003 per session on Opus 5.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-10-16.

Related

Other skills, from other repositories

code-graph

This skill should be used when understanding code structure, finding dependencies between functions/classes, tracing call graphs, or exploring code relationships. Trigger phrases include 'code graph', 'call graph', 'who calls', 'what calls', 'find dependencies', 'code structure', 'inheritance', 'find paths'.

FalkorDB/code-graph · 64 tokens

usage

Query LeanKG knowledge graph for code understanding. Use when exploring a codebase, finding functions, tracing dependencies, or calculating impact radius.

FreePeak/LeanKG · 27 tokens

kivgraph

Use Kivgraph's local MCP server to search symbols, read their source, and follow references, dependencies, cross-repository consumers and graph status in the indexed code graph.

Luqueee/kivgraph · 39 tokens

mushroom

Live graph memory for agents — query and create entities, derive relationships by rule, explain why two things are associated, read the graph at a past commit, ask what a change would do, and answer as one role. Trigger on: memory, remember, recall, relationship, entity, association, why are X and Y related, as of…

MatthewSherlin/mushroomdb · 0 tokens

potpie-cli

Use when the task is centered on running, explaining, configuring, or troubleshooting the potpie command: doctor, login, pot management, source registration, resolve/search/record, graph workbench reads/writes, resource (document payload) commands, and pot scope behavior.

potpie-ai/potpie · 60 tokens

potpie-debug-memory

Use while debugging or troubleshooting failures, flaky tests, incidents, production alerts, CI failures, local dev setup issues, repeated bugs, prior fixes, failed attempts, and verification history.

potpie-ai/potpie · 41 tokens