Lv.1 0 XP

Agentic Workflow Patterns — Prompt Chaining, Parallelization, and Best-of-N

Core 9 min +35 XP
💡
THE ANALOGY

Manufacturing processes. Assembly lines (prompt chaining) handle known sequences. Parallel production lines (parallelization) handle independent components that later get assembled. Quality control (Best-of-N) runs the same process multiple times and picks the best output.

⚠️ EXAM TRAP — The Wrong Answer People Choose

Thinking Best-of-N means running the same prompt three times and taking a majority vote. Best-of-N runs three complete agentic loops independently, then uses a separate evaluation step to select the best result — not a vote.

KEY POINTS
1 Prompt chaining passes output from one Claude call as input to the next — best for sequential tasks where each step builds on the previous.
2 Parallelization runs multiple Claude calls concurrently — best for independent subtasks that can be processed simultaneously.
3 Best-of-N generates N independent solutions and evaluates them to select the best — best for high-stakes outputs where quality matters more than speed.
4 The evaluation in Best-of-N is itself a Claude call with specific scoring criteria — not a vote or random selection.
5 Routing pattern: a classifier determines which specialized pipeline handles a request — avoids one-size-fits-all workflows.