claudeers.
// Developer Tools

burn

Local-first, zero-dependency cost ledger for your AI coding agents. Reads the transcripts Claude Code / OpenCode / Codex / Gemini CLI already leave on disk —…

Install with your AI

Paste into Claude Code, Cursor, or any agent — it reads the repo and wires the tool into your project.

Install and set up burn (git-clone project) into my current project.
Found on https://claudeers.com/burn
Repo: https://github.com/aashish254/burn
Homepage/docs: https://aashish254.github.io/burn/
Detected install method: git-clone → git clone https://github.com/aashish254/burn
Category: devtools. Platforms: cli, api.
Read the repo's README for exact setup and env vars, then install it and wire it into my project.

Claudeers Health Verdict:
unknown; community-verified: false. Confirm the source before running anything.
// or clone
git clone https://github.com/aashish254/burn

// compatibility

Platformscli, api
Operating systems—
AI compatibilityclaude
LicenseMIT
Pricingopen-source
LanguageJavaScript

Get your FREE $2.50 API credits to access TickAtlas financial data ↗

🔥 burn

🌐 Live demo →

Where did your AI budget actually go — and what did each feature cost?

burn is a local, zero-dependency ledger that reads the transcripts your coding agents already leave on disk. It answers per repo, per model, per day, per git branch: how many tokens you spent, how many dollars that cost, and how much prompt caching saved you. No network. No account. No telemetry. Nothing leaves your machine.

The ledger format itself is an open, conformance-tested protocol: ULP 1.0 — spec'd at github.com/aashish254/ulp (vendored here under ulp/ so one checkout runs both suites). burn is ULP's reference implementation #1: dashboards and CI can build on the protocol, not on this CLI.

burn — spend per repo, per model, with cache economics:

burn ledger output

burn work — what each feature/branch actually cost:

burn work output

Both shots are real CLI output over a demo dataset of synthetic transcripts; your own repo names, branches and numbers appear instead.

Why

Every coding agent quietly writes down exactly what it did — Claude Code drops a JSONL transcript per session with a full usage block and its git branch; OpenCode keeps a SQLite db with real billed cost; Codex and Gemini CLI record their own token histories. That data has been sitting on your laptop this whole time. Nobody adds it up across agents, and nobody can tell you what feature/payments-refactor actually cost.

burn answers the questions that gate agent adoption at scale:

  • Which repo is eating my spend? Which feature/branch/PR?
  • Am I paying opus prices for 100-token answers? (burn doctor)
  • What will this pace cost me next month? (burn forecast)
  • Is this PR over budget before it merges? (burn budget → exit 3)
  • What does my team spend, with no backend? (burn export | merge | team)

Install

macOS or Linux with Node ≥ 22.5 (for the built-in node:sqlite). One paste:

curl -fsSL https://raw.githubusercontent.com/aashish254/burn/main/install.sh | bash

The installer verifies the release checksum, installs the CLI under ~/.burn-cli, and links the burn command into ~/.local/bin. Nothing else — no root, no account, no telemetry. Then:

burn          # your ledger: spend per repo, model, day — across agents
burn work     # dollars per branch / feature / work unit
burn doctor   # is anything wasting money?

From source instead:

git clone https://github.com/aashish254/burn && cd burn && npm link
# or with no linking at all:  node src/cli.js

(The burn-usage npm package is on the roadmap; until it ships, these are the two official install routes.)

How cost is computed (and why we never lie)

burn distinguishes three kinds of dollar figures and labels its totals with the mix, so you always know what's real:

labelmeaningsource
billedthe agent recorded the actual chargeOpenCode session.cost
estimatedcomputed from a pricing table you controltokens × ~/.burn/pricing.json
unpricedtokens counted, dollars withheld because the model has no known priceanything not in the table

If burn doesn't know a model's price, it shows tokens and reports — for cost. It will never fabricate a dollar figure. The same rule governs every derived number: forecasts project only priced events, counterfactuals print — for unpriced routes, and the supportedAgents list only contains formats verified against upstream source — nothing ships claiming an agent it can't truly parse.

