← Back to Handbook
EP02 · 55m Cache · 0-Token Poll

9 Parallel Agents Burned 91% of My Quota in 1 Hour: 4 Fixes

At peak concurrency, 9 parallel sessions burned 91% of a 5-hour quota in one hour—and half a weekly quota in a single day. Most tokens were not spent writing code; they were lost to cache busts, bloated contexts, and coordinator bottlenecks.

1. Fixed Model + 55-Minute Wakeups to Hold Prompt Cache

Previously, switching models or toggling MCP tools mid-session invalidated Prompt Cache immediately, forcing full-price re-ingestion of the entire context.

Now the coordinator stays pinned to one model and a fixed toolset (spawning one-off higher-tier subagents only for hard edge cases). Scheduled wakeups fire within 55 minutes—just inside the 1-hour cache TTL—and handoffs happen around 300K tokens to avoid paying ~100K cold-start tax too frequently.

2. Fresh Session Per Task + 10-Line Worker Reports

Following Anthropic's context engineering guidance, every new task starts in a fresh session instead of extending an old thread. Codebase exploration runs in lightweight read-only subagents whose reports are capped at 10 lines—never dumping raw JSON payloads into the coordinator.

3. Cap Task Splits at 1 Generation + Risk-Tiered Sign-Off

Without split thresholds, agents spawned follow-up tickets on follow-up tickets—three generations deep, each paying cold-start context tax. Worse, requiring central sign-off for typo fixes forced 45 mechanical approvals in one afternoon, stalling workers for 5–10 minutes per turn.

We capped splits to one generation max and introduced risk-tiered sign-off: non-semantic wording fixes self-approve with the PR and are spot-checked asynchronously.

4. Decouple Pull Queue From Push Signals With 0-Token Polling

Push-only assignment caused a review request to sit unread for over an hour while idle agents waited for pings.

Inspired by Kubernetes label selectors and Temporal task queues vs. signals, we split data plane and control plane: role-labeled tickets form a persistent pull queue (decoupled from specific model names), polled every 5–10 minutes by a lightweight local shell script at zero token cost. Messaging is reserved strictly for review signals and merge-conflict alerts.

Related drop-in template → Multi-Agent Cache Rules + 0-Token Local Poll Script

REFERENCES

  • [1] Anthropic Docs, Prompt Caching
  • [2] Anthropic Engineering, Effective Context Engineering for AI Agents (2025)
  • [3] Kubernetes Documentation, Labels, Selectors & Controllers
  • [4] Temporal Documentation, Task Queues and Signals