Show HN: Claude Code's /stats double-counts tokens, so I built a local Wrapped A developer released aurafarm, a zero-dependency Node.js 20+ tool run via `npx aurafarm` that reads local history files from Claude Code, Codex, Gemini CLI and Antigravity to generate a Spotify Wrapped-style recap of a user's AI coding year. The tool's author says Claude Code's `/stats` view refreshes `stats-cache.json` only when opened and counts each reply's tokens once per content block, usually twice, so aurafarm recounts every day it still has a transcript and scales cached tokens for older days by the overcount it measured. aurafarm serves its recap only on 127.0.0.1 on a random port, rejects non-localhost Host headers to block DNS-rebinding attacks, and uses a Content Security Policy that forbids all network requests. How much aura did you farm with AI this year? Spotify Wrapped for Claude Code, Codex, Gemini CLI and Antigravity. npx aurafarm See the live demo https://kartikgupta2007.github.io/aurafarm/ sample data, nothing to install . aurafarm reads the history your AI coding tools already keep on your machine. It scores your year in aura points and opens a brutally honest recap in your browser, one full-screen page at a time, like Wrapped. Scroll, swipe, tap or press space to move on. At the end you get a share card for X, LinkedIn or your story. - An aura score. Flexes add aura: your streak, your tokens, a 1,000-message session. Bad habits cost aura: typing "done" and walking away, crashing out at a model, waiting up for the 2am limit reset. - A verdict. The Tokenmaxxer, The 3AM Debugger, The Crashout Coder, The Vibe Delegator, The AI Situationship, and more. - Receipts. Messages, tokens, an estimated API cost, peak hour, longest streak, most-typed slash command, and a rage report. - Sound. Every scroll plays the next chord of a tune that climbs toward your verdict. Counters tick as they climb, ranks chime, points land with a coin or a thud, and the verdict lands with a hit. It is synthesised in your browser, with no audio files. Mute it with the button at the top right. - Share cards. 1200×675 for X, 1200×1200 for LinkedIn and 1080×1920 for stories. Post on X and Post on LinkedIn copy the card to your clipboard, so you paste it straight into the post. When aurafarm finds more than one tool, it asks which ones to include. Press Enter to include all of them. | Tool | What it reads | |---|---| | Claude Code | ~/.claude/history.jsonl , ~/.claude/stats-cache.json and the session transcripts in ~/.claude/projects or $CLAUDE CONFIG DIR | | Codex | ~/.codex/history.jsonl , the session files in ~/.codex/sessions and the session index ~/.codex/state .sqlite or $CODEX HOME | | Antigravity | ~/.gemini/antigravity-cli/history.jsonl and the conversation timestamps | | Gemini CLI | ~/.gemini/tmp/ /logs.json and ~/.gemini/tmp/ /chats/ .json | Message counts, tokens and cost depend on what each tool records. Claude Code, Codex and Gemini CLI record tokens. Antigravity only records prompts. Claude Code refreshes stats-cache.json only when you open /stats , and it counts each reply's tokens once per content block, which is usually twice. So aurafarm recounts every day it still has a transcript for, counting each reply once. Claude Code deletes transcripts after 30 days. For older days, aurafarm uses the cache and scales its tokens by the overcount it measured on the days both cover. Codex's session index needs Node.js 22.13 or later. On older Node, Codex sessions and tokens only come from the session files Codex has not deleted yet. - aurafarm only reads files. It never uploads, phones home or collects telemetry. - The recap is served on 127.0.0.1 only, on a random port. It stops when you press Ctrl+C. - The server rejects any request whose Host is not localhost. This blocks DNS-rebinding attacks. - The page's Content Security Policy forbids every network request, so even the page itself cannot send your stats anywhere. - aurafarm ignores folder and project names, and the page never shows prompt text. npx aurafarm year --no-open year Year to wrap. Defaults to this year last year in January . --no-open Start the local page but do not open a browser. Requires Node.js 20 or later. There are no dependencies. Every line in the audit comes from a real number. The rules live in src/aura.js https://github.com/KartikGupta2007/aurafarm/blob/main/src/aura.js . | Flex | Aura | |---|---| | Each day of your longest streak | +50 | | Every 20 messages | +1 | | Each active day | +10 | | Every 10M tokens | +1 | | Every $10 of estimated API cost | +1 | | A session over 1,000 messages | +500 | | Each please or thank you | +25 | | Each extra AI tool you use | +150 | | Habit | Aura | |---|---| | Each lazy prompt "ok", "continue", "done" | −10 | | Each "fix it" with no context | −25 | | Each swear | −50 | | Each ALL CAPS prompt | −100 | | Each /model switch | −20 | | Each 1% of prompts after 10pm when 25% or more | −10 | | Each 1% of prompts on weekends when 25% or more | −5 | The cost estimate uses public Anthropic API prices. It is a floor, not an invoice. Models without a published price are left out, and the page says which ones. Run npx aurafarm . It reads the history Claude Code keeps in ~/.claude and shows your messages, tokens, estimated API cost, peak hour, longest streak and most-used slash commands, one page at a time. Claude Code saves each reply as several transcript lines, one per content block thinking, text, tool call , and every line repeats the reply's full token count. /stats adds up every line, so most replies are counted two or three times. aurafarm counts each reply once. This is a known open bug: anthropics/claude-code 91775 https://github.com/anthropics/claude-code/issues/91775 . Yes. aurafarm also reads Codex, Gemini CLI and Antigravity history, and it combines them into one recap when you use more than one. aurafarm estimates it from your token counts at public Anthropic API prices. On a subscription you pay your plan price instead. The estimate shows what the same usage would cost on the API. No. It only reads local files, and the page cannot make network requests. See Privacy privacy . Yes. It runs on macOS, Linux and Windows with Node.js 20 or later. git clone https://github.com/KartikGupta2007/aurafarm && cd aurafarm npm test node:test, no install needed node bin/aurafarm.js run against your own data npm run demo rebuild the demo page in docs/ with sample data To add a tool, create a file in src/sources/ that returns the activity shape documented in src/sources/index.js https://github.com/KartikGupta2007/aurafarm/blob/main/src/sources/index.js . Then register it in the same file and add a test with a fake home folder, as in test/cli.test.js . Roast lines live in src/roast.js https://github.com/KartikGupta2007/aurafarm/blob/main/src/roast.js . Funnier ones are very welcome. Every line has to be earned by a real number. MIT