tokens

Measure per-round token usage in godmode loops and log to a TSV file.

26|8|Updated Mar 19, 2026
One-click install
npx skills add https://github.com/arbazkhan971/godmode --skill tokens-arbazkhan971
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tokens
Source: https://github.com/arbazkhan971/godmode/tree/main/skills/tokens
Command: npx skills add https://github.com/arbazkhan971/godmode --skill tokens-arbazkhan971

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Token-budget observability for godmode loops. Measures approximate input + output tokens consumed by each round of the Universal Protocol, appends one row per round to .godmode/token-log.tsv, and emits a terse session-end summary with per-skill breakdown and delta vs. prior sessions. Read-only to source. Inspired by rtk-ai/rtk's gain, discover, and session analytics. Fills the observability gap next to results.tsv (metric deltas) and failures.tsv (discard reasons) — tokens.tsv answers "what did this round COST in context?"

Core Features & Use Cases

  • Observability: tracks approximate token costs per round and per session to help you optimize loops.
  • Logging: appends per-round token usage to .godmode/token-log.tsv and provides per-skill breakdowns.
  • Comparison: computes delta versus prior sessions to surface trends in token budgets.

Quick Start

Invoke token-budget observability across your loop by running /godmode:tokens to start per-round token usage tracking.

Frequently Asked Questions about tokens

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I track token usage per round in automated loops?

Track token usage per round in automated loops by measuring approximate input and output tokens consumed during each iteration and appending the data to a persistent log file. This records per-round costs for later analysis and optimization.

What is token budget observability for multi-round orchestration?

Token budget observability measures approximate input and output tokens consumed by each round of multi-round orchestration, appends one row per round to a TSV file, and emits a session summary with per-skill breakdowns and deltas versus prior sessions.

How do I log per-session token metrics to a TSV file?

Log per-session token metrics to a TSV file by appending one row per round to a persistent token-log file. The log captures per-round usage and computes a session-end summary with per-skill breakdowns and delta versus prior sessions.

Do I need any specific dependencies to measure token costs in Unix environments?

Measuring token costs in Unix environments requires a minimal environment with standard Unix tools like awk, wc, date, and gzip. No external dependencies are needed, and the process uses a model-agnostic heuristic to estimate tokens.

Can I compare token costs across different sessions?

Compare token costs across different sessions by computing the delta versus prior sessions. The observability process surfaces trends in token budgets and provides a per-session top-skill breakdown to help optimize future loops.

Why measure token usage with a model-agnostic heuristic?

Measure token usage with a model-agnostic heuristic to estimate tokens independently of specific model APIs. This approach ensures consistent token cost tracking across different models within multi-round orchestration loops.