Hierarchy and Escalations
Agents form a parent-child hierarchy tree. Escalations travel up this tree before reaching the human HITL gate, keeping human interrupt rates low.
The Hierarchy Tree
When agent A spawns agent B, A becomes B's parent. The root agent has no parent and escalates directly to the human.

agentd tracks this tree. View it with:
ash hierarchy show
Escalation Flow
When an agent encounters a situation requiring escalation (capability request beyond its manifest, anomaly alert, plan deviation requiring human review):
- The escalation is sent to the agent's parent via the bus topic
scarab.escalation.<parent-id> - The parent agent receives the escalation via
agent.pending_escalations() - The parent can auto-resolve it (approve, deny, or reroute) or escalate further up
- Only the root agent escalates to the human HITL gate
Viewing Pending Escalations
ash hierarchy escalations
Lists agents with unresolved escalations in their mailbox.
Polling Escalations (SDK)
#![allow(unused)] fn main() { let escalations = agent.pending_escalations().await?; for esc in escalations { println!("Escalation: {}", esc); // Decide: auto-resolve or escalate to parent } }
Types of Escalations
| Type | Trigger |
|---|---|
| Capability request | Agent attempts action outside its manifest |
| Anomaly alert | Anomaly detector fires (see Anomaly Detection) |
| Plan deviation | Agent deviates from declared plan (Strict mode) |
| HITL approval | A tool requires human approval and no parent handles it |
| Budget exceeded | Agent exceeds its cost budget |
Capability Grants via Escalation
When an agent needs a capability not in its manifest, it can request a runtime grant:
- Agent's tool call fails with
AccessDenied - Agent (or its SDK) sends a grant request
- Grant request escalates up the hierarchy
- Parent or human approves the grant
agentdissues a temporaryCapabilityGrantfor that agent
See Capability Grants for operator details.