Manager, handoff, and agent-as-tool patterns
8 min read
Lesson objectives
- Design a defensible decision that can choose who owns the answer and context.
Work on Manager, handoff, and agent-as-tool patterns starts from a named business result: choose who owns the answer and context. For a support system with triage, billing, and returns specialists, identify the unit of work, authorized identity, and intended effect. Establish a baseline for routing accuracy, context loss, and transfer count before introducing the selected agent. Treat forwarding all history unnecessarily or hiding a decisive fact as a failure state, not wording to explain away. The lesson requires an inspectable outcome rather than activity volume or persuasive text. For Manager, handoff, and agent-as-tool patterns, this point is checked through routing accuracy, context loss, and transfer count.
In a support system with triage, billing, and returns specialists, orchestration starts by locating decision ownership. A manager retains the journey and invokes a specialist for bounded analysis; a handoff transfers both responsibility and a compact decision packet. For a returned device with an outstanding instalment, the packet carries order identity, receipt state, amount, policy version, unresolved question, and expiry—not the whole transcript. Testing compares routing accuracy, context loss, and transfer count. Conflicting warehouse and carrier states remain explicit until the owning service resolves them.
Use a manager when ordering and one ledger matter more than specialist autonomy. Use an agent as a tool when a specialist contributes a bounded answer but the manager still owns the customer response. Use a handoff only when the receiver genuinely owns the next decision. Naming three agents after departments does not create three valid owners. The transfer packet states the decision already made, evidence references, the unresolved question, confidence limits, and the exact fields the receiver may use.
Take a message saying, “I returned the device, but the instalment remains.” Triage verifies the order and carrier receipt. Billing can explain the charge, but it cannot decide whether warehouse inspection is complete. If inspection remains with returns, the manager asks that specialist one question and preserves the conflict between carrier and warehouse state. A negative answer moves the case to a timed waiting state; a positive answer creates a new, bounded packet for billing. No component has to infer authority from the tone of the transcript.
In 120 trial cases, a keyword-driven handoff routes 96 correctly and averages 2.4 transfers. It also forces specialists to reread long histories. A manager with structured specialist calls routes 108 correctly and averages 1.2 transfers, but five summaries omit the receipt timestamp. The correct repair is to make received_at mandatory for return-billing cases, not to forward every message. Reviewers should be able to reconstruct each transfer—owner, question, evidence, and acceptance—from the ledger alone. If the original conversation is required to discover a decisive fact, the context contract is incomplete.
A mixed request asks why a return fee appears and also requests a new payment method. Returns owns the receipt and inspection facts; billing owns fee explanation; the payment service owns the effect. A single broad handoff would expose payment details to a specialist who needs only the return state. The manager asks returns for inspection_status and received_at, then asks billing to explain the fee using those verified fields. It does not pass card details through either specialist.
Suppose the carrier reports delivery on Monday and the warehouse reports inspection pending. Billing’s rule charges a temporary fee until inspection completes. The manager explains the provisional status and schedules a follow-up. It does not promise a refund based on carrier delivery alone. The separate payment-method change requires fresh customer verification and an effect tool. If verification fails, the fee explanation can still finish while the change remains paused; one incomplete branch does not erase the valid answer on another. Measure routing accuracy by decision, not by the number of named agents invoked. Count the transitions needed to resolve the fee, whether a decisive timestamp was lost, and whether private fields crossed unnecessary boundaries. An alternative design may hand the whole case to a billing owner once inspection is complete, but the transfer packet must contain the verified state, unresolved question, and authority limit. The architecture record states which pattern was selected and which new evidence would justify a real handoff.
Manager, handoff, and agent-as-tool patterns differ in decision ownership. A manager retains final composition; a handoff transfers conversational control; an agent-as-tool returns a bounded result. Billing calculation fits a tool, while an extended specialist conversation may justify handoff. Test mixed-intent requests, bounce rate, and whether decisive facts survive transfer. Forward the minimum necessary history and redact tool arguments or outputs that the receiver does not need. A handoff is justified only when the receiver owns a distinct decision, not merely because a second prompt is convenient. The transfer package should contain the prior decision, unresolved question, applicable policy version, evidence references, and an expiry time. If the receiver must inspect an unrestricted transcript to reconstruct intent, the handoff has failed as an interface. The manager pattern remains preferable when ordering and one audit trail matter more than specialist autonomy. A specialist’s answer should itself have a small schema. Returns might reply with inspection_status, received_at, source_version, and unresolved_discrepancy. Billing might reply with fee_basis, amount, policy_version, and a plain-language explanation. The manager checks these outputs before using them. A free-form answer like “looks fine” cannot tell the manager whether the fee can be reversed or merely explained. That is why an agent-as-tool call can be useful even when another agent has richer domain knowledge: responsibility remains with the manager, while specialized analysis arrives in a bounded form.
Test a failed handoff deliberately. Remove received_at from the packet and ask the returns specialist to decide whether inspection was timely. If it guesses from a carrier message, the interface has allowed evidence to be confused with authoritative state. The correct response is a missing-context error or a direct query to the owning warehouse system, depending on the specialist’s permitted tools. Count this as a contract failure, not a reason to paste the entire history. A complete packet should be sufficient for the specific decision while excluding card details and unrelated complaints.
Lesson summary
Apply Manager, handoff, and agent-as-tool patterns with explicit boundaries, measures, a safe stopped state, and reconsideration triggers.