MoonshotAI / MoonshotAI/kimi-code

kimi acp: AskUserQuestion has no free-text answer channel for ACP clients ("Other" option unreachable)

Open
#3,238 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
7.5k
Forks
1.2k
Avg merge
11h 53m
Merged PRs (30d)
350

Description

Summary

ACP clients currently have no way to let users answer AskUserQuestion with free text — they can only pick from the declared options. The CLI's own UI auto-adds a synthetic "Other" free-text option (the tool schema even tells the model not to add one because the system does), but that option is unreachable for ACP clients.

Details

  • session/request_permission bridge (packages/acp-server/src/question.ts): answers are accepted only when outcome.selected.optionId matches /^q{n}_opt_(\d+)$/ and indexes a declared option; anything else (including a client-invented "other" id) resolves to null = dismissed. The RequestPermissionResponse shape has no text field.
  • elicitation/create bridge (form mode): single-select answers must equal a declared label, and out-of-set multi-select values are dropped defensively.
  • The source is explicit about the gap: "The synthetic 'Other' free-text option (otherLabel) has no elicitation equivalent without an extra text field; it stays unsupported for now, matching the request_permission bridge."

Impact

ACP clients (editors, desktop shells like Zed or custom Electron clients) must render questions as closed option lists. Users who want to answer "something else" can only dismiss the question and send a separate message, losing the question context.

Suggested designs (any of)

a. In elicitation/create form mode, allow an optional per-question free-text field (e.g. allowFreeText: true on the question, and accept a text answer alongside/in place of the selected label).
b. Extend the request_permission bridge with a kimi-specific response extension carrying free text.
c. Bridge the synthetic "Other" option itself: when present, answer it via a follow-up client→agent session/prompt-style injection handled by the server.

Environment

kimi-code 0.38.0, Windows x64 native binary, custom ACP client (fs + terminal capabilities advertised).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with packages/acp-server/src/question.ts and trace both the session/request_permission and elicitation/create bridges, including their response shapes and validation of selected answers. Decide which proposed free-text design fits the ACP protocol, then verify that an ACP client can submit an answer outside the declared options without the question being dismissed.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
api, backend-api-design
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.