From 43dad2d4573dc961803647bcd26bfe46917bdaf2 Mon Sep 17 00:00:00 2001 From: weichen Date: Sat, 3 Oct 2026 17:46:51 +0000 Subject: [PATCH 1/8] Record the task card for feature-code-orchestration --- .task/feature-code-orchestration.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .task/feature-code-orchestration.md diff --git a/.task/feature-code-orchestration.md b/.task/feature-code-orchestration.md new file mode 100644 index 00000000..35eb70a2 --- /dev/null +++ b/.task/feature-code-orchestration.md @@ -0,0 +1,25 @@ +# feature/code-orchestration 任务卡 + +任务主记录:;状态:进行中;owner:weichen + +## 基线与授权 + +- 权威仓:ssh://git@git-ssh.u1680832.nyat.app:31411/weichen/Agent-System-Dev.git;目标分支:main;R0(initial_base_sha)= 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e +- 工作区:/home/weichen/projects/Agent-System-Dev-wt-feature-code-orchestration(worktree);分支:feature/code-orchestration +- 授权与交付终点:<本次允许的动作与终点;未授权事项写明> + +## 目标与非目标 + +<预期结果、受影响入口/模块/契约;明确不做什么。> + +## 同步记录 + +| 节点 | sync_base_sha | tested_head_sha | checked_at | +|---|---|---|---| +| 启动 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | 2026-10-03T17:46:51Z | + +## 结果与验证(完成后填写) + +- 结果: +- 验证: +- 影响与剩余项: -- 2.54.0 From 117e9933b6e1a9710f459c9980d486d2eda7e718 Mon Sep 17 00:00:00 2001 From: weichen Date: Sat, 3 Oct 2026 17:53:06 +0000 Subject: [PATCH 2/8] Record the code-orchestration task card Why: The batch needs an explicit authorization, the default-off switch, and the host limits before the libraries change. Evidence: The card names the caps, the forbidden tools, and the MCP behaviors that stay out of scope. Impact: Reviewers can match the later commits to this card. No code change. Refs: feature/code-orchestration Co-authored-by: Cursor --- .task/feature-code-orchestration.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.task/feature-code-orchestration.md b/.task/feature-code-orchestration.md index 35eb70a2..ab5cd663 100644 --- a/.task/feature-code-orchestration.md +++ b/.task/feature-code-orchestration.md @@ -6,11 +6,12 @@ - 权威仓:ssh://git@git-ssh.u1680832.nyat.app:31411/weichen/Agent-System-Dev.git;目标分支:main;R0(initial_base_sha)= 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e - 工作区:/home/weichen/projects/Agent-System-Dev-wt-feature-code-orchestration(worktree);分支:feature/code-orchestration -- 授权与交付终点:<本次允许的动作与终点;未授权事项写明> +- 授权与交付终点:实现批次 8(代码编排与 MCP)。允许改 agent-native、agent-squad(透传开关)、backend 与 Dev 指针;经 Gitea PR 合入 main 后回收 worktree。不引入 pi-durable。不把代码编排默认打开。 ## 目标与非目标 -<预期结果、受影响入口/模块/契约;明确不做什么。> +- 目标:`run_tool_script` 的 Python 宿主下沉到 `runtime/codeorch`。限额为 50 次调用、给脚本的单次结果 1 MiB、给模型的输出 16k 字符(全文落文件)、超时缺省 120 秒且最长 600 秒。禁止再调用 shell、python、命令、自身、派发和工作流工具。出错时报告已经执行的调用。开关 `runtime.codeOrchestration` 默认关。工作流 script 步骤改用同一宿主,原有确认和超时上限不变。工具可声明直接或延迟暴露;延迟工具不进清单,经 `tool_search` 与固定 schema 的 `call_tool` 调用。MCP 后台连接,stdio 维持单读循环,失败重连一次,HTTP 关闭时终止会话,`input_required` 交给 AskUser。项目配置可覆盖启用状态和暴露级别。 +- 非目标:MCP OAuth、进程级钩子、绕过确认的模式、把代码编排默认打开。 ## 同步记录 -- 2.54.0 From be388359a1fb3426d1d41ae54f49a81fffafc3b4 Mon Sep 17 00:00:00 2001 From: weichen Date: Sat, 3 Oct 2026 18:04:43 +0000 Subject: [PATCH 3/8] Pin the script host, deferred tools, and background MCP connect Why: the shared Python host and the MCP connect change landed in the libraries the product already calls. Evidence: native, squad, and backend feature commits are recorded on the task card. Impact: gitlinks move to those commits. Code orchestration stays off unless the setting is turned on. Refs: feature/code-orchestration Co-authored-by: Cursor --- .task/feature-code-orchestration.md | 6 +++--- deps/agent-native | 2 +- deps/agent-squad | 2 +- modules/backend | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.task/feature-code-orchestration.md b/.task/feature-code-orchestration.md index ab5cd663..ee907de2 100644 --- a/.task/feature-code-orchestration.md +++ b/.task/feature-code-orchestration.md @@ -21,6 +21,6 @@ ## 结果与验证(完成后填写) -- 结果: -- 验证: -- 影响与剩余项: +- 结果:native e4020d2,squad dcd523e,backend cd57276。 +- 验证:native `go test` 覆盖 codeorch、tools、mcp、policy、adapters/native。backend `go test` 覆盖 runtime、app、settings、tools、runmgr。组合验证见后续 make test。 +- 影响与剩余项:`runtime.codeOrchestration` 默认关。延迟工具不进清单。MCP 未连上时后台连接,已连上则当场注册。 diff --git a/deps/agent-native b/deps/agent-native index fb2b3b79..e4020d29 160000 --- a/deps/agent-native +++ b/deps/agent-native @@ -1 +1 @@ -Subproject commit fb2b3b796c57246306cd7384b60fb671ce371143 +Subproject commit e4020d297c168347626f9fd75456a71374a0a6c8 diff --git a/deps/agent-squad b/deps/agent-squad index a3b49e7b..dcd523ea 160000 --- a/deps/agent-squad +++ b/deps/agent-squad @@ -1 +1 @@ -Subproject commit a3b49e7b1f563b34661cec026f58eec3f135fdbd +Subproject commit dcd523ea05fe44901a6ab06e9cc8a2f0d074e0e6 diff --git a/modules/backend b/modules/backend index bead0337..cd57276f 160000 --- a/modules/backend +++ b/modules/backend @@ -1 +1 @@ -Subproject commit bead03374eb0e50de266afe5d232af511ef71159 +Subproject commit cd57276f1caa781735478ebdf9d0fe16c05f119b -- 2.54.0 From 14ddc9e342d8f136ec769840b7daa998a1caf8c5 Mon Sep 17 00:00:00 2001 From: weichen Date: Sat, 3 Oct 2026 18:06:05 +0000 Subject: [PATCH 4/8] Record the code-orchestration verification Why: the pin commit predates the full suite, and the card should name the commands that actually passed. Evidence: make test and make build exited 0 in the feature worktree. Impact: documentation only. Refs: feature/code-orchestration Co-authored-by: Cursor --- .task/feature-code-orchestration.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.task/feature-code-orchestration.md b/.task/feature-code-orchestration.md index ee907de2..84f71674 100644 --- a/.task/feature-code-orchestration.md +++ b/.task/feature-code-orchestration.md @@ -22,5 +22,5 @@ ## 结果与验证(完成后填写) - 结果:native e4020d2,squad dcd523e,backend cd57276。 -- 验证:native `go test` 覆盖 codeorch、tools、mcp、policy、adapters/native。backend `go test` 覆盖 runtime、app、settings、tools、runmgr。组合验证见后续 make test。 +- 验证:native 与 backend 相关包测试通过。`make test` 与 `make build` 通过(2026-10-03)。 - 影响与剩余项:`runtime.codeOrchestration` 默认关。延迟工具不进清单。MCP 未连上时后台连接,已连上则当场注册。 -- 2.54.0 From e352a807e5e8b1505599bcb51a69073f53eed1a8 Mon Sep 17 00:00:00 2001 From: weichen Date: Sat, 3 Oct 2026 18:06:06 +0000 Subject: [PATCH 5/8] Record the sync checkpoint --- .task/feature-code-orchestration.md | 1 + 1 file changed, 1 insertion(+) diff --git a/.task/feature-code-orchestration.md b/.task/feature-code-orchestration.md index 84f71674..08956705 100644 --- a/.task/feature-code-orchestration.md +++ b/.task/feature-code-orchestration.md @@ -24,3 +24,4 @@ - 结果:native e4020d2,squad dcd523e,backend cd57276。 - 验证:native 与 backend 相关包测试通过。`make test` 与 `make build` 通过(2026-10-03)。 - 影响与剩余项:`runtime.codeOrchestration` 默认关。延迟工具不进清单。MCP 未连上时后台连接,已连上则当场注册。 +| 同步前验收 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | 14ddc9e342d8f136ec769840b7daa998a1caf8c5 | 2026-10-03T18:06:06Z | -- 2.54.0 From bdb9452e41b737fa483af66d14569fd959011f24 Mon Sep 17 00:00:00 2001 From: weichen Date: Sat, 3 Oct 2026 18:06:07 +0000 Subject: [PATCH 6/8] Record the sync checkpoint --- .task/feature-code-orchestration.md | 1 + 1 file changed, 1 insertion(+) diff --git a/.task/feature-code-orchestration.md b/.task/feature-code-orchestration.md index 08956705..e935fcfb 100644 --- a/.task/feature-code-orchestration.md +++ b/.task/feature-code-orchestration.md @@ -25,3 +25,4 @@ - 验证:native 与 backend 相关包测试通过。`make test` 与 `make build` 通过(2026-10-03)。 - 影响与剩余项:`runtime.codeOrchestration` 默认关。延迟工具不进清单。MCP 未连上时后台连接,已连上则当场注册。 | 同步前验收 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | 14ddc9e342d8f136ec769840b7daa998a1caf8c5 | 2026-10-03T18:06:06Z | +| 同步前验收 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | e352a807e5e8b1505599bcb51a69073f53eed1a8 | 2026-10-03T18:06:07Z | -- 2.54.0 From c96580c852e91aa34943198c244e84964333618a Mon Sep 17 00:00:00 2001 From: weichen Date: Sat, 3 Oct 2026 18:06:08 +0000 Subject: [PATCH 7/8] Record the sync checkpoint --- .task/feature-code-orchestration.md | 1 + 1 file changed, 1 insertion(+) diff --git a/.task/feature-code-orchestration.md b/.task/feature-code-orchestration.md index e935fcfb..dcc40955 100644 --- a/.task/feature-code-orchestration.md +++ b/.task/feature-code-orchestration.md @@ -26,3 +26,4 @@ - 影响与剩余项:`runtime.codeOrchestration` 默认关。延迟工具不进清单。MCP 未连上时后台连接,已连上则当场注册。 | 同步前验收 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | 14ddc9e342d8f136ec769840b7daa998a1caf8c5 | 2026-10-03T18:06:06Z | | 同步前验收 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | e352a807e5e8b1505599bcb51a69073f53eed1a8 | 2026-10-03T18:06:07Z | +| 同步前验收 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | bdb9452e41b737fa483af66d14569fd959011f24 | 2026-10-03T18:06:08Z | -- 2.54.0 From d401a180f9eda683fe34fca889139b2e3e85f429 Mon Sep 17 00:00:00 2001 From: weichen Date: Sat, 3 Oct 2026 18:06:49 +0000 Subject: [PATCH 8/8] Keep the sync rows inside the task card table Why: task-sync appended the checkpoint rows after the results section, so the card no longer read as one table. Evidence: the three sync rows now sit under the existing header. Impact: documentation only. Refs: feature/code-orchestration Co-authored-by: Cursor --- .task/feature-code-orchestration.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.task/feature-code-orchestration.md b/.task/feature-code-orchestration.md index dcc40955..0b05765c 100644 --- a/.task/feature-code-orchestration.md +++ b/.task/feature-code-orchestration.md @@ -18,12 +18,12 @@ | 节点 | sync_base_sha | tested_head_sha | checked_at | |---|---|---|---| | 启动 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | 2026-10-03T17:46:51Z | +| 同步前验收 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | 14ddc9e342d8f136ec769840b7daa998a1caf8c5 | 2026-10-03T18:06:06Z | +| 同步前验收 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | e352a807e5e8b1505599bcb51a69073f53eed1a8 | 2026-10-03T18:06:07Z | +| 同步前验收 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | bdb9452e41b737fa483af66d14569fd959011f24 | 2026-10-03T18:06:08Z | ## 结果与验证(完成后填写) - 结果:native e4020d2,squad dcd523e,backend cd57276。 - 验证:native 与 backend 相关包测试通过。`make test` 与 `make build` 通过(2026-10-03)。 - 影响与剩余项:`runtime.codeOrchestration` 默认关。延迟工具不进清单。MCP 未连上时后台连接,已连上则当场注册。 -| 同步前验收 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | 14ddc9e342d8f136ec769840b7daa998a1caf8c5 | 2026-10-03T18:06:06Z | -| 同步前验收 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | e352a807e5e8b1505599bcb51a69073f53eed1a8 | 2026-10-03T18:06:07Z | -| 同步前验收 | 37a91142f2d4a91dc3e0a83296c05ee3aa0fa92e | bdb9452e41b737fa483af66d14569fd959011f24 | 2026-10-03T18:06:08Z | -- 2.54.0