欢迎使用 FlowZap,快速、清晰、掌控的绘图应用。

AI原生层级架构

Architecture

层级式多智能体架构,通过堆叠主管和团队负责人(树形结构)来扩展编排,这反映了企业组织结构并有助于分区上下文。当单个编排器无法直接管理所有工作者时,这是"企业级智能体AI架构"。适合大型企业和多领域工作流。

完整 FlowZap 代码

User { # User
n1: circle label:"Start"
n2: rectangle label:"Submit enterprise request"
n1.handle(right) -> n2.handle(left)
n2.handle(bottom) -> Supervisor.n3.handle(top) [label="Goal"]
}
Supervisor { # Top-Level Supervisor
n3: rectangle label:"Decompose goal"
n4: rectangle label:"Delegate to team leads"
n5: rectangle label:"Aggregate final output"
n6: circle label:"Done"
n3.handle(right) -> n4.handle(left)
n4.handle(bottom) -> LeadA.n7.handle(top) [label="Sub-goal A"]
n4.handle(bottom) -> LeadB.n10.handle(top) [label="Sub-goal B"]
n5.handle(right) -> n6.handle(left)
n5.handle(top) -> User.n2.handle(bottom) [label="Final report"]
}
LeadA { # Team Lead A
n7: rectangle label:"Plan subtasks for A"
n8: rectangle label:"Dispatch to workers"
n9: rectangle label:"Consolidate A results"
n7.handle(right) -> n8.handle(left)
n8.handle(bottom) -> Workers.n13.handle(top) [label="Task A1"]
n8.handle(bottom) -> Workers.n14.handle(top) [label="Task A2"]
n9.handle(top) -> Supervisor.n5.handle(bottom) [label="Result A"]
}
LeadB { # Team Lead B
n10: rectangle label:"Plan subtasks for B"
n11: rectangle label:"Dispatch to workers"
n12: rectangle label:"Consolidate B results"
n10.handle(right) -> n11.handle(left)
n11.handle(bottom) -> Workers.n15.handle(top) [label="Task B1"]
n11.handle(bottom) -> Workers.n16.handle(top) [label="Task B2"]
n12.handle(top) -> Supervisor.n5.handle(bottom) [label="Result B"]
}
Workers { # Worker Agents
n13: rectangle label:"Worker A1 executes"
n14: rectangle label:"Worker A2 executes"
n15: rectangle label:"Worker B1 executes"
n16: rectangle label:"Worker B2 executes"
n13.handle(top) -> LeadA.n9.handle(bottom) [label="A1 done"]
n14.handle(top) -> LeadA.n9.handle(bottom) [label="A2 done"]
n15.handle(top) -> LeadB.n12.handle(bottom) [label="B1 done"]
n16.handle(top) -> LeadB.n12.handle(bottom) [label="B2 done"]
}

相关模板

AI原生编排器-工作者架构

Architecture

编排器-工作者架构,其中编排器智能体将目标分解为子任务,分派给专业工作者,然后综合最终响应。这是最常见的"智能体编排"架构——强大,但随着工作者数量增长,编排器可能成为瓶颈。

AI原生生成器-评判者架构

Architecture

竞争式/生成器-评判者架构,多个生成器产生独立答案,然后评估器智能体评分并选择最佳输出。这种方法提高质量并减少单模型脆弱性。它更昂贵(多次LLM调用),但当正确性或创造力比延迟更重要时值得。

AI原生单智能体架构

Architecture

单智能体AI架构,其中一个智能体处理所有事务:解析请求、推理、通过MCP调用工具、生成响应。这是原型和简单自动化的默认架构——易于调试,但很快达到上下文窗口限制且难以并行化。适合快速交付的MVP和独立开发者。

AI原生顺序流水线架构

Architecture

顺序流水线架构,以固定顺序链接多个智能体(解析→丰富→分析→格式化),这是当每个步骤可以隔离时常见的"LLM微服务"配置。这种结构常用于文档处理和ETL类工作流,因为每个步骤都是可测试和可预测的。

AI原生并行扇出架构

Architecture

并行扇出架构,同时在独立检查(样式、安全、性能)上运行多个智能体,然后合并结果。这是吞吐量的标准多智能体设计方法,很好地映射到CI/CD、事件响应和研究。扇入协调成为微妙部分。

AI原生事件驱动Kafka架构

Architecture

事件驱动智能体AI架构,用Kafka/PubSub主题替换中央编排器:智能体订阅、响应并发布新事件。这使多智能体系统与经过验证的微服务编舞保持一致,适合实时、高吞吐量系统和"智能体网格"配置。

返回所有模板