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 agentmods add commands/lijialex/layered-memory/uninstall-cleangit clone --depth 1 https://github.com/LijiAlex/layered-memoryWrote 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/commands/lijialex/layered-memory/uninstall-clean)<a href="https://agentmods.dev/commands/lijialex/layered-memory/uninstall-clean"><img src="https://agentmods.dev/badge/commands/lijialex/layered-memory/uninstall-clean.svg" alt="Measured on agentmods" 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.00038 | $0.00323 |
| Opus 5 | $0.00019 | $0.00161 |
| Sonnet 5 | $0.00008 | $0.00065 |
| Haiku 4.5 | $0.00004 | $0.00032 |
Grade A, and why
uninstall-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 5d 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.
What it actually says
Clean up the data layered-memory wrote to disk. Uninstalling the plugin removes its code but leaves the memory files behind; this wipes them.
Important: run this BEFORE /plugin uninstall — the command disappears with the plugin.
First show the user what WOULD be deleted (dry-run, default):
python3 "${CLAUDE_PLUGIN_ROOT}/scripts/uninstall_clean.py" $ARGUMENTS
Report the listed directories to the user and ask for explicit confirmation. Only the
base dir ~/.claude/memory is auto-discovered; per-repo dirs must be added with
--dir <repo>/.claude/memory. The script refuses to delete anything that doesn't look like
a layered-memory directory (must contain index.md/themes//history/).
After the user confirms, re-run with --yes to actually delete:
python3 "${CLAUDE_PLUGIN_ROOT}/scripts/uninstall_clean.py" --yes $ARGUMENTS
This is irreversible (no snapshot — it is the deliberate wipe). A repo deleted before
cleanup leaves its <repo>/.claude/memory/ orphaned; pass its path with --dir to remove it.
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.
- 5d ago First seen · 30 lines · 38 tokens per session scan A b05d82801a13
uninstall-clean is a command published in the GitHub repository LijiAlex/layered-memory (1 stars, last pushed 2mo ago), licensed MIT. It adds 38 tokens to every session and 323 once invoked, about $0.0002 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.
Other commands, from other repositories
learn
Force claude-smart to extract learnings from this session now.
init
Install the formatters this repository needs, with every command visible before it runs.
brand-generate
Generate an on-brand document from a saved Brand Profile.
genshijin-compress
Markdown・テキストファイルを原始人形式へ安全圧縮.
save
Save this conversation as a new or existing reusable context.
wp-polylang
Translate an existing WordPress site into a second language using Polylang.