From 34f6f28716eb307cabc23a9e8bc0d8b0a94be9c7 Mon Sep 17 00:00:00 2001 From: Tianyi Cui <53024+tianyicui@users.noreply.github.com> Date: Mon, 22 Jun 2026 17:00:59 +0800 Subject: [PATCH] Make fork reachable by the model in the acp-agent demo (review feedback) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The acp-agent cordis configs loaded the fork backend but bound only one dsh-tool-subagent (to spawn), so the comment's claim that a multi-child scenario could exercise both transports was false — fork was loaded but unreachable by the model. Register a second dsh-tool-subagent bound to fork with a distinct toolName (subagent_fork), matching the coding-agent demo, in both cordis.yml (record/demo) and cordis.snapshot.yml (replay). Snapshot goldens are unchanged (the transcript does not capture the available-tool list). --- examples/acp-agent/cordis.snapshot.yml | 13 +++++++++++-- examples/acp-agent/cordis.yml | 17 +++++++++++++---- 2 files changed, 24 insertions(+), 6 deletions(-) diff --git a/examples/acp-agent/cordis.snapshot.yml b/examples/acp-agent/cordis.snapshot.yml index 5bee10f2a7..5f36a11efa 100644 --- a/examples/acp-agent/cordis.snapshot.yml +++ b/examples/acp-agent/cordis.snapshot.yml @@ -42,8 +42,10 @@ a fresh child agent (it works in its own context and returns only its final result) — give it a complete, standalone instruction. -# The subagent seam + both in-process backends + the model-facing `subagent` -# tool — identical to cordis.yml's wiring (only the LLM backend differs above). +# The subagent seam + both in-process backends + two model-facing tools — +# identical to cordis.yml's wiring (only the LLM backend differs above): spawn +# and fork are each reachable via a dsh-tool-subagent bound to it with a distinct +# toolName (subagent → spawn, subagent_fork → fork). - id: subagent name: '@deepseek-ai/dsh-subagent' @@ -61,3 +63,10 @@ name: '@deepseek-ai/dsh-tool-subagent' config: provider: spawn + toolName: subagent + +- id: tool-subagent-fork + name: '@deepseek-ai/dsh-tool-subagent' + config: + provider: fork + toolName: subagent_fork diff --git a/examples/acp-agent/cordis.yml b/examples/acp-agent/cordis.yml index e00e868dce..a00d0e6036 100644 --- a/examples/acp-agent/cordis.yml +++ b/examples/acp-agent/cordis.yml @@ -51,10 +51,12 @@ a fresh child agent (it works in its own context and returns only its final result) — give it a complete, standalone instruction. -# The subagent seam + both in-process backends + the model-facing `subagent` -# tool, as leaf entries after the app (which provides ctx.agents/ctx.tools). The -# tool is bound to the `spawn` backend (a fresh child); the `fork` backend is -# loaded too so a multi-child scenario can exercise both transports. +# The subagent seam + both in-process backends + two model-facing tools, as leaf +# entries after the app (which provides ctx.agents/ctx.tools). spawn (a fresh +# child) and fork (a child seeded with the parent's completed-turn prefix) are +# both reachable by the model: dsh-tool-subagent is loaded once per backend with +# a distinct toolName (subagent → spawn, subagent_fork → fork), so a multi-child +# scenario can exercise both transports. - id: subagent name: '@deepseek-ai/dsh-subagent' @@ -72,3 +74,10 @@ name: '@deepseek-ai/dsh-tool-subagent' config: provider: spawn + toolName: subagent + +- id: tool-subagent-fork + name: '@deepseek-ai/dsh-tool-subagent' + config: + provider: fork + toolName: subagent_fork