Edge UOL

    Discover how we transform IT and strengthen the security of the top companies in the market.

    Who we are Careers News

    Cyber Defenseseta

    Integrated security to detect, prevent, and respond to threats.

      Security Operations Center (SOC) Brand Protection | CTI Incident Response Web Application Protection (WAF) Firewall as a Service (FWaaS) Network Access Security Vulnerability Management Patch Management Endpoint Protection Pentest

    Cyber Resilienceseta

    Continuity and recovery to keep your business always running.

      Disaster Recovery as a Service (DRaaS) Anti-ransomware Data Protection Secure Desktops Access Management Data Loss Prevention (DLP)

    Cyber Governanceseta

    Compliance and security culture to elevate your company’s cyber maturity.

      Governance, Risk and Compliance Consulting Security Awareness & Training CIS Controls Maturity Assessment

    ManageEngineseta

    Take control of your company’s IT with integrated and secure management tools.

      Identity and Management Access Service Management Unified Endpoint and Security Management IT Operations Management Security Event Management Analytics

    Hybrid Cloud & Infrastructureseta

    Hybrid and integrated infrastructure to support the evolution of your business.

      Hybrid Cloud | Private Cloud Hosting | Colocation Network Segmentation & Integration

    Edge VMware Cloudseta

    Use hybrid cloud with the security of having the support of one of the most important players in the market.

      Disaster Recovery as a Service (DRaaS) Secure Desktops Edge Computing Network Segmentation & Integration

    IT Servicesseta

    Specialized services to operate and evolve your IT efficiently.

      Cloud Services Intelligent Monitoring and Observability Database, Operating Systems and Network Management ITSM and IT Governance Integration and DevSecOps SAP Basis Consulting Squads

    Private Networksseta

    Provide your company with Private Network solutions that only an end-to-end integrator can offer.

      Consulting Network Management Private Network Implementation (4G and 5G)

    Hosting and Colocationseta

    Outsource efficiently, maintaining control over everything your company needs.

      Colocation

    Payment Solutionsseta

    Handle payment and invoice issuance with credibility, efficiency, and data security.

      BPag - Payment gateway Notanet - Invoice issuing platform
Partners Cases

    Tech Insights

    Tech Insights seta

    Articles, events, and information to go beyond and dive deep into each technology. Be inspired to transform your company.

    Articles E-books Events Web series

    Tech Universe seta

    Learn about technological innovations and how they can benefit your company.

Contact Us EN
  • EN - Inglês
  • BR - Português (Brazil)
Article/

A Simplified Way to Create and Implement Customized Multi-Agents with CrewAI

January 27th, 2025
Artificial Intelligence IT Services
By Gabriel Moreira Silva
A Simplified Way to Create and Implement Customized Multi-Agents with CrewAI

We know that generative AIs are a market trend. They are already helping various fields and professionals execute their projects. However, the use of AI is not restricted only to the widely publicized prompt engineering. With the help of some tools, we can customize the use of AI to meet more demanding requirements that necessitate a higher level of complexity.

In this article, I would like to introduce CrewAI, an open-source tool that enables the creation of agents capable of using tools and interacting with other created agents. This allows for a broad use of LLMs. In addition to simplifying the creation and implementation of automated workflows, CrewAI enables the use of any LLM and cloud platform.

You might wonder why you should use CrewAI instead of directly using AI models like ChatGPT, which are already widely available on the market. The reason is clear: CrewAI allows for the simultaneous use of multiple agents. You can create an agent for each LLM, as demonstrated in the workflow available on the CrewAI website.

Figura 1 – Fluxo dos agentes

Still, there is a problem. Let’s say you ask the agents for research: they will execute the task using ready-made or customized tools. Each will return an answer, and you will have to read and weigh all of them, which can increase your workload and reduce your productivity. To solve this, CrewAI allows for the creation of a third agent that synthesizes the answers. Another advantage of CrewAI is the possibility of creating a hierarchy, similar to a company structure, where LLM agents can review, assess quality, and perform other assigned tasks.

To conclude, let’s create an agent that uses a web scraping tool to collect information from the internet and generate a summary of the content found. Another agent will be developed to rewrite the information in simple and interesting language. Finally, a last agent will be responsible for the translation, since the data will be in English and we will need it in Portuguese.

The code below is an example of an agent created along with the necessary libraries. It is important to have an API key to access an LLM. In this example, we will use GEMINI.

After creating the agent, we need to define the tool it will use to search for information on the internet through web scraping. In this case, we will use a tool already integrated into CrewAI, Serper.

Then, we delegate the tasks that each agent will execute using the code below.

With everything ready, our agents are created, with their tasks defined and tools associated. Now, we just need to create one more block of code to give the kickoff.

And that’s it! Just run the code, with the last file created being our main. After some time observing the interaction of the agents in the command prompt, you will receive the text formatted in Markdown.

Despite the simple example, it is incredible what can be done using CrewAI. It is also possible to implement other text editing tools as output and even create customized tools using the CrewAI documentation.

Fonts

  • https://www.crewai.com/use-cases
  • Serper – The World’s Fastest and Cheapest Google Search API

Project repository

  • https://github.com/GabMoreiraSilva/CrewAI-exemplo/blob/main/CrewaiGemini/agents.py
Tags:
Artificial IntelligenceCrewAIInteligência Artificial

Related

About Us

Artificial Intelligence as a pillar of business transformation

Rodrigo Rangel Lobo
Cybersecurity

The New Era of Cybersecurity: How AI is Shaping the Future of Digital Protection

Clayton Oliveira
Cybersecurity

The new era of digital protection and the power of AI against virtual threats

Rodrigo Rangel Lobo
Artificial Intelligence Hybrid Cloud & Infrastructure Hybrid Cloud | Private Cloud

Sovereign cloud in the Age of Artificial Intelligence

Rodrigo Rangel Lobo

Get in touch

Our team of experts is ready to support your company with solutions that enhance performance and security.

Contact usseta
Logo Edge UOL

Edge UOL

Who we are Careers News

Partners

Case Studies

Solutions

Cyber Defense Cyber Resilience Cyber Governance Hybrid Cloud & Infrastructure IT Services Payment Solutions

Tech Universe

Cybersecurity Cloud Computing Payment Gateway ITSM and IT Governance Autonomous Operations Digital Transformation

Tech Insights

Articles E-books Events Web series

Contact Us

Grupo UOL
Privacy Policy
Terms of use
Information security
Quality management policy
Accessibility
facebook Edge UOL linkedin Edge UOL youtube Edge UOL instagram Edge UOL
© Edge UOL - 2021 - 2026 - All rights reserved
Logo LVT