Motivation
Current usage tracking (src/core/usage.rs, __agentview_meta_usage hidden tmux session) tracks Claude usage. agent-deck tracks 14 models including Claude variants, Gemini, GPT-4o, with daily/weekly/monthly budget limits and historical backfill from transcripts.
Scope
- Extend usage tracking to record
(runner, model, input_tokens, output_tokens, cost_usd, session_id, ts).
- Pricing table per model — sourced from a config file we maintain, with version pinning.
- Budget config: per-period (daily/weekly/monthly) caps with warning thresholds (e.g. 80%).
- Dashboard view in TUI: current period spend, top sessions by cost, per-model breakdown.
- Historical backfill: parse existing Claude Code transcripts on disk to populate prior cost events.
Depends on
- Pluggable runners issue — model attribution per runner needs the runner trait in place. Could ship a Claude-only version first.
Open questions
- Pricing table maintenance — manual updates vs. fetch from a public source.
- How to attribute cost when a session uses multiple models in one transcript.
Motivation
Current usage tracking (
src/core/usage.rs,__agentview_meta_usagehidden tmux session) tracks Claude usage. agent-deck tracks 14 models including Claude variants, Gemini, GPT-4o, with daily/weekly/monthly budget limits and historical backfill from transcripts.Scope
(runner, model, input_tokens, output_tokens, cost_usd, session_id, ts).Depends on
Open questions