Skip to content

Agentic systems

AI agents vs workflows: choosing the right architecture

Use a workflow when you can define the process; use an agent when the next useful action depends on what the system discovers. Keep predictable control in code and grant model-directed behaviour where adaptation earns its additional complexity.

4 min read

Ask who controls the next step

The useful distinction is control flow, not whether a system calls a language model. Anthropic describes workflows as predefined paths connecting models and tools, while agents dynamically direct their process and tool use. A workflow can contain sophisticated reasoning. An agent can perform a narrow task. Neither label, by itself, tells you whether the result is dependable or appropriate for the problem.

Separate two decisions at the start: where does a model add useful judgement, and where should the application retain control? Asking for a structured classification does not require handing over the entire process. Conversely, a rigid sequence can become awkward when each result changes what information the system needs next. Architecture should reflect that uncertainty rather than the popularity of a particular label.

Use workflows for known processes

A hypothetical document-processing task might extract fields, validate a schema, request review for missing information and export an approved record. The stages and allowed branches are known. Application code can enforce the sequence while a model handles extraction. Microsoft’s agentic-patterns guidance similarly separates deterministic orchestration from the non-deterministic model or tool work performed inside individual steps. Deterministic control flow does not mean identical model outputs.

This design makes checkpoints and ownership easier to specify. You can reject an invalid intermediate result before the next stage consumes it, or resume a failed operation from a recorded checkpoint. These properties still require implementation and testing; drawing boxes in a workflow editor does not create them automatically. Prefer the smallest explicit process that represents the real task, including its exception paths.

Use agents for adaptive investigation

Now consider investigating an unfamiliar integration failure. The useful next action may depend on a test result, an error message or a newly discovered dependency. A bounded agent can choose which approved diagnostic tool to use, inspect the result and revise its plan. That flexibility is the reason to introduce model-directed control—not the ability to display a convincing reasoning narrative.

Anthropic cautions that agentic complexity can increase cost and latency. Test whether the extra decision-making improves task completion enough to justify those costs. Start with a constrained agent and a small tool surface before introducing several cooperating agents. Additional actors create more interfaces and coordination to inspect; they are an architectural option, not an automatic upgrade in intelligence or reliability.

Combine adaptation with boundaries

Workflows and agents need not be competing systems. A fixed workflow can delegate one uncertain investigation to an agent, then validate its output before continuing. Microsoft’s guidance shows both code-directed workflows and agent loops within durable execution, including approval and recovery mechanisms. Those are implementation patterns to consider, not reasons to assume a particular framework removes the need to design failure handling.

Before allowing a tool call, define the permitted operation and the authority behind it. Before starting a loop, define its time, step or resource budget and its escalation path. Assess success using the resulting artifact or system state, not merely the agent’s final assertion. The best architecture is the one that exposes useful judgement while keeping consequential decisions inspectable, bounded and testable.

Sources and further reading

  1. Anthropic Engineering — Building effective agents
  2. Microsoft Learn — Agentic application patterns
AI agents vs workflows: choosing the right architecture

Explore Deep Seven

Follow your
curiosity.

Find a discipline, follow an idea, or go straight to the engineering.

⌘ / Ctrl + K to explore · Esc to close