/kit:memory-tidyfrom kit
Audits a repo's git-tracked .claude/memory store, identifies duplicate/stale notes and MEMORY.md index drift, then ships cleanup as a PR. For scheduled biweekly audits or manual tidy requests.
Ships in kit. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
MEMORY.md index drift covers notes missing from the index and index entries with no file. Also fires when a scheduled run asks for the memory-tidy audit of a repository. The excluded auto-memory under ~/.claude/projects is machine-local: not git-tracked, no PR gate.
Audit a repo's git-tracked .claude/memory/ store and ship the cleanup as a PR. Core principle: every verdict cites checkable evidence, and deletions reach main only through a PR merge, the PR is the operator's approval gate, so the audit itself never needs to ask permission.
This is the judgment half of the kit's memory plane. The mechanical half is stats memory-sweep (lib/stats): a read-only scanner that never writes. This skill consumes its output and is the only path that edits a store, always behind a PR.
At the start of the pass (after any refusal guard below passes), run bin/audit start memory-tidy, so a crashed or abandoned pass leaves a trace: bin/audit due shows it running or abandoned.
Branch in a worktree first (native worktree tool). All edits and deletions ride this branch. Touching the store on the current branch is the failure this skill exists to prevent.
Mechanical pre-pass. Run uv run stats memory-sweep from the kit's lib/stats/ and filter its JSON for this repo's store: dead path refs per note, stale index entries. Always also diff both directions: the note files on disk vs the entries in MEMORY.md (files not indexed are invisible to sessions; entries with no file are ghosts).
Fan-out judgment. Split the notes into 2-4 subsystem clusters (roughly one cluster per 40 notes; a tiny store is audited directly) and dispatch parallel read-only agents. Each agent reads every note in its cluster fully and returns, per note: a 1-line gist plus one verdict:
| Verdict | Required evidence |
|---|---|
| OK (keep) | distinct fact, referents spot-checked alive |
REMOVE (merged into <sibling>) | quote the overlapping claim from both notes |
| REMOVE (stale) | concrete reason: referenced path tested and gone, superseded by a NAMED doc/ADR/newer note, the event concluded (PR merged, tool graduated), or the rule now codified verbatim in an always-loaded file (CLAUDE.md) |
| UNSURE | what only the operator can answer |
The verdict is one of the base five in docs/patterns/audit-loop.md; the parenthesis is its reason.
A verdict with no checkable evidence is not actionable: re-check it or downgrade to UNSURE. UNSURE notes are never deleted; list them in the report.
Danger check. A note whose recommended fix contradicts current policy is worse than stale, someone may follow it. Fold its still-true diagnostics into the policy-carrying note, then delete it, and say so in the PR body.
Apply. Merges preserve incident detail and dates. Fix path-drift and dangling [[wikilinks]] in surviving notes. Before deleting any note, grep the store for references to its name and rewrite them.
Rebuild the index. Every remaining note gets one short line in MEMORY.md derived from its frontmatter description. Verify: entry count equals note count, and a grep for every deleted note's name returns nothing.
Ship. Follow the repo's own session-close conventions (lab log, backlog rows, proof/gate ledger, whatever that repo's CLAUDE.md requires), commit, push, open a PR whose body lists each removal with its reason. If nothing needed changing, create no branch and report CLEAN.
This instance has a declared cadence in the ## Cadence table of docs/patterns/audit-loop.md.
Record a finished pass with bin/audit ran memory-tidy "<one line>", including a CLEAN one, so
bin/audit due stops naming it. The kit ships no scheduler: due is what a human or a job reads.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub consolelabs/devkit --plugin kit14 skills in this plugin
/backlog-reconcileUse to audit a repo's `_meta/BACKLOG.md` Active queue against reality, "audit the backlog", "reconcile the board", "is the board still true", "dọn backlog", "rà soát backlog", or a scheduled backlog-reconcile run. NOT for filing new items onto the board, NOT for a single known-stale row (just fix it), NOT for the kit's own FEATURES/workflow-paths pair (topology-drift)./ci-driftUse for the whole-estate CI audit, "audit the CI", "are the runners clean", "check the release pipeline", "ci drift", "stale workflows / secrets / runners", or a scheduled CI-audit cadence run. NOT for one failing run (/kit:debug), NOT for doc prose (doc-drift)./doc-driftUse for the whole-estate doc audit, "run the doc-drift loop", "audit the docs against the code", "are the docs still true", "doc drift sweep", "check every doc claim", or a scheduled doc-audit cadence run. NOT for diff-scoped doc sync inside a build cycle (/kit:docs), NOT for dated records like specs, research, retros, NOT for one known-wrong doc (just fix it)./gauntlet-proof-auditUse to audit the gauntlet records, "are the ROUNDS.md records honest", "verify the proof corpus", "check each run record against its evidence", "audit the gauntlet corpus", "is the gauntlet proof trustworthy", or a scheduled run. NOT for re-running probes or rounds (`/kit:gauntlet` itself), NOT for the corpus-level stats projection (`lib/gauntlet/stats.sh`), NOT for non-gauntlet records./get-api-docsFetch curated API documentation using Context Hub (chub) before coding against any external API. Use when the task involves calling a third-party API (Stripe, OpenAI, Airwallex, Notion, etc.) to prevent hallucinated parameters and deprecated endpoints./loop-engineeringUse to design or add a new bounded loop to the kit's SDLC orchestration ("design a new loop", "is this worth a loop"), or mentions the Karpathy loop / autoresearch / hill-climb / search-and-select prompt or parameter tuning. NOT for a one-off in-session Stop-hook goal (use goal-craft), NOT for the debug loop (already exists, use /kit:debug), NOT for building the loop's actual code.Other plugins' skills for the same job