Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(acp): accept SDK elicitation requests #11294

Mergedshivamhwp(GitHub profile, opens in a new tab)merged 1 commit intomain fromrefs/pull/11294/headmerged by juliusmarminge View on GitHub

Rebased onto main, which includes the device-ticket correction from #11304. This PR changes only ACP behavior.

ACP agents using elicitation/create receive "Method not found" even when T3 has a registered question handler. The shared client now accepts that SDK method and returns its flat action and content response. It also routes elicitation/complete to the existing completion handler.

The legacy session/elicitation methods retain their nested response format. Compatibility lives beside the RPC definitions because the generated schema is pinned to v0.11.3. Providers still supply their own question handler; missing handlers and malformed requests return protocol errors.

Closes #9048. This fixes the SDK method-name and response-shape mismatch reported in that issue. #10893 carries an Oh My Pi-specific workaround; adding that provider is separate. The adapter-facing generated types remain compatible, and this change covers session-scoped form and URL requests.

Validation: 44 focused client, agent, protocol and server-runtime tests pass, including flat accept/decline/cancel results, metadata, both notification names, malformed requests and legacy exchanges. A separate exchange with the official @agentclientprotocol/sdk 1.4.0 passes: its AgentSideConnection.createElicitation receives the accepted answer, and completeElicitation reaches T3's completion handler. Package and server typechecks and scoped lint pass. No live Oh My Pi process or native client UI was exercised.

Model: GPT-6. Harness: Codex in T3 Code.

Rebased on main 20363c32c9bfdbf49c2716ef11d1f18483fcc01b. Scoped validation rerun after rebasing; existing native and human review limits remain.

    1. Bugbot is paused — on-demand spend limit reached

      Bugbot uses usage-based billing for this team and has hit its on-demand spend limit.

      A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue.

    2. github-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:trusted

    3. github-actions[bot](GitHub profile, opens in a new tab)commented

      Thread transfer impact

      ✅ Thread transfer remains within every enforced ceiling.

      ProviderMetricMain baselineThis PRImpactPR ceiling
      CodexTotal thread wire13.5 KiB13.5 KiB+21 B (+0.2%)15.1 KiB✅
      CodexThread snapshot wire7.1 KiB7.0 KiB−9 B (−0.1%)7.3 KiB✅
      CodexLive turn WebSocket wire6.4 KiB6.5 KiB+30 B (+0.5%)7.8 KiB✅
      CodexLive turn WebSocket decoded56.2 KiB56.3 KiB+44 B (+0.1%)66.4 KiB✅
      CodexLive turn messages910+1 (+11.1%)21✅
      ClaudeTotal thread wire13.5 KiB13.5 KiB+11 B (+0.1%)15.1 KiB✅
      ClaudeThread snapshot wire7.1 KiB7.1 KiB+1 B (+0.0%)7.3 KiB✅
      ClaudeLive turn WebSocket wire6.4 KiB6.4 KiB+10 B (+0.2%)7.8 KiB✅
      ClaudeLive turn WebSocket decoded57.0 KiB57.0 KiB0 B (0.0%)66.4 KiB✅
      ClaudeLive turn messages990 (0.0%)21✅

      Baseline: 8c3b5be · PR result: 17e6023 · Source CI: success

      Scenario and decoded snapshot size

      10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.

      • Codex decoded thread snapshot: 113.9 KiB
      • Claude decoded thread snapshot: 114.6 KiB

      Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed.

    4. coderabbitai[bot](GitHub profile, opens in a new tab)commented
      Review Change StackReview Change Stack

      No actionable comments were generated in the recent review. 🎉

      ℹ️ Recent review info
      ⚙️ Run configuration

      Configuration used: Path: .coderabbit.yaml

      Review profile: CHILL

      Plan: Advanced

      Run ID: a26dddfd-9f91-474f-b7e0-17c5be56e48c

      📥 Commits

      Reviewing files that changed from the base of the PR and between e1c94f703f05b43f2935d09ed1ef882d0ee13ff8 and 44f78f2bbda39b47648d71bc926222357393cac7.

      📒 Files selected for processing (4)
      • packages/effect-acp/src/client.test.ts
      • packages/effect-acp/src/client.ts
      • packages/effect-acp/src/protocol.ts
      • packages/effect-acp/src/rpc.ts

      Included review availability: Your plan provides up to 10 included reviews per hour; 7 remain after this review.


      📝 Walkthrough

      Walkthrough

      Adds "elicitation/create" RPC support and accepts "elicitation/complete" notifications. The client shares elicitation handling across method aliases and validates payloads, response shapes, URL mode, malformed requests, and missing handlers.

      Changes

      Elicitation support

      Layer / File(s)Summary
      Elicitation RPC contract
      packages/effect-acp/src/rpc.ts
      Defines and registers CreateElicitationRpc with compatible request, success, and error schemas.
      Client request routing
      packages/effect-acp/src/client.ts
      Decodes "elicitation/create" requests, maps invalid payloads to protocol errors, and invokes the shared elicitation handler.
      Notification aliases and validation
      packages/effect-acp/src/protocol.ts, packages/effect-acp/src/client.test.ts
      Accepts both completion notification methods and tests response shapes, URL mode, validation failures, and missing handlers.

      Priority: ⬇️ Low

      Estimated code review effort: 3 (Moderate) | ~25 minutes

      Change: Bug fix

      Sequence Diagram(s)

      sequenceDiagram
        participant CreateElicitationRpc
        participant decodeElicitationRequest
        participant coreHandlers.elicitation
        CreateElicitationRpc->>decodeElicitationRequest: Decode request payload
        decodeElicitationRequest-->>CreateElicitationRpc: Return decoded request
        CreateElicitationRpc->>coreHandlers.elicitation: Handle elicitation
        coreHandlers.elicitation-->>CreateElicitationRpc: Return action and optional _meta

      Suggested reviewers: juliusmarminge

      Merge Risk: ⚪ Minimal · up to 44f78

      No actionable merge-blocking risk remains.

      🚥 Pre-merge checks | ✅ 5
      ✅ Passed checks (5 passed)
      Check nameStatusExplanation
      Docstring Coverage✅ PassedNo functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 4…
      Linked Issues check✅ PassedCheck skipped because no linked issues were found for this pull request.
      Out of Scope Changes check✅ PassedCheck skipped because no linked issues were found for this pull request.
      Title check✅ PassedThe title clearly summarizes the main change: enabling the ACP client to accept SDK elicitation requests.
      Description check✅ PassedThe description explains what changed, why it changed, compatibility behavior, validation results, and testing limits. It does not use the template headings or include the checklist, but the required …
      ✨ Finishing Touches 💡 1
      🛠️ Fix failing CI checks 💡
      • Create stacked PR
      • Commit on current branch
      📝 Generate docstrings
      • Create stacked PR
      • Commit on current branch
      🧪 Generate unit tests (beta)
      • Create PR with unit tests
      • Commit unit tests in branch `fix/acp-elicitation-compat`

      Comment `@coderabbitai help` to get the list of available commands.
    5. macroscopeapp[bot](GitHub profile, opens in a new tab)commented

      Approvability

      Verdict: Approved at 226856b

      Macroscope's review found this PR approvable — This is a localized ACP interoperability fix that routes SDK elicitation aliases through existing handlers while preserving legacy exchanges. The new wire translations and notification handling are covered by focused tests, with no product-default, deployment, security, billing, or static-analysis changes.

      Notes:

      • Diff unchanged. Approvability was decided on eligibility alone.

      No code changes detected at 17e6023. Prior analysis still applies.

      You can add or adjust custom eligibility rules. [Learn more](https://docs.macroscope.com/approvability#example-custom-eligibility-rules).
    6. Bugbot is paused — on-demand spend limit reached

      Bugbot uses usage-based billing for this team and has hit its on-demand spend limit.

      A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue.

    7. github-actions[bot](GitHub profile, opens in a new tab) added labels📱 Native Change

    8. juliusmarminge merged thisde6a230

    9. juliusmarminge closed this

Sign in to join this conversation.