← Back to context

Comment by exitb

2 days ago

Multiple instances of agents are an equivalent to tabs in other applications - primarily holders of state, rather than means for extreme parallelism.

I have not used Claude. But my experience with Gemini and aider is that multiple instances of agents will absolutely stomp over each other. Even in a single sessions overwriting my changes after telling the agent that I did modifications will often result in clobbering.

  • See the agent as a coworker ssh-ing on your machine, how would you work efficiently ? By working on the same directory ? No

    You give each agent a git worktree and if you want to check, you checkout their branch.

  • You should try Claude opus 4.5 then. I haven’t had that issue. The key is you need to have well defined specs and detailed instructions for each agent.

  • Proper sandboxing can fix this. But I didn’t see op mention it which I thought was weird

    • Op mentions in the follow up comments that he does a separate git checkout, one for each of the 5 Claude Code agents he runs. So each is independent and when PRs get submitted that's where the merging happens.