When not to build an agent
Most tasks called agentic are a chain of two prompts and an if statement, and they are better for it.
A workflow is a fixed sequence you wrote: retrieve, then summarise, then classify. An agent decides its own next step in a loop until it thinks it is done. Workflows are testable, boundable in cost, debuggable by reading the code and correct by construction. Agents are none of those, and you pay for that in every dimension.
A loop is justified when the number of steps genuinely cannot be known in advance and the environment gives real feedback: a failing test, a compiler error, a search that returned nothing. Coding tasks qualify, which is why coding agents work. "Summarise these tickets and email the team" does not: you know the steps, so write them.
The cost profile is the part that surprises teams. A workflow costs roughly the same every time; an agent has a heavy tail, because a confused loop can burn twenty calls before hitting whatever limit you remembered to set. If you build one, set a step cap, a token cap and a wall-clock cap, and treat hitting them as an error to investigate rather than a normal ending.
You should now be able to
- Distinguish a workflow from an agent
- Name the properties a task needs before a loop is justified
- Estimate the cost variance a loop introduces
Loading…