[Feature]: CLI - ACP: queue session/prompt while a turn is running instead of rejecting it with -32603
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 54/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
- 技术栈
- typescript
调研方向
Start by tracing the mcode acp handler for session/prompt and the existing TUI and ACP queue paths; inspect the queue extension methods and their tests. Reproduce a prompt arriving during an active turn, then verify the selected behavior: the message is delivered once after the turn and its response tracks that queued turn, or the error names the callable queue method. Check that queued messages remain visible through mcode/session/queue/list and removable with mcode/session/queue/delete.
由索引模型根据 Issue 内容生成。
描述
Product or interface
CLI - ACP
Use case and problem
A third-party ACP client that talks to mcode acp cannot steer a running turn. When it sends session/prompt while a turn is still active, the ACP adapter rejects it:
Internal error: MiniMax Code Runtime failed: Session already has an active Turn. Use queue send to deliver the message after it.
This happens in practice whenever a background message has to reach a session that is busy — for example a parent agent that is notified that its subagent finished while the parent's own turn is still running. The message is not queued and not delivered: it fails.
The agent already has the machinery for this. The TUI queues messages typed during a run, and the ACP adapter exposes the same capability as a vendor extension:
"_meta": { "minimax-code/extensions": { "methods": [
"mcode/session/steer",
"mcode/session/queue/list", "mcode/session/queue/enqueue",
"mcode/session/queue/update", "mcode/session/queue/delete", "mcode/session/queue/steer"
] } }
But the error message only says "Use queue send" without naming the method, and the ACP protocol has no standard way to advertise steering or queueing — the promptCapabilities object in the ACP schema only carries image, audio and embeddedContext, so initialize cannot tell a generic client that steering exists. A generic client therefore has to read the vendor _meta block and guess the method name, and most clients do not.
Desired behavior
Either of these would make mcode acp usable from generic ACP clients:
session/promptreceived while a turn is running is queued and delivered once the running turn finishes, with thesession/promptresponse returned when the queued turn actually runs — the same behaviour the TUI already has. This is the interoperable option, since a client that cannot know about a vendor extension cannot use it.- The error names the exact method to call, e.g.
Session already has an active Turn. Call mcode/session/queue/enqueue to deliver the message after it.— at minimum, the error should carry the method name so a client can recover without reading the source.
Acceptance criteria:
- A
session/promptthat arrives during a running turn is either queued or rejected with an error that names the callable extension method. It is never silently dropped. - With option 1, the message is delivered exactly once, after the running turn, and the
session/promptresponse corresponds to the queued turn. - Queued messages are visible through
mcode/session/queue/listand can be removed withmcode/session/queue/delete, consistent with the existing extension contract.
Platform
Multiple platforms
Alternatives and additional context
- Steering via
mcode/session/steerworks for clients that read the vendor extension, but the ACP schema itself has no capability to advertise it, so clients have to hard-code provider-specific knowledge. - The client side of this problem is tracked in the Paseo repository: https://github.com/getpaseo/paseo/issues/8300 and https://github.com/getpaseo/paseo/discussions/8301 — they are looking at queuing messages on the client side, but a client-side queue cannot be applied when the client is not the one that owns the turn.
- Related open issues in this repository: #295 (parallel queued tasks in the interactive TUI), #335 (separating mid-run steer/queue messages in Goal mode). This request is about the ACP surface specifically, not the TUI.
- 主要语言
- TypeScript
- 星标
- 2.1k
- 派生
- 271
- 平均合并
- 15 小时 10 分钟
- 30 天内合并 PR
- 34
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
MiniMax-AI/minimax-code 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 76/100
MiniMax-AI/minimax-code#556 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
MiniMax-AI/minimax-code#507 ·
维护者通常 1 天内回复
-
bug needs-triage tui
难度 2/5 1-3 小时 新手友好度 72/100
MiniMax-AI/minimax-code#481 · 1 条评论 ·
维护者通常 1 天内回复
-
bug cli documentation needs-triage
难度 2/5 1-3 小时 新手友好度 84/100
MiniMax-AI/minimax-code#299 · 3 条评论 ·
维护者通常 1 天内回复
-
难度 4/5 3-5 天 新手友好度 25/100
MiniMax-AI/minimax-code#570 ·
维护者通常 1 天内回复
查看 MiniMax-AI/minimax-code 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 76/100
Northeastern-Electric-Racing/FinishLine#4660 ·
维护者通常 2 天内回复
-
难度 2/5 1-3 小时 新手友好度 86/100
excaliburjs/Excalibur#3895 ·
维护者通常 3 天内回复
-
infer_audio_type only recognises one MPEG Layer III frame header, so most MP3 files are rejected可能已有人在做 @Steve-20-ai 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
Earn report crashes with "RangeError: Invalid time value" when a report row has an unparsable timestamp可能已有人在做 @Gurkaran18 今天认领。 未关闭bug
难度 2/5 1-3 小时 新手友好度 75/100
joinmarket-webui/jam#1588 ·
维护者通常 3 天内回复
-
难度 2/5 1-3 小时 新手友好度 72/100
mihaip/infinite-mac#475 ·