// ~/.burn/pricing.json  (USD per 1M tokens)
{ "my-router/llama-4": { "input": 0.2, "output": 0.8, "cacheWrite": 0.2, "cacheRead": 0.05 } }

Performance

A full report over half a million usage events — read transcripts, price, aggregate, serialize — finishes in about two seconds. Numbers from scripts/bench.mjs on synthetic transcripts (median of 3 spawned burn --json runs, Apple M5, node v22):

eventsextractend-to-endevents/sec
10,00023 ms109 ms91k
100,000120 ms409 ms245k
500,0001.54 s2.05 s244k

burn benchmark output

Commands

burn                     overall summary + all breakdowns
burn repos / models / agents / daily / sessions
burn work                cost per work unit: branch ▸ commit-adjacent ▸ repo
burn blame feature/pay   what one branch cost (native attribution)
burn blame v1..HEAD      what a commit range cost (read-only git join)
burn attribute S1 --unit my-epic     charge a session to a named unit
burn sources             which agents were found, where, and with how much data
burn budget --repo app --max 25 [--period day|week|month|all]   exit 3 = over
burn forecast [--window 30]          trend + last-7d-mean, priced events only
burn counterfactual --route claude-haiku-4-5                    estimate-of-estimate
burn doctor              deterministic advice, rules R-1..R-6 (advisory, exit 0)
burn watch               live per-turn cost stream as agents write transcripts
burn export -o me.burn.json          shareable bundle (mergeable, path-scrubbed)
burn export --ulp                    pure ULP 1.0 core document (schema-validated)
burn merge a.json b.json [--audit]   union across machines, recompute-not-sum
burn team a.json b.json              per-human totals (roster.json optional)
burn ingest their.ulp.json [--strict]  accept any conformant ULP ledger
burn ingest dir/                       …or a whole folder of them
burn ingest --list                   what's stored and what each bundle gave
burn conformance                     run the ULP kit (pure JSON vectors; exit 0/2)
burn snapshot                        append today's ledger to ~/.burn/history
burn history ls / history drop F --yes   inspect; delete (only destructive cmd)
burn report [--month 2026-09] [-o sept.md]  markdown digest, safe to commit
burn plan --repo app --budget 50 --months 2  forecast gate: 0 afford / 3 can't
burn attest --month 2026-09          finance one-pager: method, NOT an invoice
burn init --team                     team/usage/ + CI scaffold (git-push-only network)
burn export --otel -o x.otlp.json    OTLP/JSON to a FILE (offline transform)
burn ingest --otel x.otlp.json       OTLP/JSON back in — lossless-or-loud
burn --history / --no-history        fold local snapshots in (default ON for
                                     report, budget month|all, forecast)
burn --since 2026-09-01              only count usage on/after a date
burn --json                          machine-readable (stable schema, additive-only)

Exit codes are a contract: 0 report · 1 no supported agent data (stderr hint, stdout silent) · 2 error · 3 over budget — so CI can tell "policy failure" from "tool crash". burn checks budgets and enforces nothing: burn measures, AgentVault gates.

Supported agents

agentstorecost availablestatus
Claude Code~/.claude/projects/**/*.jsonlestimated + git branchshipped
OpenCode~/.local/share/opencode/opencode.dbbilled (session.cost)shipped
Codex CLI~/.codex/sessions/**/rollout-*.jsonlestimated; branch from session_metashipped
Gemini CLI~/.gemini/tmp/*/chats/*.jsonlestimated; repo from workspace dirsshipped
OpenClawper-agent SQLite (schema unconfirmed)billed per messageheld — we won't guess a format
Cursor agentpath TBD—planned

An extractor is one file exporting label, rootPath(), available() and extract() yielding normalized events — see src/extractors/claude.js. Run burn sources to see exactly which paths were probed on your machine.

Teams with zero backend

# each human:
burn export -o team/usage/ash.json        # git commit it — git IS the sync protocol
# anyone, anywhere:
burn merge team/usage/*.json              # one ledger, deduped by (device, session, index)
burn merge --audit team/usage/*.json      # catches copied ~/.burn/id collisions
burn team  team/usage/*.json              # per-human totals

Bundles carry no absolute paths and no hostnames (device ids are random uuids; hostnames ship as 8-hex hashes). Names appear only from a local roster.json.

Privacy

burn opens files under your home directory and prints a summary. It makes no network requests and stores nothing beyond what you explicitly export. Every dollar is either read from your own agent's records or computed from a pricing table you wrote. Repo labels are basenames only; exported events are path-scrubbed.

How this differs from the neighbours

  • vs. ccusage — great, but Claude-only (and Codex-only forks exist). burn is cross-agent, adds the cache-economics view, and separates billed vs. estimated dollars so the number is honest.
  • vs. gateways (LiteLLM / OpenRouter / Portkey) — those meter only traffic that routes through them. Your native agents bypass them entirely. burn meters what already happened, with no proxy and no config change.
  • vs. session-migrate — that moves a session between agents. burn reads all their logs to report spend. Different axis; they compose.
  • vs. AgentVault — AgentVault is the firehose gate for agent traffic; burn is the measurement layer. burn budget's exit 3 is the seam between them.

Development

npm test             # 75 tests, zero dependencies, zero Node warnings:
                     # pricing math, provenance classes, attribution ladder,
                     # reconciliation invariant, read-only git joiner, budget
                     # exit 3, merge idempotence (recompute, never sum), bundle
                     # privacy, doctor fire/no-fire fixtures, snapshot-tested
                     # forecast math, spawned-CLI JSON shape, NO_COLOR, exit
                     # codes, ULP schema + negotiation, ingest integrity, the
                     # conformance kit green in TWO languages (Node + stdlib
                     # Python), snapshot/history tie-breaks, plan gates, the
                     # 400-snapshot perf budget.

Roadmap

  • npm package — until burn-usage ships, the installer and source checkout are the official routes.
  • More agents — Cursor's store once its paths are confirmed; OpenClaw once its schema is. We hold a format rather than guess it.
  • A hosted ULP dashboard — the protocol is designed so dashboards can be built by anyone, including people who don't ship a CLI.

The fence around it all: if a feature needs a server or a socket in core, it does not ship. burn measures; your stack decides.

// faq

What is burn?

Local-first, zero-dependency cost ledger for your AI coding agents. Reads the transcripts Claude Code / OpenCode / Codex / Gemini CLI already leave on disk — spend per repo, model, day, and git branch, with honest billed/estimated/unpriced provenance. No network, no account, no telemetry. ULP 1.0 reference implementation.. It is open-source on GitHub.

Is burn free to use?

burn is open-source under the MIT license, so it is free to use.

What category does burn belong to?

burn is listed under devtools in the Claudeers registry of Claude-compatible tools.

9 views
★ 11 stars
unclaimed
updated 6 days ago

// embed badge

burn on Claudeers
[![Claudeers](https://claudeers.com/api/badge/burn.svg)](https://claudeers.com/burn)

// retro hit counter

burn hit counter
[![Hits](https://claudeers.com/api/counter/burn.svg)](https://claudeers.com/burn)

// reviews

// guestbook

0/500

// related in Developer Tools

🔓

The agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Curs…

// devtoolsaffaan-m/⟨JavaScript⟩★ 267,519◷ MIT[ claude ]
🔓

Makes your AI agent think like the laziest senior dev in the room. The best code is the code you never wrote.

// devtoolsDietrichGebert/⟨JavaScript⟩★ 148,251◷ MIT[ claude ]
🔓

Use Garry Tan's exact Claude Code setup: 23 opinionated tools that serve as CEO, Designer, Eng Manager, Release Manager, Doc Engineer, and QA

// devtoolsgarrytan/⟨TypeScript⟩★ 134,274◷ MIT[ claude ]
🔓

AI coding assistant skill (Claude Code, Codex, OpenCode, Cursor, Gemini CLI, and more). Turn any folder of code, SQL schemas, R scripts, shell scripts, docs,…

// devtoolssafishamsi/⟨Python⟩★ 123,348◷ MIT[ claude ]
→ see how burn connects across the ecosystem