npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, πŸ‘‹, I’m Ryan HefnerΒ  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you πŸ™

Β© 2026 – Pkg Stats / Ryan Hefner

toknado

v0.2.0

Published

πŸŒͺ️ A tornado of tokens β€” local, private usage dashboard for Claude Code & Codex CLI logs

Readme

πŸŒͺ️ Toknado

npm license: MIT node >= 18 zero dependencies PRs welcome

A tornado of tokens. See exactly what your coding agents devour β€” Claude Code, Codex and GitHub Copilot Chat, one dashboard, 100% local.

Toknado reads the session logs that Claude Code (~/.claude) and Codex CLI (~/.codex) already write to your machine, and turns them into a fast local dashboard. No accounts, no uploads, no telemetry, no database. Close the tab and nothing remains but your logs.

npx toknado

That's it. Your dashboard opens at http://127.0.0.1:4141.

What you get

  • πŸ“Š One dashboard for all your agents β€” Claude Code, Codex CLI and GitHub Copilot Chat (VS Code), merged or filtered per source
  • πŸ”¬ Every model, every call β€” the All-models table lists each model with API-call counts, avg tokens/call and full usage breakdown
  • πŸ“… Every range you'd ever ask for β€” today, 7 / 14 / 30 days, all time, or a custom date range
  • πŸ“ˆ Charts, not spreadsheets β€” daily stacked bars (by token type or source), model share donut, activity heatmap, busy-hours histogram
  • πŸ€– Per-model breakdown β€” which model ate how much, with share percentages
  • 🧠 Modes visible β€” Codex reasoning efforts (medium / high / xhigh / max / ultra) and Claude response speeds (standard / fast)
  • πŸ“‰ Real quota tracking β€” Codex logs its rate-limit used_percent; Toknado charts your actual weekly quota consumption over time
  • % of everything β€” every day, session, model, and project shows its share of total usage
  • 🧾 Top sessions leaderboard β€” which sessions and projects burned the most
  • πŸ’Έ What-if API cost comparison β€” what your token mix would cost at public API list prices, across model tiers (clearly labeled hypothetical β€” subscriptions don't bill per token)
  • πŸ“‘ Live pricing (opt-in) β€” --live-pricing fetches current rates for thousands of models from LiteLLM's public price DB, so even brand-new models get priced
  • πŸ“€ Export on demand β€” JSON, CSV, or Markdown. Nothing is saved unless you export it

Privacy model

| Question | Answer | |---|---| | Where does my data go? | Nowhere. The server binds to 127.0.0.1 only. The single exception: with the opt-in --live-pricing flag, Toknado makes one plain GET to LiteLLM's public price file β€” it carries nothing about you. | | What does Toknado store? | Nothing. Every view is recomputed from your logs in memory. | | What if I close it without exporting? | Nothing is saved β€” and nothing is lost. Reopen it and the same history is there, because your CLI logs are the data. | | Can it modify my logs? | No. Logs are opened read-only. |

How it works

  • Claude Code writes one JSONL file per session under ~/.claude/projects/. Each assistant turn records exact API usage (input / output / cache read / cache write) per model. Toknado deduplicates entries that appear in multiple files (forked / resumed sessions).
  • Codex CLI writes rollout JSONL files under ~/.codex/sessions/. Forked/subagent files copy the parent's entire history with rewritten timestamps β€” Toknado deduplicates on usage snapshots so each API call counts exactly once, reads model + reasoning effort from turn_context, and collects the rate_limits.used_percent samples for the quota chart.
  • GitHub Copilot Chat (VS Code) stores per-session operation logs under the editor's workspaceStorage/*/chatSessions/. Toknado replays the op log to recover each request's promptTokens/completionTokens, model and timestamp (Code, Insiders and VSCodium are auto-detected).

Token counts come straight from the logs β€” they're exact. Dollar figures in the comparison panel are estimates from public list prices.

Usage

npx toknado [options]

  -p, --port <n>        port to serve on (default 4141)
  --no-open             don't auto-open the browser
  --claude-dir <path>   Claude Code projects dir (default ~/.claude/projects)
  --codex-dir <path>    Codex home dir (default ~/.codex)
  --copilot-dir <path>  VS Code workspaceStorage dir for Copilot Chat
  --pricing <file>      JSON file with per-Mtok price overrides
  --live-pricing        fetch current API list prices from LiteLLM's public DB
                        (the only network request Toknado can ever make; off by default)

Custom pricing

Models Toknado doesn't know show n/a in the cost panel. Provide your own rates (USD per million tokens, prefix-matched against model IDs):

{
  "gpt-5.6": { "input": 1.25, "output": 10 },
  "my-local-model": { "input": 0, "output": 0 }
}
npx toknado --pricing my-prices.json

Non-goals

  • Not a spend tracker. Subscription plans don't bill per token; Toknado is tokens-first everywhere, and the single cost panel is explicitly hypothetical.
  • Not a sync service. There is no cloud, and there never will be.

Requirements

Node.js β‰₯ 18. Zero dependencies.

Contributing

Contributions are very welcome β€” see CONTRIBUTING.md. Good first areas: new log formats (other agent CLIs), chart ideas, and pricing-table updates.

License

MIT