skillreaper

module
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 10, 2026 License: MIT

README ΒΆ

skillreaper

Declare 87 skills. Use 4. Reap the rest.

reap in action

Your AI agent loads every skill, MCP server, agent, and rule file every single session. Most of it never gets used. Skillreaper tells you β€” with evidence from your own transcripts β€” what is bloat and what it costs you in context window, latency, and response quality.

One command. Zero config. Read-only. Reversible quarantine.

Items scanned:  187
Items reaped:   142 (76 %)

πŸ”’ Privacy

skillreaper is 100 % local. Zero telemetry, zero network, zero uploads. It reads your config files and session transcripts on disk, computes verdicts, and prints results. The binary has no dependencies and makes no outbound connections. Your transcript data β€” tool calls, prompts, file contents β€” never leaves your machine.

πŸ“¦ Install

# Go (any platform)
go install github.com/thousandflowers/skillreaper/cmd/reap@latest

# npm (requires Node β‰₯ 18)
npx skillreaper

# Binary download (macOS, Linux, Windows β€” amd64 + arm64)
# https://github.com/thousandflowers/skillreaper/releases

Requires Go β‰₯ 1.22 for source builds. Releases provide pre-built binaries for every combination.

πŸš€ Usage

reap                # scan every installed platform + report (read-only)
reap --json         # JSON report
reap --md           # Markdown report
reap prune          # quarantine unused items (reversible)
reap restore --all  # undo every prune
reap version        # print version
Flags
Flag Default Description
--days N 30 Evidence window in days
--min-sessions N 10 Minimum sessions for REAP verdict
--model M claude-sonnet-4-6 Model key for automatic price lookup
--price N auto Input token price ($/MTok, overrides model lookup)
--json false Output JSON
--md false Output Markdown
--claude-dir auto Override config directory (backward compat)
--claude-json auto Override config file path
--yes false Skip confirmation before prune

Price resolution: --model auto-resolves to the model's current input price. --price overrides it. When neither is set, falls back to Claude Sonnet 4.6 pricing ($3/MTok input).

Output formats
  • Default: colour-coded terminal table with REAP/KEEP/REVIEW verdicts
  • --md: Markdown table (pipeline-friendly)
  • --json: full structured JSON with timestamps, weights, verdicts

πŸ”¬ Case study: context is the bottleneck

On a real machine with Claude Code + ECC plugin installed for 6 months:

Items scanned:  187
Items kept:     23
Items reaped:   142 (76 %)
Items unclear:  22

The $2.16/month saving (at 8 000 wasted tokens/session, 3 sessions/day, Sonnet 4.6 pricing) is almost incidental. The real impact:

  • 142 fewer definitions the agent reads every session before it can start working. That is 142 skill descriptions, agent configs, and inline instructions that do nothing but push real context out.
  • Shorter context means lower latency. A smaller prompt has better cache hit rates and faster first-token generation.
  • Less noise means better responses. Every irrelevant skill is a chance for the model to pick the wrong tool, hallucinate a command that does not exist, or waste a turn on something you uninstalled months ago.

Every reaped skill shortens the model's effective context by the weight of its description and instructions β€” the agent does not have to read 142 irrelevant definitions before getting to work.

Real numbers
8 000 wasted tok/session Γ— 90 sessions/month
  = 720 000 tok/month
  = ~$2.16/month (Sonnet 4.6)
  = ~30 pages of instruction text your agent skims every month

🎯 What gets scanned

skillreaper inventories everything your agent loads at startup:

Layer What is found Transcript evidence
Skills (skills/) Personal + plugin skills (.md files) βœ… tool_use + command-name calls
Agents (agents/) Agent definitions (JSON) βœ… Task/Agent tool_use blocks
MCP servers (mcpServers) User, project, plugin scopes βœ… mcp__ tool invocations
Hooks (hooks/) Post-tool-use + stop hooks ❌ not tracked in transcripts
Prose (CLAUDE.md, rules/) Global + project always-loaded docs ❌ always loaded, no tracking
Platform support
Platform Inventory Transcript evidence Status
Claude Code βœ… full βœ… JSONL Full
OpenCode βœ… full βœ… SQLite Full
Codex CLI βœ… full βœ… JSONL Full
Hermes βœ… full βœ… JSONL Full
Cursor βœ… inventory ❌ no transcripts Inventory only
OpenClaw βœ… inventory ❌ no transcripts Inventory only

Platforms without transcript access still benefit from inventory scans: you see everything installed, but evidence-based verdicts (REAP/KEEP) work fully only on platforms with transcript parsing. Items on read-only platforms always show REVIEW.

βš™οΈ How it works

Auto-detection β€” probes every well-known config directory at launch. Only installed platforms are scanned. No flags needed.

