Skip to content

fix: always expose the free-text Other option in question prompts#1003

Merged
wbxl2000 merged 1 commit into
mainfrom
fix/web-question-other-option
Jun 23, 2026
Merged

fix: always expose the free-text Other option in question prompts#1003
wbxl2000 merged 1 commit into
mainfrom
fix/web-question-other-option

Conversation

@wbxl2000

Copy link
Copy Markdown
Collaborator

Related Issue

No prior issue — see Problem below.

Problem

The web version of the structured question prompt was missing the free-text "Other" option that the TUI always shows. The question adapter only set allow_other on the wire when the SDK question item carried an otherLabel / otherDescription, but the question tool never provides those fields. Web clients honor allow_other, so the free-text option silently disappeared in the web UI while the TUI (which renders it unconditionally) kept working.

What changed

Set allow_other unconditionally in the question adapter so the wire always advertises the free-text option, matching the tool's "users always have an Other option" contract and keeping web clients in sync with the TUI. Added a unit test asserting the affordance is on even when the SDK item has no otherLabel.

Checklist

  • I have read the CONTRIBUTING document.
  • I have linked a related issue, or explained the problem above.
  • I have added tests that prove my feature works.
  • Ran gen-changesets skill, or this PR needs no changeset.
  • Ran gen-docs skill, or this PR needs no doc update.

@changeset-bot

changeset-bot Bot commented Jun 23, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 918c3b5

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@moonshot-ai/kimi-code Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pkg-pr-new

pkg-pr-new Bot commented Jun 23, 2026

Copy link
Copy Markdown
pnpm dlx https://pkg.pr.new/@moonshot-ai/kimi-code@918c3b5
npx https://pkg.pr.new/@moonshot-ai/kimi-code@918c3b5

commit: 918c3b5

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 142b535e9c

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines +145 to +149
// The AskUserQuestion tool promises "users always have an Other option"
// (see tools/builtin/collaboration/ask-user.md) and the TUI unconditionally
// renders a synthetic Other item. Mirror that on the wire unconditionally so
// web / protocol clients that honor `allow_other` stay in sync — otherwise
// the free-text option silently disappears whenever the tool omits

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Keep service comments concise

packages/agent-core/src/services/AGENTS.md requires comments in this subtree to be used only for non-obvious WHY, be "one short line max", and avoid narrating the diff. The new explanatory block beginning here spans six lines and restates the behavior change; please reduce it to a short invariant comment or move the background to the PR text.

Useful? React with 👍 / 👎.

The question adapter only set allow_other on the wire when the SDK item carried an otherLabel/otherDescription, but the AskUserQuestion tool never provides those fields. Web clients honor allow_other, so the free-text option silently disappeared in the web UI while the TUI (which renders it unconditionally) kept working. Set allow_other unconditionally to match the tool's 'users always have an Other option' contract.
@wbxl2000 wbxl2000 force-pushed the fix/web-question-other-option branch from 142b535 to 918c3b5 Compare June 23, 2026 07:03
@wbxl2000

Copy link
Copy Markdown
Collaborator Author

@codex

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Hooray!

Reviewed commit: 918c3b5781

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

@wbxl2000 wbxl2000 merged commit e15edfd into main Jun 23, 2026
8 checks passed
@wbxl2000 wbxl2000 deleted the fix/web-question-other-option branch June 23, 2026 07:09
@github-actions github-actions Bot mentioned this pull request Jun 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant