Hierarchical Supervision

A supervisor fans work out to sub-agents behind a bounded semaphore, collecting into a pre-sized ordered results slice, with per-worker fault isolation so one panic becomes one failed result

Hierarchical Supervision A supervisor fans work out to sub-agents behind a bounded semaphore, collecting into a pre-sized ordered results slice, with per-worker fault isolation so one panic becomes one failed result 01 / Dispatch 02 / Bounded 03 / Work 04 / Collect Supervisor · owns the run · 01 / Dispatch · parent Supervisor owns the run parent Semaphore · bounded slots · 02 / Bounded · backpressure Semaphore bounded slots backpressure Worker 1 · sub-agent · 03 / Work · ok Worker 1 sub-agent ok Worker 2 · sub-agent · 03 / Work · ok Worker 2 sub-agent ok Worker 3 · panics · 03 / Work · isolated Worker 3 panics isolated Results Slice · pre-sized, ordered · 04 / Collect · fan-in Results Slice pre-sized, ordered fan-in fan-out slot 1 slot 2 slot 3 result[0] result[1] failed[2] Legend primary data policy / PII async batch data store

Bounded Fan-out

  • • The supervisor dispatches work to sub-agents
  • • A semaphore caps concurrency with backpressure
  • • No unbounded goroutine explosion

Ordered Fan-in

  • • Each worker writes to a fixed slice index
  • • The results slice is pre-sized and ordered
  • • Fan-in fires once every source completes

Fault Isolation

  • • A worker panic is recovered per worker
  • • One panic becomes one failed result
  • • The run finishes with a complete result set