Token导航 LogoToken导航

Agent Skill · 研究检索

agent-teams(Agent Teams 协作)

用于辅助测试设计、自动化测试、用例整理和回归验证。它适合让 Agent 编写单元测试、端到端测试、测试计划或根据失败日志定位问题。使用时需要确认项目测试框架、运行命令和夹具数据,避免为了通过测试而改坏真实逻辑;涉及浏览器或外部服务时,应区分本地模拟、测试环境和生产环境。

agent-teams 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为执行命令;许可证信息还不明确,第三方扫描有提醒项,按安装量在研究检索类的 73,674 个 Skill 里排第 45,481。

总安装 847周安装 36GitHub Stars 37下载 297核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:agent-teams(Agent Teams 协作)
来源仓库:https://github.com/majesticlabs-dev/majestic-marketplace
仓库路径:skills/agent-teams
安装命令:
npx skills add https://github.com/majesticlabs-dev/majestic-marketplace --skill agent-teams
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/majesticlabs-dev/majestic-marketplace --skill agent-teams

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

用于辅助测试设计、自动化测试、用例整理和回归验证。适合编写单元测试、端到端测试、测试计划或根据失败日志定位问题。使用时需确认项目测试框架、运行命令和夹具数据。涉及浏览器或外部服务时应区分本地模拟、测试环境与生产环境。agent-teams 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

来源仓库内路径:skills/agent-teams

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/majesticlabs-dev/majestic-marketplace --skill…;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要执行命令,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

agent-teams 怎么安装?

在终端执行 npx skills add https://github.com/majesticlabs-dev/majestic-marketplace --skill agent-team…。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

agent-teams 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

agent-teams 需要什么权限?

权限级别是执行命令。安装流程涉及命令执行,可能通过 npx skills add https://github.com/majesticlabs-dev/majestic-marketplace --skill agent-teams 联网下载 Skill 或依赖。用户安装前应确认命令来源、仓库内容和执行环境。

agent-teams 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

agent-teams 用的人多吗?

公开数据是累计安装 847 次,近一周安装 36 次,下载 297 次,GitHub 37 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

agent-teams 安全吗?

第三方扫描有提醒项,说明存在需要人工确认的行为。安装前请打开源码看清它读了什么、联网到哪里。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。

先想清楚的地方

  • 需要执行命令,装到常用环境前要先评估影响面。
  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方扫描存在提醒项或未通过项,需要人工逐条确认。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 不能接受 Skill 在你机器上执行命令的人。
  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
agent-teams

Agent Teams 协作 · 本页

84737执行命令未明确有提醒

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Agent Teams

Coordinate multiple Claude Code instances as a team with shared task lists, inter-agent messaging, and independent context windows. Fundamentally different from subagents (Task tool): teammates communicate directly with each other, not just back to the caller.

When to Use Agent Teams vs Subagents

Does the work require inter-agent communication?
├── No → Use subagents (Task tool)
│   ├── Focused tasks where only the result matters
│   ├── Research/verification that reports back
│   └── Lower token cost (results summarized to main context)
└── Yes → Use Agent Teams
    ├── Teammates need to share findings mid-task
    ├── Adversarial debate / competing hypotheses
    ├── Self-organizing work from shared task list
    └── Complex coordination across 3+ parallel workers

How many parallel workers?
├── 1-3 independent tasks → Subagents (less overhead)
├── 3-5 coordinating workers → Agent Teams
└── 5+ workers → Agent Teams with delegate mode

Best use cases:

  • Research + review from multiple perspectives simultaneously
  • Multi-module features where teammates own different files
  • Debugging with competing hypotheses (adversarial investigation)
  • Cross-layer coordination (frontend, backend, tests)

Avoid when:

  • Sequential tasks with many dependencies
  • Same-file edits (causes overwrites)
  • Simple focused work (coordination overhead not worth it)
  • Routine tasks (single session more cost-effective)

Environment Setup

Enable Agent Teams (experimental, disabled by default):

// settings.json (user or project level)
{
  "env": {
    "CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS": "1"
  }
}

Or set in shell: export CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1

Tool Architecture

Agent Teams use four distinct tools (not a single "TeammateTool"):

ToolPurpose
TeamCreateCreates team config + task directory. Caller becomes lead
SendMessageAll inter-agent communication (5 message types below)
TeamDeleteRemoves team resources after shutdown (cleanup)
Task (extended)Spawns teammates when name + team_name params present

SendMessage Types

TypeParametersDescription
messagerecipient, content, summaryDirect message to one teammate
broadcastcontent, summaryMessage to all teammates (expensive — N deliveries)
shutdown_requestrecipient, contentRequest teammate termination (lead only)
shutdown_responserequest_id, approve, contentAccept/reject shutdown (teammate only)
plan_approval_responserequest_id, approve, recipient, contentApprove/reject plan (lead only)

Critical: Plain text output is NOT visible to teammates. Agents MUST use SendMessage for all inter-agent communication.

Usage notes:

  • Prefer message over broadcast — broadcast creates N messages for N teammates
  • Messages delivered automatically to recipient inboxes (no polling)
  • Idle notifications sent automatically when teammates finish
  • Only the lead should run TeamDelete — teammate context may not resolve correctly

