Engineering
Multi-Agent Systems: How Commander, Workers, and Analysts Cooperate
March 22, 2026 · 5 min read
Clerk is a hierarchical multi-agent system. Here is how a Commander, an army of Workers, an Analyst, and a Synthesizer collaborate on one research task.
Single-model chatbots are great at conversation. They are less great at research — because research is not one task, it is thousands.
Clerk solves this with a hierarchical multi-agent architecture built on a map-reduce pattern.
The Commander (o3 / DeepSeek-R1) decomposes a topic into 100+ sub-niches and assigns each a timeframe and search strategy. This is the "map" — planning the shape of the investigation.
The Workers (Claude 3.5 + GPT-4o-mini) execute the plan. Each researches a single sub-niche, extracts structured data against a Pydantic schema, and scores source reliability. Because every worker is an isolated Temporal workflow, one failing to hit a rate limit never affects the other 99.
The Analyst (DuckDB + Polars) performs the "reduce" — loading every result, computing correlations and trend vectors, and deduplicating claims.
The Synthesizer (Claude 3.5) writes the final report, weaving the statistics into prose with citations and predictive odds.
Coordination across all four is handled by LangGraph, which manages state transitions and checkpoints between phases — so the whole system is resumable, observable, and durable.