Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Use this skill when the user wants to identify unused, near-zero-use, or stale skills/agents/commands in the plugin surface so they can be demoted or retired. Combines agent-dispatch telemetry (start-events only) with static reference scanning, classifies every surface item into Active / Investigate / Demote / Retire, and emits a Markdown report plus JSON sidecar. NEVER auto-deletes — surfaces candidates for human decision. Quarterly cadence. <example>Context: The plugin surface has grown and th
.claude/skills/hashgraph-online-sunset-review/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-07 | ✗→✓ | ▲ Improved | 75% | 0% |
| case-08 | ✗→✓ | ▲ Improved | 132% | 0% |
| case-10 | ✗→✓ | ▲ Improved | 0% | 0% |
| case-11 | ✗→✓ | ▲ Improved | 77% | 0% |
| case-12 | ✗→✓ | ▲ Improved | 98% | 0% |
Identify which skills, agents, and commands in the plugin surface are still earning their keep, and which are candidates to Demote (downgrade docs/tier) or Retire (remove). The skill is advisory: it produces a ranked candidate list and a sidecar artifact. It never deletes anything.
/repo-audit answers "does this repo match the ecosystem baseline?" — a pass/fail compliance check. /sunset-review answers a different question — "which parts of OUR surface are unused?" — with different inputs (dispatch telemetry + static ref scanning), a different cadence (quarterly, not per-session), and a different output (prune candidates, not compliance status). Folding it into repo-audit would muddy both.
The walker — scripts/lib/sunset/walker.mjs — is read-only and was built against the following grep-verified telemetry facts. Do not override them:
subagents.jsonl records agent dispatches; skill-invocations.jsonl records Skill tool selection events (L1 telemetry, epic #645). Agents are assessed by agent-dispatch counts; skills are assessed by real selection counts from skill-invocations.jsonl, supplemented by static reference scanning. Commands still have no invocation telemetry and are assessed by static reference scanning only. Skills with zero invocations in the window receive a zero-count (not null), so the low-coverage guard still applies and can downgrade Retire → Investigate when the telemetry window is short.event === "start" records count. agent_type is null on every stop event. A stop event must never mark an agent cold. The walker filters to start events.coverageDays < windowDays, every Retire verdict is downgraded to Investigate and meta.lowConfidence is set true. Retiring on sub-window data is unsafe — treat any cold finding as "investigate", not "delete".memory-proposal-collector, a by-design reference doc) is a Retire candidate; a once-dispatched agent (db-specialist, ui-developer at n=1) is a Demote candidate. The walker distinguishes them.| Verdict | Meaning | Action posture | |---|---|---| | Active | Agent dispatch above floor, OR skill invoked-by-command / command invokes-a-live-skill, OR ≥2 non-boilerplate refs | Keep | | Investigate | Coverage < window (low-confidence), OR conflicting signals — default-safe bucket | Manual review | | Demote | Single dispatch (n=1), OR a skill with a single cross-ref and no command linkage | Consider downgrading docs/tier | | Retire | dispatch===0 AND nonBoilerplateRefs===0 AND coverage>=window | Strong remove candidate (verify first) |
sunset-review.window-days override; default to 90 (DEFAULT_WINDOW_DAYS).Run the read-only walker and capture its JSON:
bashnode scripts/lib/sunset/walker.mjs --json --window-days 90 > /tmp/sunset-walk.json
Exit 0 = walk completed (cold findings are exit 0, not an error). Exit 1 = bad args / surface dir missing. Exit 2 = system error. The walker writes no files — it is pure analysis.
Optionally scope to one kind for focused review:
bashnode scripts/lib/sunset/walker.mjs --json --kind agent
items[] array by verdict, ordered Retire → Demote → Investigate → Active.meta.lowConfidence. If true, state plainly: "telemetry covers only N days (< window); all Retire candidates were downgraded to Investigate — do not retire anything this run."reasons[] and signals{} so the operator can sanity-check the verdict against their own knowledge (a low-traffic-but-load-bearing item should be spared).Mirror the repo-audit sidecar convention. Write both:
.orchestrator/metrics/sunset-review-<unix-timestamp>.md — the grouped, human-readable verdict list with reasons.bashmkdir -p .orchestrator/metrics
The sidecar is the durable record; the Markdown is the readable summary.
Skill Health (advisory) — render a per-skill health advisory block into the report.
scoreSkillHealth() in scripts/lib/skill-health/score.mjs, computed over the L2 join (scripts/lib/skill-health/join.mjs) plus any optional L3 judgments — the same telemetry the walker already surfaces on item.signals.judge. The mechanical/CI surface for this data is harness-audit category9 ("Skill-Health Surfacing").## Skill Health section to the Markdown report. List each skill that has sufficient samples with its verdict (insufficient signal | trigger description unclear | instructions wrong) and its diagnosis string. Skills below the sample threshold (MIN_SAMPLES_FOR_VERDICT, ~20) are NOT scored per-skill — collapse them into a single line: "Insufficient signal (N skills)"..orchestrator/metrics/sunset-review-last-run.json with an ISO timestamp). This keeps the walker free of mutable runtime state and concurrency surface.If the operator wants to file removal/demotion issues for the surfaced candidates, that decision must be made by the coordinator via AskUserQuestion — a dispatched agent cannot call AskUserQuestion (AUQ-004). When this skill runs inside a dispatched agent, it surfaces the candidate list and defers issue creation to the coordinator thread. Never auto-file issues and never auto-delete surface items.
.orchestrator/metrics/sunset-review-<timestamp>.md.scripts/lib/sunset/walker.mjs — the read-only walker (CLI + exported functions).skills/repo-audit/SKILL.md — the sibling compliance audit (different question)..claude/rules/cli-design.md — JSON-first / exit-code contract the walker follows..claude/rules/ask-via-tool.md — AUQ-004 (agents cannot call AskUserQuestion).Other measured skills in the registry, with their headline benchmark lift.