Repository navigation
fix(cli): surface stacked-skill overflow in non-interactive and ACP runs - #16404
Conversation
`parseStackedSlashCommands` already reports `exceededMax`, and the two interactive surfaces warn about it. The non-interactive path (`handleSlashCommand`) ignored the flag, so headless (`-p`, JSON, stream-JSON) and daemon/ACP runs silently dropped the extra `/skill` tokens with no signal at all. - carry the flag out of the stacked branch as `stackedSkillOverflow` on the `submit_prompt` result, using the same copy as the interactive surfaces; - headless writes it to stderr, so it never becomes a `message` of type `error` and the run keeps its exit code; - ACP emits it as a client-visible slash-command notice before the prompt runs. Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com> Patrol-Run: qwen-issue-patrol/jmw3ofzhmya
|
Re-run at Template ✓ — every required heading is filled in, the Tested-on table is honest about what was not run, and the Chinese half is a real translation rather than a stub. Problem: observed, and now independently measured. #16396 is open with Direction: aligned. It makes headless, ACP and channel runs report what the TUI already reports — a consistency fix inside the CLI's own surface, no new configurability, no mission drift. There is no upstream CHANGELOG signal to weigh: Duplicate check (1-pre): nothing to flag. The body says Size: 105 production lines (100 added, 5 deleted) across 8 files, 706 test lines across 6 files, no generated or schema files. The change does span packages ( Approach: the 3.6x growth is not scope creep, and I want to say that plainly because it is the first thing a reviewer will notice. The narrow CLI-only version was measured and found not to reach channel users — the audience #16396 actually names — because the notice landed in the slash-command slot that model text shadows, and then in a buffer that every response boundary wipes. The extra ~79 production lines are the delivery path, i.e. the part the issue complains about. One question I would still ask, non-blocking and already on round 6's deferred list: the notice is composed into Risk: Stage 1e matches one high-risk path — Moving on to code review. 🔍 中文说明在 模板完整 ✓ —— 所有必填小节都写了,测试平台表格如实标注了未运行的部分,中文部分是真正的翻译而非占位。 问题: 已观测到,并且已有独立实测。#16396 处于 open 且带 方向: 对齐。它让 headless、ACP 与渠道运行报告 TUI 早就报告的信息——属于 CLI 自身界面内的一致性修复,没有新增可配置项,也没有偏离主线。上游 CHANGELOG 无信号可参考: 重复检查(1-pre): 无需标记。正文写的是 规模: 生产代码 105 行(新增 100、删除 5),分布在 8 个文件;测试 706 行,分布在 6 个文件;无生成文件或 schema 文件。改动确实跨包( 方案: 这次 3.6 倍的增长不是范围蔓延,我想明确说明,因为这是审查者第一眼会注意到的事。最初仅改 CLI 的版本经过实测,被发现根本触达不了渠道用户——也就是 #16396 真正点名的受众——因为通知落在了会被模型正文遮蔽的 slash-command 槽位,随后又被每次响应边界清空的缓冲区吃掉。多出的约 79 行生产代码正是投递路径,即 issue 抱怨的那部分。我仍想提一个问题(非阻塞,且已在第 6 轮的延后清单里):通知先被拼进 风险: Stage 1e 命中一个高风险路径—— 进入代码审查 🔍 — Qwen Code · qwen3.8-max-2026-09-02 Reviewed at |
|
Code review at Verified fixed since the last gate passI checked these against the head rather than taking the resolved threads on faith:
Standing items — recorded, not requestedThis PR is at review round 6, so under the repo's convergence posture I am listing these rather than asking for them. None blocks the merge.
Two smaller notes, no action needed: the loop/unattended turn path ( FlowsequenceDiagram
participant P0 as User
participant P1 as nonInteractiveCliCommands
participant P2 as nonInteractiveCli headless
participant P3 as ACP Session
participant P4 as Channel bridge Acp or Daemon
participant P5 as ChannelBase inbound turn
participant P6 as Adapter qqbot dingtalk etc
P0->>P1: prompt stacking six skill tokens
P1-->>P2: submit_prompt plus stackedSkillOverflow
P2->>P2: write the warning to stderr
P1-->>P3: submit_prompt plus stackedSkillOverflow
P3->>P4: agent_message_chunk tagged as a turn notice
P4->>P4: keep the notice in its own buffer
Note over P4: response boundaries clear text chunks only
P4-->>P5: prompt returns notice then blank line then body
P5->>P6: answer first, via onResponseComplete
P5->>P6: notice second, via sendResponseMessage
Files changed (14)
Test evidence — this PR's own CI, read via the APIThis is an unattended run ( Every check on One correction to earlier rounds:
What CI proves here is that the PR's tests pass. It cannot prove they pin the change, and on two points the behavioural claim currently rests on the author's word or on fakes. The author's local report claims 1,424 targeted tests at this head — that is the author's claim, attributed as such, not evidence I re-ran. Sandboxed verification would settle this: 中文说明在 已确认修复(对照当前提交核验,不是采信线程状态):
遗留项——仅记录,不要求修改(本 PR 已到第 6 轮,按仓库的收敛姿态只落地 Critical,以下均不阻塞合并):
另两点小说明,无需处理:loop/无人值守轮次路径( 测试证据(本节携带的是什么): 这是无人值守运行( CI 能证明的是本 PR 的测试通过,不能证明这些测试钉住了改动。沙箱验证可以补上这一段: — Qwen Code · qwen3.8-max-2026-09-02 Reviewed at |
|
Confidence: 4/5 — the one Critical this PR ever had is verifiably fixed at this head, CI is fully green and settled, and everything still open is a Suggestion already recorded in round 6. Not 5/5 because two of those Suggestions sit on the seam I would eventually want hardened, and because the channel breadth is asserted by fakes rather than measured. My independent proposal was the same shape as this change, so there is no simpler path I am withholding. What I want to be honest about is the growth, because it is the thing that should make a reviewer hesitate: 4 files and 26 production lines at the head I last gated, now 14 files and 105, across six review rounds. I checked whether that is the ratchet our convergence rule exists to stop, and it is not. Each expansion was driven by a measurement showing the previous scope did not reach the audience #16396 names — first the notice landing in a slot that model text shadows, then it being wiped by every response boundary, then QQ losing it once output had streamed or a previous send was still in flight. Shipping the original 26 lines would have made the issue's headline case (a channel user stacking six skills) still silent. That is scope following evidence, not scope drifting. On the "am I being worn down by volume" question: I re-verified the Critical fix against the head instead of trusting the nine resolved threads, and I re-derived the deferred findings rather than repeating them. Two of them changed under inspection — round 6's DingTalk mention finding reads as if the main path were affected, and it is not (the answer consumes the single-use mention first; only the card early-return path leaves it for the notice), and the If I had to maintain this in six months, the part I would want changed is finding 2. One buffer, one exported wire key, and a composition rule documented on the event itself is all fine; the strip in Verdict: approve. Nothing is pending — 0 One mechanical note for whoever merges: the PR's 中文说明Confidence: 4/5 —— 本 PR 历史上唯一的 Critical 在当前提交上已被可核验地修复,CI 全绿且已跑完,剩下未结的全部是第 6 轮已记录在案的 Suggestion。没给到 5/5,是因为其中两条正落在我最终希望加固的那道接缝上,也是因为渠道覆盖面是靠替身断言的,而非实测。 我独立想到的方案与本次改动形态一致,所以我没有更简的路径藏着不说。我想坦诚讲的是它的体量增长,因为这才是让审查者应该犹豫的地方:我上次门禁时是 4 个文件、26 行生产代码,现在是 14 个文件、105 行,中间经过 6 轮审查。我核查过这是否正是收敛规则要阻止的滚雪球——不是。每一次扩张都由一次实测驱动,说明此前的范围没有触达 #16396 点名的受众:先是通知落在会被模型正文遮蔽的槽位,接着被每次响应边界清空,然后是 QQ 在正文已流式发出、或上一轮发送仍在途时丢掉它。若按最初那 26 行合并,issue 标题所述的场景(渠道用户堆叠六个 skill)仍然是静默的。这是范围跟随证据,不是范围漂移。 关于「我是不是被数量磨软了」:我是拿当前提交重新核验那个 Critical 的修复,而不是采信 9 条已 resolved 的线程;那些延后的发现我也是重新推导而非照搬。其中两条在核查后发生了变化——第 6 轮的钉钉 @ 发现读起来像主路径受影响,实际不是(单次使用的 @ 目标先被答案消费,只有卡片提前返回的路径才把它留给通知);另外两轮把 如果六个月后由我维护,我最想改的是第 2 条。一个缓冲区、一个导出的线缆键、以及写在事件本身上的拼接规则,这些都没问题; 结论:批准。没有待完成项—— 给合并者的一条机制性提示:本轮开始前 PR 的 — Qwen Code · qwen3.8-max-2026-09-02 Reviewed at |
qwen-code-review-bot
left a comment
There was a problem hiding this comment.
LGTM, looks ready to ship — CI landed green after the review. ✅
qwen-code-review-bot
left a comment
There was a problem hiding this comment.
Test Plan (not a blocker): Tests 116 passed — this review observed 40998, 355 passed; 75 passed — this review observed 40998, 355 passed; 7 passed — this review observed 40998, 355 passed.
中文说明
Test Plan(非阻断):Tests 116 passed — this review observed 40998, 355 passed; 75 passed — this review observed 40998, 355 passed; 7 passed — this review observed 40998, 355 passed。
— deepseek-v4.1-flash-1017 via Qwen Code /review (v0.26.7)
|
Local verification: PASS
Causal evidence (headless, arm-by-arm): ACP evidence: the after arm answered Controls and boundaries:
Relevant gates: local runs only ( Local verdict is not a merge approval. 中文版(可展开)本地验证:PASS(merge-reference,基线取 merge-base
关键结论:
边界:只覆盖 headless
|
…reply Channel bridges deliver only prompt()'s resolved text, so the overflow notice emitted on the slash-command channel was shadowed as soon as the turn produced model text and channel users never saw the warning. Tag the notice in `_meta` and route it into the turn's text in both bridges. Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com> Patrol-Run: qwen-pr-closeout/jmw3tg0yrfb
qwen-code-review-bot
left a comment
There was a problem hiding this comment.
Test Plan (not a blocker): Tests 116 passed — this review observed 389, 41167, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 355, 14829 passed; 75 passed — this review observed 389, 41167, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 355, 14829 passed; 7 passed — this review observed 389, 41167, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 355, 14829 passed.
中文说明
Test Plan(非阻断):Tests 116 passed — this review observed 389, 41167, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 355, 14829 passed; 75 passed — this review observed 389, 41167, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 355, 14829 passed; 7 passed — this review observed 389, 41167, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 355, 14829 passed。
— deepseek-v4.1-flash-1017 via Qwen Code /review (v0.26.8)
|
Local verification: PASS
Causal evidence (headless, arm by arm, stderr of the real Channel-consumer evidence (each arm's own built That return value is what a channel adapter sends to the chat, so row 6 is observed at the consumer boundary rather than inferred from the ACP frame. Controls and boundaries:
Relevant gates: local runs only ( Local verdict is not a merge approval. 中文版(可展开)本地验证:PASS(merge-reference,基线取 merge-base 本轮针对新 head
关键结论:
边界:未在本机跑通 |
Deep verification: PR #16404 — stacked-skill overflowVerdict: 中文摘要(点击展开)结论: 阻塞项(确认已有评审 R1-1,不是本轮新发现): 通知仍然被 作者当前 head 的 PASS 不能清除 R1-1: 评论 6667724564 的第 6 行只跑了「模型先返回文本」的形状,没有驱动工具调用;它证明的是文本优先形状,不是 覆盖缺口(确认 R2-1): 变异矩阵中删除 未覆盖: 真实 Full verification report (English)Carried-forward findings at this head
Central claim and A/BThe central claim: a non-interactive run that stacks more than five Both arms were built from the same lockfile (the PR changes no
Witnesses: Corrections
FindingsF1 (Critical, confirms R1-1): the turn notice is still dropped whenever the turn crosses a response boundary, and in
|
| Shape | Expected | Measured |
|---|---|---|
| control: notice → model text (no boundary) | Only the first 5 skills were loaded.\n\nModel text |
same — PASS (this is the PR's own added test) |
AcpBridge: notice → tool_call(pending) → model text |
notice + Model text |
Model text |
AcpBridge: notice → per_task result |
notice + Task done |
Task done |
DaemonChannelBridge: notice → tool_call(pending) → model text |
notice + Model text |
Model text |
Witness: 04-channel-boundary.png.
Blast radius: both bridges (AcpBridge.ts:681, DaemonChannelBridge.ts:1225) and every boundary source (tool_call pending/in_progress, plan, permission request). In the 10 production channel packages, only dingtalk, feishu, and qqbot override onResponseChunk; the other seven (telegram, wecom, weixin, email, github, gitlab, dws) inherit the no-op default and deliver only onResponseComplete's response text — for them the notice is completely absent in this shape. Adapters with a streaming hook may still show the notice in the transient segment; the final reply text still loses it.
This is not a new finding: review R1-1 at this head predicted the same mechanism and named the same two loss paths. The round's contribution is an independent reproduction with the two shapes the PR's tests omit, and the fact that the author's current-head PASS covers only the text-first shape. R1-1's suggested independent notice buffer was not applied or measured in this round.
F2 (Suggestion, confirms R2-1): the consumer sinks have no committed test
The mutation matrix below reverts one production hunk at a time in the head tree (byte backup, restore, clean-tree assertion) and runs the selected suite:
| Row | Hunk | Suite | Expected | Observed |
|---|---|---|---|---|
| M1 | remove the stackedSkillOverflow field from the producer |
nonInteractiveCliCommands.test.ts |
killed | killed (1 failed / 75 passed) |
| M2 | remove the headless stderr write | nonInteractiveCli.test.ts |
survived | survived (272 passed, 1 skipped) |
| M3 | remove the ACP emitSlashCommandOutput block |
Session.test.ts -t 'slash' |
survived | survived (11 passed, 1400 skipped) |
| M4 | remove the turnNotice branch in AcpBridge |
AcpBridge.test.ts |
killed | killed (1 failed / 91 passed) |
| M5 | remove the turnNotice branch in DaemonChannelBridge |
DaemonChannelBridge.test.ts |
killed | killed (1 failed / 130 passed) |
| M6 | drop the { turnNotice: true } metadata |
Session.test.ts -t 'slash' |
survived | survived (11 passed, 1400 skipped) |
Witness: 03-mutation-matrix.png. The census agrees: grep over all test files finds stackedSkillOverflow only in the producer test, and turnNotice only in the two bridge tests; nonInteractiveCli.test.ts and Session.test.ts never mention the overflow. These are coverage gaps, not behavior defects — the A/B and ACP probes above prove the sinks work at head. Suggested fixtures: a nonInteractiveCli.test.ts case that stubs process.stderr.write and asserts the warning; a Session.test.ts case that drives a submit_prompt result carrying stackedSkillOverflow and asserts an agent_message_chunk with _meta.source === 'slash_command' and _meta.turnNotice === true before the turn's own chunks.
Not covered
- A live
qwen servedaemon and its HTTP/SSE path. The ACP probe uses--acpstdio JSON-RPC, which reaches the sameSessioncode. DaemonChannelBridgeagainst a live daemon; itsprompt()path is driven through a fake session only.- Any channel adapter's rendered message (Telegram/WeCom/Weixin/Feishu/DingTalk cards, email, GitHub/GitLab comments) and any platform-specific streaming UI.
- Web Shell and TUI rendering of the notice; the Web Shell does not consume
turnNotice, so it renders the frame as an ordinary slash-command block. - A real model; the model boundary is a scripted OpenAI-compatible stub.
per_taskonDaemonChannelBridge(the AcpBridgeper_taskpath is measured; the Daemon return expression is the same class, read from code).- Windows and macOS. Linux only.
- The full monorepo test suite; the targeted CLI and channels suites only.
- A per-commit mutation enumeration. The matrix is per-hunk over the two commits, not one row per commit.
- R1-1's proposed independent notice buffer fix. It was not applied, so this round does not claim the fix works.
Methodology
Two detached worktrees — base 7c6f93ca and head d8ac0449 — installed offline from the host pnpm store (--frozen-lockfile --offline, reused 1923 packages, downloaded 0) and built with npm run build -- --cli-only && DEV=true npm run bundle (both exit 0). All execution ran in docker run node:22-bookworm --network none --init --user 54754:100 with env -i plus HOME and no credentials; verify-pr-prepare --require-isolation printed /.dockerenv; credential-free per attestation, no known credential signal and exit 0. The headless probe spawns each arm's own dist/cli.js with -p, points it at the repository's fake OpenAI server on loopback, and checks stderr, stdout, exit code, and the request body the model actually received. The ACP probe spawns dist/cli.js --acp --no-chat-recording, sends initialize → authenticate → session/new → session/prompt over stdio, and records every session/update frame. The channel probes append real vitest cases to the real test files, run them, and restore the files byte-for-byte. The mutation runner applies one production hunk at a time from an in-memory byte backup, runs the selected suite, restores, and asserts the tree is clean. Targeted gates: nonInteractiveCliCommands.test.ts + ui/commands/commands.test.ts → 116/116; AcpBridge.test.ts + DaemonChannelBridge.test.ts → 223/223; tsc --build --force packages/channels/base → exit 0. Raw logs are under logs/, harnesses and probe snippets under harness/, captures under evidence/. The head did not move during the round; CI at d8ac0449 is fully green.
Evidence
— DeepSeek-V4.1-Flash-1017@fda99a87 via Qwen Code /verify-pr (v0.26.8; skill c5273cc80df5)
The notice was pushed into `chunks`, which `clearChunks` empties on every `responseBoundary`, and the `per_task` branch never read it at all, so the stacked-skill warning still disappeared on any turn that made a tool call. Give the notice its own buffer in both bridges that boundaries never clear, and compose it into every return path (turn text and `per_task` result). The slash-command slot keeps its existing precedence and the pinned response-boundary tests stay unchanged. Tests: tool-call-boundary and `per_task` arms for both bridges, plus a Session-side test that the producer tags the overflow notice with `turnNotice: true`; each new arm reds when the buffer is removed. Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com> Patrol-Run: qwen-pr-closeout/jmw3zvicvfk
qwen-code-review-bot
left a comment
There was a problem hiding this comment.
Partially reviewed — gaps disclosed. Suggestions are inline.
Not reviewed: build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally.
Not explored to full depth (tool budget reached): "agent 3b": mutating DaemonChannelBridge.clearChunks and running npx vitest run src/DaemonChannelBridge.test.ts to witness finding 1 empirically (not run — the worktree….
Test Plan (not a blocker): src/nonInteractiveCliCommands.test.ts — no such file or directory; src/ui/commands/commands.test.ts — no such file or directory; Tests 116 passed — this review observed 392, 14566, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 14829 passed; 75 passed — this review observed 392, 14566, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 14829 passed; 7 passed — this review observed 392, 14566, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 14829 passed.
Convergence: round 3 posted 5 inline comment(s), 5 of them reported for the first time; the previous round posted 2 (1 new). Findings keep coming back to the same files: packages/channels/base/src/AcpBridge.ts (findings in round 1; 3 more now). The rate of new findings is not falling. A cluster that keeps producing siblings usually means the fixes are treating instances of a shared root cause — triaging that cause before the next round, or splitting an independent cluster into its own pull request, tends to end the loop faster than fixing them one at a time. Batching the remaining fixes and verifying them before the next push, or dropping this PR's reviews to --severity-floor critical, keeps the loop from re-deriving the same set. No Critical finding is open on this round, so merging and moving the remaining Suggestion threads to a follow-up issue is available as an ending — a merged pull request cannot diverge further. (Observation only — nothing was withheld from this review because of this observation.)
中文说明
仅完成部分审查,审查缺口已披露。 建议见行内评论。
未审查(原文为英文):build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally.
未探索到全部深度(达到工具调用预算):"agent 3b":mutating DaemonChannelBridge.clearChunks and running npx vitest run src/DaemonChannelBridge.test.ts to witness finding 1 empirically (not run — the worktree…。
Test Plan(非阻断):src/nonInteractiveCliCommands.test.ts — no such file or directory; src/ui/commands/commands.test.ts — no such file or directory; Tests 116 passed — this review observed 392, 14566, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 14829 passed; 75 passed — this review observed 392, 14566, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 14829 passed; 7 passed — this review observed 392, 14566, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 14829 passed。
收敛情况:第 3 轮发布了 5 条行内评论,其中 5 条是首次提出;上一轮发布了 2 条(其中 1 条首次提出)。发现反复回到同一批文件:packages/channels/base/src/AcpBridge.ts(第 1 轮已出过发现,本轮又有 3 条)。新发现的产出速度没有下降。一个不断再生兄弟发现的簇,通常意味着逐条修复只在处理同一根因的实例——先定位并处理该根因,或把独立的簇拆成单独的 PR,通常比逐条修复更快结束循环。把剩余修复攒成一批、验证后再推送,或将本 PR 的评审降到 --severity-floor critical,可以避免循环反复推导同一组发现。本轮没有未决的 Critical,因此"合入后把剩余 Suggestion 线程转到后续 issue"是一个可选的结束方式——已合入的 PR 不会继续发散。(仅为观察——本轮评审未因此扣留任何内容。)
— deepseek-v4.1-flash-1017 via Qwen Code /review (v0.26.8)
…plies Address the follow-up review on the turn-notice carry: - R3-1: the daemon boundary test fired `responseBoundary` before the queued notice was consumed, so it cleared nothing; drive the boundary from an in-turn `tool_call` instead and assert it goes red when `clearChunks` regains `turnNotice = ''`. - R3-3: the `turnNotice` wire key was a bare literal on every side; export `CHANNEL_TURN_NOTICE_META_KEY` beside the sibling keys and use it in the producer and both bridges. - R3-4: a notice-only turn returned `"<notice>\n\n"`; drop the separator when the body is empty and cover the exact resolved string. - R3-5: cover the per-session filter in both bridges so another session's notice cannot prefix this turn's reply. Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com> Patrol-Run: qwen-pr-closeout/jmw445tvbfr
qwen-code-review-bot
left a comment
There was a problem hiding this comment.
Partially reviewed — gaps disclosed. Suggestions are inline.
Not reviewed: build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally.
Test Plan (not a blocker): src/nonInteractiveCliCommands.test.ts — no such file or directory; src/ui/commands/commands.test.ts — no such file or directory; Tests 116 passed — this review observed 1204, 41546, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 476, 14829 passed; 75 passed — this review observed 1204, 41546, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 476, 14829 passed; 7 passed — this review observed 1204, 41546, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 476, 14829 passed.
Deferred under the convergence posture (round 4, not a blocker) — recorded, not requested in this round:
packages/cli/src/acp-integration/session/Session.ts:19929 — [review] the overflow notice is emitted live but never recorded, so a restored transcript loses it
Convergence: round 4 posted 2 inline comment(s), 1 of them reported for the first time; the previous round posted 5 (5 new). Findings keep coming back to the same files: packages/channels/base/src/DaemonChannelBridge.test.ts (findings in round 3; 1 more now). A cluster that keeps producing siblings usually means the fixes are treating instances of a shared root cause — triaging that cause before the next round, or splitting an independent cluster into its own pull request, tends to end the loop faster than fixing them one at a time. (Observation only — nothing was withheld from this review because of this observation.)
中文说明
仅完成部分审查,审查缺口已披露。 建议见行内评论。
未审查(原文为英文):build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally.
Test Plan(非阻断):src/nonInteractiveCliCommands.test.ts — no such file or directory; src/ui/commands/commands.test.ts — no such file or directory; Tests 116 passed — this review observed 1204, 41546, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 476, 14829 passed; 75 passed — this review observed 1204, 41546, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 476, 14829 passed; 7 passed — this review observed 1204, 41546, 539, 417, 82, 203, 530, 49, 4, 696, 41, 186, 47, 476, 14829 passed。
收敛姿态下延后(第 4 轮,非阻断)——已记录,本轮不要求修改:共 1 条(原文未翻译,列表见上方英文部分)。
收敛情况:第 4 轮发布了 2 条行内评论,其中 1 条是首次提出;上一轮发布了 5 条(其中 5 条首次提出)。发现反复回到同一批文件:packages/channels/base/src/DaemonChannelBridge.test.ts(第 3 轮已出过发现,本轮又有 1 条)。一个不断再生兄弟发现的簇,通常意味着逐条修复只在处理同一根因的实例——先定位并处理该根因,或把独立的簇拆成单独的 PR,通常比逐条修复更快结束循环。(仅为观察——本轮评审未因此扣留任何内容。)
— deepseek-v4.1-flash-1017 via Qwen Code /review (v0.26.8)
|
Local verification: PARTIAL — the overflow notice now reaches both headless stderr and channel replies; the notice-only (empty model reply) case is not reachable through the channel path at either revision, so it rests on the unit test alone.
Causal evidence. Item 3 is the channel boundary that matters: the value printed is exactly what a chat adapter delivers, produced by the arm's own Regression pin. At head, Gates. Narrow only: the two touched channel suites plus the headless/ACP probes above. No repo-wide build/lint/typecheck was rerun locally; CI carries those. Residuals.
中文版(点击展开)本地验证结论:PARTIAL —— 溢出提示现在同时到达 headless stderr 与渠道回复;「只有 notice、模型无正文」在两条臂上都走不到渠道可见面,因此只有单测支撑。
因果证据:第 3 条打在渠道边界上——打印出来的就是聊天适配器真正交付的文本,由该臂自己的 回归钉:head 上 门禁范围:只跑了受影响的 channel 两个套件与上面的 headless/ACP 探针,没有本地重跑全仓 build/lint/typecheck,那部分交给 CI。 残留缺口:
|
…only reply The daemon twin of the ACP per-session filter could not be reached through a session_update for another session, so it was unpinned: emit the turn notice directly and assert it never lands on the pending prompt's reply. The notice-only arm of the reply composition was likewise unexercised, so assert the notice comes back without a trailing blank paragraph. Also merges current main so the lint gate snapshot is fresh. Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com> Patrol-Run: qwen-pr-closeout/jmw4h0sl6g9
qwen-code-review-bot
left a comment
There was a problem hiding this comment.
Partially reviewed — gaps disclosed.
Not reviewed: build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally.
Test Plan (not a blocker): src/nonInteractiveCliCommands.test.ts — no such file or directory; src/ui/commands/commands.test.ts — no such file or directory; Tests 116 passed — this review observed 1209, 41690, 539, 417, 82, 203, 531, 49, 4, 720, 41, 186, 47, 476, 14832 passed; 75 passed — this review observed 1209, 41690, 539, 417, 82, 203, 531, 49, 4, 720, 41, 186, 47, 476, 14832 passed; 7 passed — this review observed 1209, 41690, 539, 417, 82, 203, 531, 49, 4, 720, 41, 186, 47, 476, 14832 passed.
Deferred under the convergence posture (round 5, not a blocker) — recorded, not requested in this round:
packages/cli/src/nonInteractiveCli.ts:1346 — [review] the headless overflow notice bypasses this file's output-format split, so stream-json consumers never see itpackages/cli/src/nonInteractiveCli.ts:1344 — [review] the headless overflow notice has no test, so both of its claims are unpinnedpackages/cli/src/acp-integration/session/Session.ts:19940 — [review] the ACP overflow notice is emitted live but never recorded, so a restored transcript loses itpackages/cli/src/nonInteractiveCliCommands.ts:633 — [review] the overflow warning is now a third verbatim copy of one user-facing sentence
中文说明
仅完成部分审查,审查缺口已披露。
未审查(原文为英文):build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally.
Test Plan(非阻断):src/nonInteractiveCliCommands.test.ts — no such file or directory; src/ui/commands/commands.test.ts — no such file or directory; Tests 116 passed — this review observed 1209, 41690, 539, 417, 82, 203, 531, 49, 4, 720, 41, 186, 47, 476, 14832 passed; 75 passed — this review observed 1209, 41690, 539, 417, 82, 203, 531, 49, 4, 720, 41, 186, 47, 476, 14832 passed; 7 passed — this review observed 1209, 41690, 539, 417, 82, 203, 531, 49, 4, 720, 41, 186, 47, 476, 14832 passed。
收敛姿态下延后(第 5 轮,非阻断)——已记录,本轮不要求修改:共 4 条(原文未翻译,列表见上方英文部分)。
— deepseek-v4.1-flash-1017@1f214e4e via Qwen Code /review (v0.26.8)
|
Delivered 129ed6d: QQ now receives the stacked-skill warning even after streamed output or a previous turn's deferred send. The notice is sent separately after model completion, preserving answer-specific adapter metadata. No QQ buffering changes, dependency, configuration, route, or persisted-format changes.
Scope: initial review had 3 production files / 26 changed lines and 1 test file / 67 lines. Incoming head had 7 production files / 84 lines and 4 test files / 500 lines. Final PR has 8 production files / 105 lines and 6 test files / 706 lines. The new production file is the shared delivery consumer needed for R3-2; the 206 added test lines protect real adapter delivery, a deferred-send regression, session isolation, completion order and notice-only formatting. Two existing bridge comments were corrected. The original warning contract remains the scope. Final verification at
Before the repair, buffered and idle-flushed QQ runs sent model text with no notice. The final tests require each model segment and warning exactly once, including an in-flight previous-turn send. Real QQ transport was not configured; bridge input and network sends are scripted around real channel code. Windows was not tested locally. Remote CI/re-review for the pushed SHA remains external verification; no automatic monitor was installed. 已完成本轮实际投递缺陷修复并推送;1,424 项定向测试通过。其余四项非阻断建议集中记录在 #16441,避免继续扩大这个 PR。真实 QQ 网络与新提交 CI 仍需外部验证。 |
Local verification reportVerified commit: Before / after
The fix delivers the channel warning separately after the model response. It keeps the warning out of QQ's streaming buffers and preserves answer-before-notice ordering for adapters such as DingTalk. The base regression also checks session isolation, notice-only delivery without an empty answer message, and listener cleanup. Test results
Root build, typecheck, and bundle passed. After the final delivery-order adjustment, the affected channel-base build/typecheck and root bundle were rerun and passed. Changed-file ESLint, Prettier, and commit hooks also passed. Commands used for the final committed test runsEach command ran from the indicated package directory with the standard Vitest configuration and workspace build guards enabled. # packages/channels/base
npx vitest run src/AcpBridge.test.ts src/DaemonChannelBridge.test.ts src/ChannelBase.test.ts
# packages/channels/qqbot
npx vitest run src/turn-notice.test.ts src/stream.test.ts
# packages/cli
npx vitest run --coverage.enabled=false src/nonInteractiveCliCommands.test.ts src/ui/commands/commands.test.ts
npx vitest run --coverage.enabled=false src/acp-integration/session/Session.test.ts -t 'tags the stacked-skill overflow notice'Verification limitsThe QQ tests run the real 中文说明最终提交的定向测试共 1,424 项通过。已覆盖 QQ 缓冲发送、空闲刷新、工具边界,以及上一轮发送未完成时连续接收两轮消息的场景;有溢出时提示只发送一次,无溢出时不发送提示,模型回复各片段也只发送一次。构建、类型检查、打包及相关格式检查通过,最后的发送顺序调整后也重新验证了受影响包。 本轮使用真实适配器代码配合模拟桥接和传输,核对实际传给发送接口的消息内容。由于本机没有运行中的 QQ 渠道服务,因此没有真实 QQ 界面截图;未将这些测试表述为线上端到端验证。 |
qwen-code-review-bot
left a comment
There was a problem hiding this comment.
Partially reviewed — gaps disclosed.
Not reviewed: build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally.
Not explored to full depth (tool budget reached): "agent 6a": verifying that a second sendResponseMessage per turn is safe in the remaining adapter overrides I did not open (email, github, gitlab, dws, feishu, wecom, wei…; "agent 6a": confirming whether the daemon's transcript replay can re-deliver a stale _meta.turnNotice frame into a later prompt's DaemonChannelBridge.handleSessionUpdate….
Deferred under the convergence posture (round 6, not a blocker) — recorded, not requested in this round:
packages/channels/base/src/ChannelBase.ts:7647 — [review] a failed advisory-notice send reclassifies an already-delivered turn as failedpackages/channels/base/src/ChannelBase.ts:7644 — [review] a <noreply>-suppressed turn still posts the overflow warningpackages/channels/base/src/ChannelBase.ts:7644 — [review] on the DingTalk card path the trailing notice consumes the single-use mention targetpackages/cli/src/nonInteractiveCli.ts:1346 — [review] the headless overflow notice bypasses this file's output-format split, so stream-json consumers never see itpackages/cli/src/nonInteractiveCli.ts:1344 — [review] the headless overflow notice has no test, so both of its claims are unpinnedpackages/cli/src/nonInteractiveCliCommands.ts:635 — [review] the overflow warning is now a third verbatim copy of one user-facing sentence
中文说明
仅完成部分审查,审查缺口已披露。
未审查(原文为英文):build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally.
未探索到全部深度(达到工具调用预算):"agent 6a":verifying that a second sendResponseMessage per turn is safe in the remaining adapter overrides I did not open (email, github, gitlab, dws, feishu, wecom, wei…;"agent 6a":confirming whether the daemon's transcript replay can re-deliver a stale _meta.turnNotice frame into a later prompt's DaemonChannelBridge.handleSessionUpdate…。
收敛姿态下延后(第 6 轮,非阻断)——已记录,本轮不要求修改:共 6 条(原文未翻译,列表见上方英文部分)。
— deepseek-v4.1-flash-1017 via Qwen Code /review (v0.26.8)
|
Local verification: PARTIAL — on head
Causal evidence. Item 3 is the channel boundary that matters: the printed value is what a chat adapter delivers, produced by the arm's own Regression pin. Gates. Narrow only: Discarded runs. None — every probe ran once per arm. The empty-reply probe issues 6 stub requests per arm because the CLI retries that turn. Residuals.
中文版(点击展开)本地验证结论:PARTIAL —— 在 head
因果证据:第 3 条打在渠道边界上——打印出来的就是聊天适配器会交付的文本,由该臂自己的 回归钉:对 门禁范围:只跑了 丢弃的运行:无——每个探针每臂只跑一次。空回复探针每臂发 6 次 stub 请求,因为 CLI 会重试这一回合。 残留缺口:
|
|
@qwen-code /triage |
|
Sandboxed verification: The verification job did not complete (checkout, runner, or setup error) and produced no report. See the workflow run for details. 中文 — 判定:
|
qwen-code-review-bot
left a comment
There was a problem hiding this comment.
LGTM, looks ready to ship. ✅
qqqys
left a comment
There was a problem hiding this comment.
Review — head 129ed6d6
Verdict: APPROVE. The one Critical this PR carried through six rounds is fixed at this head, and I verified the fix in the production code rather than accepting the ledger's empty findings list. CI is complete and green: 30 pass, 36 skipping, 0 fail, 0 pending.
The historical Critical, and why it is now closed
R1-1 was filed in round 1, re-filed in round 2, and independently reproduced with a real A/B harness by @wenshao at d8ac0449: the overflow notice was dropped whenever the turn crossed a response boundary, and in per_task mode; and because 7 of 10 production channel packages do not override onResponseChunk, those channels could never see it at all. Round 6 at this head reports findings: []. Three separate mechanisms were needed, and all three are present:
1. The notice no longer lives in the buffer that boundaries clear. Both bridges keep a dedicated variable and listener, and clearChunks — the responseBoundary handler — empties only chunks:
let turnNotice = '';
const onTurnNotice = (sid, notice) => { if (sid === sessionId) turnNotice = notice; };
const clearChunks = (sid) => { if (sid === sessionId) { chunks.length = 0; … } };
this.on('turnNotice', onTurnNotice);
this.on('responseBoundary', clearChunks);So a tool_call, plan or permission request crossing the turn cannot discard it. The producer side routes it there deliberately: both bridges test meta?.[CHANNEL_TURN_NOTICE_META_KEY] === true before the source === 'slash_command' branch, emit turnNotice, and break — so the notice cannot also land in textChunk and be double-delivered.
2. per_task mode carries it. This was the second half of the round-2 finding: per_task returned taskResult and never read chunks. Both bridges now compose the notice onto whichever body wins, and the two implementations agree exactly:
// AcpBridge
const body = options?.outputMode === 'per_task' && … ? taskResult : chunks.join('') || slashCommandOutput;
return turnNotice && body ? `${turnNotice}\n\n${body}` : turnNotice || body;
// DaemonChannelBridge
const body = taskOutput?.text || chunks.join('') || slashCommandOutput;
const textResult = turnNotice && body ? `${turnNotice}\n\n${body}` : turnNotice || body;That agreement matters, because ChannelBase strips the prefix with a hardcoded separator width — response = response.slice(turnNotice.length + 2) — and the + 2 is exactly the \n\n both bridges insert. I checked the degenerate case too: when turnNotice is set and body is empty the bridges return the notice alone with no separator, so the slice runs past the end, yields '', and the following if (!promptState.cancelled && response) correctly skips sending an empty reply while the separate notice send still happens. No truncation and no empty message.
3. Delivery no longer depends on onResponseChunk. The notice is sent from ChannelBase itself via sendResponseMessage, after onResponseComplete has delivered the answer — which is what makes it reach the seven channel packages that never implemented the chunk hook, and what lets adapter-specific reply metadata such as DingTalk's @sender mention be consumed by the answer first. The prefix is stripped from the response before delivery, so the notice is not replayed inside the model text.
The contract is pinned in one place rather than duplicated: CHANNEL_TURN_NOTICE_META_KEY = 'turnNotice' is declared in ChannelAgentBridge.ts with the event's semantics documented ("Also prefixes prompt()'s result, with a blank line before a non-empty body"), re-exported from index.ts, and imported by the producer in Session.ts from @qwen-code/channel-base. Producer and both bridges therefore cannot drift on the key, which was the round-1 failure mode of reusing the slash-command slot.
The round-5 residual (R3-2, QQ dropping the notice once a turn had streamed) is sev:"S" and non-blocking under this review's scope; the new 181-line turn-notice.test.ts in the qqbot package and the 251 lines added to DaemonChannelBridge.test.ts are what the description says cover the buffered, idle-flushed and previous-turn-still-pending shapes.
Producer side and headless path
Session.ts emits the notice on submit_prompt when result.stackedSkillOverflow is set, before the prompt is expanded, and the comment states the contract plainly: overflow is a warning, not a failure, so the turn continues. Nothing here rejects an overflowing prompt or changes the five-skill limit, which matches the stated scope — the first five skills still load, the sixth stays literal prompt text, and the exit code is unaffected. The headless path writes to stderr so that JSON and stream-JSON stdout stay parseable; I read that this is the intent and that nonInteractiveCli.ts and nonInteractiveCliCommands.ts gained 7 and 12 lines for it, but I did not read those two hunks in full, and the fully green lane set including lint, typecheck and the unit shards is my evidence there rather than a line-by-line reading.
CI and scope
30 pass, 36 skipping, 0 fail, 0 pending — every lane that ran is green and nothing is outstanding, which is unusual and worth stating because it means the assertions above have an observed result at this exact head. The prior bot approval at this head is a 28-character stub, so it carries no reasoning; my verdict rests on the code reading above, not on it.
I read every production hunk in AcpBridge.ts, DaemonChannelBridge.ts, ChannelBase.ts, ChannelAgentBridge.ts, index.ts and Session.ts, and traced the notice from producer through both bridges to channel delivery, including the slice arithmetic and its empty-body edge. I ran no test. I did not read the 620 lines of new tests beyond noting what they pin, did not read the headless hunks in full, and did not verify the QQ adapter against a live account — the description is explicit that the bridge and QQ network API were scripted, so this is adapter-level evidence rather than live acceptance.
doudouOUC
left a comment
There was a problem hiding this comment.
评审结论:通过(Approve)
评审基线
- PR:
#16404fix(cli): surface stacked-skill overflow in non-interactive and ACP runs - head
129ed6d671e6d778e93ceb91ec4f5706e4ce0dfd,base16794c25adcf2c6c922df954b6854ed3ceed259f,14 文件 +806/−5(生产 8 文件,测试 6 文件) - CI(按 head 汇总):30 pass / 36 skipped / 0 fail;Linux unit 8 分片、Build unit-test tree、Lint & Static、Integration (no-AK)、web-shell E2E 4 分片、TUI parity 均通过
- 未解决 review thread:0
总体评价
修复链路完整,四个消费面都已对齐:
- 生产端:
packages/cli/src/nonInteractiveCliCommands.ts:630-636只在parseStackedSlashCommands返回exceededMax时给出警告;消息里的 5 来自MAX_STACKED_SKILLS,与解析器实际保留的前 5 个 skill 一致(commands.ts:134-190)。5 个 skill 的对照用例与 6 个 skill 的溢出用例分别钉住不误报/不漏报。 - headless:
packages/cli/src/nonInteractiveCli.ts:1344-1350将警告写 stderr,不改变 stdout 的 JSON/stream-JSON 协议与退出码。这修正了此前 headless 用户完全无感知的缺口。 - ACP:
packages/cli/src/acp-integration/session/Session.ts:19937-19948在模型响应前用_meta.turnNotice=true发出通知;emitters/MessageEmitter.ts:214-240先展开extra再写source: 'slash_command',因此通知不会覆盖/被覆盖来源标记。 - 渠道:
AcpBridge.ts:458-530, 694-699与DaemonChannelBridge.ts:667-713, 871-873, 1237-1242为通知单独开缓冲,不受responseBoundary清空影响;ChannelBase.ts:7589-7654先交付正文,再单独发送通知,并在finally移除监听。QQ 的 buffered / flushed / boundary / deferred 与普通回合共 8 个参数化用例断言每段文本与通知各出现一次。
历史缺口复核:交互 TUI 早已有该警告(ui/hooks/slashCommandProcessor.ts:1080)、非交互路径此前在 return 点拿得到 exceededMax 却未透传,该 PR 补齐的是一致性,不是新增可配置项或行为拒绝。
建议项(非阻塞)
- 通知前缀的剥离依赖长度算术:
packages/channels/base/src/ChannelBase.ts:7624-7629用response.slice(turnNotice.length + 2)把prompt()返回的前缀剥掉,契约只靠AcpBridge/DaemonChannelBridge与ChannelBase三方隐式约定。一旦事件与返回值不同步,或返回体不以notice + "\n\n"开头,就会截断正文开头 N+2 个字符。建议改为显式判断:if (turnNotice && response.startsWith(${turnNotice}\n\n)) { response = response.slice(...) }。 - 通知发送失败会把已成功的回合改判为失败:
ChannelBase.ts:7644-7654的通知发送位于主 try 块内;若sendResponseMessage抛错,catch 分支会以phase: 'delivery'标记failed并向上抛(正文此时已成功交付)。通知是附加诊断,建议单独 try/catch 记录日志,不改变回合终态;至少不要因通知失败向用户再发一条错误提示。 - QQ deferred 场景缺少顺序断言:
packages/channels/qqbot/src/turn-notice.test.ts的 deferred 用例只断言各出现一次。QQChannel.onResponseComplete在flushingSessions时是 park 后立即返回(QQChannel.ts:3396-3403),随后ChannelBase直接发送通知,理论上通知可能先于被挂起的正文到达。如果「正文之后再发警告」是承诺语义,建议补顺序断言(或在 flush 完成后再发通知);如果允许乱序,请在 PR 描述里注明。 - headless 的 stderr 输出没有直接单测:
nonInteractiveCli.ts:1344-1350这 7 行目前只由 producer(nonInteractiveCliCommands.test.ts)与 ACP(Session.test.ts)用例间接覆盖。packages/cli/src/nonInteractiveCli.test.ts已存在,建议补一条:6 个前置 skill 时 stderr 含警告、stdout JSON 仍可解析、退出码 0;5 个时无警告。
安全审查结论
未发现硬编码密钥/Token、敏感信息、命令注入、SQL 注入、路径穿越或权限/认证变更。通知文本只由常量与 MAX_STACKED_SKILLS 组成,不拼接用户输入;新增 turnNotice 事件不进入模型上下文。上述两条投递健壮性建议属可用性/错误语义层面,非安全漏洞。置信度:基于当前 head 源码与全部新增测试通读,未在本地执行 bundle 级回放(CI 与该 PR 的验证评论提供了运行证据)。
结论
通过。未发现阻塞问题;建议项 1、2 建议在后续小改中处理,3、4 可跟进。
|
Held at the merge gate on head Closeout item (b) is only partly covered. The
The earlier |
|
Held at the merge gate on head Closeout (b) is unmet. The report bound to this head is PARTIAL: claims 1-3 (headless Clearing it needs either a real |
审查结论(post-merge,不 approve)
本次实际检查的内容
执行
未覆盖
已有评审的交叉核对
Reviewed with AI assistance. |
…n-hook main advanced 11 commits (stacked-skill overflow #16404, workflow agent approvals #16432, daemon UI tool blocks #16306, sibling model settings #15829, late snapshot publication claim #16489, inline FQN imports in runtime modules #16504, cancelled shell as interrupted #15836, CSI statement helper fold #16503, Maven suite cache write-back #15274, sed char match #15701, Ink TUI tool-batch round #16428). One conflict, the workflow size ratchet: - .size-baseline: sdk-java.yml auto-merged to 167124 bytes (HEAD recorded 161927 / main 165241, both below the combined actual), so record the actual merged size 167124 per the ratchet's "record the real size in the same PR" rule. The absolute gate (470000) and the 4096-byte baseline allowance both pass. No source conflict: main's commits did not touch this branch's A3 source files, so RuntimeBrokerService / RuntimeExecutionRecovery (R18-1/R19-1 observe-only mount-handback guard) and the cli serve fence are unchanged. Verification: check-workflow-size.sh green (bash5); workflow meta tests (workflow-size + sdk-java-workflow + hosted-process-ci) 428 green; workspace build and ClassSizeRatchetTest re-run after the merge.
|
Released in v0.27.0. |




What this PR does
Non-interactive runs now warn when a prompt stacks more than five skills. Headless runs write the warning to stderr, including when stdout uses JSON or stream-JSON. ACP clients receive a live notice before the model response. Channel bridges preserve the notice across tool boundaries and task-result selection.
Inbound channel chats deliver the warning as a separate message after completing the model reply. This also reaches QQ when its response has already streamed or an earlier turn still has a send in flight, without replaying model text. Completing the answer first preserves adapter-specific behavior such as DingTalk's @sender mention.
Why it's needed
Interactive surfaces already report the limit, but headless and ACP/channel users previously received no indication that an extra skill was not loaded. The first five skills still load, additional skill tokens remain literal prompt text, and the warning does not make the run fail.
Reviewer Test Plan
How to verify
Evidence (Before & After)
At the incoming head, a real QQ adapter driven through the shared inbound-message path sent the model text but no warning in both buffered and idle-flushed cases. At the repaired head, the retained tests assert each outgoing warning and model-text segment appears once, including the previous-turn/deferred-send case. The bridge and QQ network API are scripted; this is adapter-level evidence, not live QQ acceptance.
Final validation at
129ed6d: 1,020 channel-base/bridge tests, 287 QQ tests, 116 skill-command tests, and the focused ACP notice-producer test. Full build, typecheck, bundle, changed-file ESLint and formatting passed; the final delivery-order adjustment also received a fresh channel-base build/typecheck and bundle.Tested on
Environment
Node 22.22.3 on macOS. No live QQ account was configured. Earlier verification comments retain their original revision identifiers and do not certify this head.
Risk & Scope
Linked Issues
Refs #16396.
中文说明
这个 PR 做了什么
非交互运行现在会在提示词堆叠超过五个 skill 时发出警告。Headless 将警告写入 stderr,即使 stdout 使用 JSON 或 stream-JSON 格式也是如此。ACP 客户端在模型响应前收到实时通知。渠道 bridge 会在工具调用边界和任务结果选择过程中保留该通知。
渠道聊天在完成模型回复后,单独发送警告消息。即使 QQ 已流式发送正文,或者上一轮仍有消息正在发送,也能收到警告,且不会重发模型正文。先完成正文还会保留钉钉 @发送者等适配器行为。
为什么需要
交互界面已经会报告这个限制,但 headless 和 ACP/渠道用户此前无法知道额外的 skill 没有加载。前五个 skill 仍会加载,额外 token 仍作为普通提示词文本,警告不会导致运行失败。
评审测试计划
如何验证
前后证据
接管时的提交中,通过共享入站消息路径驱动真实 QQ 适配器,在缓冲和提前发送两种场景都只能得到模型正文,没有警告。修复后的保留测试断言:每条警告与每段正文均恰好出现一次,也覆盖前一轮延迟发送场景。Bridge 和 QQ 网络 API 使用脚本替身;这是适配器级证据,不是真实 QQ 验收。
最终
129ed6d验证:1,020 项渠道基础层/bridge 测试、287 项 QQ 测试、116 项 skill 命令测试及定向 ACP 通知生产端测试。完整构建、类型检查、打包、改动文件 ESLint 和格式检查通过;最后的投递顺序调整也重新构建并检查了渠道基础包类型,再次打包。测试平台
环境
macOS,Node 22.22.3。未配置真实 QQ 账号。此前验证评论保留各自的提交标识,不代表本次提交的验证结果。
风险与范围
关联 Issue
Refs #16396。