Yesterday I just didn’t set this up, and the subagents bred like crazy. Some of them were already grandpas.
I was using CCX, my own alias for orchestrating multiple agents. In that session I hadn’t turned off nested subagents, and I hadn’t capped the total number of subagents either, so it kept spawning downward, one generation begetting the next, several generations stacked up. The result: one session burned 90% of my quota in half an hour.
Afterward I ran the forensics: it was recursive fan-out, Agent Teams, everyone running on the most expensive Sol, long context, plus an old proxy version, all multiplied on top of each other. Any single one of them might have been fine; put together, it blew up.
The fix was to bump CLIProxyAPI from 7.2.73 to 7.2.91, then add a few guardrails to ccx(): a cap on total subagents, a cap on parallelism, background execution, a retry count, and compression. I ran one test round — 2 Terra subagents, depth 1, zero nesting — and it ended normally, no runaway burn. cc and cdx I left alone.
That’s the thing to watch out for. Besides setting the compaction window yourself, remember to turn off nested subagents and cap the total number of subagents.