claude-usage-analyst

claude-usage-analyst is a skill for Claude Code, Codex from daymade/claude-code-skills. It costs 91 tokens per session (621 once invoked), scanned A, original, MIT.

An analyst for Claude Code and Claude Desktop usage records, using ccusage data to examine tokens, costs, model use, cache activity, and five-hour quota periods.

In plain words
What is it for?
Investigating daily or historical usage, comparing models, analysing cost and token patterns, and explaining quota consumption.
Why use it?
It separates measured usage from interpretation, helping explain why a quota was exhausted or why one model used more resources.

Skill for Claude CodeCodex

Written for Claude Code and Codex: shipped in a Claude Code plugin, but also agents/openai.yaml present. Also seen: mentions Claude Code.

Part of the daymade-claude-code plugin — 19 skills shipped together

About the project

Claude Code Skills Marketplace is a collection and marketplace of skills, plugins, agents, and instructions that extend Claude Code with specialized development workflows. It is for developers who want to install existing workflows or create, validate, and package their own Claude Code skills.

daymade/claude-code-skills · 1,377 stars · on GitHub

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/daymade/claude-code-skills/claude-usage-analyst
Any agent
npx skills add daymade/claude-code-skills --skill claude-usage-analyst
Clone the repo
git clone --depth 1 https://github.com/daymade/claude-code-skills

Made for: Claude Code, Codex.

Or install daymade-claude-code, the plugin that ships this one along with the rest of its 19 skills.

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 claude-usage-analyst

README.md
[![agentmods](https://agentmods.dev/badge/skills/daymade/claude-code-skills/claude-usage-analyst.svg)](https://agentmods.dev/skills/daymade/claude-code-skills/claude-usage-analyst)
Your own site
<a href="https://agentmods.dev/skills/daymade/claude-code-skills/claude-usage-analyst"><img src="https://agentmods.dev/badge/skills/daymade/claude-code-skills/claude-usage-analyst.svg" alt="Measured on agentmods" height="20"></a>
Per session 91 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 621 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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.00091 $0.00621
Opus 5 $0.00046 $0.00311
Sonnet 5 $0.00018 $0.00124
Haiku 4.5 $0.00009 $0.00062

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

Security

Grade A, and why

claude-usage-analyst scanned grade A with 0 findings 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 6d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/analyze_claude_usage.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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

daymade-claude-code/claude-usage-analyst/SKILL.md · 56 lines

How it starts

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

Claude Usage Analyst

Overview

Use this skill to produce evidence-based usage explanations from local ccusage data. Separate observed numbers from interpretation, and explain quota burn in human terms.

Workflow

  1. Verify ccusage is available:

    ccusage --version
    

    If missing, install or update with npm install -g ccusage@latest or run with npx ccusage@latest.

  2. Run the bundled analyzer for the requested window:

    python3 /path/to/claude-usage-analyst/scripts/analyze_claude_usage.py \
      --since YYYY-MM-DD --until YYYY-MM-DD --timezone Asia/Shanghai
    

    Default --since/--until is today in the selected timezone. For historical comparison, set --since to an earlier date such as the first day of the month; otherwise rank/median fields only describe the single target day.

  3. If the user asks about a specific model comparison, pass aliases:

    python3 scripts/analyze_claude_usage.py --model-a fable --model-b opus-4-8
    
  4. Read references/explanation-guide.md when writing the final answer.

Evidence Rules

  • Base numeric claims on ccusage output or the bundled analyzer output.
  • State the scope: ccusage claude measures local Claude Code usage logs, including Claude Desktop's Claude Code sessions when those local logs exist. It is not a complete ordinary Claude.ai chat bill.
  • Report dates with timezone.
  • Explain cache clearly: cache read tokens are still usage/quota pressure even though the user did not type those words.
  • Do not infer Anthropic plan quota rules from local token counts unless the user provides plan details. Say "quota-like pressure" or "ccusage estimated cost/token burn" when exact plan accounting is unknown.
  • When comparing models, compare both token volume and estimated cost. A model can have similar token volume but higher cost.

Output Shape

Use this structure unless the user asks otherwise:

  1. Short conclusion in plain language.
  2. Evidence table: total tokens, cost, input, output, cache create, cache read.
  3. Model comparison table.
  4. 5-hour block table when quota exhaustion is discussed.
  5. Explanation of why the burn happened.
  6. Confidence and caveats.

Read the full file on GitHub · 56 lines

Files

What ships with it

4 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 6d ago First seen · 56 lines · 91 tokens per session scan A 2937e96ac368

Subscribe to this mod's changes

claude-usage-analyst is a skill published in the GitHub repository daymade/claude-code-skills (1,377 stars, last pushed yesterday), licensed MIT. It adds 91 tokens to every session and 621 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

local-ai-agents

Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…

microsoft/ai-agents-for-beginners · 200 tokens

chronicle

Analyze Copilot session history for standup reports, usage tips, session search, and session reindexing. Use when the user asks for a standup, daily summary, usage tips, workflow recommendations, wants to search or find past sessions by keyword/file/PR, wants to reindex their session store, or asks about deleting…

microsoft/vscode · 72 tokens

chat-pet-sprite-creation

Use when creating or changing VS Code chat pet sprite art, sprite sheets, state animations, eye treatments, Stable/Insiders variants, or pet transitions under src/vs/workbench/contrib/chat/browser/widget/media/chatPet.

microsoft/vscode · 53 tokens

cpu-profile-analysis

Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…

microsoft/vscode · 71 tokens

next-cache-components-adoption

Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…

vercel/next.js · 95 tokens