Chore: Record tokens and EUR cost per ticket in the dev log #5

Merged
claude-bot Bot merged 1 commits from chore/4-ticket-cost into main 2026-11-15 14:58:09 +01:00

Records tokens and cost per ticket in the dev log, taken from Claude Code's transcripts, instead of time and cost from /usage.

  • .claude/scripts/ticket-cost.py --since <start> [--until <merge>]: sums token usage of all responses in the window (each response once; Claude Code writes one response over several lines), prices them at API list rates, converts to EUR with the ECB rate of the day
  • docs/devlog.md: template field "Tokens / cost" replaces "Time" and "Cost"; #1 entry filled in (12.3M tokens, ~€9.21)
  • docs/agentic-workflow.md: Metrics section says where the numbers come from and why time is not recorded

Checked: ruff check and strict pyright pass on the script; the #1 total matches a hand calculation. No CI yet.

Closes #4

Records tokens and cost per ticket in the dev log, taken from Claude Code's transcripts, instead of time and cost from `/usage`. - `.claude/scripts/ticket-cost.py --since <start> [--until <merge>]`: sums token usage of all responses in the window (each response once; Claude Code writes one response over several lines), prices them at API list rates, converts to EUR with the ECB rate of the day - `docs/devlog.md`: template field "Tokens / cost" replaces "Time" and "Cost"; #1 entry filled in (12.3M tokens, ~€9.21) - `docs/agentic-workflow.md`: Metrics section says where the numbers come from and why time is not recorded Checked: `ruff check` and strict `pyright` pass on the script; the #1 total matches a hand calculation. No CI yet. Closes #4
claude-bot Bot added this to the MVP milestone 2026-11-15 14:55:11 +01:00
claude-bot Bot added 1 commit 2026-11-15 14:55:11 +01:00
The agent cannot read /usage, and time leaves out the developer's own work. Tokens come from Claude Code's transcripts, priced at API list rates.
claude-bot Bot merged commit 7422e0143f into main 2026-11-15 14:58:09 +01:00
claude-bot Bot deleted branch chore/4-ticket-cost 2026-11-15 14:58:09 +01:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: kasun/deverenz#5