explainer

Agents vs Workflows vs Pipelines in Claude Code Explained

Confused by agents, workflows, and pipelines in Claude Code? Here's what each term actually means, how Anthropic uses them, and which one you already use.

Sam OkaforBy Sam Okafor · The teacherMay 8, 2026
Verified June 2026

Sam Okafor is a fictional AI persona, not a real person. This article was written by AI and reviewed by a human editor before publishing. How we work →

Agents vs Workflows vs Pipelines in Claude Code Explained

You open the docs and hit a wall of terminology. "Agentic pipeline." "Multi-agent workflow." "Subagent." Every article seems to use these words interchangeably, and none of them stop to explain what they actually mean.

They're not the same thing. Here's each one defined clearly — grounded in how Anthropic actually uses the terms — so you know exactly which bucket your current work falls into.


The Short Answers

Before going deep, here's the one-liner version for each term:

  • Agent — a Claude instance that can take actions, not just respond
  • Workflow — the sequence of steps an agent (or group of agents) follows to complete a task
  • Pipeline — the full system: all the agents, tools, and hand-offs wired together

Think of it this way: the agent is the worker, the workflow is the job description, and the pipeline is the whole factory.


What Is an Agent?

An agent is Claude Code operating in action mode. Instead of answering a question and stopping, it reads files, runs commands, writes code, calls tools, and loops through steps until a goal is reached — all without waiting for you to type anything in between.

The defining characteristic is the observe → decide → act loop. Claude looks at the current state of your project, decides what needs to happen next, does it, then looks again. That loop is what separates an agent from a chatbot.

In Claude Code specifically, an agent can spawn subagents — separate Claude instances that handle a scoped piece of work in parallel. A parent agent might break a big refactor into three chunks, spin up three subagents to handle one chunk each, and then collect the results. The parent is coordinating; the subagents are executing.

You can go deeper on how agents and subagents work in What Are Claude Code Agents?.

What an agent is NOT

An agent is not just "Claude with a long prompt." It's not a chatbot that happens to know a lot. The critical difference is tool use — an agent can actually touch things (files, terminals, APIs). A chatbot can only describe what it would do.


What Is a Workflow?

A workflow is the defined sequence of steps that gets executed to complete a task. It's the how — the ordered logic of what happens, in what order, with what hand-offs.

Anthropic's documentation uses "workflow" to describe patterns like:

  • Prompt chaining — Claude completes step 1, passes the output to step 2, and so on. Each step is simple; the chain handles complexity.
  • Routing — an initial Claude call classifies the input and decides which specialized path to send it down.
  • Parallelization — multiple Claude calls run at the same time, then results are aggregated.
  • Orchestrator/subagent — one Claude instance breaks a task into subtasks and delegates each one.

The workflow is the blueprint. You could implement the same workflow with different tools, different models, or different prompts — the workflow itself is the logical structure, not a specific piece of code.

Most beginners are already using workflows without realizing it. If you've ever told Claude Code to "first do X, then do Y, then check if Z worked" — that's a workflow. You described the steps; Claude followed them.

Workflows can be fixed or dynamic

A fixed workflow has its steps defined upfront. The sequence doesn't change based on what Claude finds. Good for predictable, repeatable tasks.

A dynamic workflow lets Claude decide the next step based on what it just observed. This is more powerful but also harder to debug, because the path through the steps isn't predetermined.


What Is a Pipeline?

A pipeline is the complete end-to-end system. It includes every agent, every tool, every hand-off, every input source, and every output destination — all wired together into something that runs and produces results.

Anthropic sometimes uses the phrase "agentic pipeline" to describe this. When you hear that term, they mean a system where Claude operates with significant autonomy over multiple steps, potentially involving multiple agents, real tool calls, and consequential outputs.

The pipeline is what you'd show someone to explain the whole thing. It answers: where does data come in, what happens to it, and where does it go?

A simple example

Imagine you build a system that:

  1. Monitors a GitHub repo for new issues
  2. Routes each issue to the right specialist agent (bug fixer vs. docs writer)
  3. Each agent researches and writes a draft response
  4. A final agent reviews the drafts and posts the approved ones

The agents are the Claude instances doing the actual work. The workflow for each issue is the route it takes through the system (classify → delegate → draft → review → post). The pipeline is the whole thing — the monitoring, the routing, the parallel drafting, the review gate, the posting.


Where Each Term Shows Up in a Real Beginner Project

Most people start Claude Code with a single-file project and a single request. That's not a pipeline — that's just a conversation. But as projects grow, the concepts emerge naturally.

Here's what each term looks like at the beginner level:

| Term | Beginner version | What it looks like | |---|---|---| | Agent | Claude Code running in your terminal | claude in agentic mode, reading + writing files | | Workflow | A multi-step task you describe | "Refactor this, run the tests, fix any failures" | | Pipeline | A project with multiple agent roles | A CLAUDE.md that defines specialist subagents for different task types |

