-
Notifications
You must be signed in to change notification settings - Fork 3
Add per-model cost and cache hit rate breakdown #3
Copy link
Copy link
Open
Labels
enhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomers
Description
Summary
Add a new CLI command or report section that shows cost and cache hit rate broken down by model (e.g., Opus, Sonnet, Haiku).
Current Behavior
cta cost-report shows aggregate costs. Model-level breakdown requires manual session inspection.
Expected Behavior
A cta model-breakdown command (or --by-model flag) that shows:
| Model | Sessions | Total Cost | Avg Cache Hit | Avg Cost/Session |
|---|---|---|---|---|
| claude-opus-4-6 | 120 | $2,340 | 45% | $19.50 |
| claude-sonnet-4-6 | 5,200 | $3,100 | 72% | $0.60 |
Implementation Hints
storage.rsalready stores model information per session- Add a query method that groups by model
- Use existing
analyzer.rsaggregation patterns as reference
Acceptance Criteria
- Per-model breakdown displayed with cost, session count, cache hit rate
- Works as both CLI command and MCP tool
- Handles unknown/fallback models gracefully
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomers