π§ Pattern: Write Once, Delegate Many β The All-Clone Context Block
When a prime agent is delegating the same process to multiple clones β just with different inputs each time β there's a subtle but costly inefficiency lurking: that process description gets written out again. And again. And again. Once per clone_chat call, buried in the message, slightly different each time, with a growing risk that something gets dropped or drifts.
The classic workaround? Hope the agent remembers to be consistent, or write the process instructions into the agent's persona permanently. Neither is great β one is fragile, the other bloats every session whether you're delegating or not.
Agent C's clone delegation system already injects task-specific context per clone via the message you send. But there's a second channel β a shared context block that gets included in every clone's system prompt automatically.
A prime agent can write to:
//{{active_workspace}}/.agentc/blocks/{{session_id}}/agents/{{agent_key}}/all_clone_context.md
...and that content will appear in every clone spawned from that session, under its own clearly labelled section:
# Your Parent Agent's Instructions and Context supplied to ALL CLONES (if any)
The path is scoped to the session and the agent, so there's no cross-contamination between different agents or different runs.
The prime agent sees this in its instructions:
You may write information and instructions to the file:
`//{{active_workspace}}/.agentc/blocks/{{session_id}}/agents/{{agent_key}}/all_clone_context.md`
to provide context and instructions that will be visible to all clones.And because a picture is worth a thousand tokens, there's also an expandable preview block right there in the prompt β the prime agent can check what it actually wrote without going back to the file:
### Current All Clone Context
{{ contents of the file, rendered inline }}That preview only shows up in the prime session, never the clone β keeping clone prompts lean.
- Write the process once β define your delegation guidelines, constraints, or workflow steps a single time at the start of a delegation run
- Every clone gets it automatically β no need to repeat it in each individual message
- Session and agent scoped β isolated per run, no stale instructions bleeding across sessions
- Inspect without leaving the chat β the expandable preview lets the prime agent verify what clones will see
- Per-clone context still works β the all-clone block and the per-task message are additive, not mutually exclusive
Think of it like a pre-shift briefing versus individual task assignments. The briefing covers the rules of engagement, the goals, the constraints β once, for everyone. Then each worker gets their specific job. You wouldn't repeat the entire briefing for every task assignment. Neither should your agent.