Skip to main content

Multi-Agent Pattern

Production systems rarely have one agent. You have a planner, executor, verifier, and escalation agent. The hard part isn’t building them — it’s keeping them consistent when they share a task. StateBase gives every agent a shared, durable source of truth: sessions, memories, and traces that all agents read and write.

Orchestrator + Workers

The most common topology. One orchestrator decomposes the task, dispatches workers, and merges results.
Each worker rehydrates the same session, so partial results are visible to everyone:

Supervisor Pattern

A supervisor delegates and evaluates — nothing critical runs without a checkpoint:

Handoffs

When agent A hands off to agent B, write a handoff record so B has full context — and any third agent can audit the chain:

Shared Memory

Agents that should learn from each other share memories, not just sessions:

Anti-Patterns

  • Shared mutable globals — agents overwriting each other’s state; use one session + namespaced keys
  • Orphan workers — workers that die without checkpointing; always checkpoint start and finish
  • Blind trust — the verifier agent must validate worker output before merge
  • Infinite delegation — cap handoff depth with a metadata counter (see above)

Next Steps