caveman-stats

Report measured token usage and savings from Claude Code JSONL session logs.

199|41|Updated Oct 25, 2020
One-click install
npx skills add https://github.com/rvdbreemen/OTGW-firmware --skill caveman-stats-rvdbreemen
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: caveman-stats
Source: https://github.com/rvdbreemen/OTGW-firmware/tree/main/.agents/skills/caveman-stats
Command: npx skills add https://github.com/rvdbreemen/OTGW-firmware --skill caveman-stats-rvdbreemen

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Caveman-style workflows make it hard to tell whether a change actually reduces token usage, because token savings are often estimated rather than measured.

Core Features & Use Cases

  • What it measures: Reads actual Claude Code session input/output token usage from the on-disk JSONL session log, avoiding AI token estimation.
  • How it reports: Computes and displays formatted stats including input tokens, output tokens (with caveman attribution), a baseline estimate, and approximate savings percentage.
  • Where it plugs in: Triggers on the /caveman-stats route, with the hook injecting the formatted result so you see numbers immediately.

Quick Start

Ask for the report by requesting: /caveman-stats.

Frequently Asked Questions about caveman-stats

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I measure actual token usage from Claude Code session logs?

You measure actual token usage by reading the Claude Code JSONL session log on disk to extract real input and output tokens, avoiding inaccurate AI token estimation. This provides precise operational metrics for your active session.

Can I track token savings during an active Claude Code session?

Yes, you can track token savings during an active session by triggering a report that reads on-disk session logs and compares actual input/output tokens against a non-caveman baseline to calculate approximate savings percentages.

How do I report input and output token reductions without model-side estimation?

To report token reductions without model-side estimation, read the measured token counts directly from the JSONL session log file on disk and compute the savings against a baseline estimate using a hook-injected formatted output.

Does caveman-stats work without installing additional dependencies?

Yes, caveman-stats works without additional dependencies because it relies on hook-injected formatted output and reads existing Claude Code session log files directly from disk, requiring no external components or model-side estimation.

What is the best way to quantify token usage reductions in Caveman workflows?

The best way to quantify token usage reductions is to trigger a dedicated reporting command that parses the JSONL session log on disk to display formatted stats including input tokens, output tokens, baseline estimates, and savings percentages.

Why are my AI token estimation reports inaccurate for Claude Code sessions?

AI token estimation reports are inaccurate because they rely on model-side approximations rather than measured data. Reading the actual JSONL session log on disk captures true input and output token usage for reliable savings reporting.