690456d21ece7cf26282642c1948f2cebd0c6611
All checks were successful
CI / test (pull_request) Successful in 55s
sumTokens read the Agent SDK's per-model `modelUsage` entries with snake_case field names, but the SDK reports those per-model entries in camelCase (`inputTokens`, `cacheReadInputTokens`, ...). Every token component therefore fell through to zero, silently zeroing the cost-equivalent-token headline metric — while `total_cost_usd` and `num_turns` (top-level snake_case) kept working and masked it. Read `modelUsage` with the correct camelCase fields, keeping the snake_case aggregate `usage` as the fallback. Export `sumTokens` and add a regression test covering both the per-model camelCase sum (folding in the auxiliary model) and the snake_case fallback, so a future SDK field-casing drift fails a test instead of producing zero-token samples.
Description
Gitea CLI for agents — designed with AXI (Agent eXperience Interface).
Languages
TypeScript
97.6%
Nix
2.3%