Inventory β€” within each config directory, reap scans skills, agents, MCP servers, hooks, and always-loaded prose files.

Evidence β€” parses session transcripts (JSONL or SQLite depending on platform). Counts tool_use blocks, <command-name> invocations, and tool declarations from init messages β€” all with timestamps.

Cost estimation β€” two sources:

  1. Character weight: ceil(chars / 3.7) β€” every skill description, agent definition, and prose file has a known character count.
  2. Dead tool declarations: init messages list every declared tool. Tools declared in init but never used carry their schema weight as pure overhead. Reported as init parser: ~N chars of tool descriptions unused per session.

MCP server schema sizes are unknown without running the server, so their weight is marked ?.

Verdicts β€” three outcomes:

  • REAP β€” zero uses in the evidence window (β‰₯ N sessions, installed before the window)
  • KEEP β€” used at least once in the window
  • REVIEW β€” insufficient evidence (too few sessions, recently installed, or platform without transcript parsing)
Model pricing (June 2026)

--model resolves the input token price automatically. Supported models and their current input pricing from the respective providers:

Model Input price ($/MTok)
claude-opus-4-8 5.00
claude-opus-4-7 5.00
claude-opus-4-6 5.00
claude-opus-4-5 5.00
claude-sonnet-4-6 3.00
claude-sonnet-4-5 3.00
claude-haiku-4-5 1.00
claude-3-5-sonnet 3.00
claude-fable-5 10.00
claude-mythos-5 10.00
gpt-4o 2.50
gpt-4o-mini 0.15
o3-mini 1.10

Default: claude-sonnet-4-6 (the most widely used Claude model as of June 2026). Add new models by editing internal/cost/cost.go β€” one file, one patch.

Prune is reversible quarantine

reap prune moves files to <config-dir>/reaped/ with a versioned manifest. Nothing is ever deleted. reap restore --all puts everything back exactly where it was.

{
  "version": 1,
  "quarantined_at": "2026-06-10T15:30:00Z",
  "entries": [
    {
      "id": "a1b2c3d4",
      "category": "skill",
      "name": "graphify",
      "from": "~/.claude/skills/graphify",
      "to": "~/.claude/reaped/skills/graphify",
      "timestamp": "2026-06-10T15:30:00Z"
    }
  ]
}

πŸ— Design

  • 100 % local, zero dependencies, single static binary
  • Go β‰₯ 1.22, stdlib only (no external JSON/DB libraries)
  • All scanners accept explicit root paths β€” testable with bare directory fixtures
  • Prune is reversible quarantine β€” never deletes, never destructive
  • Multi-platform architecture β€” adding a new platform is one struct in internal/platform/
  • Each platform has its own transcript source, config paths, and scan layout β€” all resolved at runtime
Project structure
cmd/reap/            β€” CLI entry point, flag handling
internal/
  platform/          β€” platform definitions + auto-detection
  scan/              β€” inventory scanners (skills, agents, MCP, hooks, prose)
  usage/             β€” transcript parser (JSONL + SQLite) + init analysis
  report/            β€” evidence β†’ verdicts + renderers (ANSI/JSON/MD)
  prune/             β€” reversible quarantine + restore + manifest
  cost/              β€” model pricing map + token/money helpers
npm/                 β€” npm wrapper (npx skillreaper)
docs/                β€” screenshots, demo assets

βš– License

MIT

Directories ΒΆ

Path Synopsis
cmd
reap command
Command reap scans a Claude Code installation, reports unused skills/MCP servers/agents with evidence from real transcripts, and prunes them reversibly.
Command reap scans a Claude Code installation, reports unused skills/MCP servers/agents with evidence from real transcripts, and prunes them reversibly.
internal
cost
Package cost estimates token counts and money from character counts.
Package cost estimates token counts and money from character counts.
platform
Package platform defines the AI coding tools that skillreaper supports and auto-detects which are installed on the current machine.
Package platform defines the AI coding tools that skillreaper supports and auto-detects which are installed on the current machine.
prune
Package prune quarantines unused items reversibly.
Package prune quarantines unused items reversibly.
report
Package report joins inventory and usage evidence into verdicts and renders the result as ANSI text, JSON, or Markdown.
Package report joins inventory and usage evidence into verdicts and renders the result as ANSI text, JSON, or Markdown.
scan
Package scan inventories the context payload of an AI coding agent installation: skills, agents, MCP servers, hooks, and always-loaded prose.
Package scan inventories the context payload of an AI coding agent installation: skills, agents, MCP servers, hooks, and always-loaded prose.
usage
Package usage extracts invocation evidence from Claude Code session transcripts (~/.claude/projects/**/*.jsonl).
Package usage extracts invocation evidence from Claude Code session transcripts (~/.claude/projects/**/*.jsonl).

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL