Why it matters

LLM-driven orchestration is expensive and unpredictable. Workflow agents make known patterns deterministic and cheap.

Advertisement

The architecture

SequentialAgent: children run in list order, each seeing previous outputs.

ParallelAgent: children run concurrently, all seeing same input.

LoopAgent: repeatedly run child until termination condition (max iterations or explicit stop).

Workflow patternsSequentialsteps in orderParallelconcurrent branchesLoopiterate until doneState flows between sequential steps; parallel branches merge outputs
Workflow types.
Advertisement

How it works end to end

Session state passes info between agents. Sequential naturally chains; parallel aggregates.

Loop termination: max iterations config or child agent explicit stop.

Combining: Sequential can contain LlmAgent + workflow; deeply nested workflows possible.