Repository navigation
Conversation
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
When ACP agents (such as Antigravity 1.3.0 or any ACP-compliant agent) send interactive form elicitation requests (
session/elicitationwithmode: "form") containing multi-select question items (type: "array"withitems.oneOf/items.anyOf/items.enum), T3 Code:itemsschemas or setmultiSelect: true, leaving questions unselectable as multi-choice or with empty options.allowCustomAnswer: falseon fixed option lists, allowing blank or arbitrary inputs when a fixed set of choices was required.elicitation.formclient capability in Antigravity chat sessions, causing Antigravity to fall back to permission prompt cards instead of interactive elicitation question forms.minimum/maximum, and unbounded multi-select responses on arrays withmaxItems: 1or explicit bounds.Change
elicitation?: booleantoAntigravityAcpRuntimeInputinAntigravityAcpSupport.ts.true, advertiseselicitation: { form: {} }inclientCapabilities. (Leaves it omitted for installation validation and helper probes to prevent spurious prompts in headless contexts).AntigravityAdapterV2.ts.AcpAdapterV2.ts:record?.type === "array"and setmultiSelect: true(omitted ifmaxItems === 1so UI behaves as single-select and serializes back as a 1-item array).items.oneOf/items.anyOf(const,title,description) anditems.enumto populate question options for multi-select.parseChoiceOptionsandparseEnumOptionsto upholdTrimmedNonEmptyStringcontracts.oneOf,anyOf,enum).allowCustomAnswer: falsewheneveroptions.length > 0 || record?.type === "boolean"to prevent invalid arbitrary user inputs on fixed option sets.required: truewhen field id is present inrequestedSchema.required.elicitationContent:"true"/"false"strings or arrays to native boolean).Number.isInteger(num)), rejecting floating-point values for integer fields.minimumandmaximumnumerical boundaries, omitting non-compliant values.propSchema.maxItems(rather than silently slicing) and omit answers failingminItems.requestedSchema.requiredis missing fromcontent(due to validation rejection or user omission), return{ action: "decline" }rather than{ action: "accept" }, preventing agent-side schema validation crashes.AcpAdapterV2.test.tsverifying multi-select parsing, single-select preservation, choice sanitization, whitespace preservation, schema constraints, array rejection,allowCustomAnswer: false, decline on missing required fields, and answer type coercion.AntigravityAcpSupport.test.tsverifying conditionalelicitation.formcapability negotiation.AntigravityAdapterV2.test.tsverifying Antigravity chat sessions passelicitation: trueto the ACP runtime.Stacked on PR 1 (#15746).
Closes #15743.
Side-Effects & Compatibility Analysis
elicitation: true. This prevents the agent from hanging on an elicitation request in headless operations.AntigravityAcpSupport.tsisolates capability negotiation to Antigravity. Other ACP agents (Grok, Devin, generic ACP registry providers) maintain their existing capability declarations. If a registry agent emits form elicitation,AcpAdapterV2now safely handles its schema and enforces bounds without regressions.{ action: "decline" }when required fields are missing conforms to ACP semantics and allows the agent to recover with a follow-up turn, avoiding remote JSON-RPC-32602invalid params exceptions.ComposerPendingUserInputPanel,pendingUserInput) and mobile (pendingUserInputLayout). Supports single-select radio auto-advance (200ms debounce), multi-select checkbox toggling in place, numeric keyboard shortcuts 1-9, and displacement of typed text back to composer.Scope and approval
CONTRIBUTING.md.Verification
pnpm vp test run apps/server/src/orchestration-v2/Adapters/AcpAdapterV2.test.ts -t "ACP elicitation question parsing and answer serialization"(all passed).pnpm vp test run apps/server/src/orchestration-v2/Adapters/AcpAdapterV2.test.ts(120/120 passed).pnpm vp test run apps/server/src/provider/acp/AntigravityAcpSupport.test.ts(37/37 passed).pnpm vp test run apps/server/src/orchestration-v2/Adapters/AntigravityAdapterV2.test.ts(8/8 passed).pnpm vp test run apps/server/src/provider/AntigravityInstallation.test.ts(33/33 passed).pnpm --filter @t3tools/web test src/pendingUserInput.test.ts(23/23 passed).pnpm --filter @t3tools/mobile test src/features/threads/pendingUserInputLayout.test.ts(3/3 passed).pnpm --filter t3 typecheck).