claude-code
claude-code copied to clipboard
[BUG] /stats command doesn't count the subagent models
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
Subagent invocation are missing from /stats command. The model that is used by subagent is not even displayed
What Should Happen?
Subagent invocation should be correctly displayed with /stats command
Error Messages/Logs
Steps to Reproduce
- Set up Claude Code with AWS Bedrock
settings.json
{
"env": {
"AWS_PROFILE": "bedrock-code-access",
"CLAUDE_CODE_USE_BEDROCK": "1",
"AWS_REGION": "us-east-1",
"ANTHROPIC_MODEL": "arn:aws:bedrock:us-east-1:194516173173:inference-profile/us.anthropic.claude-opus-4-5-20251101-v1:0"
}
}
- Create subagent with Haiku model:
.claude/agents/stats-counter-tester.md
---
name: stats-counter-tester
description: "Use this agent when it is directly requested by the user"
model: haiku
color: red
---
Your primary purpose is to assist in testing model types. You need to assist user with exploring what is the LLM model you are using.
- Request from the subagent the model it is using:
Prompt:
Ask stats-counter-tester what model it is using
The subagent is uses haiku model and indeed it is invoked (opus is the model for the main chat, ignore it):
BUT
The /stats command doesn't show any haiku invocations at all
Claude Model
Not sure / Multiple models
Is this a regression?
I don't know
Last Working Version
No response
Claude Code Version
2.1.5
Platform
AWS Bedrock
Operating System
macOS
Terminal/Shell
iTerm2
Additional Information
No response