Spawning Teammates

Method 1: Natural language — Tell Claude to create a team and describe structure:

Create an agent team to review this PR. Spawn three reviewers:
- One focused on security
- One checking performance
- One validating test coverage

Method 2: Task tool with team parameters:

Task({
  team_name: "my-team",
  name: "worker-1",
  subagent_type: "general-purpose",
  prompt: "Review src/auth/ for security vulnerabilities...",
  model: "sonnet",
  run_in_background: true
})

Teammate receives on spawn:

  • Same project context as regular session (CLAUDE.md, MCP servers, skills)
  • The spawn prompt from the lead
  • Does NOT inherit lead's conversation history

Built-in agent types for teammates:

TypeCapabilities
general-purposeAll tools (Edit, Write, Bash, Task, etc.)
ExploreRead-only — codebase search and analysis
PlanRead-only — architectural design
BashSystem commands only

Model selection: Use Sonnet for most teammates (cost-effective). Reserve Opus for leads or complex reasoning tasks. Specify via model parameter or natural language ("Use Sonnet for each teammate").

Spawn Backends

Controls how teammates display. Set via teammateMode in settings.json or --teammate-mode CLI flag.

ModeSettingRequirementsBehavior
Auto (default)"auto"NoneSplit panes if in tmux, else in-process
In-process"in-process"NoneAll in main terminal. Shift+Up/Down to select
Split panes"tmux"tmux or iTerm2Each teammate gets own pane
// settings.json
{ "teammateMode": "in-process" }
# CLI override for single session
claude --teammate-mode in-process

Auto-detection logic:

  1. $TMUX env var set → use tmux split panes
  2. $ITERM_SESSION_ID set + it2 available → use iTerm2
  3. which tmux succeeds → use tmux
  4. Fallback → in-process

In-process navigation:

  • Shift+Up/Down → select teammate
  • Enter → view teammate's session
  • Escape → interrupt teammate's current turn
  • Ctrl+T → toggle task list

Split-pane navigation:

  • Click into pane to interact directly
  • Each teammate has full terminal view

Communication Patterns

Direct message (type: "message"): Send to one specific teammate via SendMessage. Use for targeted instructions, follow-ups, or redirecting approach.

Broadcast (type: "broadcast"): Send to all teammates simultaneously via SendMessage. Use sparingly — costs scale with team size. Good for: announcing shared decisions, requesting status updates.

Automatic delivery: Messages arrive at recipients automatically. Lead does not need to poll for updates.

Idle notifications: When a teammate finishes and stops, it automatically notifies the lead.

Message type schemas: See assets/message-formats.yml

Task Coordination

The shared task list coordinates work across the team. All agents see task status and can claim available work.

Task lifecycle: pending → in_progress → completed

Assignment patterns:

  • Lead assigns explicitly ("Give task 3 to the security reviewer")
  • Self-claim: after finishing a task, teammate picks next unassigned, unblocked task

Dependencies:

  • Express with blockedBy field (array of task IDs)
  • Auto-unblock: when blocking task completes, blocked tasks become available
  • Enables sequential pipelines without polling

File locking: Task claiming uses file locking to prevent race conditions when multiple teammates try to claim simultaneously.

Recommended task sizing:

  • 5-6 tasks per teammate for steady throughput
  • Self-contained units producing clear deliverables
  • Avoid: tasks too small (overhead > benefit) or too large (risk of wasted effort)

Delegate Mode

Restricts the lead to coordination-only tools: spawning, messaging, shutting down teammates, and managing tasks. Prevents lead from implementing tasks itself.

Enable: Press Shift+Tab to cycle into delegate mode after starting a team.

When to use:

  • Lead keeps implementing tasks instead of waiting for teammates
  • You want pure orchestration (break down work, assign, synthesize)
  • Large teams where lead should focus on coordination

Known bug: Teammates spawned AFTER entering delegate mode inherit restricted tool access (lose Read, Write, Edit, Bash, Glob, Grep). Workaround: Spawn all teammates BEFORE pressing Shift+Tab.

When to skip:

  • Small teams where lead can contribute implementation
  • Lead needs to do synthesis work requiring file edits

Plan Approval Workflow

Require teammates to plan before implementing. Teammate works in read-only plan mode until lead approves.

Spawn with plan approval:

Spawn an architect teammate to refactor the auth module.
Require plan approval before they make any changes.

The planModeRequired field in team config controls this per-member.

Workflow:

1. Teammate spawned with planModeRequired: true
2. Teammate explores codebase, creates plan
3. Teammate sends plan_approval_request to lead
4. Lead reviews plan:
   ├── approvePlan → teammate exits plan mode, begins implementation
   └── rejectPlan(feedback) → teammate stays in plan mode, revises
5. Cycle repeats until approved

Influence approval criteria via prompt:

Only approve plans that include test coverage.
Reject plans that modify the database schema.

File Conflict Avoidance

Two teammates editing the same file causes overwrites. Prevent this by assigning file ownership:

- teammate-1: owns src/api/ files
- teammate-2: owns src/ui/ files
- teammate-3: owns tests/ files

Anti-pattern: Multiple teammates modifying shared config files, package.json, or migration files simultaneously.

Mitigation: Use task dependencies to serialize edits to shared files.

Hooks Integration

Two hook events for enforcing quality gates in agent teams:

TeammateIdle

Fires when a teammate is about to go idle after finishing its turn.

  • Exit 0 → allow idle
  • Exit 2 → keep working (stderr fed back as feedback to teammate)
  • No matcher support (fires on every occurrence)
  • Input includes: teammate_name, team_name

TaskCompleted

Fires when a task is being marked as completed (via TaskUpdate or when teammate finishes with in-progress tasks).

  • Exit 0 → allow completion
  • Exit 2 → prevent completion (stderr fed back as feedback)
  • No matcher support (fires on every occurrence)
  • Input includes: task_id, task_subject, task_description, teammate_name, team_name

TeammateIdle: command hooks only (no prompt/agent hooks). TaskCompleted: supports command, prompt, and agent handler types.

See assets/hook-examples.yml for configuration examples.

Graceful Shutdown

Shutdown sequence:

1. Lead sends requestShutdown to each teammate
2. Teammate receives request:
   ├── approveShutdown → finishes current request/tool call, terminates
   └── rejectShutdown(reason) → continues working
3. Wait for all teammates to terminate
4. Lead calls cleanup
   ├── If active teammates remain → cleanup fails
   └── If all terminated → removes team config + task directories

Important:

  • Shutdown can be slow — teammates finish current request before terminating
  • Always use lead for cleanup (not teammates)
  • For orphaned tmux sessions: tmux ls && tmux kill-session -t <name>

Permissions

  • Teammates start with lead's permission settings
  • If lead uses --dangerously-skip-permissions, all teammates do too
  • Can change individual teammate modes after spawning
  • Cannot set per-teammate modes at spawn time
  • Pre-approve common operations in permission settings to reduce prompt interruptions

File Structure

~/.claude/
├── teams/
│   └── {team-name}/
│       ├── config.json          # team config (members, lead, settings)
│       └── inboxes/
│           └── {agent}.json     # per-agent message inbox
└── tasks/
    └── {team-name}/
        ├── 1.json               # task files (auto-incremented IDs)
        ├── 2.json
        └── N.json

See assets/team-config-schema.yml for full schemas.

Known Limitations

LimitationImpactWorkaround
No session resumption with in-process teammates/resume and /rewind don't restore teammatesTell lead to spawn new teammates after resume
Task status can lagTeammates sometimes fail to mark tasks completedManually update or tell lead to nudge teammate
Shutdown can be slowTeammates finish current request before stoppingWait patiently or spawn replacement
One team per sessionCannot manage multiple teams from one leadClean up current team before starting new one
No nested teamsTeammates cannot spawn their own teamsOnly leads manage team structure
Lead is fixedCannot promote teammate or transfer leadershipPlan team structure before starting
Permissions set at spawnAll teammates inherit lead's permission modeChange individual modes after spawning
Split panes require tmux/iTerm2Not supported in VS Code terminal, Windows Terminal, GhosttyUse in-process mode as fallback
5-minute heartbeat timeoutInactive teammates auto-marked inactiveKeep teammates active with tasks
Broadcast scales linearlyN messages for N teammatesPrefer targeted message over broadcast
Delegate mode spawn bugTeammates spawned after Shift+Tab lose file toolsSpawn all teammates before entering delegate mode

Error Handling

ErrorCauseFix
"Cannot cleanup with active members"Teammates still runningrequestShutdown all teammates first
"Already leading a team"Team already existscleanup existing team or use different name
"Agent not found"Wrong teammate name/IDCheck config.json for correct agent IDs
"Team does not exist"No team createdRun spawnTeam first
Teammates not appearingVariousShift+Down to cycle; check task complexity; verify tmux installed
Too many permission promptsTeammate permissions bubble to leadPre-approve common operations in settings
Lead shuts down before work doneLead thinks team is finishedTell lead to wait for teammates

Orchestration Patterns

See references/orchestration-patterns.md for 4 detailed patterns:

  1. Parallel Review — Multiple specialists review simultaneously with distinct lenses
  2. Competing Hypotheses — Adversarial investigation prevents anchoring bias
  3. Multi-Module Feature — File ownership + task dependencies for coordinated implementation
  4. Research Pipeline — Research phase feeds into plan-approved implementation

平台分布

Claude

31.71%
按下载量换算94

Codex

31%
按下载量换算92

Cursor

19.07%
按下载量换算57

Gemini CLI

9.12%
按下载量换算27

安全审计

Gen Agent Trust Hub

可疑

Socket

可疑

Snyk

通过

权限和风险

执行命令

安装流程涉及命令执行,可能通过 npx skills add https://github.com/majesticlabs-dev/majestic-marketplace --skill agent-teams 联网下载 Skill 或依赖。用户安装前应确认命令来源、仓库内容和执行环境。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在提醒或未通过项,安装前请自行复核。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills