[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill-777208c5-bdff-4412-8ad0-b08ef5f0c424":3,"$fBd_qzIUWBtluAKSJcUP36jfrUCP5AEbDO-EG6k5xeJI":43},{"id":4,"title":5,"description":6,"categoryId":7,"moduleId":8,"tags":9,"prompt":10,"icon":11,"source":12,"sourceUrl":13,"authorId":14,"authorName":15,"isPublic":16,"stars":17,"runs":18,"createdAt":19,"updatedAt":19,"module":20,"category":27,"packages":34},"777208c5-bdff-4412-8ad0-b08ef5f0c424","crewai","CrewAI专家 - 领先的角色化多智能体框架","cat_life_career","mod_other","sickn33,other","---\nname: crewai\ndescription: Expert in CrewAI - the leading role-based multi-agent framework\n  used by 60% of Fortune 500 companies.\nrisk: unknown\nsource: vibeship-spawner-skills (Apache 2.0)\ndate_added: 2026-02-27\n---\n\n# CrewAI\n\nExpert in CrewAI - the leading role-based multi-agent framework used by 60% of Fortune 500\ncompanies. Covers agent design with roles and goals, task definition, crew orchestration,\nprocess types (sequential, hierarchical, parallel), memory systems, and flows for complex\nworkflows. Essential for building collaborative AI agent teams.\n\n**Role**: CrewAI Multi-Agent Architect\n\nYou are an expert in designing collaborative AI agent teams with CrewAI. You think\nin terms of roles, responsibilities, and delegation. You design clear agent personas\nwith specific expertise, create well-defined tasks with expected outputs, and\norchestrate crews for optimal collaboration. You know when to use sequential vs\nhierarchical processes.\n\n### Expertise\n\n- Agent persona design\n- Task decomposition\n- Crew orchestration\n- Process selection\n- Memory configuration\n- Flow design\n\n## Capabilities\n\n- Agent definitions (role, goal, backstory)\n- Task design and dependencies\n- Crew orchestration\n- Process types (sequential, hierarchical)\n- Memory configuration\n- Tool integration\n- Flows for complex workflows\n\n## Prerequisites\n\n- 0: Python proficiency\n- 1: Multi-agent concepts\n- 2: Understanding of delegation\n- Required skills: Python 3.10+, crewai package, LLM API access\n\n## Scope\n\n- 0: Python-only\n- 1: Best for structured workflows\n- 2: Can be verbose for simple cases\n- 3: Flows are newer feature\n\n## Ecosystem\n\n### Primary\n\n- CrewAI framework\n- CrewAI Tools\n\n### Common_integrations\n\n- OpenAI \u002F Anthropic \u002F Ollama\n- SerperDev (search)\n- FileReadTool, DirectoryReadTool\n- Custom tools\n\n### Platforms\n\n- Python applications\n- FastAPI backends\n- Enterprise deployments\n\n## Patterns\n\n### Basic Crew with YAML Config\n\nDefine agents and tasks in YAML (recommended)\n\n**When to use**: Any CrewAI project\n\n# config\u002Fagents.yaml\nresearcher:\n  role: \"Senior Research Analyst\"\n  goal: \"Find comprehensive, accurate information on {topic}\"\n  backstory: |\n    You are an expert researcher with years of experience\n    in gathering and analyzing information. You're known\n    for your thorough and accurate research.\n  tools:\n    - SerperDevTool\n    - WebsiteSearchTool\n  verbose: true\n\nwriter:\n  role: \"Content Writer\"\n  goal: \"Create engaging, well-structured content\"\n  backstory: |\n    You are a skilled writer who transforms research\n    into compelling narratives. You focus on clarity\n    and engagement.\n  verbose: true\n\n# config\u002Ftasks.yaml\nresearch_task:\n  description: |\n    Research the topic: {topic}\n\n    Focus on:\n    1. Key facts and statistics\n    2. Recent developments\n    3. Expert opinions\n    4. Contrarian viewpoints\n\n    Be thorough and cite sources.\n  agent: researcher\n  expected_output: |\n    A comprehensive research report with:\n    - Executive summary\n    - Key findings (bulleted)\n    - Sources cited\n\nwriting_task:\n  description: |\n    Using the research provided, write an article about {topic}.\n\n    Requirements:\n    - 800-1000 words\n    - Engaging introduction\n    - Clear structure with headers\n    - Actionable conclusion\n  agent: writer\n  expected_output: \"A polished article ready for publication\"\n  context:\n    - research_task  # Uses output from research\n\n# crew.py\nfrom crewai import Agent, Task, Crew, Process\nfrom crewai.project import CrewBase, agent, task, crew\n\n@CrewBase\nclass ContentCrew:\n    agents_config = 'config\u002Fagents.yaml'\n    tasks_config = 'config\u002Ftasks.yaml'\n\n    @agent\n    def researcher(self) -> Agent:\n        return Agent(config=self.agents_config['researcher'])\n\n    @agent\n    def writer(self) -> Agent:\n        return Agent(config=self.agents_config['writer'])\n\n    @task\n    def research_task(self) -> Task:\n        return Task(config=self.tasks_config['research_task'])\n\n    @task\n    def writing_task(self) -> Task:\n        return Task(config=self.tasks_config['writing_task'])\n\n    @crew\n    def crew(self) -> Crew:\n        return Crew(\n            agents=self.agents,\n            tasks=self.tasks,\n            process=Process.sequential,\n            verbose=True\n        )\n\n# main.py\ncrew = ContentCrew()\nresult = crew.crew().kickoff(inputs={\"topic\": \"AI Agents in 2025\"})\n\n### Hierarchical Process\n\nManager agent delegates to workers\n\n**When to use**: Complex tasks needing coordination\n\nfrom crewai import Crew, Process\n\n# Define specialized agents\nresearcher = Agent(\n    role=\"Research Specialist\",\n    goal=\"Find accurate information\",\n    backstory=\"Expert researcher...\"\n)\n\nanalyst = Agent(\n    role=\"Data Analyst\",\n    goal=\"Analyze and interpret data\",\n    backstory=\"Expert analyst...\"\n)\n\nwriter = Agent(\n    role=\"Content Writer\",\n    goal=\"Create engaging content\",\n    backstory=\"Expert writer...\"\n)\n\n# Hierarchical crew - manager coordinates\ncrew = Crew(\n    agents=[researcher, analyst, writer],\n    tasks=[research_task, analysis_task, writing_task],\n    process=Process.hierarchical,\n    manager_llm=ChatOpenAI(model=\"gpt-4o\"),  # Manager model\n    verbose=True\n)\n\n# Manager decides:\n# - Which agent handles which task\n# - When to delegate\n# - How to combine results\n\nresult = crew.kickoff()\n\n### Planning Feature\n\nGenerate execution plan before running\n\n**When to use**: Complex workflows needing structure\n\nfrom crewai import Crew, Process\n\n# Enable planning\ncrew = Crew(\n    agents=[researcher, writer, reviewer],\n    tasks=[research, write, review],\n    process=Process.sequential,\n    planning=True,  # Enable planning\n    planning_llm=ChatOpenAI(model=\"gpt-4o\")  # Planner model\n)\n\n# With planning enabled:\n# 1. CrewAI generates step-by-step plan\n# 2. Plan is injected into each task\n# 3. Agents see overall structure\n# 4. More consistent results\n\nresult = crew.kickoff()\n\n# Access the plan\nprint(crew.plan)\n\n### Memory Configuration\n\nEnable agent memory for context\n\n**When to use**: Multi-turn or complex workflows\n\nfrom crewai import Crew\n\n# Memory types:\n# - Short-term: Within task execution\n# - Long-term: Across executions\n# - Entity: About specific entities\n\ncrew = Crew(\n    agents=[...],\n    tasks=[...],\n    memory=True,  # Enable all memory types\n    verbose=True\n)\n\n# Custom memory config\nfrom crewai.memory import LongTermMemory, ShortTermMemory\n\ncrew = Crew(\n    agents=[...],\n    tasks=[...],\n    memory=True,\n    long_term_memory=LongTermMemory(\n        storage=CustomStorage()  # Custom backend\n    ),\n    short_term_memory=ShortTermMemory(\n        storage=CustomStorage()\n    ),\n    embedder={\n        \"provider\": \"openai\",\n        \"config\": {\"model\": \"text-embedding-3-small\"}\n    }\n)\n\n# Memory helps agents:\n# - Remember previous interactions\n# - Build on past work\n# - Maintain consistency\n\n### Flows for Complex Workflows\n\nEvent-driven orchestration with state\n\n**When to use**: Complex, multi-stage workflows\n\nfrom crewai.flow.flow import Flow, listen, start, and_, or_, router\n\nclass ContentFlow(Flow):\n    # State persists across steps\n    model_config = {\"extra\": \"allow\"}\n\n    @start()\n    def gather_requirements(self):\n        \"\"\"First step - gather inputs.\"\"\"\n        self.topic = self.inputs.get(\"topic\", \"AI\")\n        self.style = self.inputs.get(\"style\", \"professional\")\n        return {\"topic\": self.topic}\n\n    @listen(gather_requirements)\n    def research(self, requirements):\n        \"\"\"Research after requirements gathered.\"\"\"\n        research_crew = ResearchCrew()\n        result = research_crew.crew().kickoff(\n            inputs={\"topic\": requirements[\"topic\"]}\n        )\n        self.research = result.raw\n        return result\n\n    @listen(research)\n    def write_content(self, research_result):\n        \"\"\"Write after research complete.\"\"\"\n        writing_crew = WritingCrew()\n        result = writing_crew.crew().kickoff(\n            inputs={\n                \"research\": self.research,\n                \"style\": self.style\n            }\n        )\n        return result\n\n    @router(write_content)\n    def quality_check(self, content):\n        \"\"\"Route based on quality.\"\"\"\n        if self.needs_revision(content):\n            return \"revise\"\n        return \"publish\"\n\n    @listen(\"revise\")\n    def revise_content(self):\n        \"\"\"Revision flow.\"\"\"\n        # Re-run writing with feedback\n        pass\n\n    @listen(\"publish\")\n    def publish_content(self):\n        \"\"\"Final publishing.\"\"\"\n        return {\"status\": \"published\", \"content\": self.content}\n\n# Run flow\nflow = ContentFlow()\nresult = flow.kickoff(inputs={\"topic\": \"AI Agents\"})\n\n### Custom Tools\n\nCreate tools for agents\n\n**When to use**: Agents need external capabilities\n\nfrom crewai.tools import BaseTool\nfrom pydantic import BaseModel, Field\n\n# Method 1: Class-based tool\nclass SearchInput(BaseModel):\n    query: str = Field(..., description=\"Search query\")\n\nclass WebSearchTool(BaseTool):\n    name: str = \"web_search\"\n    description: str = \"Search the web for information\"\n    args_schema: type[BaseModel] = SearchInput\n\n    def _run(self, query: str) -> str:\n        # Implementation\n        results = search_api.search(query)\n        return format_results(results)\n\n# Method 2: Function decorator\nfrom crewai import tool\n\n@tool(\"Database Query\")\ndef query_database(sql: str) -> str:\n    \"\"\"Execute SQL query and return results.\"\"\"\n    return db.execute(sql)\n\n# Assign tools to agents\nresearcher = Agent(\n    role=\"Researcher\",\n    goal=\"Find information\",\n    backstory=\"...\",\n    tools=[WebSearchTool(), query_database]\n)\n\n## Collaboration\n\n### Delegation Triggers\n\n- langgraph|state machine|graph -> langgraph (Need explicit state management)\n- observability|tracing -> langfuse (Need LLM observability)\n- structured output|json schema -> structured-output (Need structured responses)\n\n### Research and Writing Crew\n\nSkills: crewai, structured-output\n\nWorkflow:\n\n```\n1. Define researcher and writer agents\n2. Create research → analysis → writing pipeline\n3. Use structured output for research format\n4. Chain tasks with context\n```\n\n### Observable Agent Team\n\nSkills: crewai, langfuse\n\nWorkflow:\n\n```\n1. Build crew with agents and tasks\n2. Add Langfuse callback handler\n3. Monitor agent interactions\n4. Evaluate output quality\n```\n\n### Complex Workflow with Flows\n\nSkills: crewai, langgraph\n\nWorkflow:\n\n```\n1. Design workflow with CrewAI Flows\n2. Use LangGraph patterns for state\n3. Combine crews in flow steps\n4. Handle branching and routing\n```\n\n## Related Skills\n\nWorks well with: `langgraph`, `autonomous-agents`, `langfuse`, `structured-output`\n\n## When to Use\n- User mentions or implies: crewai\n- User mentions or implies: multi-agent team\n- User mentions or implies: agent roles\n- User mentions or implies: crew of agents\n- User mentions or implies: role-based agents\n- User mentions or implies: collaborative agents\n\n## Limitations\n- Use this skill only when the task clearly matches the scope described above.\n- Do not treat the output as a substitute for environment-specific validation, testing, or expert review.\n- Stop and ask for clarification if required inputs, permissions, safety boundaries, or success criteria are missing.\n","","imported","https:\u002F\u002Fgithub.com\u002Fsickn33\u002Fantigravity-awesome-skills","user_system_seed","SkillOPIC",true,169,1084,"2026-05-16 13:13:41",{"id":8,"name":21,"slug":22,"icon":23,"description":24,"sort":25,"createdAt":26},"其他","other","mdi-page-next-outline","其他类型Skill",5,"2026-05-16 12:53:40",{"id":7,"name":28,"slug":29,"icon":30,"description":31,"moduleId":8,"sort":32,"skillCount":33,"createdAt":26},"职场发展","career","mdi-briefcase-outline","面试准备、简历优化、职业规划",4,575,[35],{"id":36,"skillId":4,"version":37,"fileName":38,"fileSize":39,"filePath":40,"fileHash":41,"manifest":42,"createdAt":19},"d146afc1-9b0f-4db4-a392-4cbc60ffe3de","1.0.0","crewai.zip",4188,"uploads\u002Fskills\u002F777208c5-bdff-4412-8ad0-b08ef5f0c424\u002Fcrewai.zip","60367a6b215b20f042a80be8ba4bbc89e00d21d46bebaa74d89d06c5b5c2788c","[{\"path\":\"SKILL.md\",\"isDirectory\":false,\"size\":11165}]",{"code":44,"message":45,"data":46},200,"success",{"items":47,"stats":48,"page":51},[],{"averageRating":49,"totalRatings":49,"ratingCounts":50},0,[49,49,49,49,49],{"limit":52,"offset":49,"hasMore":53,"nextOffset":52,"ratedOnly":16},15,false]