PrepGenAICerts

Workflow Composition Patterns & the Orchestrator-Workers Trap

Advanced

Select among the augmented LLM, workflow, and agentic architectural patterns · Difficulty 4/5

0%
workflowprompt-chainingroutingorchestrator-workersexam-traps

Explanation

Most workflows are built by composing the augmented LLM using one or more of five recurring patterns.

The Five Composition Patterns

  • Prompt chaining -- a fixed sequence of steps, each an LLM call on the previous output (with optional programmatic gate checks).
  • Routing -- classify the input, then dispatch to a specialized prompt or model.
  • Parallelization -- run subtasks concurrently (*sectioning*) or run one task several times and vote (*voting*).
  • Orchestrator-workers -- a central LLM decides subtasks *at runtime* and delegates to workers (this is where a workflow shades into an agent).
  • Evaluator-optimizer -- one LLM generates, another critiques and returns it for refinement.

Each pattern is still a workflow, not an agent, as long as the control flow itself is predefined in code -- even orchestrator-workers, where only the *content* of the subtasks (not the fact that delegation happens) is decided at runtime.

Common Exam Trap

> Trap: Confusing orchestrator-workers (subtasks decided dynamically at runtime) with parallelization sectioning (subtasks known in advance). The dividing line is *who decides the subtasks and when*.

In parallelization sectioning, the architect (or the code) already knows what the independent subtasks are before execution starts -- the workflow just runs them concurrently. In orchestrator-workers, a central LLM looks at the specific input and decides, at runtime, what the subtasks should be, then delegates. Both patterns involve delegating to multiple workers, which is exactly why they get confused on exam scenarios -- the test is whether the subtask boundaries were fixed in advance or discovered dynamically.

Matching Pattern to Task Shape

Task shapePattern
Same fixed sequence every timePrompt chaining
Input falls into distinguishable categories needing different handlingRouting
Independent subtasks known in advanceParallelization (sectioning)
Same task run multiple times for confidenceParallelization (voting)
Subtasks can't be enumerated until the input is inspectedOrchestrator-workers
Output quality benefits from a critique-and-refine cycleEvaluator-optimizer

Key Takeaways

  • Five workflow composition patterns: prompt chaining, routing, parallelization, orchestrator-workers, evaluator-optimizer
  • Prompt chaining is a fixed sequence of LLM calls, each on the previous output, with optional gate checks
  • Parallelization sectioning runs known-in-advance independent subtasks concurrently; voting repeats the same task and aggregates
  • Orchestrator-workers has a central LLM decide subtasks at runtime -- this is where workflow shades into agent
  • Exam trap: the line between orchestrator-workers and parallelization sectioning is who decides the subtasks, and when

Glossary Terms

Related Concepts

PrepGenAICerts.com is an independent third-party exam-prep platform for the Claude Certified Architect (CCA-F) certification. We are not affiliated with, endorsed by, or acting on behalf of Anthropic PBC.

Note: New premium upgrades are temporarily paused while we resolve an issue with our payment provider. Existing premium members retain full access.