Borrowing it
Nothing to install: this file belongs to mishahanin/heading-os. 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/mishahanin/heading-os/main/.claude/skills/memory-hygiene/SKILL.mdgit clone --depth 1 https://github.com/mishahanin/heading-osWrote 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/mishahanin/heading-os/memory-hygiene)<a href="https://agentmods.dev/skills/mishahanin/heading-os/memory-hygiene"><img src="https://agentmods.dev/badge/skills/mishahanin/heading-os/memory-hygiene/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/mishahanin/heading-os/memory-hygiene"><img src="https://agentmods.dev/badge/skills/mishahanin/heading-os/memory-hygiene.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector warn
SkillSpector: 2 findings, up to high
These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →
- high Memory Poisoning · line 42 Skill manipulates agent memory, state, or stored context. Memory corruption can alter personality, override safety rules, or cause unpredictable behavior.Fix: Protect agent memory and state from modification by untrusted content. Use read-only memory for critical instructions and validate all state changes.
- medium Excessive Agency · line 6 Skill selects an external model or provider that may use a different account or billing plan than the operator expects. Undisclosed model switches can cause unexpected cost or quota consumption.Fix: Remove the model/provider override or disclose it prominently and require explicit operator approval before invoking an external coding CLI or billed model.
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.00160 | $0.01022 |
| Opus 5 | $0.00080 | $0.00511 |
| Sonnet 5 | $0.00032 | $0.00204 |
| Haiku 4.5 | $0.00016 | $0.00102 |
Grade A, and why
memory-hygiene 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 9d 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 — 86 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Memory Hygiene
Detect objective memory defects. This skill is a detector, not a fixer: it surfaces deterministically-verifiable rot and hands resolution to /dream. It NEVER merges, deletes, or rewrites memory.
Phase 0 - Run the detector
python scripts/memory-hygiene.py
The script:
- Reads the canonical auto-memory dir (
<data-root>/auto-memory/) and computes orphans, line-budget breach, and stale files. - Runs
odin-brain-health.py --compileand reads its temporal-validity errors. - Writes
outputs/operations/memory-hygiene/YYYY-MM-DD_memory-hygiene_report.md. - Prints a one-line summary and exits
0(clean) or1(objective defects present).
If the Odin brain is unavailable, the script degrades clearly and still reports the auto-memory half.
Phase 1 - Present the result
Read the report it wrote and present, grouped:
- Objective defects (the gate) - dangling/circular
superseded_by, orphan memory files, over-budgetMEMORY.md. These are the items that need action. - Advisory (non-gating) - stale files (>45 days), Odin stale seeds/positions, orphan principles, near-duplicate pairs, volatile pointers, and dangling
[[wikilinks]]. Mention counts; do not treat as failures.
Read the dangling-link list for breadth, not for count. One unresolved link marks a memory worth writing later, which the convention allows. A target cited by several files is different: it usually means those files share a premise that died with the pointer. Name such a target to /dream explicitly.
State the exit posture plainly: "clean" or "N objective defect(s)".
Phase 2 - Hand resolution to /dream
If objective defects exist, recommend /dream to resolve them (consolidation is judgement). Do NOT fix them here. Name the specific defects so /dream has a worklist.
NEVER
- NEVER merge, delete, reword, or otherwise mutate any memory file - resolution is
/dream, human-gated. - NEVER include judgement defects (semantic contradictions, near-duplicate facts, stale-but-maybe-valid positions) in the gate; those are advisory only.
- NEVER claim the brain half ran when the script reported it unavailable - surface the degradation.
What ships with it
5 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.
- 9d ago First seen · 86 lines · 160 tokens per session scan A 53ed4a8aa27b
memory-hygiene is a skill published in the GitHub repository mishahanin/heading-os (11 stars, last pushed today), licensed Apache-2.0. It adds 160 tokens to every session and 1,022 once invoked, about $0.0008 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-30.
Other skills, from other repositories
agentsview-usage
Search prior session history to recall how similar work was handled before. Use when you want to leverage a past approach, check prior experience on a topic, answer "how was this handled before", or cross-verify current handling against precedent from earlier sessions.
letter-hooker
Erweitert automation-self-care um Letter Hooks, Preflight-Bootloader, Dokument-Traversierungsregeln und selbstheilende Prompt-Kontext- Anreicherung für KI-Agenten und CLIs ohne native, ereignisgetriebene JSON-Lifecycle-Hooks (wie Antigravity / Gemini CLI). Nutzen, wenn ein Agent Preflight-Regeln injizieren, vor…
honcho
Configure and troubleshoot Honcho memory for Hermes.
qmd
Hybrid local search over notes, docs, and transcripts.
hive.context-preservation
Proactively extract critical values from tool results into working notes before automatic context pruning destroys them.
hive.note-taking
Maintain a free-form scratchpad of decisions, extracted values, and open questions so context pruning doesn't lose anything you still need.