Problem
CAT tracks cost per individual tool call and computes baselines per tool type, but never shows an aggregated view like "Bash consumed 45% of all tokens, Read consumed 30%". Users can't identify which tool types are the most expensive overall.
What to do
- Add a SQL query for tool-type aggregation:
SELECT task_type, COUNT(*) as call_count,
SUM(estimated_tokens) as total_tokens,
AVG(estimated_tokens) as avg_tokens
FROM tasks
WHERE estimated_tokens IS NOT NULL
GROUP BY task_type
ORDER BY total_tokens DESC
- Add an API endpoint
/api/tool-summary in src/context_analyzer_tool/collector/routes.py
- Add a CLI command
top-tools in src/context_analyzer_tool/cli.py that renders a ranked Rich table
- (Optional) Add a panel in the TUI dashboard
Why this is a good first issue
It's a clean vertical slice: one SQL query → one API endpoint → one CLI command. Follow the pattern of existing commands like anomalies or context-cost.
Problem
CAT tracks cost per individual tool call and computes baselines per tool type, but never shows an aggregated view like "Bash consumed 45% of all tokens, Read consumed 30%". Users can't identify which tool types are the most expensive overall.
What to do
/api/tool-summaryinsrc/context_analyzer_tool/collector/routes.pytop-toolsinsrc/context_analyzer_tool/cli.pythat renders a ranked Rich tableWhy this is a good first issue
It's a clean vertical slice: one SQL query → one API endpoint → one CLI command. Follow the pattern of existing commands like
anomaliesorcontext-cost.