docs(agent): 记录设备生命周期需求的 ai-proj 关联信息与 REST 契约实测

This commit is contained in:
wangheng
2026-09-24 11:01:03 +08:00
parent 98a3d3c6e4
commit 89af0c45fc
+2 -1
View File
@@ -3,7 +3,7 @@
## ai-proj 关联信息
- **ai-proj 项目 ID:224**(项目名 xiaoqu_agent_service)。本仓所有需求/任务创建后应挂到该项目,关联任务前确保任务也在项目 224。
- 近期需求示例:REQ-20260921-0007(id 5778,设备电量消息查询工具,released)→ 任务 22306;REQ-20260919-0003(id 5747,出入库工具复查修复,released)→ 任务 22123。
- 近期需求示例:REQ-20260924-0003(id 5800,设备生命周期查询工具,implementation 完成)→ 任务 22391;REQ-20260921-0007(id 5778,设备电量消息查询工具,released)→ 任务 22306;REQ-20260919-0003(id 5747,出入库工具复查修复,released)→ 任务 22123。
## ai-proj MCP 已知限制与真实契约
@@ -13,6 +13,7 @@
- REST base 推导:mcp.json 里 ai-proj 的 url 去掉尾部 `/mcp/sse`(即 `https://ai.pipexerp.com/api/v1`),认证头 `X-API-Key` 同 mcp.json。
- ⚠️ 本机 shell(Bash 工具)直读 `~/.kimi-code/mcp.json` 会被托管层拦截("local Shell bypass is disabled for a managed MCP route");用 Read 工具读取不受限。
- 任务跨项目用 `move_task`,再 `link_tasks_to_requirement`(role=implementation)。
- REST 建需求/任务实测(2026-09-24):`POST /requirements` 与 `POST /tasks` 的 body 带 `project_id:224` 会创建失败/被忽略,先裸建再走 reassignment;关联用 `POST /requirements/{id}/tasks` body=`{task_id, role:"implementation"}`;更新用 `PUT /requirements/{id}`(不支持 PATCH),`delivery_stage` 为只读(PUT 静默忽略),released 由 CLI sync 或界面流转。
- 本机无 ai-proj CLI,远程同步需在有 CLI 的机器执行 `ai-proj sync requirement --id <id> --direction to_remote`。
## 生产 ES 集群关键坑