参考

Model 配置参考

Agent 项目如何绑定 Downcity City AIService 模型

Model 配置参考

Downcity 不把完整模型实现细节放进 Agent 项目。项目只保存模型 ID;provider key、provider routing 和模型目录由City AIService 负责。

心智模型

City AIService 模型目录
  -> city
  -> town city use
  -> downcity.json execution.modelId
  -> agent session runtime

这样每个 Agent 项目都保持轻量,多个产品或 Agent 可以复用同一套模型基础设施。

项目绑定

Agent 项目通过 execution.modelId 绑定模型:

{
  "execution": {
    "type": "api",
    "modelId": "quality"
  }
}

说明:

  • execution.type 应写为 api
  • execution.modelId 应对应已连接 City AIService 暴露的某个模型
  • provider secrets 和 provider 连接细节不写进项目配置

常用命令

先连接 Town 与 City,再写入项目绑定:

town city use
town city status
town config set execution.modelId <modelId>

模型绑定变更后重启 agent:

town agent restart .

项目不应该保存什么

项目 downcity.json 不应该保存 provider secrets 或 provider 连接细节。这些属于City runtime。

相关文档