feat(tui): show usage by routed model#11608
Conversation
Code Review SummaryStatus: 1 Issue Found | Recommendation: Address before merge Overview
Issue Details (click to expand)WARNING
Fix these issues in Kilo Cloud Files Reviewed (1 files)
Previous Review Summaries (9 snapshots, latest commit 611fcb1)Current summary above is authoritative. Previous snapshots are kept for context only. Previous review (commit 611fcb1)Status: No Issues Found | Recommendation: Merge Files Reviewed (5 files)
Previous review (commit 92a756e)Status: 2 Issues Found | Recommendation: Address before merge Overview
Issue Details (click to expand)WARNING
SUGGESTION
Fix these issues in Kilo Cloud Files Reviewed (15 files)
Previous review (commit 96a0f3d)Status: 1 Issues Found | Recommendation: Address before merge Overview
Issue Details (click to expand)WARNING
Fix these issues in Kilo Cloud Files Reviewed (1 files)
Previous review (commit 6e387f5)Status: 1 Issues Found | Recommendation: Address before merge Overview
Issue Details (click to expand)WARNING
Fix these issues in Kilo Cloud Files Reviewed (15 files)
Previous review (commit 41e9082)Status: No Issues Found | Recommendation: Merge Files Reviewed (3 files)
Previous review (commit 78cc8da)Status: 1 Issue Found | Recommendation: Address before merge Overview
Issue Details (click to expand)WARNING
Fix these issues in Kilo Cloud Files Reviewed (3 files)
Previous review (commit b5dad58)Status: 1 Issue Found | Recommendation: Address before merge Overview
Issue Details (click to expand)WARNING
Fix these issues in Kilo Cloud Files Reviewed (5 files)
Previous review (commit b24464c)Status: 4 Issues Found | Recommendation: Address before merge Overview
Issue Details (click to expand)WARNING
SUGGESTION
Fix these issues in Kilo Cloud Files Reviewed (15 files)
Previous review (commit a70121d)Status: No Issues Found | Recommendation: Merge Files Reviewed (15 files)
Reviewed by gpt-5.4-2026-03-05 · Input: 63K · Output: 9.1K · Cached: 261.6K Review guidance: REVIEW.md from base branch |
c7a25c8 to
b24464c
Compare
41e9082 to
6e387f5
Compare
|
@alex-alecu - I think this is ready for re-review |
96a0f3d to
92a756e
Compare
…-usage feat(tui): show usage by routed model

Why
The TUI sidebar shows aggregate token usage, but it does not explain which concrete routed models consumed those tokens or incurred the cost. Delegated subagent usage is also omitted from the active session summary.
What changed
The sidebar now shows cumulative input, output, reasoning, cache read/write, cache rate, and direct cost, followed by the same metrics grouped by concrete routed model. Aggregation covers the complete top-level session tree, including subagents, and sums step costs directly to avoid double counting propagated child costs.
The aggregation is exposed through the local CLI API and implemented in Kilo-owned code to minimize upstream merge conflicts. Older steps without routed model metadata fall back to the assistant message model.
Dependency
This builds on the routed step model metadata merged in #11556. The branch is rebased directly onto
main.