Concept
SUMMARY is text that you write in the route. It is not a summary that the platform generates. The runtime fills the {{variables}} in your text with the calling agent’s values and sends the result to the target as _handoff_summary. The target model reads it as context.
The summary and the history setting work together. HISTORY decides whether the target also gets raw messages. See Choose the right history strategy for handoff.
Write the summary for a reader who has not seen the conversation. State who the customer is, what they want, and what is already done.
Minimal working example
A billing router gathers the account number and the disputed amount. It sends a one-line brief and no raw history. The specialists are short stand-ins in the same project. Replace them with your real agents.agents/billing-hub.agent.abl
agents/dispute-agent.agent.abl
agents/payment-plan-agent.agent.abl
account_idanddisputed_amountareGATHERfields of the router.PASScopies them. The summary text reads the same router values.dispute_reasonandinstallmentsare gathered by the specialists.
How it works
- The router selects a route.
- The runtime replaces each
{{variable}}in the summary with the router value. A variable with no value becomes an empty string. No error occurs. - The runtime stores the result as
_handoff_summaryin the target context and authorizes it for the target prompt. - The runtime applies the
HISTORYsetting. Withsummary_onlyornone, the target gets no raw messages.
- A routing model cannot supply
_handoff_summary. Only theSUMMARYtext in the route sets it. - The summary is a template. It does not change between conversations except through its variables.
- The shorthand
SUMMARY:takes a one-line quoted string. For several lines, usesummary: |inside aCONTEXT:block, as the payment plan route does. - In a
DELEGATE,SUMMARYis a synonym forPURPOSE. A delegate does not use it as a history summary.
HISTORY: auto decides:
- If the route has a non-empty
SUMMARYand the target runs on a model, the runtime sends the summary only. - If the target does not run on a model, the runtime sends the last 5 messages.
- If a pipeline short-circuit triggers the handoff, the runtime sends the last 5 messages even when a summary exists.
Common variations
Summary with a bounded window of messages
Keep the summary and add the last few messages when the target needs the customer’s exact words.GATHER fields from the minimal example. last_5 and the block form mode: last_n with count are equivalent.
Summary on a returnable handoff
A child that returns control also gets the summary. Use it to state the one job the child must finish. See Transfer control to another agent and return later.Summary that carries a fixed instruction
A summary can hold fixed text and no variables, as in “Identity is already verified in this session.” Use this for facts the router knows from its own flow. Do not use the summary to grant permissions or skip checks. The target must verify any fact that affects authorization.Verification
- Run the validator. Expect no errors and no warnings.
- Send “I want to dispute a charge” and answer the router questions.
- Expect a
handofftrace event withto: Dispute_Agent. - Expect the target context to include
_handoff_summarywith the account number and amount filled in. - Expect
Dispute_Agentto ask only for the dispute reason. - Send a payment plan request. Expect the
history: autoroute to send the summary and no raw messages, becausePayment_Plan_Agentruns on a model. - Remove
SUMMARYfrom the first route. Expect the warningHANDOFF_SUMMARY_ONLY_WITHOUT_SUMMARY.
Production readiness checklist
- Each route that uses
summary_onlyorautohas aSUMMARY. - Each variable in the summary exists in the calling agent.
- The summary holds no data that the target must not see. See Minimize context for privacy and compliance.
- The target does not depend on facts that only the raw conversation held.
- Tests cover a filled summary and a summary with a missing variable.
- Trace checks confirm the summary text on each handoff.
Common mistakes
Troubleshooting
Related articles: