Esta página se muestra en inglés. Una traducción al español está en curso.
CLI ToolsMay 12, 2026·2 min de lectura

Tokentap — Token Tracker for LLM CLIs

Tokentap adds a live terminal dashboard and prompt archive for LLM CLI tools, so you can see token usage in real time while using Claude Code or Codex.

Introducción

Tokentap adds a live terminal dashboard and prompt archive for LLM CLI tools, so you can see token usage in real time while using Claude Code or Codex.

  • Best for: power users of LLM CLIs who need visibility into token burn and context window pressure
  • Works with: Python 3.10+; supports Claude Code, Codex, Gemini CLI (noted as blocked by an upstream issue), and OpenAI-compatible providers (per README)
  • Setup time: 5–15 minutes

Practical Notes

  • Per README: shows a context “fuel gauge” (default limit 200,000) and saves prompts to Markdown + JSON.
  • Useful for regression: compare token usage before/after prompt/tool changes.
  • Combine with guardrails: when fuel gauge hits 70–80%, switch to summarization or retrieval mode.

Main

A simple workflow that pays off quickly:

  1. Run your normal CLI session with Tokentap enabled.
  2. When usage spikes, open the saved prompt archive and identify the culprit: retrieval payload, tool output, or template bloat.
  3. Fix one thing at a time (shorten tool output, add truncation, or dedupe context), then measure again.

Treat token usage as a budget: you’ll get better answers by spending tokens on relevant evidence, not repeated boilerplate.

FAQ

Q: Does it require certificates? A: Per README: no—"Zero configuration" and it runs as a local proxy with path-prefix routing for OpenAI-compatible providers.

Q: Can it run with Gemini CLI? A: README notes Gemini CLI is currently blocked by an upstream issue when using OAuth; check the linked issue for status.

Q: What should I store? A: Keep prompt archives in a private directory; they may contain secrets or code. Add redaction if you share logs.

🙏

Fuente y agradecimientos

Source: https://github.com/jmuncor/tokentap > License: MIT > GitHub stars: 798 · forks: 37

Discusión

Inicia sesión para unirte a la discusión.
Aún no hay comentarios. Sé el primero en compartir tus ideas.

Activos relacionados