Skip to content

feat: log tool_use calls in agent-runner for debugging#608

Closed
neocode24 wants to merge 1 commit intoqwibitai:mainfrom
neocode24:feat/tool-use-logging
Closed

feat: log tool_use calls in agent-runner for debugging#608
neocode24 wants to merge 1 commit intoqwibitai:mainfrom
neocode24:feat/tool-use-logging

Conversation

@neocode24
Copy link
Copy Markdown
Contributor

Summary

  • Log each tool invocation (name + truncated input) from assistant messages in the agent-runner
  • Helps diagnose which tools the agent is calling and with what arguments during container execution
  • Input is truncated to 200 chars to avoid log bloat

Changes

  • container/agent-runner/src/index.ts — Add tool_use logging in the assistant message handler

Example output

Tool use: Bash input={"command":"ls -la /workspace/group","description":"List files"}
Tool use: Read input={"file_path":"/workspace/group/CLAUDE.md"}
Tool use: mcp__nanoclaw__send_message input={"message":"Hello from the agent"}

Test plan

  • Verified logging output in container logs during agent execution
  • Confirmed truncation works for large tool inputs

🤖 Generated with Claude Code

Log each tool invocation (name + truncated input) from assistant
messages. Helps diagnose which tools the agent is calling and with
what arguments during container execution.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant