---
title: 'What Is a Multi-Agent System | How Multi-Agent Systems Work | Multi-Agent Architecture | Simplilearn'
source: 'https://youtube.com/watch?v=4-4Pd-ZeoWg'
video_id: '4-4Pd-ZeoWg'
date: 2026-08-08
duration_sec: 2731
---

# What Is a Multi-Agent System | How Multi-Agent Systems Work | Multi-Agent Architecture | Simplilearn

> Source: [What Is a Multi-Agent System | How Multi-Agent Systems Work | Multi-Agent Architecture | Simplilearn](https://youtube.com/watch?v=4-4Pd-ZeoWg)

## Summary

This video from Simplilearn provides a comprehensive introduction to multi-agent systems, explaining what they are, why they are becoming important, and how they work. It covers the evolution from simple chatbots to AI agents, compares single-agent and multi-agent approaches, and explores architectures, design patterns, and real-world applications. The tutorial also includes a practical demo using the CrewAI framework to build a simple multi-agent content creation system.

### Key Points

- **AI Revolution and Multi-Agent Systems** [00:07] — The AI revolution is moving beyond single question-answering systems to collaborative systems that can plan, make decisions, and complete tasks. This shift is creating interest in multi-agent systems, which are groups of intelligent software agents working together to achieve a common goal.
- **McKinsey Report on AI Adoption** [00:21] — According to McKinsey's State of AI 2025 report, organizations are moving from experimentation towards integrating AI into real business workflows, exploring more advanced AI applications.
- **Definition of Multi-Agent System** [00:47] — A multi-agent system is a group of intelligent software agents that work together to complete a common goal, with each agent focusing on a specific responsibility instead of one system trying to handle everything alone.
- **Analogy to a Company** [01:11] — Multi-agent systems mimic how a company operates: a research team collects information, a finance team analyzes numbers, a marketing team creates campaigns, and managers coordinate efforts. No single person handles every responsibility, but together they achieve a larger objective.
- **Value from Clear Responsibilities** [02:26] — The real value of multi-agent systems comes from giving each agent a clear responsibility and creating a workflow where they can communicate, share information, and work towards the same goal, not just adding more AI systems together.
- **What is an AI Agent?** [06:25] — An AI agent is a system that can understand a goal, decide the steps required to achieve that goal, use available tools, and perform actions to complete a task. Unlike a chatbot that focuses on answering questions, an AI agent focuses on completing an objective.
- **Evolution of AI** [07:19] — AI has evolved from rule-based systems to machine learning, then to conversational AI and large language models, and now to AI agents that can independently plan and execute workflows. This evolution created the need for systems that can take action.
- **Multi-Agent System Definition** [08:39] — A multi-agent system is a group of multiple AI agents that work together to achieve a common goal. Instead of one agent doing everything, different agents are assigned to different roles based on their strengths, similar to how a company has different teams.
- **Why Multiple Agents?** [09:44] — The answer is complexity. Real-world problems involve multiple steps and different areas of expertise. Multi-agent systems solve this by dividing responsibilities, improving specialization and organization.
- **Components of Multi-Agent Systems** [11:52] — Key components include: agents with clear responsibilities, an orchestrator or manager agent that coordinates the workflow, tools for interacting with external resources, memory to maintain context, and communication for exchanging information.
- **Workflow of a Multi-Agent System** [12:57] — The process starts with a user providing a goal. The system breaks the goal into smaller tasks, assigns each task to the most suitable agent, agents communicate and share information, and finally the system combines outputs and delivers the final solution.
- **Agent Specialization** [14:26] — Agents can be specialized for specific tasks, such as planning, writing, reviewing, coding, testing, security, and documentation. This specialization makes the system more organized and easier to improve.
- **Communication in Multi-Agent Systems** [15:33] — Communication is crucial because agents need to exchange information to complete a shared goal. Communication can be managed by a supervisor agent or direct between agents, but too many agents without organization can complicate the system.
- **Architectures** [16:47] — Common architectures include: supervisor (one main agent coordinates), decentralized (agents communicate directly), and hierarchical (agents organized in levels). The choice depends on the problem complexity.
- **Design Patterns** [18:03] — Design patterns include: sequential (agents work one after another), parallel (agents work simultaneously), router (a router agent decides which specialist handles a request), reviewer/critic (one agent creates, another reviews), and network (agents communicate directly).
- **Real-World Applications** [19:34] — Multi-agent systems are used in customer support (understanding, account, policy, response agents), software development (planning, coding, testing, security agents), research and analysis, healthcare, finance, cyber security, and retail.
- **Practical Example: Content Creation Team** [21:45] — A simple multi-agent workflow for creating a tutorial involves a research agent, planning agent, writing agent, review agent, and manager agent. Frameworks like CrewAI and LangGraph are used to build such workflows.
- **Challenges** [23:13] — Challenges include complexity (more interactions), defining clear responsibilities, maintaining accuracy, cost and performance, and security. Successful systems require careful design, not just adding more agents.
- **Best Practices** [24:41] — Best practices include starting simple, defining clear roles, creating proper communication flow, and adding evaluation steps. Avoid the mistake of assuming more agents always produce better results.
- **Future of Multi-Agent Systems** [25:58] — The future is moving towards AI teams that work alongside humans, supporting professionals by handling repetitive tasks, analyzing information faster, and assisting with decision-making. Human involvement remains important for defining goals and ensuring responsible use.
- **Demo: Building with CrewAI** [27:58] — The demo shows how to build a multi-agent content creation system using CrewAI. Steps include setting up a Python environment, installing CrewAI, creating agents (research, writer, review), defining tasks, and running the workflow.

### Conclusion

Multi-agent systems represent a significant shift in AI, moving from single, all-purpose models to collaborative teams of specialized agents. The key takeaway is that the power of these systems comes from designing clear roles, effective communication, and structured workflows, not just from adding more agents.

## Transcript

AI revolution isn't a single brain. It's a room full of them. Today, companies are moving beyond AI tools that simply answer questions and exploring systems that can plan, make decisions, and complete tasks with less manual effort.
According to McKenzie's state-of-the-art AI 2025 report, organizations are experimentation towards integrating AI into real business workflows with many companies exploring more advanced AI
applications. And this shift is creating interest in a concept called multi-agent systems. So what exactly does this mean? Well, in simple words, a multi- aent system is a group of intelligent software agents that work together to
complete a common goal where each agent focuses on a specific responsibility instead of one system trying to handle everything alone. IBM describes AI agents as systems that can perform tasks, make decisions, and interact with
tools to achieve specific goals. And when multiple specialized agents collaborate, they can solve more complex problems through coordination and teamwork. Think about how a company operates. A research team collects
information. A finance team analyzes numbers. A marketing team creates campaigns. And managers coordinate everyone's effort. No single person handles every responsibility. But together they can achieve a larger
objective. Multi- aent systems follow the same idea by creating different AI workers with different roles. For example, one agent can research information, another can analyze findings, another can create content,
and another can review the final result. The reason this topic is becoming so important is because real world problems are becoming more complex. A customer support request may require understanding and a customer's problem,
company policies, and preparing a solution. A software project may require planning, coding, testing, and security checks. And instead of depending on the organizations are exploring collaborative AI workflows where
different agents can handle different parts of the process. Gardner predicts that AI systems will become increasingly important in enterprise environments as organizations look for AI solutions that can perform independently, perform
tasks, support business operations, and more. However, multi-agent systems are not about simply adding more AI systems together. The real value comes from giving each agent a clear responsibility and creating a workflow where they can
communicate, share information, and work towards the same goal. In this tutorial, systems are and why they're becoming so relevant and how this approach is applications. So now that we have a basic understanding of what multi-agent
systems are and why they're becoming important, let's move on ahead and look throughout this tutorial. Introduction to AI agents. Understand what AI agents different from traditional chatbots. Understanding multi-agent systems. Learn
how multiple AI agents collaborate and why teamwork between agents is useful. Single agent and multi-agent systems. Explore the difference between using one agent and a group of specialized agents. Multi-agent architecture and workflow.
Understand how agents are structured, communicate, and complete tasks patterns. Learn about different agent responsibilities and common applications. Explore how multi-agent systems are being used in industries
like software, customer support, research and cyber security. Building a multi- aent system. So creating a simple agent workflow using specialized agents and understand how they work. Challenges and best practices. Learn common
for designing effective multi-agent systems. Future of multi-agent systems. Understand how collaborative AI systems are shaping the next generation of on, let me share something really exciting with you guys. If you're
generative AI, agentic AI and technologies like multi- aent systems there is an opportunity to take your learning to the next level with the advanced executive program in apply generative AI in collaboration with
designed to help you build a strong foundation in generative AI concepts, explore agentic AI workflows, understand large language models, work with systems, and apply these concepts
through hands-on projects. You will also get exposure to popular AI tools, build real world applications, and learn how AI systems can be designed to solve different industries. Whether you're a developer looking to build AI
applications or a professional planning to transition into AI or someone who wants to understand how AI can improve everyday workflows, this program helps you gain practical skills and the confidence to work with modern AI
advanced executive program in the applied generative AI which is in here. Now that we understand the basics of multi-agent systems, let's quickly test your understanding with a simple question. So what is the main purpose of
multi-agent system? Is it A to store more data? Is it B to create multiple agents together? Is it C replacing all humans? Or is it D create faster the comments below. Imagine one person handling an entire project all alone.
Research, analysis, content, quality checks, and the final delivery all in one plate. For a small risk, fine. But scale it up and it falls apart fast. Now imagine a team instead. One person researches, another person analyzes, one
executes, and one reviews. Everyone owns one job and does it well. And that's how bigger, messier projects actually get done. And that's exactly the idea behind multi- aent systems. And instead of
depending on one AI system to perform every task, we create multiple AI agents where each agent has a specific role. So one agent can collect information, another can analyze it and another can make decisions while another can review
the final output. So together these agents collaborate to complete a common objective. This topic is becoming so popular because AI is moving beyond simple questionans answering systems. Businesses today are looking for AI
systems that can plan, make decisions, use tools and complete workflows. So according to Mckenzie state of AI report, organizations are increasingly moving from AI experiments towards practical AI implementation and business
process. Companies are exploring AI systems that can handle complex tasks rather than only generating responses. So now that we understand why attention, let's first understand the foundation behind them. So what is an AI
agent? An AI agent is a system that can understand a goal, decide the steps required to achieve that goal, use available tools and perform actions to complete a task. So many people compare AI agents with chatbots. But there is an
important difference between them. So a chatbot mainly focuses on answering machine learning. So this can provide information and explanations. But an AI agent goes beyond just answering. It focuses on completing an objective. For
example, if you ask an AI agent to create a market research report, it can information, analyze the data, and prepare the final report. So, a simple with a personal assistant. So, personal assistant doesn't just provide
information. They plan, organize, and complete tasks on your behalf. Similarly, an AI agent can understand requirements, plan actions, use tools, and deliver results. So now that we understand a single AI agent, let's look
at how AI evolved from a simple chatboard into an intelligent agent. So the evolution of AI has moved through different stages. Initially AI systems were mainly rule-based where they followed predefined instructions. So
these systems worked well for simple tasks but they struggled when situations became unpredictable. So later machine learning allowed systems to learn applications like recommendation systems, fraud detection and predictive
analysis. Then conversational AI and larger language models changed the way that humans interacted with machines. So users could communicate with AI naturally and receive detailed responses. However, traditional
conversation systems mainly focused on generating answers. They could explain couldn't independently plan and execute the entire workflow. So this created the need for AI systems that could actually take action. So AI agents introduced the
ability to understand goals, plan steps, use tools and complete tasks. And when these tasks became more complex, multiple specialized agents could work together. So as you can see here in the slide, we have a team of AI agents. And
when these tasks became more complex, multiple specialized agents could work journey from chatbots to agents, let's move on to the main concept, which is what is multi-agent system. So a multi- aent system is a group of multiple AI
agents that work together to achieve a common goal. So instead of an agent different agents are assigned to different roles based on their strengths. So think about how a company works. A company has different teams
like marketing, finance, sales and operations. Now each team has a collaborate to achieve the company's objective. So a multi- aent system follows the same approach. For example, imagine creating an AI system for
generating a technical course. So, a research agent can collect information, structure, a writing agent can create explanations, and a review agent can check accuracy and quality. Also, a manager agent can coordinate all these
activities and combine the final output. So, IBM explains multi- aent systems using the example of a bee colony. So a single bee can perform individual tasks but a group of bees working together can build and maintain an entire hive.
Similarly, multiple AI agents working together can solve complex problems more effectively. So now that we understand what multi- aent system means, let's understand why we need multiple agents instead of relying on one powerful AI
system. So a single AI agent can handle many tasks. So why do we actually even need multiple agents? Well, the answer is complexity. In real world scenarios, problems usually involve multiple steps and different areas of expertise. For
example, creating a business report may require research, data analysis, writing, and quality checking. Expecting one agent to perform all of these tasks perfectly can become challenging. So, for the same reason, multi- aent systems
solve this problem by dividing the responsibilities. So, one agent can focus on research, another can focus on analysis, another focuses on decision-m out. So this approach improves specialization and organization. Each
agent becomes responsible for a specific task instead of trying to handle everything. So this is very similar to how a human team works. A software doing the development, testing, design, and management alone. Different
specialists work together to achieve the final goal. However, adding more agents doesn't always mean better results. The goal here is not to create many agents unnecessarily, but to create the right agents with clear responsibilities. So
now that we understand why multi- aent systems are useful, let's compare a single agent system with multi-agent system. So single agent system is useful when the task is simple and requires limited steps. For example, answering
generating basic content, it can be handled by one agent. Now multi-agent involves multiple stages and requires different skills. For example, building
planning, coding, testing, security checking and documentation. So instead of one agent handling everything, different agents can specialize in different areas. So a single agent is like a general employee who can perform
multiple tasks while a multi- aent system is like a team of specialists working together. Now the choice depends on the complexity of the problem. If the workflow is simple, a single agent may not be enough. And if the workflow
requires collaboration, multiple tools and different types of expertise, a multiple agent approach becomes more effective. So now that we understand the multi-agent systems, let's explore the important components that make
multi-agent systems work. So a multi- aent system consists of several important components that allow agents to work together. Now the first agent should have a clear responsibility. For example, a research
agent collects information while a review agent checks the quality of the output. Now, the second component is the orchestrator or the manager agent. This agent coordinates the workflow by deciding which agent should handle which
task and how different tasks should be connecting each other. By deciding which different tasks should be connecting together. Now, the third component is tools. Agents become more useful when they interact with external resources
such as databases, APIs, documents, and applications. The fourth component is maintain context and remember how important the information is during the workflow. The final component here is communication. Agents need a way to
exchange information because one agents output often becomes an other agent's input. And altogether these components allow multiple agents to collaborate and complete complex tasks. Now that we understand the building blocks, let's
actually see how a multi- aent system can work step by step. So now that we aent systems, let's understand how these agents actually work together to complete a task. So the process usually starts when the user provides a goal.
Instead of directly generating an answer, the system will first understand what needs to be achieved and breaks the larger goal into smaller tasks. So let's take an example. Imagine the goal is create a complete market research report
for a new product. So now this is not a single task. It requires collecting competitors, understanding customer needs and preparing a structured report. So multi- aent system divides this large
assigns each activity to the most suitable agent. The next step is task assignment. A manager or an ustrator agent decides which agent should be handling each responsibility. Now the
research agent collects information, the analysis agent studies the data, the the review agent checks the final output. So after completing their individual tasks, agents communicate with each other and share information.
So one agent's output finally becomes the other agents input. And lastly, the system combines all of these, delivers the final solution to the user. So the basic workflow of a multi- aent system can be understood as understand a goal,
break the task into smaller activities, assign responsibilities, allow agents to output. So now that we understand the workflow, let's look at how different responsibilities. So one of the biggest advantages of multi- aent systems is
specializations. So instead of creating one agent that does everything, we create different agents that focuses on specific tasks. A planning agent takes the information and creates a proper structure. A writing agent converts the
review agent checks whether the final output is accurate and complete. So similarly in software development we have coding agents that can write code, testing agent that can identify bugs, a security agent that can check
agent that can create technical documents. So this specialization makes the system more organized because each agent has a clear purpose. So it can also make it easier to improve individual parts of the system and if
improve the research agent without changing the entire workflow. However, defining clear roles is very important because if multiple agents have the same responsibility, they may duplicate work or create confusion. So, successful
multi- aent system requires every agent to understand what it is responsible for goal. So, now that we understand how agents are divided into roles, let's understand how these agents communicate together and collaborate with each
other. So communication is one of the most important parts of a multi- aent system because agents need to exchange information to complete a shared goal. Without communication, individual agents would work separately without
contributing to the final outcome. Now let's think about a real world team. A researcher cannot simply complete their work and stop. They need to share their findings with an analyst. The analyst needs to provide insights to the writer
and the writer needs feedback from the reviewer. So every person's work connects with someone else. Agents share information, provide updates, and pass results between each other. For example, a research agent may provide collected
data to an analysis agent. The analysis agent processes that information and sends insights to a decision-making agent. Communication can happen in different ways. And in some systems, a manager agent controls the communication
by assigning tasks and collecting results. In other systems, agents communicate directly with each other and collaborate based on the situation. The communication. If too many agents communicate without proper organization,
the system can become complicated. And this is why many modern multi- aent systems use a coordinator or a supervisor agent to manage interactions. So now that we understand how agents communicate, let's explore the different
architectures used to design multi- aent systems. So the architecture defines how agents are organized and how they interact with each other. Different So the first common architecture is the supervisor or manager architecture. In
this approach, one main agent acts as a coordinator. The supervisor receives the user request, decides whether the agent should handle each task and combines the final result. So this approach is easier to manage because there is a clear
decision maker. For example, in a customer support system, the supervisor agent can receive customer complaints and assign it to a different specialist agent such as billing, technical support or account management agents. Now the
second architecture is the decentralized architecture. In this approach, there is no single controlling agent. Agents communicate directly and make decisions together. Now, this can be useful when flexibility is important, but managing
communication becomes more challenging. Now, the third architecture is hierarchical architecture. Now, there are agents which are organized into manages multiple lower level agents. Now, choosing the right architecture
depends on the problem. Simple workflows may work well together with a supervised model. But however, complex systems may require more flexible structure. So now architectures, let's move on to one of the most important areas in multi- aent
systems, which is design patterns. So design patterns are a common way of organizing agents to solve specific types of problems. They provide a structured approach for building multi- aent systems. Now the first pattern is
the sequential pattern. In this approach, agents work one after the other. For example, a research agent collects information, a writing agent collects content, and a review agent checks the final result. Now, the second
part is parallel pattern. Multiple agents work at the same time on a example, while one agent analyzes customer feedback, their results are combined later. The third pattern is a
routter pattern. Now, a routter agent decides which specialist agent should handle a specific request. This is commonly used in customer support different experts. Now the fourth pattern is reviewer or critic pattern.
One agent creates the output while another agent checks for the mistake and suggests improvements. So this improves quality because the system gets a second level of verification. Now the fifth pattern is network pattern where agents
communicate directly with each other instead of following a fixed sequence. systems are not about simply adding more designing the right collaboration structure. Langshen also highlights that
not every problem requires multiple agents. Sometimes a single agent with the right tools can complete a specific task effectively. The goal here is to choose the right approach based on the complexity of the workflow. So now that
patterns, let's explore where multi-agent systems are being used in the real world scenario. So now that we understand how multi-agent systems are examples of where this technology is being used. The reason why multi-agent
many real world problems require multiple steps, different steps of expertise and continuous decision-m. So one of the most common applications is one AI systems are handling every customer request, multiple agents can
work together. A customer understanding agent can identify the issue. An account agent can verify the customer details. A policy agent can check available solutions and a response agent can prepare the file and reply. Now this
allows businesses to provide faster and more personalized support. Another important use case is software development. Today AI is being used not through the development life cycle. A planning agent can understand project
requirements. A coding agent can create implementation. A testing agent can identify bugs and a security agent can create vulnerabilities. So this creates an AI powered development team that can support developers at different stages.
So multi-agent systems are also becoming useful in research and analysis. For example, a research agent can collect information from different sources and analysis agent can identify important insights and a summary agent can prepare
the final report. Now this can help professionals process large amounts of information more efficiently. Other industries like healthcare, finance, cyber security and retail are also exploring multi- aent systems. In cyber
security, one agent can monitor suspicious activities and another can investigate threats while an other can suggest possible actions. In finance, agents can analyze market information, identify patterns, and support
decision-m. Cognizant highlights that multi- aent systems have potential applications across industries such as healthcare, banking, retail, insurance, and cyber security because different agents can handle specialized tasks
while collaborating together. So now that we have seen how multi-agent industries, let's understand a practical example of how we can create a simple multi- aent workflow. So for understanding multi-agent systems
practically, let's consider the simple example of creating an AI content creation team. Now the goal here is to create a beginner friendly tutorial on a technical topic. So instead of asking one AI agent to handle everything, we
divide the work into multiple specialized agents. So the first agent responsible to collect important information about the topic, identify key concepts and gather relevant examples. Now the second agent is
planning agent. Now this takes research information and creates a proper come first and how the explanation should flow. The third agent is writing agent. The agent converts the plan into
a detailed content which is easy for learners to understand. The fourth agent content if there is any missing information, unclear explanations or incorrect details. Finally, we have manager agent. So, this coordinates the
complete workflow, assigning tasks, collecting outputs from different agents and combining everything into the final result. This simple example shows the main advantage of multi- aent systems. Each agent focuses on one responsibility
and together they complete a larger task. Frameworks like crew AI and Langraph are commonly used to build such agent workflows because they can provide ways to create specialized agents, manage communication and control
workflows. The important point is that the power of multi-agent systems comes from collaboration and not just creating multiple agents. So now that we understand how a simple workflow can be built, let's discuss some challenges
developers face while designing multiple agents. So although multi-agent systems may provide many benefits, they are also introducing new challenges. Creating multiple agents doesn't mean that they automatically guarantee better results.
The system needs proper planning, coordination, and monitoring. So the complexity. So when more agents are added, more interactions happen between them. And if communication is not properly managed, agents may repeat
tasks, misunderstand information, or create unnecessary steps. The second challenge is defining clear responsibilities. Every agent has a specific role. If two agents perform the same task or if no agent owns a
particular responsibility, the workflow becomes inefficient. The third challenge is maintaining accuracy. Even though agents can collaborate, they can still generate incorrect information. A review process is important to verify outputs
before delivering the final result. Another major challenge is cost and performance. So running multiple agents requires more computing resources organizations need to balance the
real value that it provides. Now security is also an important consideration. So since agents may interact with external tools and data sources, proper controls are required to ensure safe usage. Therefore successful
multi-agent systems are not created by simply adding more agents. They require careful design, clear responsibilities and continuous improvement. So now that at some of the best practices for building effective multi-agent systems.
So while designing a multi-agent system, the first best practice is to start simple. So instead of creating many agents from the beginning, start with a small number of specialized agents that can expand only when required. Now the
second best practice is defining clear roles. Every agent should have a specific responsibility. A research agent should be focusing on research. A checking and a planning agent should be focusing on organizing tasks. The third
best practice is creating proper communication flow. Agents should be communicate, what information to share, and how decisions should be made. Another important practice is adding evaluation steps. A final review agent
or a human approval process can help identify mistakes before the output has reached the user. So, one common mistake is assuming that more agents always create better results. In reality, unnecessary agents can make the system
much slower and complicated. So an other mistake can be creating agents without a clear purpose. The goal of a multi- aent system is not complexity. The goal here is to create an organized workflow where different agents can work together
efficiently. So now that we understand the practical side of multi-agent systems, let's have a look at where this technology is heading in the future. The future of AI is moving from the systems that simply respond to the systems that
can actively assist in completing tasks. Multi-agent systems are an important step in the direction because they allow AI systems to collaborate, specialize, and handle more complex workflows. So in the future, we can expect more
organizations to use AI teams that work alongside humans. So instead of replacing human expertise, these systems can support professionals by handling repetitive tasks, analyzing information faster, and assisting with decision-m.
For example, a business team may have AI agents supporting market research, customer analysis, financial planning, and reporting. A software team may have AI agents assisting with coding, testing, and documentation. However,
human involvement will remain important. People will continue to define goals, creativity, and ensure responsible use of AI systems. Now, the future will not simply be about creating smarter AI. This will be about creating better
collaboration between humans and AI systems. So now that we have covered the let's quickly summarize the key concepts that we have learned. So multi- aent system is a group of AI agents working together to achieve a common goal. AI
agents can understand goals, plan actions, use tools and complete tasks. So we started by understanding what an AI agent is, how AI evolved from simple chatbots to task oriented systems. And then we explored why multiple agents are
useful, how single agent and multi-agent systems differ, how different agents design patterns. We also discussed real customer support, software development, cyber security, finance and research.
effective multi- aent systems by focusing on clear roles, proper communication, evaluation, and practical workflows. The main idea to remember here is simple. Multi- aent systems are like a digital team where every agent
together they solve a problem that's difficult for a single AI system to handle all by themselves. And with that, we have come to the end of our presentation. So, we can now move on to our practical demo part. So now that we
have understood how multiple agents collaborate, let's move from concepts into a practical example. So in this demo, we will be building a simple agents can work together like a small
creating one AI system that handles everything, we will create multiple specialized agents where one agent will focus on research, another will focus on organizing the information and another agent will be reviewing the final
output. Now for this demonstration we will use crew AI which is a framework that helps us create and manage AI agent work. So the idea behind using crew AI agents, assign them with responsibilities, give them tasks and
allow them to collaborate and create a complete goal. So before we create our development environment. So in order to build this project, we need three things. First, we need Python installed on our system because crew AI works only
with Python. Second, we need a code editor. For this demo, we can use visual environment to create and run the Python projects. And thirdly, we need to access an AI model through an API key because our agents need a language model to
understand instructions and generate responses. So let's start by creating a new project folder. So let's open your terminal here and then create a new folder. So just go ahead and type make directory multi- aent content system.
Now that the directory is created, let's move into the folder. So multi- aent content system. So these two commands create a new project folder called multi-agent content system. So then we move our terminal into that folder where
let's go ahead and create a python virtual environment. So for that you go virtual environment. So for that you go and type python - m. So this command creates an isolated environment for our project so that the required libraries
affecting any other python projects. Now environment. So for Windows you will have to type the following command which have to type the following command which is VNV / script/ So now that our virtual
environment is activated, let's ensure that all of the upcoming installations happen inside this project. So now we're ready to install Crew AI. So let's go ahead and install it. So that's pip install crew. So you have to make sure
that none of the letters in crew AI are in caps. So this command downloads and installs the crew AI framework which provides the functionality to create agents assign tasks and manage collaboration. We also need environment
variable support. So for that so let's go ahead and install python-n. So this package allows us to securely store configuration details like API keys without directly writing them inside our code. So now that our
environment is ready, let's go ahead and create the project structure. So I've gone ahead and opened VS code over here. So I have my folder name multi-agent content system. We'll go ahead and add new files. So I'm going to create three
files. The first one is main.py. The second one is agents.py. The third one is tasks.py. Let's go ahead and create agents as save this as python. Then we have our last file which is tasks. Save this as
well as a python file. So now that we have all of our files ready, let's go ahead and understand the purpose of each file. The agents py file contains the definition of our AI workers. The tasks py file will contain the
responsibilities assigned to each agent. So the main py file will connect workflow. So along with this, let's go ahead and create an additional file which is called dot. So the env file
will store our API key securely. So now let's go ahead and configure our AI key. over here. So I got a random API key which was generated pasted over here. So this file stores the authentication key required for connecting our application
writing sensitive information directly inside of our Python code. So we load this from the environment file. Now that the setup is complete, let's start creating our first AI agent. The first agent in our workflow will be the
research agent. So the responsibility of this agent is simple. collect important information about a given topic. So for that open agents py and add the that open agents py and add the following code. So from crew AI import
following code. So from crew AI import agent research agent is equal to agent agent research agent is equal to agent research specialist goal equals collect research specialist goal equals collect accurate information which is also
accurate information which is also useful about the given topic. You are an useful about the given topic. You are an expert researcher who finds important information and organizes
key points. Let's close this with a double quotes. Verbos is equals to true. So this code creates our first AI worker. So the role defines what the
agent does. The goal explains the objective and the backstory gives us additional context so that the agent understands how it should behave. So responsible for writing the final answer. It's only responsibilities
information. So now that our first agent is ready, let's create the next specialist creating the content writing agent. So the second agent will convert the research information into understandable content. So add this code
understandable content. So add this code inside agents. PY agent writer agent inside agents. PY agent writer agent equals agent role is equal to content equals agent role is equal to content writer. The goal will be to create clear
writer. The goal will be to create clear and friendly content using research and friendly content using research information. backstory equals you are an information. backstory equals you are an expert technical writer who explains
complex topics simply verbos is true. So we replace the is with an equals unlike the research agent this agent focuses on
communication and explanation. So this shows the main advantage of a multi- aent system. So each agent has a focused responsibility instead of trying to perform every task. Now let's go ahead and create one final agent that checks
the quality of the output and that is creating the review agent. Now go ahead and add the following code. So right under the previous writer's agent, you under the previous writer's agent, you type this review agent equals agent
type this review agent equals agent equals quality goal is to be review the equals quality goal is to be review the content and identify the missing
information or improvements. information or improvements. You are a reviewer who checks the You are a reviewer who checks the accuracy and clarity before final
accuracy and clarity before final delivery. Vobos is true. So this creates a review specialist that evaluates the final output instead of generating it. So having a separate reviewer improves the quality because the system gets an
other level of checking. So now we have three different agents which is research agent, writer agent and review agent. Next we will need to define what tasks these agents should be performing. So now that we have created our specialized
agents the next step is to define the responsibilities of each agent. So in a multi- aent system agents need clear instructions because every agent should know what exactly needs to be accomplished and for this demo we will
agent will collect information. The content writer agent will create explanation and the review agent will be checking the final output. So to define these responsibilities, we will have to create tasks inside our task.py file. So
create tasks inside our task.py file. So now add the following code. from crew AI now add the following code. from crew AI import task. From agents, import search import task. From agents, import search agent agent review agent. Research task
within brackets equals equals task description equals research the latest information and concepts that are important about
and concepts that are important about topic. Collect key points, topic. Collect key points, examples, and practical use cases. examples, and practical use cases. Expected output, a structured research
Expected output, a structured research summary containing important information and industry applications. Agent here is search
applications. Agent here is search agent. Then we type writing task equals agent. Then we type writing task equals task description is create a beginner
friendly explanation about topic using the research about topic using the research provided. Make the content simple and
provided. Make the content simple and easy to understand. also make it clear easy to understand. also make it clear and engaging. Expected output will be and engaging. Expected output will be complete tutorial style explanation
complete tutorial style explanation with proper structure and examples and with proper structure and examples and the agent here is writer agent. Now for
the review agent we will be writing the following code which is review task following code which is review task equals task with the description as equals task with the description as review the generated content about the
topic. Put this within brackets. Check the accuracy, clarity and missing the accuracy, clarity and missing information. suggest where improvements
information. suggest where improvements may be necessary. Expected review report containing feedback and improvement
feedback and improvement suggestions agent equals review agent. So this code creates three different tasks each task with a specific agent. So the description tells the agent what work needs to be completed. The expected
output defines the results we want and the agent parameter connects the task with the corrected specialist. Here the research agent receives the research creation task and the review agent receives the quality checking task. So
this separation is important because it creates a clear workflow. So instead of only one AI system trying to perform every activity, each agent focuses on one responsibility. So now that we have created our agents and assigned their
tasks, let's connect everything together and create a complete workflow. So now we need a central file that can bring everything together and execute the process. For that open main py. So inside this file we will be importing
our agents and tasks, creating the workflow and running our multi- aent system. So add the following code. So from crew AI import from crew AI import process from tasks import research task
process from tasks import research task writing task and review task. So crew writing task and review task. So crew equals crew within brackets tasks equals equals crew within brackets tasks equals research task writing task review
process underscore sequential sequential verbos equals true close this result verbos equals true close this result equals crew dot kickoff inputs equals
equals crew dot kickoff inputs equals topic multi- aent agent systems. Finally, let's go ahead and print the result. We'll have to move this over. So, this code creates the complete agent workflow. The crew object acts as the
coordinator that manages the tasks. The task list contains all of the earlier. The sequential process means that one agent completes its task before passing information to the next agent. And the kickoff function here starts the
workflow and provides the input topic. So in this example, we are asking our AI team to create content about multi-agent systems. Now let's understand what happens internally when we execute this code. So first the research agent
receives the topic and starts collecting important information. After completing the research, the information moves to the writing agent and the writing agent uses that research and creates a structured explanation. So finally the
review agent checks the content and provides the feedback. This is exactly how multiple specialists collaborate inside multi- aent systems. So now that our workflow is ready, let's run the application and observe the output. Now
sure that our virtual environment is still active. So we've opened the terminal and let's go ahead and run python main dot. So this command starts multi- aent workflow that we created. So once we run the application, we can
observe the agents working one by one. Now let's head back to the terminal here. Make sure that you save all of your files. So typically what happens is the command starts the Python application and triggers a multi- aent
application is run, we can actually observe the agents working one by one. The terminal will show the execution process. So firstly the research agent starts to work and analyzes the topic, collects important information and then
output and starts generating the explanation. Finally the review agent checks the generated content and provides suggestions. The final result containing the combined output generated by our agent team. So the important
thing here to notice is that we did not create one large AI instruction asking it to do everything. Instead, we created a small team where each agent had a specific responsibility and this is the core idea behind multi- aent systems. So
can improve this workflow and make it closer to real world systems. So the example to understand the basic idea of multi- aent systems. In a real world
more powerful by adding additional agents and better coordination. For example, in a professional content creation workflow, we can add a fact-checking agent that can verify information before publishing. So we can
decide what sources should be analyzed. We can also add a feedback agent which matches the audience requirements. workflow structure. So currently we're using a sequential approach where the
agents work one after the other which is research, writing, review but some real world problem solving requires parallel execution. So for example we have while other agent can analyze customer
results can be combined later. Now this creates faster workflows. Another improvement is adding tools. For example, a research agent can be a coding agent can use development tools. A business agent can work with
company databases. So the important point here is the power of multi- aent systems coming from designing the right workflow and not just simply increasing the number of agents. So I have opened crew AI over here to simulate the exact
same output that we were supposed to be getting on our VS code. So I've added a prompt here which is supposed to do the same work which was supposed to be done when I type python main.py. Let's go ahead and run this. So as you can see
the execution has started. So this will be the crewi interface for your reference. So in this demonstration we built a simple multi- aent content setting up our development environment and installing crew AI. Then we created
three specialized agents. A research agent that collects information. A explanations. a review agent that can check quality. After creating the agents, we defined separate tasks for each responsibility and connected them
through a workflow. So, as you can see here, it's asking us to enter a topic. here, it's asking us to enter a topic. So, let's just enter multi- aent system. Let's go ahead and execute this. We finish it. So, as you can see, we were
observe how different agents collaborated to complete one common goal. So the main takeaway from this demo is that multi- aent systems are built around collaboration. So instead of creating just one AI system that
handles everything, we create multiple specialized agents that work together solving complex problems. So as you can see, we were able to successfully run an automation on crew AI. And with that, we have successfully completed our demo
part. And that brings us to the end of this multi- aent system tutorial. We explore what AI agents are, how multiple agents collaborate, where they are used, and how they can help solve complex problems. As AI continues to evolve,
understanding concepts like multi-agent systems will help you stay ahead and build a better understanding of the future of intelligent applications. insights and check out our related videos to continue your learning
videos to continue your learning journey.
