Workflows vs Agents

Updated · 4 min read
mediumPython 3.13aiworkflowsagentsautomationinterview

Should Campus Helper be a chatbot, a workflow or an agent? Everyone on Srihitha's team uses the word "agent" for everything. But a system that follows six fixed steps is very different from one that decides its own steps, and that difference changes how you test it, how you trust it, and what can go wrong.

This lesson separates the three, using one simple question: who decides what happens next?

Three Kinds of AI Systems

Who decides what happens next?
ChatbotWorkflowAgent
Who decides the next stepYou, each messageThe designer, in advanceThe model, within limits
StepsOne reply at a timeFixedChosen as it goes
PredictabilityHigh for one replyHighLower
TestingTest answersTest each stepTest many paths and outcomes
Best forQuestions and draftingRepeated, well-defined processesOpen-ended tasks with many possible steps

When to Use Which

Use a...When
ChatbotPeople want answers or drafts, and decide themselves what to do next
WorkflowThe steps are known and repeat, such as sorting and drafting email replies
AgentThe steps depend on what it finds, such as researching, comparing and scheduling across several tools

Most business processes are workflows, even when people call them agents. A workflow is easier to test, cheaper to run and simpler to explain, so start there. Choose an agent only when the steps genuinely can't be planned in advance, and then add the limits and approvals covered later in "Controlling Agent Autonomy".

Common Mistakes

Calling every AI system an agent. It hides important differences in risk and testing.

Building an agent for a fixed process. You add unpredictability for no benefit.

Giving an agent tools without limits. Agents need approvals, limits and logs.

Interview Corner

What is the difference between a workflow and an agent?

In a workflow, the steps are designed in advance and AI performs some of them; in an agent, the model decides its own next steps and which tools to use, in a loop toward a goal. Workflows are more predictable; agents are more flexible.

When would you choose a workflow over an agent?

When the process is well defined and repeats, because a workflow is easier to test, cheaper and more predictable. An agent suits open-ended tasks where the steps depend on what it finds.

Practice

Exercise: classify five systems. For each, decide chatbot, workflow or agent, and say who decides the next step: (1) an assistant that answers homework questions, (2) a system that tags invoices and sends them for approval, (3) an assistant that researches flights and hotels and proposes a trip plan, (4) a tool that summarizes every new support ticket, (5) an assistant that fixes a failing test by reading code, editing it and rerunning tests. Which could be redesigned as a simpler workflow?

Check your understanding:

  1. What question separates the three kinds?
  2. Why are most business processes workflows?
  3. When does an agent make sense?

Quick check: workflows vs agents

4 questions
1In a workflow, who decides the steps?
2Which is an agent?
3Why start with a workflow?
4What does an agent need that a workflow needs less?

Key Takeaways

Quick reference

SystemNext step decided by
ChatbotYou
WorkflowThe designer
AgentThe model, within limits

Was this tutorial helpful?

Lesson 75 of 186