doc-freshness-reverse-lint

doc-freshness-reverse-lint is a skill for Claude Code from wan-huiyan/claude-ecosystem-hygiene. It costs 376 tokens per session (4,674 once invoked), scanned B, original, MIT.

A documentation checker that finds project guidance made outdated by newer rules, including rules that were withdrawn or narrowed.

In plain words
What is it for?
Use it to review research, decision, findings, and runbook documents after adding new lessons or rules, and to check whether skills’ verification dates have expired.
Why use it?
Old instructions can look authoritative and cause future work to repeat decisions that have already been rejected.

Skill for Claude Code

Written for Claude Code: $CLAUDE_PLUGIN_ROOT variable. Also seen: reads .claude/ paths; positional $N argument.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the doc-freshness-reverse-lint plugin — 1 skill shipped together

Good fit Use it to review research, decision, findings, and runbook documents after adding new lessons or rules, and to check whether skills’ verification dates have expired.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add wan-huiyan/claude-ecosystem-hygiene
Claude Code
/plugin install doc-freshness-reverse-lint

Made for: Claude Code.

Or install doc-freshness-reverse-lint, the plugin that ships this one along with the rest of its 1 skill.

Wrote 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.

agentmods badge for doc-freshness-reverse-lint

README.md
[![agentmods](https://agentmods.dev/badge/skills/wan-huiyan/claude-ecosystem-hygiene/doc-freshness-reverse-lint/github.svg)](https://agentmods.dev/skills/wan-huiyan/claude-ecosystem-hygiene/doc-freshness-reverse-lint)
Your own site
<a href="https://agentmods.dev/skills/wan-huiyan/claude-ecosystem-hygiene/doc-freshness-reverse-lint"><img src="https://agentmods.dev/badge/skills/wan-huiyan/claude-ecosystem-hygiene/doc-freshness-reverse-lint/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.

agentmods 80×15 button for doc-freshness-reverse-lint

Your own site · 80×15
<a href="https://agentmods.dev/skills/wan-huiyan/claude-ecosystem-hygiene/doc-freshness-reverse-lint"><img src="https://agentmods.dev/badge/skills/wan-huiyan/claude-ecosystem-hygiene/doc-freshness-reverse-lint.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 376 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,674 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00376 $0.04674
Opus 5 $0.00188 $0.02337
Sonnet 5 $0.00075 $0.00935
Haiku 4.5 $0.00038 $0.00467

Measured 11d ago against content hash db264a3bfa3c, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade B, and why

doc-freshness-reverse-lint scanned grade B with 1 finding 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 11d ago.

The scan reads SKILL.md. This mod also ships 3 executable files (scripts/hook_dispatch.sh, scripts/reverse_lint.py, scripts/weekly_audit.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

[ -f "$s" ] || s="$(find -L "$HOME/.claude/plugins/cache" -mindepth 5 -maxdepth 5 \
plugins/doc-freshness-reverse-lint/SKILL.md · 360 lines

How it starts

The opening of the file, as written. The whole thing — 360 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Doc Freshness Reverse-Lint

Problem

Huiyan's project docs under docs/{research,decisions,findings,runbooks}/ contain normative guidance. When she later corrects that guidance in ~/.claude/lessons.md or a feedback_*.md entry, the original project docs stay stale. Future Claude sessions read them as authoritative and repeat the retracted advice.

Real example: the-causal-impact-repo/docs/research/pre_period_length_methodology.md:92,98 referenced "sorting by p-value" after the user had already decided that approach was wrong.

And a second shape the grep above cannot see (added v1.3.0). A rule is not always contradicted — sometimes it is retired, and the docs that carried it keep a scoped survivor: "X is retired — but it still applies if you are a Y." That reads as current guidance, and it is dead the moment no Y exists.

Real example (DoodleRun, 2026-08-04): "no deploys by agents" was retired across four live briefs, and every retirement kept "a cloud session still cannot" as a live branch — after cloud sessions had stopped existing. The next reader would have paused to work out which kind of session it was instead of just deploying. The retirement was correct; the surviving condition was the defect. The owner caught it by hand, one turn after the retirement shipped.

Mechanisms

1. Reverse-lint (primary, event-driven)

Runs when a negation rule is added to a memory file. Extracts the "don't X" phrase, greps project docs, lists matches. Does NOT edit.

1b. Dead-branch detection (v1.3.0, runs with the reverse-lint)

Same trigger, different question. Where mechanism 1 asks "does any doc still assert the thing you just forbade?", this asks "does any doc still carry the CONDITION of a rule you just retired?"

THREE explicit signals, ANDed — a scoped survivor is often perfectly legitimate, and only a human knows whether the branch can still fire:

  1. a retirement trigger in the memory file (retired, superseded, no longer applies, is dead, …);
  2. a quoted subject within 160 chars either side of it — retirement prose nearly always quotes the rule it retires ("...", '...', `...`, **...**), and the quote must be ≥ 2 tokens and not a path or filename;
  3. a doc paragraph containing that subject with a surviving-conditional marker after it (still cannot, only applies, unless you, except when, if you are a, remains true for, …).

Read the full file on GitHub · 360 lines

Changes

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.

  1. 11d ago First seen · 360 lines · 376 tokens per session scan B db264a3bfa3c

Subscribe to this mod's changes

doc-freshness-reverse-lint is a skill published in the GitHub repository wan-huiyan/claude-ecosystem-hygiene (1 stars, last pushed 25d ago), licensed MIT. It adds 376 tokens to every session and 4,674 once invoked, about $0.0019 per session on Opus 5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

session-handoff

End-of-session handoff that captures session knowledge, dispatches output across the canonical 7-bucket docs/ taxonomy (decisions/runbooks/analysis/references/reviews/handoffs/deliverables — aligned with memory-hygiene v3.3), triggers a doc-freshness reverse-lint + skill-freshness audit to catch stale normative…

wan-huiyan/context-baton · 247 tokens

llm-wiki

Build and maintain an LLM-curated personal knowledge base — the "LLM Wiki" pattern from Andrej Karpathy's April 2026 gist. Use this skill whenever the user wants to ingest a source (paper, article, transcript, PDF, notes) into a persistent compounding knowledge base, ask a question against accumulated notes, lint or…

praneybehl/llm-wiki-plugin · 221 tokens

reflect

Per-project self-improvement - reads the .harness ledger and feedback memories, then proposes gated rule/threshold/ADR changes so the project stops repeating mistakes. Run periodically.

sneg55/agent-starter · 37 tokens

remember

Review auto-memory entries and propose promotions to CLAUDE.md, CLAUDE.local.md, or shared memory. Also detects outdated, conflicting, and duplicate entries across memory layers.

sneg55/agent-starter · 38 tokens

ucai-patterns

Use when the user asks about Claude Code best practices, how to write agents, how to use hooks, how to manage context, or how to work effectively with Claude Code's native systems.

Joncik91/ucai · 42 tokens

dream

Memory consolidation - review, merge, prune, and index memory files. Run periodically to keep memories organized and up-to-date.

sneg55/agent-starter · 27 tokens