1
Curious builder0 XP earned · 300 to level 2
0 daysFinish a lesson to begin
Badge collection0 of 6 unlocked
51 small wins to finish your pathNext question →
Workflow vs agent: when would you NOT use an agent?
30-second answerSay your answer out loud first, then reveal.
A common framing (popularised by Anthropic's "Building effective agents"):
- Workflow: LLMs and tools are orchestrated through predefined code paths.
- Agent: the LLM dynamically directs its own process and tool use.
| Workflow | Agent | |
|---|---|---|
| Steps known upfront | Yes | No |
| Predictability | High | Lower |
| Cost / latency | Low, bounded | Higher, variable |
| Testing | Unit-test each step | Needs trajectory evals |
| Best for | Invoice extraction, classification + routing, fixed report generation | Open-ended research, coding, debugging, multi-system troubleshooting |
Don't use an agent when
- The task is a fixed pipeline, e.g. extract fields → validate → write to DB.
- Latency budgets are tight, e.g. under 1–2s for a UI autocomplete.
- Errors are expensive and the path can be specified, as with regulated financial or medical steps.
- You can't yet measure success. Without evals, an agent is impossible to improve.
Good answer pattern. "I'd first try a single well-prompted LLM call with retrieval. If that fails, a workflow such as prompt chaining or routing. I'd move to an agent only if the task genuinely needs dynamic, multi-step decisions, and even then I'd constrain its tools."
Common mistakes
- Treating "agentic" as automatically better.
- Building a multi-agent system for something a single prompt could do.
Follow-ups to expect
- Give an example where you'd move from a workflow to an agent.
- Can you mix the two? (Yes. Most production systems are workflows with agentic sub-steps.)
Related
This is what real progress feels like.