crewai

Orchestrate multiple AI agents with shared context and automatic task handoffs.

3|Updated Jul 17, 2024
One-click install
npx skills add https://github.com/Castrozan/.dotfiles --skill crewai-castrozan
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: crewai
Source: https://github.com/Castrozan/.dotfiles/tree/main/agents/skills/crewai
Command: npx skills add https://github.com/Castrozan/.dotfiles --skill crewai-castrozan

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires crewai, crewai-tools.

What problem does it solve?

CrewAI provides a framework to orchestrate role-based AI agents that collaborate with shared context and automatic task handoff, enabling teams to work together more efficiently.

Core Features & Use Cases

  • Agents = Roles with tools
  • Tasks = Work with expected outputs assigned to agents
  • Crews = Teams with process (sequential/hierarchical)
  • Tools = Functions agents use (search, files, APIs)
  • Flows = Event-driven (start, listen, router)
  • Use case: Researchers and writers, analysts and coders collaborating on complex projects.

Quick Start

Install CrewAI via pip install crewai crewai-tools From crewai import Agent, Task, Crew, Process

Define agents

researcher = Agent(role='Senior Researcher', goal='Find and analyze technical information', tools=[SerperDevTool()], verbose=True) writer = Agent(role='Content Writer', goal='Craft engaging content', verbose=True)

Define a research task

research = Task(description='Research {topic}', expected_output='5 key findings', agent=researcher)

Define an article task that uses research output

article = Task(description='Write article on {topic}', expected_output='Markdown article', agent=writer, context=[research])

Frequently Asked Questions about crewai

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I orchestrate multiple AI agents to collaborate on a task in Python?

Multi-agent orchestration coordinates role-based AI agents by defining Agents, Tasks, and Crews in Python. It supports sequential and hierarchical processes, allowing agents to pass shared context and hand off tasks automatically.

How do agents share context and hand off tasks automatically in a multi-agent workflow?

Agents share context automatically by defining Tasks with context dependencies, where downstream tasks reference upstream outputs. This allows a researcher agent to pass findings directly to a writer agent within the same Crew.

Can I build event-driven multi-agent workflows that react to specific triggers?

Yes, you can build event-driven multi-agent workflows using Flows. Flows enable processes to start, listen for specific events, and route data dynamically, supporting event-driven orchestration alongside standard sequential or hierarchical Crews.

Do I need the crewai and crewai-tools Python packages to run a multi-agent crew?

Yes, you need the crewai and crewai-tools Python packages to run a multi-agent crew. These dependencies provide the core libraries to define Agents, Tasks, Crews, and integrate external tools like search or APIs.

What is the best way to structure a Python workflow for a researcher and writer to collaborate?

The best way to structure this workflow is defining a sequential Crew with a researcher Task and a writer Task. The writer task references the research output as context, enabling automatic task handoff and shared context within the Python crew.