Repository navigation
Description
Where it breaks. ACP registry agents (Devin among them) run on AcpAdapterV2. When one asks permission for a t3-code MCP call, acpPermissionDisposition treats it as an ordinary unclassified tool: a native card in approval-required, and a denial for persona seats (approval never, read-only sandbox), so a persona Captain cannot propose and a persona seat cannot message its Captain or write its handoff. codex-acp asks through an mcp_tool_call elicitation instead, which prompts in approval-required. Code-derived (#233).
What should change. A J5-owned apps/server/src/j5/a2a/mcp/acpToolApproval.ts allows exactly j5PreapprovedTools(policy), and only for a call whose t3-code identity it can prove. The identity is looked up by toolCallId in the adapter's merged tool-call state, so a sparse permission request still resolves; the codex-acp elicitation is linked through its mcp_tool_call_approval_<execId> request id. Two lists:
- Tier 1, structured identity:
_meta.is_mcp_tool_callwithrawInput.server"t3-code" andrawInput.tool(codex-acp);_meta.serverId"t3-code" with_meta.toolName(qwen). - Tier 2, exact namespaced names, matched against the title,
_meta.toolName, or_meta.claudeCode.toolName: ~~t3-code_<t>(Kilo, opencode), ~~mcp__t3-code__<t>(claude-acp),mcp__t3_code__<t>(Amp),t3-code___<t>(droid),.t3-code-<t>(Copilot),,<t> (t3-code MCP Server)(Gemini CLI)<t>_t3-code(Auggie)
Never matched: bare tool names, the acp-mcp-call command fallback, a foreign server id, and edit/delete/move calls; execute only under tier 1. Anything unmatched keeps today's verdict. Two one-line ?? prefixes in AcpAdapterV2.ts (permission handler and elicitation handler) consult the J5 module first, recorded as one FORK.md case.
Tests to ship. Pure-function parity across the shared policy matrix plus the persona policy; tier 1 from the existing codex-acp and qwen fixtures as merged state against a sparse request; one fixture per tier 2 form. Negatives: a bare name with and without is_mcp_tool_call, rm -rf x; acp-mcp-call send_message, send_message on a foreign serverId, an execute call with a tier 2 name, and a non-J5 t3-code tool. One adapter-level test per hook.
Done when. On codex-acp, qwen, claude-acp, ~~Kilo, opencode, ~~Amp, droid, Copilot, , a Captain's Gemini CLI, and Auggiepropose_crew reaches the roster gate without an extra card in every runtime mode and persona seats can coordinate. docs/user/personas.md drops those agents from the harnesses that still prompt and keeps the ACP agents that match no form (for example glm and Kimi, which use bare names).
Part of #233.
Edit (2026-09-24): tier 2 narrowed and the approval rules hardened
Tier 2 uses only the four forms that another server cannot produce: mcp__t3-code__<t> (claude-acp), t3-code___<t> (droid), <t> (t3-code MCP Server) (Gemini CLI), and mcp__t3_code__<t> (Amp).t3-code_<t>, t3-code-<t>, and <t>_t3-code are ambiguous, because J5 tool names contain single underscores (a server named t3-code_send with a tool message also produces t3-code_send_message). They stay unmatched, so Kilo, opencode-acp, Copilot, and Auggie stay on the still-prompts list in docs/user/personas.md.
Rules the change must hold to, after review found an approval bypass in an earlier draft:
- Identity comes only from the tool_call state the harness already sent for that
toolCallId. The permission request may confirm it (same tool and kind) but never add to it; with no prior state there is no match. - Any server-identifying field that names a server other than t3-code means no match, even when a title form matches.
- The J5 hook answers with a one-time allow only, never
allow_alwaysor any persisting option. With no one-time option offered, the existing policy decides. - Tier 2 never matches execute, edit, delete, or move; execute only under tier 1.
- The hooks sit at the call sites in
AcpAdapterV2.ts;AcpClientPolicy.tsis untouched. - Negative tests: a kind
otherrequest with a J5 title andallow_alwaysand no prior state; prior state for tool A with a request for tool B; an offer of onlyallow_always; a kind mismatch; a matching title with a foreign_meta.serverId; and each of the three ambiguous collisions.
Done when codex-acp, qwen (tier 1) and claude-acp, droid, Gemini CLI, Amp (tier 2) reach the roster gate without an extra card in every runtime mode.
Edit (2026-09-24): no title matching
Some ACP harnesses write model text into tool-call titles (pi-acp puts the shell command there; cline and Kimi append raw arguments), so a model can title an unrelated operation mcp__t3-code__propose_crew. Nothing at permission time proves a call came from T3's server, because the bridge only sees a call after it is approved. So no title form is matched, in either the request or the earlier tool_call state.
Identity comes only from structured fields the harness fills from its own MCP dispatch: rawInput.server / rawInput.tool with _meta.is_mcp_tool_call (codex-acp), _meta.serverId / _meta.toolName with the mcp::t3-code:: prefix (qwen), and _meta.claudeCode.toolName as mcp__t3-code__<t> (claude-acp). Every identity field present, in the earlier state and the request, must agree on server t3-code and the same tool. The matcher runs over the existing Grok and Antigravity fixtures in the tests and must not match them.
Done when codex-acp, qwen, and claude-acp reach the roster gate without an extra card in every runtime mode and persona seats on them can coordinate. droid, Gemini CLI, Amp, Kilo, opencode-acp, Copilot, Auggie, glm, Kimi, Grok, and Antigravity stay on the still-prompts list in docs/user/personas.md.
Activity
Jacksondr5 commentedon Sep 26, 2026
Closing as not planned per Jackson's ruling on #233 (2026-09-26). J5 pre-approves its tools only on Codex and Claude. Other harnesses may show their own MCP prompt once before the roster card, and making them skip it is upstream adapter work. The general fix is tracked for upstream give-back in #276.