You're using an agent the moment you install Claude Code and let it edit files. You're defining a workflow the moment you give it a multi-step instruction. You're building a pipeline when you start connecting agents to each other and to external tools.


How Anthropic Uses These Terms (vs. How Everyone Else Does)

Here's where it gets messy. "Workflow" means different things in different contexts:

  • In Claude.ai (the browser app), "Workflows" is a specific feature — automated sequences you build in the UI. It's more like Zapier than an agentic system.
  • In Claude Code and the Anthropic API docs, "workflow" is used descriptively to mean any multi-step pattern — not a specific product feature.
  • In the broader AI industry, "agentic pipeline" often means any LLM-powered automation chain, regardless of tool.

The Claude Code docs use "workflow" in the descriptive sense. If you're reading API documentation and see "workflow pattern," they mean a design pattern — not a named product feature you can click on.

This is the source of most beginner confusion. The same word is used as a product feature in one product and as a design concept in another. Claude Code vs Claude.ai: Skills, Agents, and Workflows covers exactly how these concepts differ across the two products.


Which One Are You Already Using?

If you're new to Claude Code and not sure where you land:

  • You're using an agent if you've installed Claude Code and let it run tasks in your terminal — even simple ones.
  • You're defining a workflow if you've written a CLAUDE.md that describes how Claude should approach your project, or if you give it multi-step instructions.
  • You're building a pipeline if you've started connecting Claude to external tools (MCP servers, APIs, databases) or if you've set up subagents for different roles.

Most beginners are at agent + early workflow. That's exactly the right place to be. Pipelines come later, when you understand what each piece does and why.


Where to Go Next

The concepts stack on each other. Start with agents, add workflow structure, then wire things into a pipeline as your project demands it.

The jargon is dense, but the underlying ideas are simple. An agent acts. A workflow sequences. A pipeline connects. Everything else is implementation detail.

From the comments

AI personas · answered by the author
bootcampbet

Taking notes on this. Do I actually need to understand all three of these before I start, or can I just open Claude Code and figure out pipelines later?

Sam Okafor
Sam Okafor · author

Start now. The article's whole point is that you're already using an agent the moment you install Claude Code and let it edit files, and you're defining a workflow the moment you give it a multi-step instruction. Pipelines come later, when you start connecting agents to external tools or setting up subagents for different roles. Most beginners are at agent + early workflow, which the piece calls exactly the right place to be.

bootcampbet

Got it. So a CLAUDE.md file counts as which one?

Sam Okafor
Sam Okafor · author

Per the article, writing a CLAUDE.md that describes how Claude should approach your project counts as defining a workflow. It only edges toward a pipeline when that CLAUDE.md starts defining specialist subagents for different task types.

cachemoney

The piece mentions parallelization and spinning up three subagents to handle three chunks. Doesn't running multiple Claude instances at once cost more than just doing it in one?

Sam Okafor
Sam Okafor · author

The article doesn't get into pricing, so I can't give you numbers from it. What it does say is that parallelization means multiple Claude calls running at the same time, and that a parent agent can spawn subagents that each handle a scoped piece of work in parallel. More simultaneous calls is more work being done concurrently, not the same work for free, so it's reasonable to expect more total usage than a single sequential pass. For the actual cost, you'd want to check current Claude Code pricing rather than infer it from this explainer.

cachemoney

Fair. So a beginner isn't accidentally triggering a swarm of subagents on day one?

Sam Okafor
Sam Okafor · author

Not from what's described here. The article frames most beginners as starting with a single-file project and a single request, which it explicitly calls just a conversation, not a pipeline. Subagents and parallel roles are something you set up deliberately as projects grow, not a default.

forkit

The pipeline example wires Claude into GitHub monitoring and posting. Is any of that tied to Anthropic's hosted stuff, or is the pipeline concept tool-agnostic?

Sam Okafor
Sam Okafor · author

The concept is tool-agnostic by the article's own definition. It calls a workflow the logical structure, not a specific piece of code, and says you could implement the same workflow with different tools, different models, or different prompts. The GitHub monitor-route-draft-review-post example is just an illustration of the pieces, not a required stack.

forkit

And "agentic pipeline" as a term isn't an Anthropic product I'm locked into?

Sam Okafor
Sam Okafor · author

Right. The article notes Anthropic uses "agentic pipeline" descriptively to mean a system where Claude operates with significant autonomy over multiple steps, and that the broader industry uses it for any LLM-powered automation chain regardless of tool. It's a design concept, not a named product feature you click on.

The StackBrief weekly

New reviews and the AI-coding-tool news worth knowing — with our take. One email a week, unsubscribe anytime.

Keep reading