The ladder of autonomy
more autonomy, cost and latency ↓
- Augmented LLMone call with retrieval, tools, memory
- Workflowyour code fixes the path; Claude does each step
- AgentClaude chooses the next step in a loop
- Multi-agent systemseveral agents coordinated (see 1.4)
The definitions that everything rests on
Anthropic’s “Building effective agents” draws the line that this task statement uses. Workflows are systems where LLMs and tools are orchestrated through predefined code paths. Agents are systems where the LLM dynamically directs its own process and tool use, keeping control over how it accomplishes the task. Both are built from the same block: the augmented LLM, a model enhanced with retrieval, tools and memory that it can use actively — writing its own search queries, choosing tools, deciding what to remember.
The augmented LLM
- Retrievalsearch the knowledge base
- Toolsquery or act on systems
- Memorynotes kept across turns
- Instructionssystem prompt, examples
The five workflow patterns
When one call is not enough but the path can be written down, a workflow keeps control in your code. Anthropic describes five recurring shapes. Learn each one with the signal that points to it, because items often describe the signal and not the name.
| Pattern | How it works | Choose it when | Enterprise example |
|---|---|---|---|
| Prompt chaining | Fixed sequence of calls; code gates between steps | The task splits cleanly into known steps | Draft a policy summary, check it against a rule list, then translate |
| Routing | Classify the input, send it to a specialised path | Distinct input types need different handling | Send billing, fraud and technical tickets to different prompts or models |
| Parallelization | Run calls at once: independent sections, or votes | Subtasks are independent, or you want several opinions | Screen a contract for five risk types at once; vote on a fraud flag |
| Orchestrator-workers | A model splits the task at run time and delegates | You cannot predict the subtasks in advance | Update every affected clause across a set of contracts |
| Evaluator-optimizer | One call drafts, another critiques, loop | Clear criteria exist and feedback measurably helps | Refine a regulator letter until it meets a style and content rubric |
Two distinctions are worth holding onto. Parallelization and orchestrator-workers both fan out, but in parallelization your code fixed the subtasks beforehand, while the orchestrator decides them from the input. And routing is also a cost lever: the article notes that easy queries can go to a smaller, cheaper model and hard ones to a more capable one. Anthropic’s ticket-routing guide adds a practical twist — with more than about twenty categories, a hierarchy of classifiers can beat one flat classifier.
ROUTES = {
"billing": {"model": FAST_MODEL, "system": BILLING_PROMPT},
"fraud": {"model": CAPABLE_MODEL, "system": FRAUD_PROMPT},
"technical": {"model": FAST_MODEL, "system": TECH_PROMPT},
}
def handle(ticket: str) -> str:
# Step 1: one small call classifies the ticket.
label = classify(ticket) # returns "billing" | "fraud" | "technical"
route = ROUTES.get(label)
if route is None:
return send_to_human(ticket) # unknown label: fail safe, not creative
# Step 2: the specialised prompt handles it. Code, not the model, chose this path.
reply = client.messages.create(
model=route["model"], max_tokens=1024,
system=route["system"],
messages=[{"role": "user", "content": ticket}],
)
return reply.content[0].textWhen an agent is worth it
Anthropic’s guidance is to reach for agents on open-ended problems where the number of steps cannot be predicted and a fixed path cannot be hard-coded. An agent is, at heart, a model using tools in a loop and checking the results against the real environment at each step. That makes it powerful for work like resolving an IT incident or investigating an account anomaly, where each finding changes what to look at next.
The article is equally clear about the price. Agentic systems trade latency and cost for task performance; autonomy brings higher cost and the potential for compounding errors, so agents need extensive testing in sandboxed environments and appropriate guardrails. Two domains fit especially well: customer support, which combines conversation with actions such as looking up orders or issuing refunds, and coding, where automated tests give the agent objective feedback.
Choosing a pattern
- One judgement, known inputsAugmented LLMsingle call, retrieval, tools
- Known steps, fixed orderWorkflowchain, route, parallelize, evaluate
- Subtasks depend on inputOrchestrator and workersmodel plans, code bounds it
- Open-ended, unknown stepsAgentloop, guardrails, checkpoints
Workflow versus agent at a glance
Workflow
- Path fixed in code; predictable and repeatable
- Cost and latency known per request
- Easy to test step by step and to audit
- Breaks on inputs the designer did not foresee
Agent
- Model chooses tools and steps at run time
- Cost and latency vary per task
- Needs sandbox testing, guardrails and stop rules
- Adapts to inputs nobody anticipated
How you build it follows from the pattern
The article recommends starting with direct API calls — many patterns are a few lines of code — and adopting a framework only when you understand what it does underneath, since abstractions can hide the prompts and responses you need to debug. For agentic patterns, Anthropic offers three routes. With the Client SDK you call the API and implement the tool loop yourself. The Agent SDK is a Python and TypeScript library that runs the agent loop for you, with the same built-in tools, context management, hooks, subagents, permissions and MCP support as Claude Code. Managed Agents is a separate hosted API where Anthropic runs the agent and its sandbox, for long-running or asynchronous agents without your own infrastructure.
| Pattern | Usual implementation | What the architect still owns |
|---|---|---|
| Augmented LLM | Messages API call with retrieval and tools | Context selection, output contract |
| Workflow | Your code calling the API step by step | Gates between steps, error paths, routing rules |
| Agent | Agent SDK, or a hand-written loop; Managed Agents if hosted | Tool permissions, stop conditions, human checkpoints |
Traps the wrong answers are built from
| Tempting but wrong | Do this instead |
|---|---|
| Defaulting to an agent because the stakeholder said “agent” | Match autonomy to the task: use an agent only when the steps cannot be predicted. |
| Forcing a rigid chain onto open-ended investigative work | Use orchestrator-workers or an agent where the next step depends on what was just found. |
| Calling any system with a loop an “agent” | If code fixes the roles and the exit, it is a workflow (for example, evaluator-optimizer). |
| Adopting a heavy framework before understanding the pattern | Start with direct API calls or a well-understood SDK, and know what it does underneath. |
| Shipping an agent without sandbox testing, guardrails or stop rules | Constrain tools and permissions, set limits and add human checkpoints before production. |
You should now be able to
- Define workflow, agent and augmented LLM, and explain how they relate.
- Recognise the five workflow patterns from a scenario’s signals and name when each fits.
- Decide when the unpredictability of a task justifies an agent’s extra cost and risk.
- Assign different patterns to different processes within one engagement and justify each in business terms.
- Choose between direct API calls, the Agent SDK and Managed Agents for an agentic design.