Repository navigation
Conversation
- Plan: discord-acp-form-elicitation - Branch: worktree/discord-acp-form-elicitation-e627a028 - Files: .gitignore, docs/plans/discord-acp-form-elicitation.md
- Plan: discord-acp-form-elicitation - Description: ### Approved repair expansion — 2026-09-11 - Branch: worktree/discord-acp-form-elicitation-e627a028 - Files: README.md, crates/openab-core/src/acp/connection.rs, crates/openab-core/src/acp/elicitation.rs, crates/openab-core/src/acp/mod.rs, crates/openab-core/src/acp/pool.rs and 14 more
- Plan: discord-acp-form-elicitation
- Description: OpenAB initializes each Agent Runtime with `clientCapabilities: {}`. Its downstream ACP reader has one special Agent-to-Client request path: it automatically answers `session/request_permission`. Other ID-bearing messages are treated as possible responses before their `method` is considered. An Agent Runtime therefore cannot use the official ACP v1 `elicitation/create` method to pause a turn and ask Discord users for structured information. A reverse request can also collide with an OpenAB request ID and remove the wrong pending response.
- Branch: worktree/discord-acp-form-elicitation-e627a028
- Files: .wld/settings.json, crates/openab-core/src/acp/agentcore.rs, crates/openab-core/src/acp/connection.rs, crates/openab-core/src/acp/elicitation.rs, crates/openab-core/src/acp/pool.rs and 31 more
- Plan: discord-acp-form-elicitation
- Description: OpenAB initializes each Agent Runtime with `clientCapabilities: {}`. Its downstream ACP reader has one special Agent-to-Client request path: it automatically answers `session/request_permission`. Other ID-bearing messages are treated as possible responses before their `method` is considered. An Agent Runtime therefore cannot use the official ACP v1 `elicitation/create` method to pause a turn and ask Discord users for structured information. A reverse request can also collide with an OpenAB request ID and remove the wrong pending response.
- Branch: worktree/discord-acp-form-elicitation-e627a028
- Files: docs/plans/discord-acp-form-elicitation.md, docs/work-records/2026-09-14-discord-acp-form-elicitation.md
RunWield-Publication-Attempt: e627a028
RunWield-Publication-Plan-Path: docs/plans/discord-acp-form-elicitation.md
This comment has been minimized.
This comment has been minimized.
|
Important CHANGES REQUESTED What This PR DoesAdds official ACP v1 How It WorksA new platform-neutral Findings
Finding Details🔴 F1: Unrelated repository-wide reformatting violates the PR's own scope
🟡 F2: Byte-by-byte reader on a hot pathThe reader awaits a one-byte read per byte instead of buffered chunk scanning. 🟡 F3: Oversized frame remainder not drainedOn an over-limit frame the reader closes without consuming the remaining bytes. Process isolation guarantees a fresh socket today, so there is no current exploit, but any future socket reuse (connection pooling) turns this into cross-connection data corruption. 🟡 F4: Unbounded
|
|
@gandazgul Could you identify the concrete coding CLI(s) or ACP Agent Runtime(s) that currently emit official ACP v1 This feature requires support on both sides: OpenAB (the ACP client) can present the form and return one result, but the downstream ACP agent must actually initiate the To help us assess readiness, please share:
Thanks! |
|
Here is a coding agent that implements this currently: Peri agent-v3.14.5 was published on 2026-09-12. The tag The release source contains a production question-to-ACP path:
This is evidence of an emitter in released source, not proof that its release binary interoperates with OpenAB. I intend to implement this with RunWield, I will release the ACP ability soon, some parts of it are already in the code just need to finish the full support. I could run this experiment if you want?
Or I can release RunWield's support or both let me know. Thank you |
Major Coding Agents elicitation support research findings:Kimi: first-party, released supportThis is the strongest match for a vendor-owned CLI requirement.
Do not confuse the new Kimi Code CLI ( Claude: released ACP adapter around the official SDK
The release package This is concrete Claude-backed runtime support, not proof that Anthropic's standalone Codex: released ACP adapter around Codex App Server
The release README
The old Other requested vendors
|
|
Review fixes pushed:
|
|
Thanks for the detailed evidence and the review-fix round, @gandazgul. The team broadly endorses the direction. Standard ACP Before we finalize how this adapter should be written, we want to do some investigation of our own. We plan to write a small test that stands up a minimal ACP client, advertises We will produce a summary of that behavior. With that data we will have a much clearer, evidence-based picture of what the adapter needs to handle and how to shape it, rather than relying on source-level inference alone. No action needed from you right now. We will follow up here with the findings. Thanks again for the thorough work and the fixes already pushed. |
A completed form retained its coordinator slot until expire_form finished editing the Discord message. The ACP result had already been delivered, so an Agent could immediately ask its next question while the previous form still occupied the slot. OpenAB rejected that request with "elicitation already pending". In the live RunWield canary, selecting Other submitted the choice but prevented the free-text follow-up from opening, leaving the interview without an answer. Release the completed form's nonce-scoped slot before publishing its ACP response. Keep Discord message cleanup best effort after delivery, and keep failed delivery marked Expired. Remove the now-redundant attempt to expire a slot that has already been released. Unanswered concurrent forms still receive the existing busy response. Add a subprocess regression that holds Discord cleanup open while the Agent submits Other, immediately requests text, receives the typed answer, and completes the same prompt. It fails before this fix and passes after. Also cover simultaneous coordinator/presenter completion for Cancel and Decline across repeated follow-up turns in the same Session. Validation: - cargo test: 18 passed. - cargo test -p openab-core --test acp_form_elicitation: 16 passed. - cargo clippy -- -D warnings: passed. - cargo build --features unified: passed. - Updated regression file passes rustfmt; repository-wide formatting drift remains unchanged and is already documented in the PR. Refs openabdev#1533
|
An agent can request a form, receive its answer, and immediately request a follow-up form based on that answer. Live Discord testing exposed a sequencing bug: OpenAB sent the first answer before releasing the completed form’s pending slot. While Discord was still updating the first message, the follow-up request was rejected with “elicitation already pending,” even though the first form had already been answered. The fix releases the completed form’s slot before sending its response. Discord message cleanup happens afterward, so it cannot block the next question. A regression test deliberately delays Discord cleanup and verifies that a follow-up form opens and returns its answer successfully. New fix: Replies after form elicitation were appended to an earlier progress message, placing the answer above the form. OpenAB now sends the completed reply below the form as a new message, while preserving tool status updates in the earlier message. Applies to any ACP agent using forms. |
A turn keeps one streaming progress message, but elicitation presents its form as a separate later message. When the agent resumes, editing its reply into the original progress message places the answer above the form. Track whether the current ACP turn admitted a form. Keep subsequent narration out of the earlier placeholder, finalize its tool status, and send the completed reply as a new message below the form. Reset this state for the next prompt so ordinary turns retain their streaming behavior. This applies to any ACP agent using form elicitation. Add subprocess regression coverage for submit, cancel, and decline, plus a following turn without a form. The test fails with the old adapter and passes with this change. Document the delivery behavior and canary checks. Validation: 17 form integration tests and 38 adapter unit tests passed; cargo test (18 tests), cargo clippy -- -D warnings, and cargo build --features unified passed. Repository-wide cargo fmt --check still reports existing formatting drift outside this change.
|
Thanks for the substantial work here, and for running the live Claude canary — that closed the one question that was blocking this. We support the direction. Before we take on a change of this size, though, we want to be able to measure who actually benefits. The premise of the PR is that downstream agents will honor
So today: one confirmed producer (Claude), one adapter that can but whose model didn't (Codex), and the default agent that cannot (Kiro). That is a thin base for a change of this footprint. Roughly 4.5k lines of production code, most of it a Discord-only presentation layer, currently serving one backend. We'd like to proceed in a way that captures the value without committing to the whole surface on one data point:
The probe we used is a small stdio JSON-RPC client; happy to share it so the same runs can be reproduced against other adapters. |
|
Caution This PR has been waiting on the author for more than 2 days (labeled @gandazgul — You must add a new comment on this PR to remove the |
|
🔒 Auto-closing: this PR has had the If you'd like to continue working on this, please submit a new PR and link to this one if necessary. |
|
new PR #1540 I cant produce this evidence unfortunately, RunWield will find a different path. I'll continue using OpenAB anyways if I find other feature gaps I'll bring them up in Discord first. |
Discord ACP form elicitation
Summary
elicitation/createform support for Discord-backed sessions.clientCapabilities.elicitation.formonly when a Discord form presenter is available.Validation
Automated checks reported by the saved work record and prior execution:
cargo check --workspace— passed.cargo clippy --workspace -- -D warnings— passed.cargo test --workspace— passed.cargo clippy --workspace --features unified -- -D warnings— passed.cargo test --features acp— passed.cargo build --features unified— passed.cargo fmt --check— did not pass cleanly. The saved work record says repository-wide formatting diffs outside the feature path remained.cargo check --target x86_64-pc-windows-gnu— not run successfully because the Windows target standard library was not installed.No live Discord manual canary was run in this preparation step.
Review notes
gandazgul:discord-acp-form-elicitationopenabdev:mainccc334e1993980b1c88097809c158699a78af6e9Review Contract
Goal
This PR lets OpenAB act as an ACP Client that can receive official ACP v1 form elicitation requests from a downstream Agent Runtime during Discord turns. It must show bounded, progressive forms to the verified human users who contributed to the active turn, return exactly one ACP result, and leave unsupported adapters unchanged.
Non-goals
session/request_inputextension inopenab-agent.Accepted Residual Risks
cargo fmt --checkis not clean in the saved validation record because repository-wide formatting diffs remained outside the feature path. Reviewers should decide whether to require a separate formatting cleanup before merge.Acceptance Criteria
clientCapabilities.elicitation.form; unsupported sessions do not advertiseclientCapabilities.elicitationand never advertise URL elicitation.methodplus ID before outbound response correlation. Numeric and string request IDs are echoed unchanged, including same-number collisions with active OpenAB requests.session/request_inputcompatibility.Follow-ups
cargo check --target x86_64-pc-windows-gnuif cross-platform evidence is required before merge.https://discord.com/channels/1491295327620169908/1491365158868619404/1549133818089316454