workflow (LLM)
A system in which your code fixes the sequence of model calls and tools, as opposed to an agent that chooses its own steps.
In more detail
Anthropic lists five workflow patterns: prompt chaining, routing, parallelisation, orchestrator-workers and evaluator-optimiser. Start with the simplest that works; workflows are cheaper, more predictable and easier to test than agents.
Related terms
- AI agent — A system in which a model decides its own next steps, calling tools in a loop until a task is done, rather than following a path your code fixed.
- prompt chaining — A workflow that splits a task into fixed steps, each a model call that feeds the next, often with a check in code between them.
- routing (LLM) — A workflow that classifies each input and sends it to a specialised prompt, tool or model.
- orchestrator-workers — A pattern in which a lead model breaks a task into subtasks at run time, hands them to worker calls or sub-agents, and combines their results.
Taught in
- The Agent Loop — AI Engineering: LLM Apps, RAG & Agents
- Workflows Before Agents — AI Engineering: LLM Apps, RAG & Agents