agentica-infrastructure
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseAgentica Infrastructure Reference
Agentica基础设施参考
Complete API specification for Agentica multi-agent coordination infrastructure.
Agentica多智能体协调基础设施的完整API规范。
When to Use
使用场景
- Building multi-agent workflows with Agentica patterns
- Need exact constructor signatures for pattern classes
- Want to understand coordination database schema
- Implementing custom patterns using primitives
- Debugging agent tracking or orphan detection
- 使用Agentica模式构建多智能体工作流
- 需要模式类的精确构造函数签名
- 希望了解协调数据库的架构
- 使用原语实现自定义模式
- 调试智能体追踪或孤立智能体检测
Quick Reference
快速参考
11 Pattern Classes
11种模式类
| Pattern | Purpose | Key Method |
|---|---|---|
| Parallel perspectives | |
| Sequential stages | |
| Coordinator + specialists | |
| Voting consensus | |
| Iterative refinement | |
| Failure fallback | |
| Debate + judge | |
| Route to handler | |
| Fan out + reduce | |
| Shared state | |
| Event bus | |
| Pattern | 用途 | 核心方法 |
|---|---|---|
| 并行视角收集 | |
| 串行阶段执行 | |
| 协调者+专家模式 | |
| 投票共识决策 | |
| 迭代优化 | |
| 故障降级 | |
| 辩论+裁决 | |
| 责任链路由 | |
| 扇出+归约 | |
| 共享状态管理 | |
| 事件驱动 | |
Core Infrastructure
核心基础设施
| Component | File | Purpose |
|---|---|---|
| | SQLite tracking |
| | Agent with tracking |
| | Universal handoff format |
| | Hot tier communication |
| | Core + Archival memory |
| | Scope with file ops |
| 组件 | 文件 | 用途 |
|---|---|---|
| | SQLite追踪管理 |
| | 带追踪功能的智能体 |
| | 通用智能体交接格式 |
| | 热层通信缓存 |
| | 核心+归档记忆服务 |
| | 带文件操作的作用域 |
Primitives
原语
| Primitive | Purpose |
|---|---|
| Voting (MAJORITY, UNANIMOUS, THRESHOLD) |
| Combine results (MERGE, CONCAT, BEST) |
| Structured agent handoff |
| Structured premise builder |
| TaskGroup-based parallel execution |
| 原语 | 用途 |
|---|---|
| 投票机制(多数决、一致决、阈值决) |
| 结果合并(合并、拼接、最优选择) |
| 结构化智能体交接状态 |
| 结构化前提构建器 |
| 基于TaskGroup的快速失败并行执行 |
Full API Spec
完整API规范
See: in this skill directory
API_SPEC.md详见:本技能目录下的
API_SPEC.mdUsage Example
使用示例
python
from scripts.agentica_patterns.patterns import Swarm, Jury
from scripts.agentica_patterns.primitives import ConsensusMode
from scripts.agentica_patterns.coordination import CoordinationDB
from scripts.agentica_patterns.tracked_agent import tracked_spawnpython
from scripts.agentica_patterns.patterns import Swarm, Jury
from scripts.agentica_patterns.primitives import ConsensusMode
from scripts.agentica_patterns.coordination import CoordinationDB
from scripts.agentica_patterns.tracked_agent import tracked_spawnCreate tracking database
Create tracking database
db = CoordinationDB(session_id="my-session")
db = CoordinationDB(session_id="my-session")
Swarm with tracking
Swarm with tracking
swarm = Swarm(
perspectives=["Security expert", "Performance expert"],
db=db
)
result = await swarm.execute("Review this code")
swarm = Swarm(
perspectives=["Security expert", "Performance expert"],
db=db
)
result = await swarm.execute("Review this code")
Jury with consensus
Jury with consensus
jury = Jury(
num_jurors=3,
consensus_mode=ConsensusMode.MAJORITY,
premise="You evaluate code quality",
db=db
)
verdict = await jury.decide(bool, "Is this code production ready?")
undefinedjury = Jury(
num_jurors=3,
consensus_mode=ConsensusMode.MAJORITY,
premise="You evaluate code quality",
db=db
)
verdict = await jury.decide(bool, "Is this code production ready?")
undefinedLocation
位置
API spec:
Source:
.claude/skills/agentica-infrastructure/API_SPEC.mdscripts/agentica_patterns/API规范:
源码:
.claude/skills/agentica-infrastructure/API_SPEC.mdscripts/agentica_patterns/