代理产卵

人工智能 社区

技能解读

当前原文的自动摘译,尚未人工审校。

何时使用

在agentica-orchestrator提示用户进行模式选择之后 当用户明确请求多智能体模式(群体、分层等)时 当实现受益于并行智能体执行的复杂任务时 对于需要多个视角的研究任务(使用群体) 对于需要协调的实施任务(使用分层)

环境变量

所有生成的代理都会收到: SWARM_ID:此群体运行的唯一标识符 AGENT_ROLE:模式中的角色(协调员、专家等) PATTERN_TYPE:正在运行哪个模式

流狐档案 运行与权限由流狐静态检查推断,不代表作者声明或实际测试结果。
领域
人工智能
作者声明的智能体
未找到明确声明;不据此推断已兼容或已测试
静态检查
88 / 100 · 启发式扫描,不代表运行安全
运行环境证据
未执行;当前没有隔离运行测试证据
作者 / 版本 / 许可证
@parcadei · 未声明许可证
上下文用量评级
低消耗
接入复杂程度
需简单配置
是否需要外部接口密钥
不需要
兼容的系统
未声明(默认跨平台)
运行环境要求
Python
检测到的文件与系统行为
  • 只读
  • 允许写入 / 修改
  • 命令执行
  • 读取环境变量
网络行为
仅限本地
安装命令数
无(仅作为资料)

需要注意: 未声明工具权限范围;实际权限由运行环境决定。

作者说明文件(原文) SKILL.md

# Agentica Spawn Skill

Use this skill after user selects an Agentica pattern.

## When to Use

- After agentica-orchestrator prompts user for pattern selection
- When user explicitly requests a multi-agent pattern (swarm, hierarchical, etc.)
- When implementing complex tasks that benefit from parallel agent execution
- For research tasks requiring multiple perspectives (use Swarm)
- For implementation tasks requiring coordination (use Hierarchical)
- For iterative refinement (use Generator/Critic)
- For high-stakes validation (use Jury)

## Pattern Selection to Spawn Method

### Swarm (Research/Explore)
```python
swarm = Swarm(
    perspectives=[
        "Security expert analyzing for vulnerabilities",
        "Performance expert optimizing for speed",
        "Architecture expert reviewing design"
    ],
    aggregate_mode=AggregateMode.MERGE,
)
result = await swarm.execute(task_description)
```

### Hierarchical (Build/Implement)
```python
hierarchical = Hierarchical(
    coordinator_premise="You break tasks into subtasks",
    specialist_premises={
        "planner": "You create implementation plans",
        "implementer": "You write code",
        "reviewer": "You review code for issues"
    },
)
result = await hierarchical.execute(task_description)
```

### Generator/Critic (Iterate/Refine)
```python
gc = GeneratorCritic(
    generator_premise="You generate solutions",
    critic_premise="You critique and suggest improvements",
    max_rounds=3,
)
result = await gc.run(task_description)
```

### Jury (Validate/Verify)
```python
jury = Jury(
    num_jurors=5,
    consensus_mode=ConsensusMode.MAJORITY,
    premise="You evaluate the solution"
)
verdict = await jury.decide(bool, question)
```

## Environment Variables

All spawned agents receive:
- `SWARM_ID`: Unique identifier for this swarm run
- `AGENT_ROLE`: Role within the pattern (coordinator, specialist, etc.)
- `PATTERN_TYPE`: Which pattern is running

讨论

基于 GitHub Discussions。登录 GitHub 即可参与讨论、点赞、订阅更新。