Plot
Render the tokens-saved chart from an analyzer output directory. Dependency-free SVG generator — reads summary.json + report.csv produced by benchmark/bin/analyze.js and emits TWO SVGs of the same cumulative billable-input story (passthrough baseline vs clawback, honest green/red shaded gap): tokens_saved.svg (labeled, titled "Token Efficiency", for on-screen) and tokens_saved.bg.svg (BARE 1200×630, lines + wedge only, no text — the share-card PNG background; without it the posted card has no chart lines). No cost/$/CI tables. Use after .skills/bench to produce the visuals that document the win.From its SKILL.md
npx -y skills add zapgun-ai/clawback --skill plotAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
2 things to look at
- no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
- 4 stars4 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
3.0 KB, 605 tokens by cl100k_base, as published. Nobody here has run it
clawback chart renderer
Run benchmark/bin/plot.js from the project root. It reads an analyzer
output directory (the --out dir you gave benchmark/bin/analyze.js)
and writes TWO SVGs to a charts directory. No dependencies — pure Node + string
templating, so it runs anywhere clawback runs.
Usage
node benchmark/bin/plot.js --in runs/smoke --out runs/smoke/charts
--in must contain summary.json and report.csv (run .skills/bench
first). The SVG is written to --out.
Charts emitted
Both SVGs draw the same figure — cumulative billable input tokens over turns, two lines (passthrough baseline vs clawback) with the gap between them shaded. The shade is honest about direction: green when clawback's line ends below passthrough (it spent fewer full-rate tokens — a real saving), red when clawback ends above (it spent more — a regression we never hide). The chart carries no per-turn reclaim callout; the report hero overlay owns that figure now, so a chart copy would only collide with it.
tokens_saved.svg— the labeled, on-screen chart: legend, axes, ticks, and the title "Token Efficiency". This is what the report GUI shows.tokens_saved.bg.svg— the BARE share-card background: a 1200×630 white card with just the two lines + the filled wedge, zero<text>. The report GUI inlines this behind the scrim to build the downloadable / shareable PNG. Missing it ⇒ the share PNG is a solid card with no chart lines. (Backfill old runs that predate it with.skills/finish --all.)
One figure on purpose: the product story is "how many more tokens can you spend,
because clawback saves your quota" — not a dashboard of stats, and never a
dollar figure. Billable input = input_tokens + cache_creation_input_tokens
(the full-rate buckets); cache_read is the discounted reuse and is excluded.
Cost lives only in the analyzer's report.md appendix; it is never plotted.
Honest-claim discipline
The win is conditional on idle gaps: on a tight loop the baseline caches well too, so the gap trends to ~0 (no regression); it widens as gaps cross the 5-min / 60-min eviction boundaries. Read the chart by regime, never as one context-free number.
Reproducibility
The charts are a pure function of summary.json + report.csv; re-rendering
the same analyzer output yields byte-identical SVGs.
What ships with it
Read from the repository
Just SKILL.md. No reference files, no scripts.
Gives 0 of the 12 instructions most docs writing skills give in 605 tokens
Counted across 1,637 of the 3,044 authors here whose files we hold, read 2026-08-07
- Announce the skill at startin 54 of 1637, across 26 files
- Convert legacy doc files before editingin 45 of 1637, across 7 files
- Predict questions readers might askin 42 of 1637, across 4 files
- Generate clarifying questions for initial contextin 42 of 1637, across 3 files
- Create document scaffold with placeholder textin 42 of 1637, across 3 files
- Brainstorm content options for each sectionin 42 of 1637, across 3 files
- Test the document with a fresh context-less instancein 42 of 1637, across 3 files
- Include exact file paths in every taskin 42 of 1637, across 15 files
- Ask interview questions one at a timein 42 of 1637, across 27 files
- Apply surgical edits during refinementin 41 of 1637, across 2 files
- Offer structured workflow or freeformin 40 of 1637, across 1 file
- Ask for document meta-contextin 40 of 1637, across 2 files
Said here and by no other author read
- pass an input directory containing summary.json and report.csv
- pass an output directory for the charts
- draw cumulative billable input tokens over turns
- shade the chart gap green for token savings
- title the labeled chart "Token Efficiency"
- exclude discounted cache reads from billable tokens
Grouped from the skills themselves: near-identical wordings counted once, and counted by distinct author, so one author publishing three of these counts once. Length counted with cl100k_base; the agent that loads this file may tokenize it differently.