davsclaus opened a new pull request, #24361:
URL: https://github.com/apache/camel/pull/24361

   ## Summary
   
   _Claude Code on behalf of Claus Ibsen_
   
   - Add `TokenUsage` record to `LlmClient` to capture input/output/total token 
counts from all three LLM providers (OpenAI, Anthropic, Ollama) in both 
streaming and non-streaming modes
   - Display accumulated token usage summary in `camel ask` CLI output after 
each response
   - Show token count alongside elapsed time in the TUI AI panel (title bar, 
footer, and activity log)
   - Track MCP tool call count in `TuiMcpServer` and display it in the MCP Log 
popup title
   
   ## Test plan
   
   - [ ] Run `camel ask` with Anthropic API and verify token summary line 
appears after response
   - [ ] Run `camel ask` with OpenAI-compatible API and verify token summary
   - [ ] Run `camel ask` with Ollama and verify token summary (streaming and 
non-streaming)
   - [ ] Open TUI with F8 AI panel and verify tokens appear in `(3s, 1234 
tokens)` format
   - [ ] Open TUI with `--mcp`, connect an external AI agent, and verify MCP 
Log shows `(N calls)` in title
   - [ ] Verify builds: `cd dsl/camel-jbang/camel-jbang-core && mvn install 
-DskipTests` and same for `camel-jbang-plugin-tui`
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)
   
   Co-Authored-By: Claude <[email protected]>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to