What is narrative casting in multi-agent systems?
Narrative casting is a multi-agent context technique in which one agent's earlier messages and tool calls are rewritten as attributed background before another agent sees them, so the new agent does not treat them as its own.
Checked
When control passes from one agent to another, the new agent often needs to see what happened so far. Passed through unchanged, the earlier agent's replies arrive as assistant messages, which the new model reads as things it said and did itself. It may then claim actions it never took, repeat tool calls, or carry on in the other agent's role.
Google's "Architecting efficient context-aware multi-agent framework for production" (2025-12-04) names the fix narrative casting. During a handoff, prior assistant messages are re-cast as narrative context, along the lines of "For context: Agent B said...", and tool calls from other agents are marked or summarised so the new agent acts on their results without confusing them with its own execution.
How ADK implements it
Role change
In the ADK source, an event authored by another agent is rewritten with the user role instead of the assistant role, so the model reads it as information supplied to it.
Attribution
Text is prefixed "[agent name] said:", tool calls become "[agent name] called tool ... with parameters", and results become "[agent name] ... tool returned result". Another agent's reasoning is included only when a setting allows it.
A framing preamble
The rewritten block opens with a note that it is a quoted transcript of what another agent did, and that instructions come only from the agent's own system instruction and the user.
Fenced as data
The source notes that relayed text is attacker-reachable, since anyone who talks to the other agent can shape it. Each relayed payload is therefore fenced in quote markers and treated as data.
When it applies
Google describes two multi-agent modes. With agents as tools, the called agent sees only focused instructions and the artifacts it needs, with no history, so there is little to cast. With agent transfer, the receiving agent inherits a view over the session, and narrative casting is what keeps that inherited history from being mistaken for its own. A setting can also pass no prior history at all.
What it is confused with
Handoff
The handoff is the transfer of control. Narrative casting is how the history is presented to the agent that receives it.
Summarisation
A summary condenses what happened. Narrative casting keeps the content but changes who it is attributed to, and can be combined with a summary.
Prompt injection defence
Casting is not a complete defence, but fencing relayed text as data narrows one path by which content from another agent's conversation could issue instructions.
How Motiontic's engineers apply it
In multi-agent designs, Motiontic's engineers decide per handoff whether the receiving agent needs history at all, and when it does, pass it attributed and fenced rather than raw. Evals include handoffs where the earlier agent made a mistake, to check the next agent does not repeat or claim it.
Raw history compared with narrative-cast history
| Raw history | Narrative-cast history | |
|---|---|---|
| Other agent's replies arrive as | Assistant messages | User-role context with the agent's name |
| Other agent's tool calls | Look like the new agent's own | Attributed, with parameters and results quoted |
| Risk of claiming others' actions | High | Low |
| Injected text in relayed content | Can read as instructions | Fenced and framed as data |
Common questions
What is narrative casting in AI agents?
It is a way of passing one agent's history to another: prior messages and tool calls are rewritten as attributed background, so the receiving agent knows another agent said and did them.
Why do multi-agent systems need narrative casting?
Without it, a new agent reads another agent's assistant messages as its own, and may claim actions it did not take, repeat tool calls or adopt the other agent's role.
Which framework uses narrative casting?
Google introduced the term for its Agent Development Kit, which rewrites other agents' events as attributed user-role context during agent transfer.
Related
Agent handoff
One agent passes the conversation to another, which carries on from there.
Working context
The per-call view of the agent's state, compiled fresh for each model call.
Prompt injection
Untrusted text that hijacks a model's instructions, and how agents are built to survive it.
Single Agent vs Multi-Agent
One loop with good tools, compared with several agents splitting the work.
AI agent development
Agents that do real work for users, with the evals, traces and guardrails to keep them in production.
Running agents that have to hold up?
Describe the agent, the systems it touches and what it must never get wrong. The first call is with a lab engineer, who will say plainly whether it is ready for production, and whether Motiontic is the right team.