← All posts

Agentic Design Patterns, Explained: The 7 Building Blocks Behind Smart AI Agents

Share

Seven patterns that help an AI agent finish real work, explained with one running example.

Agentic Design Patterns, Explained: The 7 Building Blocks Behind Smart AI Agents

In today's post, let's talk about Agentic Design Patterns. Most of you probably know what an AI Agent is. But if you don't, here's a simple explanation.

A chatbot helps you think, brainstorm, and find answers. An AI Agent can actually take tasks off your plate.

For example, ask a chatbot to plan your team's offsite, and it will give you a checklist. Ask an AI Agent, and it can check calendars, book a venue, and email the team. At least, that's the goal!

But building reliable AI Agents isn't that easy. They can skip steps, use the wrong tools, or spend more money than expected. Using a bigger or smarter AI model won't necessarily solve these problems. What you need is a better structure.

That's where Agentic Design Patterns come in. In this post, we'll explore the 7 most important patterns in simple English, using one practical example throughout.

A friendly robot assembling seven building blocks labeled Chaining, Routing, Parallel, Reflection, Tools, Planning, and Teamwork

This post introduces seven building blocks in plain English. For all agentic design patterns in more detail, see the Agentic Design Patterns on-demand course.

Agentic Design Patterns on-demand course preview

Meet Our Agent: The Offsite Planner

Let's use one example throughout this post.

You ask an AI agent:

"Plan a two-day offsite for our 20-person team in March. The budget is $15,000."

You've told the agent what you want. Now it's the agent's job to figure out how to make it happen.

Let's see how different design patterns help it do that.

1. Break Big Tasks Into Smaller Steps (Prompt Chaining)

Imagine asking an AI to do ten things at once. It might miss a few steps, forget important details, or make mistakes along the way.

Prompt chaining solves this by breaking a big task into smaller steps. Each step completes one job and passes its result to the next.

For our offsite planner, the steps could be:

  1. Understand the requirements (dates, team size, and budget).
  2. Find suitable venues.
  3. Create a two-day agenda.
  4. Draft an email to announce the event.

It's like an assembly line. Each station has one job, and the output from one station becomes the input for the next.

An assembly line with four robot stations passing work along: Requirements, Venues, Agenda, Email

You can use the same approach to research complex topics, extract information from invoices, or write a long article (outline first, draft next, polish last).

Another important concept here is context engineering. Before asking the AI to do something, give it the information it needs. For example, share your calendar, previous meeting notes, and details about the people receiving the email.

When to use it: When a task is too big to handle reliably in one go.

2. Send Each Request to the Right Place (Routing)

Prompt chaining follows a fixed sequence of steps. But what happens when people start asking different questions?

Once the offsite is announced, your team might ask the agent:

  • "Can we move it to the second week?" (Scheduling)
  • "Do we have vegetarian food options?" (Catering)
  • "How much budget is left?" (Finance)
  • "What do you think?" (The agent needs to ask for more details.)

Routing helps the agent understand what each request is about and send it to the right place.

Think of a hospital receptionist. They listen to your problem and direct you to the right department.

An AI agent can do something similar. It can use simple rules, ask an AI model to classify the request, or use a smaller trained model to decide where it should go.

For example, a message about a refund goes to billing, while a question about food goes to catering.

A receptionist robot sorting incoming messages onto four colored paths labeled Schedule, Catering, Budget, and Ask More

Routing is also useful for sorting customer support tickets, organizing emails, helping students choose their next lesson, and deciding whether a coding assistant should fix, explain, or translate code.

When to use it: When your agent receives different types of requests and needs to choose the right workflow or tool.

3. Do Multiple Things at the Same Time (Parallelization)

Some tasks don't depend on each other. Doing them one after another just wastes time.

Our offsite planner needs to:

  • Check venue availability.
  • Get catering quotes.
  • Find travel options.
  • Check the weather forecast.

There is no reason to wait for one task to finish before starting the next.

Parallelization allows the agent to run all these tasks at the same time. Once they are complete, it brings the results together.

It's like having several cooks in a kitchen, each preparing a different dish.

Two timelines compared: four tasks done one after another versus the same four tasks running side by side and merging into one result

This approach is also useful when researching a company using multiple sources, analyzing customer feedback, checking form entries, or generating several headline options at once.

The main benefit is speed. However, managing multiple tasks at the same time can make the system harder to build and debug.

When to use it: When a task has several independent parts that can run at the same time.

4. Let the Agent Review Its Own Work (Reflection)

An AI agent's first answer isn't always correct. It might miss an instruction, make a calculation error, or leave something incomplete.

Reflection helps the agent review and improve its work before delivering the final result.

Here's how it works:

  1. The agent creates a first draft.
  2. It checks the result against the requirements.
  3. It identifies mistakes or missing details.
  4. It fixes them and checks again.

A useful approach is to have two roles: one agent creates the work, and another reviews it. Think of a writer and an editor.

Let's return to our offsite planner.

The agent creates a plan. The reviewer spots two problems:

"The total cost is $16,200, which is over budget. Also, day two doesn't include a vegetarian lunch."

The agent then goes back and fixes the plan.

A loop between a writer robot holding a draft and an editor robot with a magnifying glass, with arrows labeled Draft, Critique, and Improve

Reflection is useful for improving blog posts, reviewing code, checking summaries against original documents, and finding problems in a plan.

One thing to remember: every review takes additional time and costs more tokens.

When to use it: When accuracy and quality matter more than speed.

5. Give the Agent Access to Tools (Tool Use)

An AI model has limitations. It doesn't automatically know today's prices, have access to your private data, or perform actions in other applications.

Tool use allows an agent to connect with external tools and services.

Think of tools as the agent's hands and eyes.

The agent decides what it needs and asks for a tool to be used. The system executes that tool and sends the result back to the agent.

For our offsite planner, the available tools could include:

  • Calendar: Find dates that work for everyone.
  • Web search: Find suitable venues.
  • Calculator: Check the budget.
  • Booking system: Reserve the venue.
  • Email: Send updates to the team.

A robot at the center connected to tool icons: calendar, search, calculator, booking, and email

A tool can be almost anything: a database, an API, another application, or even another AI agent.

Other examples include checking weather, tracking orders, running code, sending messages, and controlling smart-home devices.

When to use it: When your agent needs real-time information, access to external data, accurate calculations, or the ability to perform actions.

6. Let the Agent Figure Out the Steps (Planning)

Some tasks are too complex to solve with a fixed sequence of instructions.

Planning allows an agent to figure out what needs to be done and in what order.

It looks at the current situation and the desired result, then creates a plan to get there.

For our offsite planner:

  • Starting point: 20 people, $15,000 budget, and March dates.
  • Goal: A fully planned and booked two-day offsite.

The agent works out the steps needed to reach that goal.

And here's the important part: the plan can change.

What if the preferred venue is no longer available? The agent can reconsider the options and find another venue or suggest different dates.

A route map from a starting point to a finish flag, with one venue crossed out and the path detouring to an alternative

You've probably seen this in action with AI research tools. They break your question into smaller research tasks, search for information, cross-check findings, and then prepare a report.

Planning gives the agent flexibility, but the results can be less predictable.

If you already know the exact steps, a fixed workflow is often a better choice.

When to use it: When the agent needs to figure out the steps rather than simply follow a predefined process.

7. Divide the Work Among Specialist Agents (Multi-Agent Collaboration)

One agent doing everything can be like one person trying to be a researcher, analyst, writer, and editor at the same time.

Multi-agent collaboration solves this by dividing the work among multiple agents. Each agent has a specific responsibility.

Our offsite planner could work like a small team:

  • Venue Agent: Finds and books the venue.
  • Budget Agent: Tracks expenses and checks the budget.
  • Communication Agent: Keeps the team informed.
  • Coordinator Agent: Assigns tasks and brings everything together.

An org chart with a coordinator robot at the top and three specialist robots below: Venue, Budget, and Comms

These agents can work in different ways. They can pass tasks to each other, work in parallel, discuss different options, or have one agent review another's work.

They can also be organized in different structures:

  • Team: Agents work together as equals.
  • Manager and workers: One agent assigns tasks to others.
  • Multiple levels: Agents manage other agents, just like a large organization.

A manager-led structure is easier to control, but the manager can become a bottleneck if too much work comes its way.

You'll find multi-agent systems being used for research, software development, marketing campaigns, and customer support.

When to use it: When a task is too complex for one agent and requires different skills or responsibilities.

Bonus: Help Your Agent Remember (Memory)

Imagine planning another team offsite next year.

Wouldn't it be helpful if your agent remembered what worked last time?

That's what memory does.

There are two common types:

  • Short-term memory: Remembers information from the current conversation. Think of it as a desk where you keep the documents you're currently working on.
  • Long-term memory: Stores important information that can be retrieved in future conversations. Think of it as a filing cabinet.

For example, next year our offsite planner might remember:

  • Three team members are vegetarian.
  • Everyone loved the lakeside venue.
  • Transport costs were higher than expected last time.

This saves time and helps the agent make better decisions.

Memory also makes other patterns more useful. For example, an agent that remembers previous feedback is less likely to repeat the same mistakes.

Putting It All Together

In real-world applications, agents rarely use just one design pattern. They combine several of them.

Our offsite planner could:

  • Use Planning to figure out what needs to be done.
  • Use Prompt Chaining to break the work into smaller steps.
  • Use Routing to direct questions to the right specialist.
  • Use Parallelization to check venues, catering, and travel options simultaneously.
  • Use Tools to access calendars, search the web, and make bookings.
  • Use Reflection to review the plan and catch mistakes.
  • Use Multi-Agent Collaboration to divide responsibilities.
  • Use Memory to remember what worked for future events.

The offsite planner robot at the center, surrounded by icons for all eight patterns, connected to a calendar showing the offsite booked

Which Pattern Should You Use?

Here's a quick way to decide:

If your agent... Consider using
Struggles with big tasks Prompt Chaining
Receives different types of requests Routing
Takes too long to complete independent tasks Parallelization
Makes mistakes in its first attempt Reflection
Needs live information or must perform actions Tool Use
Needs to figure out the steps itself Planning
Needs different skills to complete a task Multi-Agent Collaboration
Forgets information between conversations Memory

Where Should You Start?

Don't start by making your agent more complicated or switching to a bigger AI model.

First, identify what's going wrong.

Is it skipping steps? Try Prompt Chaining.

Is it using the wrong tool? Try Routing.

Is it making mistakes? Add Reflection.

Is it struggling with complex tasks? Consider Planning or Multi-Agent Collaboration.

The key is to choose the right pattern for the problem.

And remember, these patterns aren't tied to any particular AI model. As models improve, good agent design will continue to matter.

Need a quick definition?

Browse the AI Glossary for plain-English explanations of common terms in this post.

Open AI Glossary →

Enjoyed this post? Share it