RAG & Agents Engineering

M36 lab, parallel agents

Parallel branches wait for the slowest one.

One Larkspur Cloud support question, split into four sub-questions, each answered by its own LangGraph node, then one synthesizer. Run them one at a time or in parallel, and watch where the superstep barrier, the join and a concurrency cap spend the time.

“I’m cancelling my annual plan after this week’s outages. Can I get a full refund, how long will it take, can I still export my data, and do I get credits for the outages?”

Run the four sub-question agents
The outage sub-question
Join into the synthesizer
Answer lands at
One at a time
Time saved
First sub-answer streamed
Synthesizer runs
Supersteps

Timeline, one lane per node

Superstep timeline

Bars are node runs; numbers above the grid are supersteps, and a dashed rule marks where each one ends. A dotted line is a node whose input was ready but which had to wait: for the barrier, or for a free slot under the cap.

What astream emits

Time (s)ModeEvent

Latencies are stubs, as in notebook 05b: each node sleeps a fixed time (plan 0.4 s, refund window 1.0, refund timing 0.8, export 1.2, rewrite 0.5, credits 1.0, synthesizer 0.8). The schedule is LangGraph’s, checked against LangGraph 1.2.18 running the same graph with asyncio.sleep at every setting.