Preflight Checklist
What's Wrong?
Claude Code process consumes ~13 GB of RAM when running a session with Teammate mode (multi-agent teams via TeamCreate / Task with team_name). Upon closing the session, memory usage spikes to ~16 GB before the process terminates.
What Should Happen?
Memory usage should remain reasonable (under 2-4 GB) even during multi-agent sessions, with proper cleanup of agent contexts when they go idle or shut down.
Error Messages/Logs
Steps to Reproduce
- Start a Claude Code session
- Create a team using
TeamCreate and spawn multiple teammates via Task tool (I used just 3 teammates and teamlead)
- Work with the team for a moderate session (~30-60 min)
- Observe memory usage in Task Manager — it grows to ~13 GB
- Close/exit the session — memory spikes to ~16 GB before process exits
Claude Model
Opus
Is this a regression?
I don't know
Last Working Version
No response
Claude Code Version
2.1.34 (Claude Code)
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
PowerShell
Additional Information
- Node.js version: v22.22.0
- RAM: 32 GB total
- Single-agent (non-team) sessions do not exhibit this level of memory usage
- The issue appears to be related to agent context accumulation — each teammate likely retains its full conversation history in memory without compaction or disposal
Preflight Checklist
What's Wrong?
Claude Code process consumes ~13 GB of RAM when running a session with Teammate mode (multi-agent teams via
TeamCreate/Taskwithteam_name). Upon closing the session, memory usage spikes to ~16 GB before the process terminates.What Should Happen?
Memory usage should remain reasonable (under 2-4 GB) even during multi-agent sessions, with proper cleanup of agent contexts when they go idle or shut down.
Error Messages/Logs
Steps to Reproduce
TeamCreateand spawn multiple teammates viaTasktool (I used just 3 teammates and teamlead)Claude Model
Opus
Is this a regression?
I don't know
Last Working Version
No response
Claude Code Version
2.1.34 (Claude Code)
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
PowerShell
Additional Information