Borrowing it
Nothing to install: this file belongs to auerbachb/claude-code-config. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/auerbachb/claude-code-config/main/.claude/skills/memory-clean/SKILL.mdgit clone --depth 1 https://github.com/auerbachb/claude-code-configWrote 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.
[](https://agentmods.dev/skills/auerbachb/claude-code-config/memory-clean)<a href="https://agentmods.dev/skills/auerbachb/claude-code-config/memory-clean"><img src="https://agentmods.dev/badge/skills/auerbachb/claude-code-config/memory-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.
<a href="https://agentmods.dev/skills/auerbachb/claude-code-config/memory-clean"><img src="https://agentmods.dev/badge/skills/auerbachb/claude-code-config/memory-clean.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00109 | $0.01633 |
| Opus 5.5 | $0.00044 | $0.00653 |
| Sonnet 5.5 | $0.00022 | $0.00327 |
| Haiku 4.5 | $0.00011 | $0.00163 |
Grade A, and why
memory-clean 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 2mo 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 — 116 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Audit this project's durable memory store and present prune recommendations. Same discipline as /pm-clean: evidence for every recommendation, conservative on "stale," and nothing is removed without an explicit yes. All detection and mutation lives in the shared, tested script .claude/scripts/memory-audit.py — this file is the recommend-then-confirm layer.
Step 0: Locate the audit script
Prefer the global install; fall back to the in-repo copy when developing the skill itself.
SCRIPT=""
for candidate in \
"$HOME/.claude/skills-worktree/.claude/scripts/memory-audit.py" \
"$HOME/.claude/scripts/memory-audit.py" \
".claude/scripts/memory-audit.py"; do
if [[ -f "$candidate" ]]; then SCRIPT="$candidate"; break; fi
done
if [[ -z "$SCRIPT" ]]; then
echo "ERROR: memory-audit.py not found (checked ~/.claude/scripts/, skills-worktree, in-repo)" >&2
exit 1
fi
Parse $ARGUMENTS: pass through an explicit --dir PATH (for a non-current project or a relocated store) and translate --budget-kb N to --budget-bytes $((N*1024)). With no arguments the script auto-detects the current project's memory dir — the ROOT project, not the worktree, since memory is pinned to the root project across worktree sessions.
Step 1: Scan (read-only)
python3 "$SCRIPT" --check --json [--dir PATH] [--budget-bytes N]
Exit 0 = scanned (a clean store is a valid result). Exit 3 = memory dir not found — tell the user and offer to re-run with --dir PATH. The JSON has memory_dir, index (bytes, entry_count, file_count, budget_bytes, over_budget), orphans, dangling, and advisory (duplicate_names, superseded). Read memory_dir back to the user so they know exactly which store is in scope.
Step 2: Present recommendations
Group findings into scannable sections. Omit any empty section. If nothing is flagged and the index is under budget, report "Memory store is clean — {entry_count} entries, {bytes} bytes, nothing to prune." and stop.
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.
- 2mo ago First seen · 116 lines · 109 tokens per session scan A e0d2165e6fb0
memory-clean is a skill published in the GitHub repository auerbachb/claude-code-config (5 stars, last pushed 2d ago), licensed MIT. It adds 109 tokens to every session and 1,633 once invoked, about $0.0004 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-08-31.
Other skills, from other repositories
PlanGate 決定論的 GC 判定
A rule-based checker that decides whether stored files, logs, and other review records should be kept or removed. It applies retention limits and safety exceptions to a supplied file list.
Closure Scope Retention Guard
Detects long-lived objects (caches, listeners, singletons) that capture an entire enclosing scope via closures/environment capture, keeping large arrays or buffers alive, and proposes copying only the needed fields.
codex-context-keeper
Prepare or read explicit reviewed evidence-preserving context packs for Codex handoffs. Use when asked to preserve exact evidence across compaction or when a Context Keeper hook points to a staged snapshot. Never scan raw transcripts.
memory-to-skill
Turn workflows from your MemSearch memory into reusable skills. Use when the user asks to make/create/extract/distill a skill from what they just did or from past work, review skill candidates, install a distilled skill, or 'turn this into a skill'. Manages MemSearch procedural-memory candidates under…
mindos
MindOS: local knowledge assistant & shared KB. Keeps decisions, notes, SOPs, debugging lessons, research findings, preferences across sessions/agents. Core: save notes, search KB, organize files, run workflows, review, append CSV, hand off context, distill lessons. NOT for app source or paths outside KB. Triggers…
referee
Final arbiter for Bug Hunter. Independently verifies behavioral findings, resolves Skeptic challenges, and calibrates severity and confidence.