.agents/design/core/ai/index.md
状态:当前实现
最后核对:2026-07-16
本目录只维护当前代码仍然遵循的设计约束。已经完成的迁移步骤、旧目录方案、阶段性修复方案和完成态 TODO 不再保留在主文档中,需要追溯时使用 Git 历史。
| 文档 | 说明 |
|---|---|
| Agent Loop | 统一模型循环、工具、事件、暂停恢复、上下文和计费协议 |
| 辅助生成 | Chat Agent Helper 等非 workflow 生成场景的通用生命周期 |
| Agent Sandbox | 沙盒实例、provider、工具、Skill 部署、entrypoint 和归档 |
| Agent Skill | 空白工作区、发布约束和内置辅助生成 Skill |
业务入口
|-- Workflow Agent / ToolCall
| `-- agentLoopCore
| `-- runAgentLoop
|
|-- Auxiliary Generation
| `-- runAuxiliaryGenerationAgentLoop
| `-- runAgentLoop
|
`-- Skill Edit / Agent runtime
`-- Sandbox runtime + Skill deployment
runAgentLoop
|-- fastAgent provider
`-- piAgent provider
Sandbox
|-- runtime client and lifecycle
|-- sandbox system tools
`-- published and builtin Skills
packages/service/core/ai/llm/agentLoop/interface 进入,业务调用方不直接依赖 provider 实现。assistantResponses、nodeResponse、interactive 和账单展示由 agentLoopCore 适配,不能下沉到通用 Agent Loop。sourceType/sourceId,sandboxId 仅用于定位物理实例。