| name | skill-usage-stats |
| description | Generate an HTML dashboard of skill usage across Claude Code and Codex (global + project .claude/skills, ~/.codex/skills, ~/.codex/prompts). Counts invocations, last-used date, days-since-use, session reach, and on-disk size so you can decide which skills to keep, archive, or delete. Triggers — "skill usage stats", "which skills do I actually use", "clean up skills", "audit my skills", "스킬 사용 통계", "안 쓰는 스킬", "스킬 정리". |
Skill Usage Stats
Scans local Claude Code (~/.claude/projects/**/*.jsonl) and Codex (~/.codex/sessions/**/*.jsonl) transcripts, joins against the installed skill/prompt catalog, and writes an interactive HTML dashboard to ~/.claude/skill-stats.html.
When to use
- User asks which skills they actually use, or wants to clean up unused skills.
- User wants a usage report comparing global vs. project-level skills.
- User mentions auditing Claude Code or Codex skills.
Files in this skill
analyze.py — scans transcripts, writes the HTML dashboard, opens browser.
summary.py — terminal-only views (top/zero/stale/overview) from the same HTML.
How to run
Generate the HTML dashboard (default: scan all transcripts, write to ~/.claude/skill-stats.html, open browser):
python3 ~/.claude/skills/skill-usage-stats/analyze.py
analyze.py flags:
--days N — only count invocations in the last N days (default: all time).
--project <substr> — restrict to transcripts whose cwd matches.
--out <path> — output HTML path (default: ~/.claude/skill-stats.html).
--no-open — generate but don't open the browser.
Terminal views (after the HTML exists):
python3 ~/.claude/skills/skill-usage-stats/summary.py overview
python3 ~/.claude/skills/skill-usage-stats/summary.py top -n 20
python3 ~/.claude/skills/skill-usage-stats/summary.py zero
python3 ~/.claude/skills/skill-usage-stats/summary.py stale --days 90
summary.py accepts --source claude-global|claude-project|codex-global-skill|codex-global-prompt and --html <path>.
Detection rules
Covers both explicit slash-command calls and auto-triggered loads (the harness loads SKILL.md on its own when a description matches user intent).
- Claude Code — explicit
Skill tool: tool_use with name="Skill", input.skill=<name>.
- Claude Code — slash command:
<command-name>/name</command-name> tag in user messages.
- Claude Code — auto-trigger via
Read: tool_use with name="Read", file_path ending in /skills/<name>/SKILL.md (this is how using-superpowers, using-symphony, etc. actually get activated).
- Claude Code — auto-trigger via
Bash: tool_use with name="Bash", command containing /skills/<name>/SKILL.md (e.g. cat, sed).
- Codex — slash command: user
input_text whose first non-blank line is /<name>.
- Codex — auto-trigger via shell:
function_call events with name in {exec_command, shell, apply_patch} whose arguments contain /skills/<name>/SKILL.md (Codex reads skills via shell, not a Read tool).
Each tool_use / function_call event credits the skill once. Source is decided by the path containing .claude vs .codex.
Catalog sources (where the SKILL.md lives on disk):
claude-global: ~/.claude/skills/*/SKILL.md
claude-project: <repo>/.claude/skills/*/SKILL.md (discovered from transcript cwds)
codex-global-skill: ~/.codex/skills/*/SKILL.md
codex-global-prompt: ~/.codex/prompts/*.md
Output columns
name | source | count | sessions | first_used | last_used | days_since | size_kb | path
Sortable, filterable. Stale skills (>90 days unused) and zero-use skills are highlighted.