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.
npx skills add shandar/memory-map --skill memory-prunegit clone --depth 1 https://github.com/shandar/memory-mapWrote 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/shandar/memory-map/memory-prune)<a href="https://agentmods.dev/skills/shandar/memory-map/memory-prune"><img src="https://agentmods.dev/badge/skills/shandar/memory-map/memory-prune/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/shandar/memory-map/memory-prune"><img src="https://agentmods.dev/badge/skills/shandar/memory-map/memory-prune.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.00147 | $0.01209 |
| Opus 5.5 | $0.00059 | $0.00484 |
| Sonnet 5.5 | $0.00029 | $0.00242 |
| Haiku 4.5 | $0.00015 | $0.00121 |
Grade A, and why
memory-prune 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.
How it starts
The opening of the file, as written. The whole thing — 148 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Memory Prune
Identify and remove stale, outdated, or redundant memory entries to keep the store clean and decision-useful over time.
Works in claude.ai (uses memory_user_edits) and Claude Code (writes
~/.claude/memory.md). Detected automatically.
Step 0 — Detect environment
| Signal | Environment | Load |
|---|---|---|
memory_user_edits tool is available |
claude.ai | references/claude-ai.md |
| Not available / running in terminal | Claude Code | references/claude-code.md |
Core Protocol
Step 1 — Read all memory
Fetch every entry with the environment-appropriate read command.
Step 2 — Audit for cleanup candidates
Categorise each entry into:
Stale — references past events or dates that have passed:
- Events with past dates that are not retrospectively meaningful
- "Upcoming" tags on things that have shipped
- Old "CURRENT STATE SNAPSHOT" entries that have been superseded but not replaced
Redundant — covered by another entry:
- Two entries with overlapping content (one is more current)
- Sub-entries that have been folded into a parent entry
- Duplicate category labels
Outdated — factually wrong now:
- Old contact details, links that no longer work
- Specs that have been revised
- Cohort numbers that have changed
Mergeable — could be consolidated to save space:
- Two related entries that are both under-character-limit could become one
- Multiple small notes about the same project
Step 3 — Propose changes (do not apply yet)
Show the user a structured proposal:
MEMORY PRUNE — proposed changes
REMOVE (stale)
→ Entry 12: "P2P landing page draft v1" (superseded by v2 in entry 13)
→ Entry 18: "TIU registration link" (event closed)
REMOVE (redundant)
→ Entry 7: "Workshop tools" (covered by entry 14 — frameworks)
CONSOLIDATE
→ Entries 9 + 10 → single "V2V EDITIONS" entry (saves 1 slot)
KEEP (just confirming these are still current)
→ Entry 1-6: PWP and operating preferences
→ Entry 19: Current state snapshot
Apply these changes? [yes / modify / cancel]
What ships with it
2 files 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.
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.
- 14d ago Changed 40cc4688f27f
- 3mo ago First seen · 148 lines · 147 tokens per session scan A b277c4160f85
memory-prune is a skill published in the GitHub repository shandar/memory-map (2 stars, last pushed 16d ago), licensed MIT. It adds 147 tokens to every session and 1,209 once invoked, about $0.0006 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.
memory-prune compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| memory-pruneshandar/memory-map | Skill | 2 | 16d ago | MIT | A | 147 | Claude Code |
| ltm:initLaserPhaser/claude-ltm | Skill | 4 | 7mo ago | MIT | A | 18 | Claude Code |
| ltm:compactLaserPhaser/claude-ltm | Skill | 4 | 7mo ago | MIT | A | 17 | Claude Code |
| ltm:saveLaserPhaser/claude-ltm | Skill | 4 | 7mo ago | MIT | A | 15 | Claude Code |
| gather-contextt1djani/servo | Skill | 1 | 5mo ago | MIT | A | 52 | Claude Code |
| iteratingoaustegard/claude-skills | Skill | 421 | today | MIT | A | 60 | Claude Code, Codex |
| session-memoryoaustegard/claude-skills | Skill | 421 | today | MIT | A | 94 | Claude Code |