本文へ移動
cccskills
無料GitHub で公開

crewai

CrewAI is a Python framework for building multi-agent AI systems: you define agents with roles, goals and tools, give them tasks, and run them as a crew with sequential or hierarchical processes, memory and delegation. Use when a user wants to build a multi-agent workflow, set up a CrewAI project, write custom CrewAI tools, or run a crew from the crewai CLI.

インストール方法を見る

含まれるファイル(2)

  • SKILL.md6.6 KB
  • _scores.json3.1 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

CrewAI — Multi-Agent Orchestration

Overview

CrewAI organizes LLM agents into a Crew: each Agent has a role, goal, backstory and tools, each Task has a description and expected output, and the crew runs the tasks in order (Process.sequential) or under an auto-created manager (Process.hierarchical). Besides crews, the package has Flow for event-driven, stateful pipelines that can call crews. Checked against crewai and crewai-tools 1.15.23 (28 Sep 2026): imports and constructors below were executed; model calls were not (no API key used).

Instructions

Step 1: Install and scaffold

pip install crewai crewai-tools          # or: uv tool install crewai
crewai --version
crewai create crew research-crew         # interactive wizard that writes agents.yaml, tasks.yaml, crew.py
cd research-crew && crewai install && crewai run

Set the provider key in a .env file or the environment (for OpenAI, OPENAI_API_KEY); never commit it. Scaffolded projects keep prompts in src/<name>/config/agents.yaml and tasks.yaml, with a @CrewBase class in crew.py using @agent, @task and @crew decorators; {topic} placeholders are filled by kickoff(inputs=...).

Step 2: Agents, tasks and a crew in plain Python

from crewai import Agent, Task, Crew, Process, LLM
from crewai_tools import SerperDevTool, WebsiteSearchTool, FileReadTool   # SerperDevTool needs SERPER_API_KEY

llm = LLM(model="openai/gpt-4o-mini", temperature=0.2)

researcher = Agent(
    role="Senior Research Analyst",
    goal="Find accurate, cross-checked facts about {topic}",
    backstory="You have 15 years in technology analysis and always verify claims against several sources.",
    tools=[SerperDevTool(), WebsiteSearchTool()],
    llm=llm,
    allow_delegation=False,
    verbose=True,
)
writer = Agent(
    role="Content Writer",
    goal="Turn research into a clear article for developers",
    backstory="A technical writer who explains complex topics with concrete examples.",
    tools=[FileReadTool()],
    llm=llm,
)

research_task = Task(
    description="Research {topic}. Find at least 5 credible sources, key numbers and recent developments.",
    expected_output="A research brief with source URLs",
    agent=researcher,
)
writing_task = Task(
    description="Write a 1200-word markdown article from the research brief.",
    expected_output="A markdown article with intro, 3 sections and conclusion",
    agent=writer,
    context=[research_task],               # output of research_task is passed in
    output_file="article.md",
)

crew = Crew(agents=[researcher, writer], tasks=[research_task, writing_task],
            process=Process.sequential, verbose=True)
result = crew.kickoff(inputs={"topic": "AI agents in production"})
print(result.raw)                          # final text; also result.pydantic, result.json_dict, result.tasks_output
print(result.token_usage)

Task also accepts output_pydantic=MyModel for structured results, guardrail= for output checks and async_execution=True.

Step 3: Custom tools

import json
from crewai.tools import BaseTool
from pydantic import BaseModel, Field

class OrdersQueryInput(BaseModel):
    query: str = Field(description="Read-only SQL SELECT against the orders database")

class OrdersQueryTool(BaseTool):
    name: str = "orders_query"
    description: str = "Run a read-only SQL query on the orders analytics database"
    args_schema: type[BaseModel] = OrdersQueryInput

    def _run(self, query: str) -> str:
        rows = run_readonly_query(query)   # your own function
        return json.dumps(rows, default=str)

The @tool("name") decorator from crewai.tools works for simple functions. Agents can also take MCP servers through the mcps= field.

Step 4: Hierarchical process and memory

crew = Crew(
    agents=[researcher, writer],
    tasks=[research_task, writing_task],
    process=Process.hierarchical,          # requires manager_llm or manager_agent
    manager_llm="gpt-4o",
    memory=True,                           # or pass a Memory instance for custom storage
)

Memory is a unified store (Memory, with scoped views) and calls an embedding model; configure embedder= if you do not use OpenAI. Reset it with crewai reset-memories. Other useful CLI commands: crewai test, crewai train, crewai replay.

Examples

Example 1: "Set up a researcher and writer crew for blog posts"

Run the Step 2 script with OPENAI_API_KEY and SERPER_API_KEY exported. Result: verbose logs show the researcher's tool calls, then article.md is written and the token usage dictionary prints.

Example 2: "Let the crew query our orders database"

Add OrdersQueryTool() to a Data Analyst agent's tools, give it a Task such as "Summarize last month's refunds by reason", and run crew.kickoff(). Result: the agent calls orders_query with SQL, and the answer in result.raw cites the returned rows.

Guidelines

  • Specific roles, goals and expected_output text drive quality; vague agents wander and burn tokens.
  • Use Process.sequential by default; hierarchical adds a manager LLM and more calls, so use it only when task assignment must be dynamic.
  • Pass data between tasks explicitly with context=[...]; set max_iter and max_rpm on agents to cap loops and rate-limit errors.
  • Tools run with your credentials: give database tools read-only access and validate inputs; do not let agents run arbitrary shell or write code unless sandboxed (allow_code_execution runs code and should stay off unless needed).
  • Delegation (allow_delegation=True) increases cost and can loop between agents; enable it only where needed.
  • CrewAI collects anonymous telemetry by default; set CREWAI_DISABLE_TELEMETRY=true where policy requires.
  • Old tutorials use crewai_tools imports that moved or LangChain tools; prefer crewai_tools and crewai.tools.BaseTool, and pin the version you tested.

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

Scripts and configures production rendering in Autodesk 3ds Max with the V-Ray and Corona renderers: output size and files, render elements, denoising, light mix, batch and command-line rendering, and network rendering. Use when a user asks to set up a production render, render several cameras in one batch, render from the command line or on a render farm, add render passes for compositing, or cut render time for archviz and product shots.

日本語の概要は準備中です。原文の説明を表示しています。

TerminalSkills/skills1652026年10月4日 更新

Covers scripting Autodesk 3ds Max, the 3D modeling and rendering application, with MAXScript and Python (pymxs): scene manipulation, object creation, material assignment, camera and light setup, batch operations, and file I/O. Use when tasks involve automating repetitive 3ds Max workflows, batch processing scenes, running scripts headless with 3dsmaxbatch, creating custom tools, or scripting scene setup for archviz, product visualization, or VFX.

日本語の概要は準備中です。原文の説明を表示しています。

TerminalSkills/skills1652026年10月4日 更新

3proxy

無料

3proxy is a small open-source proxy server that runs HTTP/HTTPS, SOCKS4/5, SNI and TCP/UDP port-mapping proxies from one config file. Use when a user asks to set up an HTTP or SOCKS5 proxy, add proxy users and passwords, write 3proxy access rules, chain or rotate upstream (parent) proxies, limit bandwidth, connections or monthly traffic per user, run 3proxy in Docker, or fix a 3proxy.cfg that will not start.

日本語の概要は準備中です。原文の説明を表示しています。

TerminalSkills/skills1652026年10月4日 更新

Builds Agent2Agent (A2A) servers and clients, the open protocol (originally from Google, now under the Linux Foundation) that lets AI agents from different frameworks call each other. Use when the user wants to create an A2A-compliant agent, build an Agent Card, implement task management, connect agents across frameworks, set up agent discovery, handle streaming responses, implement push notifications, or orchestrate multi-agent workflows. Trigger words: a2a, agent to agent, agent2agent, a2a protocol, a2a server, a2a client, agent card, agent interoperability, agent collaboration, multi-agent, agent discovery, a2a sdk, a2a task.

日本語の概要は準備中です。原文の説明を表示しています。

TerminalSkills/skills1652026年10月4日 更新

Plans a controlled experiment (A/B test) so its result can be trusted: writes the hypothesis, picks one primary metric and the guardrails, computes sample size and run time, specifies how visitors are assigned and when exposure is logged, and reads out the result with a confidence interval. Use when someone says "set up an A/B test", "split test this page", "how many visitors do I need", "how long should the experiment run", "is this result significant", "can I stop the test early", or wants to test a headline, price, layout or onboarding change against the current version.

日本語の概要は準備中です。原文の説明を表示しています。

TerminalSkills/skills1652026年10月4日 更新

ably

無料

Ably is a hosted realtime messaging service: clients publish and subscribe to named channels over WebSockets, see who is present, replay message history, and resume after a dropped connection. Use when a user asks to "add realtime updates", "push live notifications to the browser", "show who is online", "add a chat room with typing indicators", "publish from a serverless function", or "authenticate Ably clients without exposing the API key". Covers the ably 2.x JavaScript SDK (Realtime and REST), JWT token authentication, presence, history and rewind, batch publishing, and the @ably/chat 1.x SDK.

日本語の概要は準備中です。原文の説明を表示しています。

TerminalSkills/skills1652026年10月4日 更新

TerminalSkills のスキルをすべて見る

このスキルの問題を報告する