Basic composition
Add a compiled graph as a node in another graph:aegra.json:
Streaming subgraph events
By default, streaming only includes events from the top-level graph. To include subgraph events:Interrupts in subgraphs
Interrupts work transparently across subgraph boundaries. If a subgraph callsinterrupt(), the parent run pauses and the client receives the interrupt payload. Resuming the run continues execution inside the subgraph.
Inspecting subgraphs
Use the assistant API to explore subgraph structure:State and checkpoints
Subgraph state is stored within the parent graph’s checkpoints. When you inspect thread state, subgraph checkpoints are available via thecheckpoint_ns parameter: