Skip to content

feat(serve): adaptively grow live-journal caps before truncating mid-turn replay - #8905

Merged
wenshao merged 13 commits into
mainfrom
worktree-adaptive-journal-growth
Aug 13, 2026
Merged

feat(serve): adaptively grow live-journal caps before truncating mid-turn replay#8905
wenshao merged 13 commits into
mainfrom
worktree-adaptive-journal-growth

Conversation

@wenshao

@wenshao wenshao commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

What this PR does

When an in-flight turn outgrows the per-session live-journal caps, the daemon now tries to grow that session's caps before dropping the oldest replay entries. Growth doubles the caps (entries scaled proportionally with bytes) while the growth granted across the bridge's live sessions fits in a pool derived from the daemon memory budget (5% of the effective budget, clamped to [32, 1024] MB), and never past a per-session hard cap of 256 MiB. Growth is on demand and throttled after a refusal; the accounting is stateless — each request re-sums the current caps of all live sessions, so granted headroom disappears automatically when a session is reaped. When no headroom is granted, behavior is exactly as before: the oldest entries are dropped whole and a history_truncated marker is prepended. The complete turn content remains available from the persisted transcript after the turn finishes, as today.

Why it's needed

The journal caps were introduced as a memory-safety device against runaway turns, but the fixed defaults silently degrade exactly the sessions that benefit most from live replay: a single turn fanning out many concurrent subagents (the canonical case is a /review run with ~14 agents) can emit hundreds of thousands of source events in one turn, far past the 10 000-entry / 8 MiB baseline. A mid-turn (re)load then shows only a small retained tail — in one observed session 230 123 of 247 413 events were dropped — and the full content stays hidden until the turn ends. The only escape so far was a hidden boot flag (--max-journal-bytes) that no real user knows about and that, raised naively, would give every session an unbounded-by-concurrency allowance. This makes the caps adaptive by default: they grow only under pressure, only within memory the daemon believes it has, and never past bounded ceilings.

Reviewer Test Plan

How to verify

  • Growth mechanics are pinned by unit tests on the compaction engine: grant raises caps in place and avoids eviction, the advisor always receives the current (already grown) caps, refusal / throw / malformed grant all degrade to plain eviction, re-asks are throttled after a refusal until the interval elapses or a turn boundary resets it, and grown caps persist across turn boundaries.
  • Policy accounting is pinned separately: doubling within the pool, baseline caps not charged against the pool, partial-headroom grants, refusal once the pool is fully granted, and the per-session hard cap with proportional entries.
  • Budget derivation is pinned in the memory-budget tests (5% of effective budget, clamped to [32, 1024] MB).
  • Two new daemon-boot tests assert the wiring end to end: a real daemon derives the pool from the memory budget and passes it to every bridge it constructs, and pinning --max-journal-bytes disables growth (no pool passed).
  • Suite results: acp-bridge full suite 27 files / 1221 tests pass; cli run-qwen-serve.test.ts 245 pass; fast-path 88 pass (including the bundle-closure check); acp-http transport 298 pass; sdk daemon UI normalizer 291 pass; typecheck, lint, build, and bundle all green.
  • Behavior notes: growth is on by default whenever neither journal flag is passed; an operator-pinned --max-journal-events or --max-journal-bytes disables it (explicit config wins); bridges without a configured pool keep the fixed-cap behavior unchanged.

Evidence (Before & After)

N/A (daemon internals; no TUI change — the user-visible effect is that a mid-turn reload of a fan-out session retains much more of the in-flight turn instead of showing the truncation marker early).

Tested on

OS Status
🍏 macOS
🪟 Windows ⚠️
🐧 Linux ⚠️

Environment (optional)

Unit/integration tests only (npm run dev daemon boot is exercised by the daemon-boot tests); no model E2E.

Risk & Scope

  • Main risk or tradeoff: growth retains more daemon heap during a genuinely huge turn. It is bounded — per-session hard cap 256 MiB, per-bridge pool at most 1024 MB — and the pool is an allowance, not a preallocation: heap only grows with events that actually exist (and would previously have been dropped). Accounting is per bridge, so a multi-workspace daemon carries one pool per workspace bridge.
  • Not validated / out of scope: merging cumulative tool-call updates inside the journal (a complementary source-level lever, deliberately separate); surfacing the pool or grown caps on /daemon/status (limits there still report the configured baselines); the compacted-replay window caps are untouched.
  • Breaking changes / migration notes: none. Without a configured pool (operator-pinned flags, or bridges that don't pass one, e.g. channel bridges) behavior is byte-for-byte the pre-change fixed-cap eviction.

Linked Issues

None — observed locally: a /review session's single turn (14 concurrent review agents) hit the live-journal caps and dropped 230 123 of 247 413 source events for mid-turn replay.

中文说明

这个 PR 做了什么

当一个进行中的回合超出会话级 live journal 上限时,daemon 现在会先尝试提高该会话的上限,而不是直接丢弃最老的回放条目。增长按翻倍进行(条目数与字节数按比例放大),前提是该 bridge 上所有活跃会话已获授的增长总量仍在增长池之内——增长池由 daemon 内存预算派生(有效预算的 5%,clamp 到 [32, 1024] MB),且单会话硬顶不超过 256 MiB。增长完全按需触发,被拒绝后有节流;会计是无状态的——每次请求都重新求和所有活跃会话的当前上限,因此会话被回收时其已获授额度自动消失。若未获得额度,行为与之前完全一致:整段丢弃最老条目并前置 history_truncated 标记。回合结束后,完整内容依旧可从持久化 transcript 获取,与现状一致。

为什么需要

journal 上限最初是作为防失控回合的内存安全装置引入的,但固定默认值恰恰悄悄拖垮了最需要实时回放的那类会话:单个回合扇出大量并发子代理(典型场景是约 14 个代理的 /review 运行)可以在一个回合内产生数十万个 source 事件,远超 10 000 条 / 8 MiB 基线。此时中途(重新)加载只会看到很小的保留尾部——实际观察到一个会话 247 413 个事件中丢弃了 230 123 个——完整内容要等回合结束才可见。此前唯一的办法是一个没有真实用户知道的隐藏启动参数(--max-journal-bytes),而且简单调大它等于给每个会话一个不受并发约束的额度。本 PR 让上限默认自适应:只在压力下增长、只在 daemon 认为拥有的内存范围内增长、且永远不超过有界硬顶。

评审者测试计划

如何验证

  • 增长机制由 compaction engine 单元测试钉死:授权就地提高上限并避免驱逐;顾问每次收到的是当前(可能已增长的)上限;拒绝/抛异常/非法授权均降级为普通驱逐;拒绝后的重复询问被节流,直到超过间隔或回合边界重置;增长后的上限跨回合边界保留。
  • 策略会计单独钉死:池内翻倍、基线上限不计入池、剩余额度不足时的部分授权、池授满后拒绝、单会话硬顶及条目按比例放大。
  • 预算派生在 memory-budget 测试中钉死(有效预算的 5%,clamp 到 [32, 1024] MB)。
  • 两个新 daemon 启动测试端到端验证装配:真实 daemon 从内存预算派生池并传入其构造的每个 bridge;钉住 --max-journal-bytes 时禁用增长(不传池)。
  • 套件结果:acp-bridge 全量 27 文件 / 1221 测试通过;cli run-qwen-serve.test.ts 245 通过;fast-path 88 通过(含 bundle 闭包检查);acp-http transport 298 通过;sdk daemon UI normalizer 291 通过;typecheck、lint、build、bundle 全绿。
  • 行为说明:两个 journal flag 都未传时增长默认开启;operator 传了 --max-journal-events--max-journal-bytes 任一则禁用增长(显式配置优先);未配置池的 bridge(如 channel bridge)保持固定上限行为不变。

前后对比证据

N/A(daemon 内部改动,无 TUI 变化——用户可见的效果是:扇出会话中途刷新页面时能保留进行中的回合的更多内容,而不是过早看到截断标记)。

测试环境

OS 状态
🍏 macOS
🪟 Windows ⚠️
🐧 Linux ⚠️

运行环境(可选)

仅单元/集成测试(daemon 启动路径由启动测试覆盖);无模型 E2E。

风险与范围

  • 主要风险/权衡:增长会让真正巨大的回合在 daemon 堆上保留更多内容。它有界——单会话硬顶 256 MiB、单 bridge 池至多 1024 MB——且池是额度而非预分配:堆只随真实存在的事件增长(这些事件此前只是被丢弃)。会计按 bridge 独立,因此多 workspace daemon 每个 workspace bridge 各持一份池。
  • 未验证/不在范围内:journal 内合并累积的 tool-call 更新(互补的源头手段,刻意分开);在 /daemon/status 上暴露池或已增长上限(limits 仍报告配置的基线);compacted-replay 窗口上限不动。
  • 破坏性变更/迁移说明:无。未配置池时(operator 钉住 flag,或 bridge 未传池,如 channel bridge),行为与改动前的固定上限驱逐逐字节一致。

关联 Issue

无——来自本地观察:一个 /review 会话的单回合(14 个并发 review 子代理)触碰 live journal 上限,中途回放丢弃了 247 413 个 source 事件中的 230 123 个。

…turn replay

A single turn fanning out many concurrent subagents (e.g. a /review run) can emit hundreds of thousands of source events, far past the per-session live-journal baseline caps (10 000 entries / 8 MiB), so a mid-turn (re)load silently shows a truncated replay until the turn finishes. Before evicting, the engine now asks a growth advisor: caps double (entries scaled proportionally) while the growth granted across the bridge's live sessions fits in a pool derived from the daemon memory budget (5%, clamped to [32, 1024] MB), never past a per-session hard cap of 256 MiB. Growth is on demand, throttled after a refusal, and accounted statelessly from the current caps of all live sessions, so granted headroom dies with its session. An operator-pinned --max-journal-events/--max-journal-bytes disables growth; without a pool the fixed-cap eviction behavior is unchanged.
@qwen-code-ci-bot

qwen-code-ci-bot commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

Qwen Triage finished — CI landed green on 68fe75d and the deferred approval was posted. finalize run

Qwen Triage 已完成 —— 68fe75d 的 CI 全绿,延迟审批已提交。查看 finalize 运行

@qwen-code-ci-bot

qwen-code-ci-bot commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

Re-run after a sixth autofix round — head advanced from a4d0dabe to 68fe75d3 right as this pass started (the push and the /triage trigger crossed), so this review covers the new head.

Template looks good ✓

Problem: observed, not theoretical — unchanged from earlier passes. A single /review turn fanning out ~14 agents hit the live-journal caps and dropped 230 123 of 247 413 source events for mid-turn replay, with the full content hidden until turn end. Concrete numbers from a real session; since the last pass the sandboxed A/B run also reproduced it end to end (base build truncates at 10 000 entries under a 60k-event flood, this PR retains all 60 000).

Direction: aligned, unchanged. Live-replay fidelity for fan-out sessions is squarely qwen serve territory, and turning a memory-safety device from "silent truncation" into "bounded adaptive growth" is the right shape of improvement. Claude Code CHANGELOG: no direct reference to this mechanism, but the area (transcript/replay fidelity under load) is clearly relevant.

Size: cross-package (packages/acp-bridge + packages/cli + SDK types), so the core-module lens applies. Current breakdown: 850 production logic lines, 2 487 test lines, 218 docs lines. Author is a maintainer (admin), so the two-tier gate is exempt; numbers reported for transparency. The only production delta since the last pass is +2 lines — the nargs: 1 strictness fix from review round 6.

Approach: the scope still feels right. The new commit is exactly the round-6 feedback and nothing else: valueless --max-journal-events / --max-journal-bytes are now a parse error instead of silently leaving the caps unpinned, and the retained-window test now pins the full expected window. One standing hygiene note, non-blocking: the PR body is still stale in three places (per-bridge pools, the [32, 1024] MB clamp, and /daemon/status surfacing out of scope — all three changed during review rounds).

Risk: no high-risk path matches from the revert-history signal.

Moving on to code review. 🔍

中文说明

第六轮 autofix 后的重新运行——本次运行刚启动时 head 恰好从 a4d0dabe 推进到 68fe75d3(推送与 /triage 触发交错),本评审覆盖新 head。

模板完整 ✓

问题:已观测到的真实问题,不是理论假设——与早前各轮结论一致。单个 /review 回合扇出约 14 个 agent 时触及 live journal 上限,247 413 个源事件中有 230 123 个在中途回放中被丢弃,完整内容要等回合结束才可见。有真实会话的具体数字;上一轮之后的沙箱 A/B 运行也已端到端复现(base 构建在 6 万事件洪峰下截断于 10 000 条,本 PR 保留全部 60 000 条)。

方向:对齐,不变。扇出会话的实时回放保真度正是 qwen serve 的核心领域;把内存安全装置从"静默截断"升级为"有界自适应增长"是正确的改进方向。Claude Code CHANGELOG 中没有对该机制的直接引用,但该领域明显相关。

规模:跨包改动(packages/acp-bridge + packages/cli + SDK 类型),适用核心模块审查。当前拆分:850 行生产逻辑2 487 行测试218 行文档。作者是 maintainer(admin),两级门控豁免;数字仅作透明记录。自上轮以来生产代码仅 +2 行——即第六轮评审要求的 nargs: 1 严格化修复。

方案:范围仍然合理。新提交恰恰是第六轮反馈本身,别无其他:无值的 --max-journal-events / --max-journal-bytes 现在直接报解析错误,而不是静默地不锁定上限;保留窗口测试现在固定完整的预期窗口。一个持续的非阻塞卫生问题:PR 正文仍有三处过期(per-bridge 池、[32, 1024] MB clamp、/daemon/status 呈现超出范围——三者均已在评审轮次中改变)。

风险:回滚历史信号无高风险路径命中。

进入代码审查 🔍

Qwen Code · qwen3.8-max

Reviewed at 68fe75d3f63aca88e9290c7ed0c319252330c73a · re-run with @qwen-code /triage

@github-actions

github-actions Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

Code Coverage Summary

Package Lines Statements Functions Branches
CLI 84.01% 84.01% 89.91% 83.27%
Core 87.89% 87.89% 89.46% 86.41%
CLI Package - Full Text Report
-------------------|---------|----------|---------|---------|-------------------
File               | % Stmts | % Branch | % Funcs | % Lines | Uncovered Line #s 
-------------------|---------|----------|---------|---------|-------------------
All files          |   84.01 |    83.27 |   89.91 |   84.01 |                   
 src               |   85.12 |     81.7 |   88.49 |   85.12 |                   
  cli.ts           |   95.68 |    84.11 |     100 |   95.68 | ...60-561,565-566 
  gemini.tsx       |   73.75 |    79.33 |   80.76 |   73.75 | ...1319-1323,1450 
  ...ractiveCli.ts |   86.74 |    81.15 |   88.13 |   86.74 | ...2955,2961,3026 
  ...liCommands.ts |   89.33 |     85.6 |      90 |   89.33 | ...01,518,552,674 
  ...ActiveAuth.ts |     100 |     87.5 |     100 |     100 | 66-80             
 ...cp-integration |   71.47 |    73.67 |   91.19 |   71.47 |                   
  acpAgent.ts      |   70.88 |    73.47 |   90.74 |   70.88 | ...61,12266-12268 
  ...k-reporter.ts |     100 |    80.95 |     100 |     100 | 77,80,115,135     
  authMethods.ts   |      92 |       60 |     100 |      92 | 33-34             
  errorCodes.ts    |     100 |      100 |     100 |     100 |                   
  ...ion-skills.ts |     100 |    88.23 |     100 |     100 | 17,32             
  generation.ts    |    97.1 |    81.25 |     100 |    97.1 | 109,112           
  ...DirContext.ts |     100 |      100 |     100 |     100 |                   
 ...ration/service |    97.1 |    95.83 |   93.33 |    97.1 |                   
  filesystem.ts    |    97.1 |    95.83 |   93.33 |    97.1 | ...22-123,246-247 
 ...ration/session |   91.49 |    86.99 |   96.71 |   91.49 |                   
  Session.ts       |   90.51 |    85.18 |   95.94 |   90.51 | ...90,10717-10721 
  ...entTracker.ts |    96.8 |    89.36 |      90 |    96.8 | 137-143,221       
  ...projection.ts |   98.57 |    93.29 |     100 |   98.57 | ...76,333,344,356 
  ...stop-guard.ts |     100 |    98.07 |     100 |     100 | 37,127            
  ...eplay-page.ts |   93.44 |    91.74 |     100 |   93.44 | 74,85-88,115-125  
  ...y-replayer.ts |   98.54 |    95.65 |     100 |   98.54 | 241-243           
  index.ts         |       0 |        0 |       0 |       0 | 1-40              
  ...ssionUtils.ts |   89.76 |    87.32 |     100 |   89.76 | ...54-270,326-328 
  ...lure-guard.ts |   98.32 |    97.75 |     100 |   98.32 | 294-295,340-341   
  tasksSnapshot.ts |    94.3 |     87.5 |     100 |    94.3 | 65-71             
  ...on-tracker.ts |     100 |      100 |     100 |     100 |                   
  types.ts         |     100 |      100 |     100 |     100 |                   
 ...ssion/emitters |   96.01 |    94.15 |   96.66 |   96.01 |                   
  ...ageEmitter.ts |   95.95 |       96 |     100 |   95.95 | 52-59             
  PlanEmitter.ts   |     100 |       90 |     100 |     100 | 66                
  base-emitter.ts  |   78.26 |       75 |     100 |   78.26 | 23-24,26-28       
  index.ts         |       0 |        0 |       0 |       0 | 1-10              
  ...ll-emitter.ts |   99.18 |    96.47 |     100 |   99.18 | 355-356           
 ...ession/rewrite |    91.8 |    89.13 |   94.44 |    91.8 |                   
  LlmRewriter.ts   |    82.4 |     86.2 |     100 |    82.4 | ...,88-89,166-170 
  ...Middleware.ts |   96.96 |    88.09 |     100 |   96.96 | 144,152-154       
  TurnBuffer.ts    |     100 |      100 |     100 |     100 |                   
  config.ts        |     100 |      100 |     100 |     100 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  types.ts         |       0 |        0 |       0 |       0 | 1                 
 src/agent-view    |   89.03 |    81.37 |   89.09 |   89.03 |                   
  ...t-cli-argv.ts |     100 |      100 |     100 |     100 |                   
  protocol.ts      |     100 |      100 |     100 |     100 |                   
  ...sor-client.ts |   80.38 |    72.54 |   76.66 |   80.38 | ...22-626,652-656 
  ...or-process.ts |   96.61 |    89.47 |   84.61 |   96.61 | 129-130,150-151   
  ...sor-runner.ts |    84.9 |     75.6 |      85 |    84.9 | ...44,468,471-481 
  ...sor-server.ts |   85.71 |    83.06 |   95.45 |   85.71 | ...67-468,471-488 
  ...isor-store.ts |   97.73 |    81.16 |     100 |   97.73 | ...92,594,607,643 
  ...nal-bridge.ts |   93.98 |     91.3 |   83.33 |   93.98 | 228-238           
 src/commands      |   90.96 |       80 |   66.66 |   90.96 |                   
  auth.ts          |     100 |    83.33 |     100 |     100 | 11,14             
  channel.ts       |   55.55 |      100 |       0 |   55.55 | 18-22,30-40       
  extensions.tsx   |   96.77 |      100 |      50 |   96.77 | 39                
  hooks.tsx        |   66.66 |      100 |       0 |   66.66 | 20-24             
  mcp.ts           |   95.45 |      100 |      50 |   95.45 | 31                
  review.ts        |   98.66 |      100 |      50 |   98.66 | 86                
  serve.ts         |   90.08 |    77.84 |     100 |   90.08 | ...81,884-887,899 
  sessions.ts      |     100 |      100 |      50 |     100 |                   
  update.ts        |   98.13 |    94.44 |   66.66 |   98.13 | 82-83             
 ...mmands/channel |   88.91 |     88.5 |   90.54 |   88.91 |                   
  channel-cwd.ts   |     100 |      100 |     100 |     100 |                   
  ...l-registry.ts |   95.21 |    96.73 |   88.88 |   95.21 | ...18-221,266-269 
  ...entry-path.ts |      75 |       50 |     100 |      75 | 8-9               
  config-utils.ts  |   95.87 |    96.35 |     100 |   95.87 | ...08-213,271-274 
  configure.ts     |    14.7 |      100 |       0 |    14.7 | 18-21,23-84       
  daemon-worker.ts |   93.96 |    85.44 |   94.23 |   93.96 | ...1229,1236-1237 
  loop-runtime.ts  |   91.66 |      100 |      50 |   91.66 | 15,22             
  ...classifier.ts |   98.49 |    96.51 |     100 |   98.49 | 115-116,161       
  ...tact-store.ts |   93.51 |    87.65 |     100 |   93.51 | ...71,288-289,337 
  pairing.ts       |      75 |      100 |      50 |      75 | 22-28,59-70       
  pidfile.ts       |   95.55 |       90 |     100 |   95.55 | ...50-251,315-316 
  proxy.ts         |     100 |      100 |     100 |     100 |                   
  reload.ts        |    77.5 |    86.95 |      75 |    77.5 | 72-84,93-97       
  runtime.ts       |   82.43 |    86.44 |     100 |   82.43 | ...87-191,251-253 
  set.ts           |   75.72 |    85.71 |      50 |   75.72 | 65-83,111-116     
  start.ts         |    85.8 |    82.17 |      88 |    85.8 | ...85,591-594,606 
  ...ure-format.ts |   93.65 |    82.45 |     100 |   93.65 | ...42,48-49,74-75 
  status.ts        |   78.57 |    59.25 |   66.66 |   78.57 | ...36-137,150-161 
  stop.ts          |   57.83 |    82.35 |      50 |   57.83 | ...3,74-76,85-111 
 ...nds/extensions |   88.85 |    87.91 |   87.09 |   88.85 |                   
  consent.ts       |   72.53 |    90.32 |   42.85 |   72.53 | ...86-142,157-163 
  disable.ts       |     100 |       90 |     100 |     100 | 30                
  enable.ts        |     100 |    91.66 |     100 |     100 | 38                
  install.ts       |   82.95 |    81.57 |      75 |   82.95 | ...96-199,202-211 
  link.ts          |     100 |      100 |     100 |     100 |                   
  list.ts          |     100 |     90.9 |     100 |     100 | 18                
  new.ts           |     100 |      100 |     100 |     100 |                   
  settings.ts      |   99.15 |      100 |   83.33 |   99.15 | 151               
  sources.ts       |   93.42 |    87.09 |   92.85 |   93.42 | ...4-66,96-98,167 
  uninstall.ts     |   74.57 |       40 |   66.66 |   74.57 | 45-47,60-67,70-73 
  update.ts        |   96.71 |    97.05 |     100 |   96.71 | 114-118           
  utils.ts         |   75.63 |    57.14 |     100 |   75.63 | ...30-134,136-140 
 ...les/mcp-server |       0 |        0 |       0 |       0 |                   
  example.ts       |       0 |        0 |       0 |       0 | 1-60              
 ...amples/starter |       0 |        0 |       0 |       0 |                   
  example.ts       |       0 |        0 |       0 |       0 | 1-64              
 src/commands/mcp  |   90.31 |    84.61 |   83.33 |   90.31 |                   
  add.ts           |    99.3 |    96.07 |     100 |    99.3 | 154-155           
  approve.ts       |   76.19 |     87.5 |   66.66 |   76.19 | ...,89-99,114-124 
  list.ts          |   93.15 |    84.84 |      80 |   93.15 | ...78-180,198-199 
  reconnect.ts     |   78.85 |    66.66 |   85.71 |   78.85 | 42-55,169-191     
  remove.ts        |     100 |       80 |     100 |     100 | 21-25             
 ...ommands/review |   87.63 |     88.2 |   88.45 |   87.63 |                   
  agent-prompt.ts  |   93.67 |    91.71 |   97.22 |   93.67 | ...2498,2623-2703 
  base-tree.ts     |   76.16 |    80.76 |   77.77 |   76.16 | ...50-371,373-386 
  capture-local.ts |   68.57 |     90.9 |      75 |   68.57 | 107-111,158-189   
  ...k-coverage.ts |   50.71 |       35 |   66.66 |   50.71 | ...40-245,279-289 
  cleanup.ts       |   89.12 |    82.22 |   83.33 |   89.12 | ...99-504,506-507 
  ...ent-status.ts |   93.03 |    83.87 |   83.33 |   93.03 | 291,531-551       
  ...ose-review.ts |   96.99 |    93.17 |   96.66 |   96.99 | ...2197,2225-2247 
  cost-ledger.ts   |   94.67 |    95.86 |   78.57 |   94.67 | ...04-505,545-555 
  drive.ts         |   76.07 |    85.71 |   81.81 |   76.07 | ...90-492,497-499 
  extract-step.ts  |   91.36 |    90.62 |   88.88 |   91.36 | ...90-707,714-729 
  fetch-pr.ts      |    76.7 |    68.75 |   63.63 |    76.7 | ...95,417,450-455 
  findings.ts      |   89.35 |    89.13 |   95.45 |   89.35 | ...15-918,927-928 
  load-rules.ts    |   26.41 |      100 |   16.66 |   26.41 | ...41-153,155-156 
  match-remote.ts  |   85.54 |     92.3 |   66.66 |   85.54 | 67-72,131-136     
  mock-provider.ts |   95.44 |    90.25 |   89.47 |   95.44 | 145,690-709       
  parse-args.ts    |   99.66 |    96.55 |     100 |   99.66 | 404               
  plan-diff.ts     |   64.04 |      100 |   66.66 |   64.04 | 127-163           
  pr-context.ts    |   81.77 |    80.86 |   92.85 |   81.77 | ...1043,1072-1074 
  presubmit.ts     |   83.75 |    92.72 |   88.88 |   83.75 | ...77-578,655-685 
  ...ish-assets.ts |   77.18 |    82.14 |   71.42 |   77.18 | ...85-531,533-544 
  repo-context.ts  |   94.92 |    90.82 |     100 |   94.92 | ...67-368,376-377 
  ...ve-anchors.ts |   77.77 |    88.88 |      75 |   77.77 | ...77-182,194-211 
  run.ts           |   82.16 |    87.12 |   91.66 |   82.16 | ...52,468-516,529 
  save-artifact.ts |    89.9 |    81.81 |   94.11 |    89.9 | ...08-311,404-407 
  script-lint.ts   |   81.14 |    79.23 |   88.88 |   81.14 | ...59-773,775-797 
  submit.ts        |   83.77 |    83.95 |      90 |   83.77 | ...55,544,571-607 
  test-delta.ts    |   87.13 |    91.46 |      75 |   87.13 | 206-237,477-485   
  test-efficacy.ts |   88.04 |    84.12 |   95.45 |   88.04 | ...2602,2610-2630 
  test-plan.ts     |   91.44 |    91.39 |   89.47 |   91.44 | ...38-839,903-920 
 ...w/__fixtures__ |     100 |      100 |     100 |     100 |                   
  ...r-default.mjs |     100 |      100 |     100 |     100 |                   
  ...der-empty.mjs |     100 |      100 |     100 |     100 |                   
  ...der-named.mjs |     100 |      100 |     100 |     100 |                   
 ...nds/review/lib |   97.34 |    94.93 |   98.26 |   97.34 |                   
  agent-briefs.ts  |   98.96 |      100 |      50 |   98.96 | 719-720           
  anchors.ts       |     100 |    94.79 |     100 |     100 | ...33,169,178,225 
  assets.ts        |     100 |      100 |     100 |     100 |                   
  authorization.ts |    92.4 |    92.59 |     100 |    92.4 | 127-133           
  budget.ts        |     100 |    97.14 |     100 |     100 | 513,553           
  coverage.ts      |   96.66 |    94.02 |     100 |   96.66 | ...85-486,526-537 
  deadline.ts      |   98.33 |    93.61 |     100 |   98.33 | ...88,237,629,661 
  diff-flags.ts    |     100 |        0 |     100 |     100 | 63                
  diff-plan.ts     |   98.73 |    93.01 |     100 |   98.73 | ...41,264,290-291 
  disk.ts          |     100 |      100 |     100 |     100 |                   
  effort.ts        |     100 |      100 |     100 |     100 |                   
  gh.ts            |   87.07 |    92.45 |   76.47 |   87.07 | ...72,309-310,337 
  git.ts           |   97.64 |    95.65 |     100 |   97.64 | 180-181           
  heavy.ts         |     100 |      100 |     100 |     100 |                   
  inline-counts.ts |     100 |      100 |     100 |     100 |                   
  ledger.ts        |     100 |      100 |     100 |     100 |                   
  local-diff.ts    |    84.4 |    88.46 |     100 |    84.4 | ...63-473,475-483 
  ...ry-context.ts |   96.19 |    94.93 |     100 |   96.19 | ...90-491,496-499 
  merge-base.ts    |     100 |      100 |     100 |     100 |                   
  npm-toolchain.ts |   97.36 |    95.37 |     100 |   97.36 | ...86,409,770,787 
  path-rules.ts    |     100 |      100 |     100 |     100 |                   
  paths.ts         |     100 |     87.5 |     100 |     100 | 92                
  prompt-record.ts |   97.88 |    93.87 |     100 |   97.88 | 260-261,267       
  receipt.ts       |     100 |      100 |     100 |     100 |                   
  remote-match.ts  |   97.26 |    91.42 |     100 |   97.26 | 49-50             
  report.ts        |   94.68 |    93.75 |     100 |   94.68 | 189-193           
  ...ry-context.ts |     100 |    98.66 |     100 |     100 | 184               
  retirement.ts    |     100 |    92.39 |     100 |     100 | ...28,308-309,449 
  review-footer.ts |     100 |      100 |     100 |     100 |                   
  roster.ts        |     100 |    95.71 |     100 |     100 | 145,163,208       
  shell-quote.ts   |     100 |      100 |     100 |     100 |                   
  stale-bundle.ts  |   98.11 |    94.04 |     100 |   98.11 | 416,457,497-498   
  test-utils.ts    |     100 |      100 |     100 |     100 |                   
  toolchain.ts     |     100 |      100 |     100 |     100 |                   
  transcripts.ts   |   96.59 |     94.5 |     100 |   96.59 | ...08,297-298,323 
  ...pace-scope.ts |     100 |    96.96 |     100 |     100 | 172               
  workspaces.ts    |     100 |    96.77 |     100 |     100 | 222,452,499,512   
  worktree.ts      |     100 |      100 |     100 |     100 |                   
 ...mands/sessions |   91.56 |    86.95 |   83.33 |   91.56 |                   
  common.ts        |     100 |      100 |     100 |     100 |                   
  list.ts          |   90.96 |    86.66 |   81.81 |   90.96 | 208-219,221-222   
 src/config        |    94.9 |    89.83 |   96.27 |    94.9 |                   
  ...l-fallback.ts |     100 |      100 |     100 |     100 |                   
  auth.ts          |   89.35 |    83.56 |     100 |   89.35 | ...97-298,314-315 
  ...eMcpImport.ts |   87.91 |    81.52 |     100 |   87.91 | ...63-371,453-454 
  compile-cache.ts |     100 |      100 |     100 |     100 |                   
  config.ts        |   88.93 |    88.59 |   83.33 |   88.93 | ...2451,2453-2461 
  ...cy-monitor.ts |   88.75 |    76.19 |     100 |   88.75 | ...3,90-92,98,101 
  ...ust-policy.ts |   83.02 |    88.88 |     100 |   83.02 | ...02-209,232-240 
  ...heme-names.ts |     100 |      100 |     100 |     100 |                   
  environment.ts   |    96.5 |    93.51 |      95 |    96.5 | ...85-586,640-641 
  ...le-watcher.ts |   90.86 |    83.65 |   95.83 |   90.86 | ...23-325,370,418 
  ...resh-state.ts |   90.57 |    97.29 |   93.75 |   90.57 | 137-142,146-152   
  ...ime-reload.ts |     100 |    69.69 |     100 |     100 | ...12-113,122-123 
  hot-reload.ts    |     100 |    89.13 |     100 |     100 | 47,172-178,238    
  keyBindings.ts   |    97.4 |       50 |     100 |    97.4 | 240-243           
  ...ngsAdapter.ts |     100 |    94.11 |     100 |     100 | 64                
  ...ig-watcher.ts |   95.17 |    83.05 |     100 |   95.17 | ...78,200,292-293 
  ...er-secrets.ts |   98.97 |    96.87 |     100 |   98.97 | 85                
  mcpApprovals.ts  |   96.55 |    95.55 |     100 |   96.55 | 223-224,229-231   
  mcpJson.ts       |     100 |      100 |     100 |     100 |                   
  mcpServers.ts    |   92.85 |     87.5 |     100 |   92.85 | 46-47             
  ...idersScope.ts |      95 |    94.73 |     100 |      95 | 11-12             
  ...abledTools.ts |     100 |      100 |     100 |     100 |                   
  ...comparison.ts |     100 |      100 |     100 |     100 |                   
  ...n-settings.ts |   99.15 |    93.75 |     100 |   99.15 | 63                
  sandboxConfig.ts |   93.33 |    93.33 |     100 |   93.33 | ...42-147,216-217 
  session-id.ts    |     100 |      100 |     100 |     100 |                   
  ...ings-cache.ts |   96.52 |    93.93 |     100 |   96.52 | 90-91,201-202     
  settings.ts      |   91.27 |    92.64 |      90 |   91.27 | ...1030,1032-1033 
  ...ingsSchema.ts |     100 |      100 |     100 |     100 |                   
  ...ngsWatcher.ts |   95.54 |    88.34 |     100 |   95.54 | ...28,277-278,293 
  ...d-env-keys.ts |     100 |      100 |     100 |     100 |                   
  ...l-settings.ts |     100 |      100 |     100 |     100 |                   
  ...paths-lite.ts |   89.47 |       88 |     100 |   89.47 | 43-44,53-54,56-57 
  ...precedence.ts |   98.79 |     92.3 |     100 |   98.79 | 62                
  ...tedFolders.ts |   92.53 |     93.4 |     100 |   92.53 | ...36-337,373-384 
 ...nfig/migration |   95.23 |    76.47 |   83.33 |   95.23 |                   
  index.ts         |   95.65 |    85.71 |     100 |   95.65 | 117-118           
  scheduler.ts     |   96.55 |    77.77 |     100 |   96.55 | 19-20             
  types.ts         |       0 |        0 |       0 |       0 | 1                 
 ...ation/versions |   94.91 |      100 |     100 |   94.91 |                   
  ...-v2-shared.ts |     100 |      100 |     100 |     100 |                   
  v1-to-v2.ts      |   81.75 |      100 |     100 |   81.75 | ...28-229,231-247 
  v2-to-v3.ts      |     100 |      100 |     100 |     100 |                   
  v3-to-v4.ts      |     100 |      100 |     100 |     100 |                   
  v5-to-v4.ts      |      96 |      100 |     100 |      96 | 94-95,99          
 src/core          |     100 |      100 |     100 |     100 |                   
  auth.ts          |     100 |      100 |     100 |     100 |                   
  initializer.ts   |     100 |      100 |     100 |     100 |                   
  theme.ts         |     100 |      100 |     100 |     100 |                   
 src/dualOutput    |    71.8 |    70.31 |   66.66 |    71.8 |                   
  ...tputBridge.ts |   71.95 |    70.96 |   68.42 |   71.95 | ...08-409,417-420 
  ...utContext.tsx |     100 |      100 |     100 |     100 |                   
  index.ts         |       0 |        0 |       0 |       0 | 1-8               
 src/export        |       0 |        0 |       0 |       0 |                   
  index.ts         |       0 |        0 |       0 |       0 | 1-7               
 src/generated     |     100 |      100 |     100 |     100 |                   
  git-commit.ts    |     100 |      100 |     100 |     100 |                   
 src/hooks         |     100 |      100 |     100 |     100 |                   
  ...elete-hook.ts |     100 |      100 |     100 |     100 |                   
 src/i18n          |   85.98 |    81.92 |   89.65 |   85.98 |                   
  index.ts         |   73.45 |    77.77 |      90 |   73.45 | ...70-271,294-299 
  languages.ts     |   93.07 |     92.3 |   85.71 |   93.07 | ...35,164-169,184 
  ...nslateKeys.ts |     100 |      100 |     100 |     100 |                   
  ...lationDict.ts |   93.33 |    66.66 |     100 |   93.33 | 15                
 src/i18n/locales  |     100 |      100 |     100 |     100 |                   
  ca.js            |     100 |      100 |     100 |     100 |                   
  de.js            |     100 |      100 |     100 |     100 |                   
  en.js            |     100 |      100 |     100 |     100 |                   
  fr.js            |     100 |      100 |     100 |     100 |                   
  ja.js            |     100 |      100 |     100 |     100 |                   
  pt.js            |     100 |      100 |     100 |     100 |                   
  ru.js            |     100 |      100 |     100 |     100 |                   
  zh-TW.js         |     100 |      100 |     100 |     100 |                   
  zh.js            |     100 |      100 |     100 |     100 |                   
 ...nonInteractive |   80.98 |    77.27 |   84.12 |   80.98 |                   
  session.ts       |   84.97 |    76.31 |   96.07 |   84.97 | ...1048,1057-1067 
  types.ts         |    42.5 |      100 |   33.33 |    42.5 | ...31-632,635-636 
 ...active/control |   75.54 |    89.83 |      80 |   75.54 |                   
  ...rolContext.ts |    6.06 |        0 |       0 |    6.06 | 57-99             
  ...Dispatcher.ts |   91.95 |    92.98 |   88.88 |   91.95 | ...54-372,392,395 
  ...rolService.ts |    6.89 |        0 |       0 |    6.89 | 46-188            
 ...ol/controllers |   45.95 |    69.03 |   55.26 |   45.95 |                   
  ...Controller.ts |    42.4 |      100 |   83.33 |    42.4 | 101-105,140-223   
  ...Controller.ts |       0 |        0 |       0 |       0 | 1-56              
  ...Controller.ts |   55.01 |    67.14 |   58.33 |   55.01 | ...15-624,639-644 
  ...Controller.ts |   49.23 |       60 |      50 |   49.23 | ...07-108,111-121 
  ...Controller.ts |   40.64 |    68.11 |   46.66 |   40.64 | ...72-684,693-722 
 .../control/types |       0 |        0 |       0 |       0 |                   
  serviceAPIs.ts   |       0 |        0 |       0 |       0 | 1                 
 ...Interactive/io |    98.1 |    94.13 |   95.23 |    98.1 |                   
  ...putAdapter.ts |   97.98 |     93.2 |   98.07 |   97.98 | ...1415,1431-1432 
  ...putAdapter.ts |      96 |    91.66 |   85.71 |      96 | 51-52             
  ...nputReader.ts |     100 |    94.73 |     100 |     100 | 67                
  ...putAdapter.ts |   98.49 |      100 |   90.47 |   98.49 | 85-86,126-127     
  index.ts         |     100 |      100 |     100 |     100 |                   
 src/patches       |       0 |        0 |       0 |       0 |                   
  is-in-ci.ts      |       0 |        0 |       0 |       0 | 1-17              
 src/remoteInput   |   87.31 |    75.32 |   88.23 |   87.31 |                   
  ...utContext.tsx |     100 |      100 |     100 |     100 |                   
  ...putWatcher.ts |   88.01 |       76 |   93.33 |   88.01 | ...49-350,361-364 
  index.ts         |       0 |        0 |       0 |       0 | 1-8               
 src/runtime       |   99.61 |    95.04 |     100 |   99.61 |                   
  ...livery-ipc.ts |     100 |     90.9 |     100 |     100 | 94,106,134        
  ...l-delivery.ts |     100 |      100 |     100 |     100 |                   
  cpu-percent.ts   |     100 |      100 |     100 |     100 |                   
  ...erver-name.ts |     100 |      100 |     100 |     100 |                   
  ...-constants.ts |     100 |      100 |     100 |     100 |                   
  ...-summaries.ts |   86.66 |       50 |     100 |   86.66 | 11,19             
  ...ber-errors.ts |     100 |    95.32 |     100 |     100 | 53,93-94,172,192  
  ...ls-mapping.ts |     100 |      100 |     100 |     100 |                   
 src/serve         |    87.6 |    83.89 |   90.49 |    87.6 |                   
  ...tp-enabled.ts |     100 |      100 |     100 |     100 |                   
  ...ion-bridge.ts |     100 |      100 |     100 |     100 |                   
  auth.ts          |   93.43 |    93.05 |     100 |   93.43 | ...20-321,324-326 
  ...em-adapter.ts |     100 |      100 |     100 |     100 |                   
  capabilities.ts  |     100 |    98.07 |     100 |     100 | 679               
  ...cp-command.ts |     100 |      100 |     100 |     100 |                   
  ...horization.ts |   92.79 |    93.33 |    87.5 |   92.79 | 75-80,135-136     
  ...op-mcp-ipc.ts |   81.06 |    73.68 |   94.11 |   81.06 | ...37-242,267,289 
  ...nt-service.ts |    94.1 |    86.89 |     100 |    94.1 | ...75-477,484,486 
  ...-selection.ts |     100 |      100 |     100 |     100 |                   
  ...ings-store.ts |   88.59 |    93.68 |   96.29 |   88.59 | ...95-207,451-454 
  ...ebhook-ipc.ts |    98.5 |    86.66 |     100 |    98.5 | 47                
  ...iagnostics.ts |     100 |      100 |     100 |     100 |                   
  ...worker-env.ts |     100 |      100 |     100 |     100 |                   
  ...rker-group.ts |   87.27 |     85.2 |     100 |   87.27 | ...10,816-820,838 
  ...er-manager.ts |   89.39 |    83.88 |   93.33 |   89.39 | ...98,711,722-724 
  ...tartup-ipc.ts |   97.72 |    96.66 |     100 |   97.72 | 88-89             
  ...supervisor.ts |   92.42 |    84.44 |    97.1 |   92.42 | ...1466,1520-1524 
  ...e-grouping.ts |     100 |    94.28 |     100 |     100 | 71,137            
  core-runtime.ts  |     100 |      100 |     100 |     100 |                   
  ...ub-session.ts |    90.1 |    77.83 |   94.73 |    90.1 | ...1014,1021-1026 
  daemon-logger.ts |    82.2 |    77.42 |   91.76 |    82.2 | ...1720,1747-1753 
  ...y-pressure.ts |     100 |    96.96 |     100 |     100 | 135               
  ...trics-ring.ts |     100 |      100 |     100 |     100 |                   
  ...s-provider.ts |   68.04 |    52.77 |     100 |   68.04 | ...44-249,282-290 
  daemon-status.ts |   98.58 |    90.88 |     100 |   98.58 | ...1438,1440-1441 
  debug-mode.ts    |     100 |      100 |     100 |     100 |                   
  env-snapshot.ts  |   93.37 |    85.18 |     100 |   93.37 | 114-117,195-202   
  ...-scheduler.ts |   87.34 |    83.87 |     100 |   87.34 | 33-36,48-50,79-81 
  ...d-provider.ts |   92.06 |    86.95 |     100 |   92.06 | ...72,287-293,316 
  ...-path-argv.ts |     100 |      100 |     100 |     100 |                   
  ...h-settings.ts |   94.94 |    90.41 |     100 |   94.94 | ...30,708,724,734 
  fast-path.ts     |   90.99 |    81.38 |   95.45 |   90.99 | ...33-542,608-609 
  ...ration-sse.ts |   42.55 |    33.33 |     100 |   42.55 | 23-24,30,33-56    
  health-query.ts  |     100 |      100 |     100 |     100 |                   
  index.ts         |       0 |        0 |       0 |       0 | 1-144             
  ...e-observer.ts |   89.89 |    83.24 |      96 |   89.89 | ...11-512,541-543 
  ...back-binds.ts |     100 |    88.88 |     100 |     100 | 32                
  ...-workspace.ts |    90.9 |    85.71 |     100 |    90.9 | ...30-131,142-143 
  ...iders-edit.ts |     100 |    82.14 |     100 |     100 | 58-60,65,81       
  ...ory-picker.ts |     100 |    86.95 |     100 |     100 | 36,66,92          
  ...sion-audit.ts |     100 |      100 |   93.33 |     100 |                   
  rate-limit.ts    |   92.68 |    88.29 |     100 |   92.68 | ...89-291,303-305 
  ...qwen-serve.ts |   84.27 |    80.34 |    75.6 |   84.27 | ...7571,7577-7578 
  ...tup-errors.ts |     100 |      100 |     100 |     100 |                   
  ...-keepalive.ts |   94.22 |    88.99 |     100 |   94.22 | ...27,531-532,572 
  ...-lifecycle.ts |     100 |      100 |     100 |     100 |                   
  server.ts        |   90.59 |    91.18 |   71.81 |   90.59 | ...2720,2734-2738 
  ...-admission.ts |   98.24 |    94.73 |     100 |   98.24 | 79-80,303-304     
  ...on-helpers.ts |     100 |      100 |     100 |     100 |                   
  ...t-event-id.ts |     100 |    95.23 |     100 |     100 | 12                
  ...-admission.ts |   98.71 |    89.65 |     100 |   98.71 | 68                
  types.ts         |     100 |      100 |     100 |     100 |                   
  ...ion-limits.ts |     100 |      100 |     100 |     100 |                   
  ...t-sessions.ts |   93.72 |    77.93 |     100 |   93.72 | ...51,854,867-869 
  ...l-resolver.ts |   90.32 |    66.66 |     100 |   90.32 | 16,45-46          
  ...ell-static.ts |   92.18 |    88.37 |     100 |   92.18 | ...21-224,267-270 
  ...ace-agents.ts |   66.13 |    70.57 |   92.68 |   66.13 | ...2246,2256-2266 
  ...generation.ts |    95.4 |    82.35 |   66.66 |    95.4 | 55-56,78,92       
  ...-git-state.ts |     100 |    91.93 |    90.9 |     100 | 161,172,202,265   
  ...ace-inputs.ts |     100 |      100 |     100 |     100 |                   
  ...ace-memory.ts |      83 |    74.54 |     100 |      83 | ...30-537,597-604 
  ...ers-status.ts |   98.58 |       79 |     100 |   98.58 | 106,134,174,177   
  ...tion-store.ts |   89.67 |    88.27 |   92.59 |   89.67 | ...91-400,411-414 
  ...e-registry.ts |   93.89 |     87.5 |     100 |   93.89 | ...18-519,525-526 
  ...e-remember.ts |   98.23 |    92.51 |     100 |   98.23 | ...36,340-345,386 
  ...te-runtime.ts |   83.98 |    90.29 |     100 |   83.98 | ...48-156,216-237 
  ...me-storage.ts |     100 |      100 |     100 |     100 |                   
  ...management.ts |   72.63 |    72.72 |      96 |   72.63 | ...88-889,896-900 
  ...lls-status.ts |     100 |    95.45 |     100 |     100 | 152               
  ...reconciler.ts |   91.63 |    84.09 |     100 |   91.63 | ...71-273,306-307 
 ...serve/acp-http |   78.26 |    80.02 |    93.1 |   78.26 |                   
  ...r-registry.ts |   96.92 |    94.87 |     100 |   96.92 | 184-187           
  client-mcp-ws.ts |   54.85 |    58.62 |   72.72 |   54.85 | ...99-300,304-305 
  ...n-registry.ts |    98.2 |    88.55 |     100 |    98.2 | 1015,1041-1052    
  dispatch.ts      |   73.87 |    77.71 |   94.23 |   73.87 | ...5240,5288-5294 
  index.ts         |   82.23 |    80.11 |   91.07 |   82.23 | ...2341,2425-2426 
  json-rpc.ts      |     100 |    96.96 |     100 |     100 | 92                
  safe-ws-send.ts  |   52.94 |    71.42 |     100 |   52.94 | 33-42,47-55       
  sse-stream.ts    |   93.96 |    88.57 |   84.61 |   93.96 | ...57-159,161-163 
  ...ort-stream.ts |       0 |        0 |       0 |       0 | 1                 
  ws-stream.ts     |   91.86 |       80 |     100 |   91.86 | 45,50,96,100-103  
 src/serve/auth    |   86.86 |     79.7 |   93.87 |   86.86 |                   
  device-flow.ts   |   96.35 |    80.57 |   97.61 |   96.35 | ...1358,1453,1519 
  ...w-provider.ts |   44.24 |    74.07 |   71.42 |   44.24 | ...23-284,297,301 
 ...rve/cdp-tunnel |   87.73 |    76.21 |    97.5 |   87.73 |                   
  ...r-emulator.ts |   93.27 |    77.77 |     100 |   93.27 | ...53-256,282-283 
  ...verse-link.ts |      88 |    76.19 |     100 |      88 | ...28-329,420-423 
  ...l-registry.ts |     100 |      100 |     100 |     100 |                   
  cdp-ws.ts        |   76.28 |    61.29 |    87.5 |   76.28 | ...13-217,223-228 
 ...nel/acceptance |    6.12 |    57.89 |   46.15 |    6.12 |                   
  ...helpers.d.mts |       0 |        0 |       0 |       0 | 1                 
  ...e-helpers.mjs |   97.64 |    70.96 |     100 |   97.64 | 22-23             
  ...mcp-smoke.mjs |       0 |        0 |       0 |       0 | 1-124             
  ...cceptance.mjs |       0 |        0 |       0 |       0 | 1-473             
  ...re-server.mjs |       0 |        0 |       0 |       0 | 1-59              
  ...ols-smoke.mjs |       0 |        0 |       0 |       0 | 1-268             
  real-tab.mjs     |       0 |        0 |       0 |       0 | 1-218             
  ...al-chrome.mjs |       0 |        0 |       0 |       0 | 1-223             
 src/serve/fs      |   86.46 |    81.42 |     100 |   86.46 |                   
  audit.ts         |     100 |    96.15 |     100 |     100 | 204               
  errors.ts        |     100 |      100 |     100 |     100 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...x-registry.ts |     100 |      100 |     100 |     100 |                   
  paths.ts         |   77.64 |    74.21 |     100 |   77.64 | ...65,594-598,611 
  policy.ts        |   90.42 |    89.18 |     100 |   90.42 | 161-169           
  text-cursor.ts   |   88.23 |       90 |     100 |   88.23 | 74-77,92-95       
  ...ile-system.ts |   86.27 |    80.56 |     100 |   86.27 | ...2699,2709-2710 
 src/serve/live    |   78.01 |    69.52 |   90.61 |   78.01 |                   
  ...en-context.ts |   95.74 |    81.25 |     100 |   95.74 | ...0,66-67,99-100 
  ...-workspace.ts |   88.63 |    82.53 |     100 |   88.63 | ...40-241,253-254 
  discovery.ts     |   85.77 |    76.92 |      90 |   85.77 | ...49-250,255-256 
  ...structions.ts |     100 |      100 |     100 |     100 |                   
  ...oordinator.ts |   82.67 |    76.75 |   97.01 |   82.67 | ...1319,1351-1353 
  ...-installer.ts |    64.3 |    82.35 |   80.76 |    64.3 | ...45-446,460-472 
  ...oordinator.ts |   75.99 |    65.18 |   85.71 |   75.99 | ...1883,1974-1975 
  ...controller.ts |   67.82 |    79.31 |   72.72 |   67.82 | ...66-278,287-295 
  ...ak-to-user.ts |   96.66 |      100 |   83.33 |   96.66 | 37-38             
  ...sk-service.ts |    86.3 |    59.78 |   93.33 |    86.3 | ...1160,1184-1191 
  ...task-tools.ts |      99 |      100 |   85.71 |      99 | 205-206           
  ...redentials.ts |   96.26 |    93.47 |     100 |   96.26 | 91-94             
  ...me-session.ts |   65.63 |    57.24 |   88.88 |   65.63 | ...2270,2275-2282 
  ...up-context.ts |   94.83 |    77.58 |     100 |   94.83 | ...18,327-330,350 
  ...ion-source.ts |     100 |      100 |     100 |     100 |                   
  types.ts         |     100 |      100 |     100 |     100 |                   
 src/serve/routes  |   85.63 |    80.13 |   94.75 |   85.63 |                   
  a2ui-action.ts   |   96.84 |     88.5 |    87.5 |   96.84 | ...70-272,309-311 
  capabilities.ts  |     100 |      100 |     100 |     100 |                   
  ...nel-notify.ts |   86.45 |       88 |     100 |   86.45 | ...,83-87,103-104 
  ...l-webhooks.ts |   93.56 |    84.09 |     100 |   93.56 | ...42,292,332,334 
  daemon-status.ts |   85.71 |    83.33 |     100 |   85.71 | 101-108           
  goals.ts         |   98.92 |     90.9 |     100 |   98.92 | 146               
  health.ts        |   99.09 |    91.17 |     100 |   99.09 | 147               
  live-setup.ts    |   33.33 |     37.5 |      50 |   33.33 | ...18-123,130-135 
  live.ts          |    82.4 |    71.42 |     100 |    82.4 | ...-94,96-101,121 
  permission.ts    |     100 |     92.3 |     100 |     100 | 50,98             
  ...uled-tasks.ts |   87.29 |    82.94 |   92.59 |   87.29 | ...1275,1318-1319 
  ...on-runtime.ts |     100 |    90.47 |     100 |     100 | 58,94             
  session.ts       |   85.87 |     82.3 |   91.54 |   85.87 | ...4873,4875-4876 
  sse-events.ts    |   86.82 |    85.71 |   94.11 |   86.82 | ...16-927,930,937 
  usage-stats.ts   |     100 |    95.45 |     100 |     100 | 118               
  ...space-auth.ts |   85.55 |    75.64 |     100 |   85.55 | ...21-326,331,345 
  ...el-control.ts |   86.26 |    78.94 |     100 |   86.26 | ...17-318,339-347 
  ...management.ts |   90.92 |    79.69 |     100 |   90.92 | ...81-482,501-502 
  ...d-contacts.ts |     100 |      100 |     100 |     100 |                   
  ...controller.ts |   83.11 |    79.31 |      90 |   83.11 | ...1033,1039,1042 
  ...extensions.ts |   88.15 |    74.95 |   92.98 |   88.15 | ...2027,2072-2073 
  ...-file-read.ts |      91 |    80.91 |     100 |      91 | ...20-621,624-625 
  ...file-write.ts |   84.44 |    64.51 |     100 |   84.44 | ...73-275,355-357 
  ...t-branches.ts |   75.43 |    66.66 |     100 |   75.43 | ...13-618,627-634 
  ...e-git-diff.ts |   97.32 |    90.56 |     100 |   97.32 | 161-162,189-191   
  ...ce-git-log.ts |     100 |    93.18 |     100 |     100 | 52,77,188         
  workspace-git.ts |   77.08 |    89.65 |     100 |   77.08 | 97-118            
  ...github-prs.ts |   88.26 |    63.46 |     100 |   88.26 | ...38-239,264-265 
  ...-lifecycle.ts |   95.23 |    75.75 |     100 |   95.23 | ...50-151,186-187 
  ...management.ts |   87.41 |    84.13 |     100 |   87.41 | ...1660,1680-1685 
  ...cp-control.ts |    73.2 |    67.54 |   85.71 |    73.2 | ...27-633,644-645 
  ...ace-models.ts |   95.53 |    89.74 |     100 |   95.53 | ...52-157,296-297 
  ...ermissions.ts |    77.9 |    72.41 |     100 |    77.9 | ...69-277,298-316 
  ...e-settings.ts |   75.04 |    72.99 |     100 |   75.04 | ...79-690,696-697 
  ...tup-github.ts |   77.97 |    70.58 |   84.21 |   77.97 | ...46-352,397-398 
  ...ace-skills.ts |    76.9 |    87.15 |     100 |    76.9 | ...29-354,360-394 
  ...ace-status.ts |   82.94 |     74.5 |     100 |   82.94 | ...84-486,490-491 
  ...pace-tools.ts |   75.94 |    69.69 |   66.66 |   75.94 | ...59-164,193-194 
  ...pace-trust.ts |   78.92 |    66.21 |      80 |   78.92 | ...38-343,351-352 
  ...pace-voice.ts |   91.33 |    80.92 |     100 |   91.33 | ...70-673,676-678 
 src/serve/server  |   91.74 |    89.37 |   96.95 |   91.74 |                   
  access-log.ts    |   98.68 |     97.1 |     100 |   98.68 | 115,186           
  ...er-helpers.ts |   63.82 |    77.96 |   81.81 |   63.82 | ...16,330,332-347 
  ...w-registry.ts |    98.8 |    81.81 |     100 |    98.8 | 107               
  ...r-handlers.ts |   97.29 |       75 |     100 |   97.29 | 17                
  ...r-response.ts |   86.54 |    72.48 |     100 |   86.54 | ...49,766,829-838 
  fs-factory.ts    |     100 |    94.54 |     100 |     100 | 42,103,159        
  ...branch-ops.ts |     100 |      100 |     100 |     100 |                   
  ...list-cache.ts |   99.01 |    95.52 |     100 |   99.01 | 184-185           
  ...t-deadline.ts |     100 |      100 |     100 |     100 |                   
  ...iter-setup.ts |      65 |    73.33 |   33.33 |      65 | 30-35,38-43,47-48 
  ...st-helpers.ts |   95.13 |    95.09 |     100 |   95.13 | ...66-168,423-428 
  self-origin.ts   |   76.19 |       80 |     100 |   76.19 | 45-54             
  ...e-features.ts |      95 |     87.5 |     100 |      95 | 182-188           
  ...on-archive.ts |   89.55 |    87.72 |   97.14 |   89.55 | ...32-836,888-889 
  ...ion-export.ts |     100 |    94.44 |     100 |     100 | 64                
  session-list.ts  |   95.86 |    93.37 |     100 |   95.86 | ...-848,1026-1030 
  telemetry.ts     |   99.03 |    97.44 |     100 |   99.03 | ...31,645,787-789 
 src/serve/voice   |    92.7 |    91.48 |   97.67 |    92.7 |                   
  ...ice-config.ts |   84.81 |       30 |     100 |   84.81 | 91-100,104-105    
  voice-ws.ts      |   91.58 |    93.44 |      96 |   91.58 | ...68,483,521-523 
  ...oordinator.ts |     100 |    98.21 |     100 |     100 | 176               
 ...kspace-service |   90.65 |    87.73 |   91.11 |   90.65 |                   
  index.ts         |   90.13 |    87.04 |   89.74 |   90.13 | ...1464-1468,1471 
  types.ts         |     100 |      100 |     100 |     100 |                   
 src/services      |   92.49 |    89.25 |      98 |   92.49 |                   
  ...mandLoader.ts |     100 |    88.88 |     100 |     100 | 105-118           
  ...killLoader.ts |   97.19 |    85.29 |     100 |   97.19 | 142,153-154       
  ...andService.ts |   98.73 |      100 |     100 |   98.73 | 107               
  ...mandLoader.ts |   87.09 |    83.07 |     100 |   87.09 | ...35-340,345-350 
  ...omptLoader.ts |   79.55 |    88.29 |   83.33 |   79.55 | ...48,178,245-246 
  ...mandLoader.ts |   97.77 |    92.15 |     100 |   97.77 | 176,183-184       
  ...nd-factory.ts |   91.42 |    91.66 |     100 |   91.42 | 128,137-144       
  ...ation-tool.ts |     100 |    95.45 |     100 |     100 | 125               
  ...ndMetadata.ts |   98.23 |    96.72 |     100 |   98.23 | 83,87             
  commandUtils.ts  |      96 |     90.9 |     100 |      96 | 48                
  ...and-parser.ts |   90.69 |    85.71 |     100 |   90.69 | 63-66             
  ...ionService.ts |     100 |      100 |     100 |     100 |                   
  prompt-stash.ts  |   96.66 |    92.85 |     100 |   96.66 | 34-35             
  ...tree-lease.ts |   88.23 |    86.48 |     100 |   88.23 | ...94-199,232-233 
  ...low-loader.ts |     100 |    96.15 |     100 |     100 | 88                
  setup-github.ts  |    90.8 |    80.95 |     100 |    90.8 | ...49-450,457-458 
  ...-args-file.ts |   93.93 |    91.66 |    87.5 |   93.93 | 208-210,224-230   
  types.ts         |     100 |      100 |     100 |     100 |                   
  ...e-keyterms.ts |   98.64 |    95.77 |     100 |   98.64 | 116,142-143       
  voice-model.ts   |     100 |      100 |     100 |     100 |                   
  voice-service.ts |    90.4 |    87.87 |     100 |    90.4 | ...81,288,353-358 
  ...e-settings.ts |     100 |    95.23 |     100 |     100 | 19                
  ...ranscriber.ts |   91.77 |    87.11 |   97.22 |   91.77 | ...99-901,904-906 
 ...rvices/insight |     100 |      100 |     100 |     100 |                   
  dates.ts         |     100 |      100 |     100 |     100 |                   
 ...ght/generators |   88.91 |     86.8 |   96.15 |   88.91 |                   
  DataProcessor.ts |   88.28 |    86.77 |   94.73 |   88.28 | ...1362,1366-1373 
  ...tGenerator.ts |   98.24 |    85.71 |     100 |   98.24 | 47                
  ...teRenderer.ts |     100 |      100 |     100 |     100 |                   
 .../insight/types |       0 |       50 |      50 |       0 |                   
  ...sightTypes.ts |       0 |        0 |       0 |       0 |                   
  ...sightTypes.ts |       0 |        0 |       0 |       0 | 1                 
 ...mpt-processors |   97.27 |    94.04 |     100 |   97.27 |                   
  ...tProcessor.ts |     100 |      100 |     100 |     100 |                   
  ...eProcessor.ts |   94.52 |    84.21 |     100 |   94.52 | 46-47,93-94       
  ...tionParser.ts |     100 |      100 |     100 |     100 |                   
  ...lProcessor.ts |   97.41 |    95.65 |     100 |   97.41 | 96-99             
  types.ts         |     100 |      100 |     100 |     100 |                   
 src/services/tips |   97.27 |    84.61 |     100 |   97.27 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  tipHistory.ts    |   92.59 |       70 |     100 |   92.59 | ...24,146,153,162 
  tipRegistry.ts   |     100 |      100 |     100 |     100 |                   
  tipScheduler.ts  |     100 |    91.66 |     100 |     100 | 55                
 src/startup       |   88.99 |    83.47 |    90.9 |   88.99 |                   
  ...p-prefetch.ts |   98.09 |    94.23 |    87.5 |   98.09 | 50,209,225-226    
  ...reeStartup.ts |   80.53 |     74.6 |     100 |   80.53 | ...94,403,409-412 
 src/test-utils    |   94.09 |    79.16 |   77.77 |   94.09 |                   
  ci-env.ts        |      88 |     62.5 |     100 |      88 | 22-23,28          
  ...omMatchers.ts |   69.69 |       50 |      50 |   69.69 | 32-35,37-39,45-47 
  ...mised-lock.ts |     100 |      100 |   66.66 |     100 |                   
  ...andContext.ts |     100 |      100 |     100 |     100 |                   
  render.tsx       |     100 |      100 |     100 |     100 |                   
 src/ui            |   73.15 |    75.52 |   67.03 |   73.15 |                   
  App.tsx          |   33.33 |       75 |   33.33 |   33.33 | 32-86             
  AppContainer.tsx |   74.35 |    72.04 |   68.57 |   74.35 | ...4181,4297-4303 
  ...tionNudge.tsx |    9.58 |      100 |       0 |    9.58 | 24-94             
  ...ackDialog.tsx |    30.3 |      100 |       0 |    30.3 | 26-76             
  ...tionNudge.tsx |    7.69 |      100 |       0 |    7.69 | 25-103            
  colors.ts        |      60 |      100 |   35.29 |      60 | ...52,54-55,60-61 
  constants.ts     |     100 |      100 |     100 |     100 |                   
  keyMatchers.ts   |   95.91 |    97.14 |     100 |   95.91 | 25-26             
  ...tic-colors.ts |     100 |      100 |     100 |     100 |                   
  ...ractiveUI.tsx |   70.51 |       74 |    62.5 |   70.51 | ...12,339,392-397 
  ...inePresets.ts |   96.27 |    83.87 |     100 |   96.27 | ...97,402,410-412 
  textConstants.ts |     100 |      100 |     100 |     100 |                   
  types.ts         |     100 |      100 |     100 |     100 |                   
 src/ui/auth       |   58.53 |    66.18 |   51.06 |   58.53 |                   
  AuthDialog.tsx   |   59.01 |     42.1 |   16.66 |   59.01 | ...25,332-354,358 
  ...nProgress.tsx |       0 |        0 |       0 |       0 | 1-64              
  ...etupSteps.tsx |   60.21 |    70.73 |   57.69 |   60.21 | ...90,794,803,806 
  useAuth.ts       |    94.6 |    73.52 |     100 |    94.6 | ...21-222,241-247 
  ...rSetupFlow.ts |   43.18 |    33.33 |      50 |   43.18 | ...78-399,416-459 
 src/ui/commands   |   82.69 |     83.2 |   89.17 |   82.69 |                   
  aboutCommand.ts  |     100 |      100 |     100 |     100 |                   
  agentsCommand.ts |   83.78 |      100 |      60 |   83.78 | 30-32,42-44       
  ...odeCommand.ts |    93.1 |    95.23 |     100 |    93.1 | 77-82             
  arenaCommand.ts  |   63.89 |    65.71 |   65.21 |   63.89 | ...01-606,691-699 
  authCommand.ts   |     100 |      100 |     100 |     100 |                   
  branchCommand.ts |     100 |      100 |     100 |     100 |                   
  btwCommand.ts    |   94.32 |    81.25 |     100 |   94.32 | 35-36,114-119     
  bugCommand.ts    |     100 |    77.77 |     100 |     100 | 27,61             
  cdCommand.ts     |    92.3 |    82.75 |     100 |    92.3 | ...,94-99,178,187 
  clearCommand.ts  |    80.9 |    70.83 |     100 |    80.9 | ...28-129,137-146 
  ...essCommand.ts |   68.06 |    54.05 |      75 |   68.06 | ...96-197,211-214 
  ...astCommand.ts |   84.17 |       75 |     100 |   84.17 | ...,91-97,125-130 
  ...ig-command.ts |   93.12 |    88.42 |     100 |   93.12 | ...07-315,321-323 
  ...extCommand.ts |   69.07 |     72.6 |   84.61 |   69.07 | ...78-611,622-623 
  copyCommand.ts   |    98.7 |    96.29 |     100 |    98.7 | 66-67,172,272,323 
  ...or-command.ts |   85.95 |    80.55 |   88.88 |   85.95 | ...68-274,298-309 
  deleteCommand.ts |     100 |      100 |     100 |     100 |                   
  diffCommand.ts   |     100 |    87.87 |     100 |     100 | ...63,231-232,245 
  ...ryCommand.tsx |   81.64 |    87.67 |    90.9 |   81.64 | ...73-278,325-332 
  docsCommand.ts   |     100 |     90.9 |     100 |     100 | 25                
  doctorCommand.ts |   65.37 |    81.88 |   94.11 |   65.37 | ...85-535,538-672 
  dreamCommand.ts  |   85.45 |    88.88 |     100 |   85.45 | 58-65             
  editorCommand.ts |     100 |      100 |     100 |     100 |                   
  ...rt-command.ts |   80.48 |       75 |     100 |   80.48 | 49-54,69-72,93-98 
  effort-utils.ts  |     100 |      100 |     100 |     100 |                   
  exportCommand.ts |   98.25 |    91.02 |     100 |   98.25 | ...81,198-199,364 
  ...onsCommand.ts |   52.31 |    56.25 |   69.23 |   52.31 | ...09,277-329,390 
  forgetCommand.ts |     100 |       90 |     100 |     100 | 59                
  forkCommand.ts   |     100 |    94.11 |     100 |     100 | 96,147            
  goalCommand.ts   |   72.81 |    86.84 |   66.66 |   72.81 | ...63-168,277-280 
  helpCommand.ts   |     100 |      100 |     100 |     100 |                   
  ...oryCommand.ts |     100 |      100 |     100 |     100 |                   
  hooksCommand.ts  |   81.13 |    65.71 |   85.71 |   81.13 | ...,86-93,131-132 
  ideCommand.ts    |   60.75 |    64.28 |   41.17 |   60.75 | ...05-306,310-324 
  ...figCommand.ts |   52.83 |    81.25 |      70 |   52.83 | ...74-319,321-330 
  initCommand.ts   |   91.86 |       80 |     100 |   91.86 | 48,83-88          
  ...ghtCommand.ts |   77.87 |    71.42 |     100 |   77.87 | ...44-245,250-272 
  ...ageCommand.ts |   94.44 |    90.14 |     100 |   94.44 | ...13-214,241-251 
  learn-command.ts |     100 |      100 |     100 |     100 |                   
  lspCommand.ts    |     100 |    86.95 |     100 |     100 | 31,101-102        
  mcpCommand.ts    |     100 |      100 |     100 |     100 |                   
  memoryCommand.ts |     100 |      100 |     100 |     100 |                   
  modelCommand.ts  |   84.78 |    82.47 |     100 |   84.78 | ...1071,1105-1110 
  ...onsCommand.ts |     100 |      100 |     100 |     100 |                   
  planCommand.ts   |   78.82 |    76.92 |     100 |   78.82 | 30-35,51-56,68-73 
  quitCommand.ts   |     100 |      100 |     100 |     100 |                   
  recapCommand.ts  |   21.81 |      100 |      50 |   21.81 | 24-73             
  ...ns-command.ts |   98.83 |    81.81 |     100 |   98.83 | 100               
  ...berCommand.ts |     100 |     87.5 |     100 |     100 | 46                
  renameCommand.ts |   89.06 |    88.37 |     100 |   89.06 | ...72-176,202-209 
  ...oreCommand.ts |   90.96 |    86.04 |     100 |   90.96 | ...41-146,177-178 
  resumeCommand.ts |     100 |      100 |     100 |     100 |                   
  rewindCommand.ts |   81.25 |      100 |      50 |   81.25 | 20-22             
  ...ngsCommand.ts |     100 |      100 |     100 |     100 |                   
  ...hubCommand.ts |   89.47 |       75 |      80 |   89.47 | 54-59             
  skillsCommand.ts |   78.82 |    81.81 |     100 |   78.82 | 37-52,78,97       
  statsCommand.ts  |   90.65 |    76.73 |     100 |   90.65 | ...30-733,825-832 
  ...ineCommand.ts |     100 |      100 |     100 |     100 |                   
  ...aryCommand.ts |   73.04 |     82.3 |      90 |   73.04 | ...20-547,561-565 
  tasksCommand.ts  |   77.22 |    72.13 |     100 |   77.22 | ...46-150,172-177 
  ...tupCommand.ts |     100 |      100 |     100 |     100 |                   
  themeCommand.ts  |     100 |      100 |     100 |     100 |                   
  toolsCommand.ts  |     100 |      100 |     100 |     100 |                   
  trustCommand.ts  |     100 |      100 |     100 |     100 |                   
  types.ts         |     100 |      100 |     100 |     100 |                   
  ...te-command.ts |     100 |    94.11 |     100 |     100 | 74,148            
  vimCommand.ts    |   54.54 |      100 |      50 |   54.54 | 19-29             
  voice-command.ts |   93.57 |       88 |     100 |   93.57 | 35,97-102         
  ...owsCommand.ts |   92.92 |       85 |   66.66 |   92.92 | ...72-177,276-281 
 src/ui/components |   71.73 |    79.32 |   79.85 |   71.73 |                   
  AboutBox.tsx     |     100 |      100 |     100 |     100 |                   
  AnsiOutput.tsx   |   65.57 |      100 |      50 |   65.57 | 69-90             
  ApiKeyInput.tsx  |       0 |        0 |       0 |       0 | 1-97              
  AppHeader.tsx    |    88.7 |       75 |     100 |    88.7 | 36,38-43,45       
  ...odeDialog.tsx |   87.24 |    72.22 |   33.33 |   87.24 | ...85,233-238,245 
  AsciiArt.ts      |     100 |      100 |     100 |     100 |                   
  ...Indicator.tsx |   95.65 |    66.66 |     100 |   95.65 | 27,52             
  ...TextInput.tsx |   88.65 |    90.41 |     100 |   88.65 | ...84-286,300-302 
  Composer.tsx     |   94.49 |    66.66 |     100 |   94.49 | ...-72,84,139,153 
  ...entPrompt.tsx |     100 |      100 |     100 |     100 |                   
  ...ryDisplay.tsx |   75.89 |    62.06 |     100 |   75.89 | ...,88,93-108,113 
  ...geDisplay.tsx |   68.42 |    57.14 |     100 |   68.42 | 16-17,31-32,42-50 
  CronPill.tsx     |     100 |    93.75 |     100 |     100 | 19                
  ...ification.tsx |      84 |       60 |     100 |      84 | 23-24,40-42       
  ...gProfiler.tsx |       0 |        0 |       0 |       0 | 1-36              
  ...ogManager.tsx |       0 |        0 |       0 |       0 | 1-598             
  DiffDialog.tsx   |    53.5 |     37.5 |   69.23 |    53.5 | ...32-737,747-760 
  ...ngsDialog.tsx |       0 |        0 |       0 |       0 | 1-195             
  EffortDialog.tsx |   97.36 |      100 |     100 |   97.36 | 55-56             
  ExitWarning.tsx  |     100 |      100 |     100 |     100 |                   
  ...hProgress.tsx |    87.8 |    33.33 |     100 |    87.8 | 28-31,56          
  ...ustDialog.tsx |     100 |      100 |     100 |     100 |                   
  Footer.tsx       |   81.19 |    69.23 |      50 |   81.19 | ...02,240,262-267 
  ...ngSpinner.tsx |   68.42 |    85.71 |      50 |   68.42 | 35-52,73,80-81    
  GoalPill.tsx     |   93.51 |    81.81 |     100 |   93.51 | 37-38,106-109,123 
  Header.tsx       |   98.65 |    94.73 |     100 |   98.65 | 173,175           
  Help.tsx         |   98.33 |       90 |     100 |   98.33 | ...25,382,448-449 
  ...emDisplay.tsx |   79.28 |    66.99 |     100 |   79.28 | ...08,511,514-520 
  ...ngeDialog.tsx |     100 |      100 |     100 |     100 |                   
  InputPrompt.tsx  |   84.26 |    82.94 |      80 |   84.26 | ...2215,2236,2332 
  ...Shortcuts.tsx |     100 |       88 |     100 |     100 | 98,119            
  ...Indicator.tsx |   98.18 |    97.82 |     100 |   98.18 | 161-162           
  ...firmation.tsx |   91.42 |      100 |      50 |   91.42 | 26-31             
  MainContent.tsx  |   96.31 |    95.06 |      50 |   96.31 | ...01,464-468,471 
  MemoryDialog.tsx |   86.59 |    80.15 |     100 |   86.59 | ...34-435,485,553 
  ...geDisplay.tsx |       0 |        0 |       0 |       0 | 1-41              
  ModelDialog.tsx  |   81.95 |    71.27 |     100 |   81.95 | ...1045,1050-1066 
  ...tsDisplay.tsx |     100 |    97.22 |     100 |     100 | 270               
  ...fications.tsx |       0 |        0 |       0 |       0 | 1-56              
  ...onsDialog.tsx |       0 |        0 |       0 |       0 | 1-1004            
  ...ryDisplay.tsx |     100 |      100 |     100 |     100 |                   
  ...icePrompt.tsx |   92.64 |    85.71 |     100 |   92.64 | 102-106,134-139   
  PrepareLabel.tsx |   91.66 |    77.27 |     100 |   91.66 | 73-75,77-79,110   
  ...atePrompt.tsx |       0 |        0 |       0 |       0 | 1-134             
  ...geDisplay.tsx |     100 |      100 |     100 |     100 |                   
  ...ngDisplay.tsx |       0 |        0 |       0 |       0 | 1-39              
  ...hProgress.tsx |   85.25 |    88.46 |     100 |   85.25 | 121-147           
  ...dSelector.tsx |   92.79 |    82.65 |     100 |   92.79 | ...19-323,354-370 
  ...ionPicker.tsx |   83.66 |    72.13 |     100 |   83.66 | ...96,402,444-466 
  ...onPreview.tsx |   93.58 |    83.78 |     100 |   93.58 | ...,70-71,195-197 
  ...ryDisplay.tsx |     100 |      100 |     100 |     100 |                   
  ...putPrompt.tsx |   92.06 |    86.36 |   83.33 |   92.06 | ...,70-72,120-123 
  ...tedDialog.tsx |     100 |      100 |     100 |     100 |                   
  ...ngsDialog.tsx |   71.49 |    73.89 |   69.23 |   71.49 | ...1244,1250-1251 
  ...ionDialog.tsx |    92.3 |    96.15 |   33.33 |    92.3 | 60-63,68-75,164   
  ...putPrompt.tsx |    15.9 |      100 |       0 |    15.9 | 20-63             
  ...Indicator.tsx |   57.14 |      100 |       0 |   57.14 | 12-15             
  ...MoreLines.tsx |       0 |        0 |       0 |       0 | 1-40              
  ...iewDialog.tsx |   97.77 |    87.67 |     100 |   97.77 | ...97,305-307,324 
  ...tsDisplay.tsx |   95.86 |       75 |     100 |   95.86 | 67-71             
  ...ionPicker.tsx |       0 |        0 |       0 |       0 | 1-172             
  ...tivityTab.tsx |    3.94 |      100 |       0 |    3.94 | 27-275            
  StatsDialog.tsx  |    8.64 |      100 |       0 |    8.64 | ...76-111,130-322 
  StatsDisplay.tsx |     100 |      100 |     100 |     100 |                   
  ...ciencyTab.tsx |    78.9 |    56.52 |     100 |    78.9 | ...26,213,262-288 
  ...atmapView.tsx |    8.98 |      100 |       0 |    8.98 | 20-107            
  ...essionTab.tsx |      80 |    66.66 |     100 |      80 | ...70-277,283-300 
  ...ineDialog.tsx |   93.82 |    86.66 |     100 |   93.82 | ...17,279,299-301 
  ...yTodoList.tsx |   96.36 |    88.23 |     100 |   96.36 | 138-141           
  ...nsDisplay.tsx |   95.62 |    87.09 |     100 |   95.62 | ...24-125,273-275 
  ...inalImage.tsx |     100 |    93.93 |     100 |     100 | 75,129            
  ThemeDialog.tsx  |   89.95 |    46.15 |      75 |   89.95 | ...71-173,243-245 
  Tips.tsx         |   93.54 |       75 |     100 |   93.54 | 39-40             
  TodoDisplay.tsx  |     100 |      100 |     100 |     100 |                   
  ...tsDisplay.tsx |     100 |     87.5 |     100 |     100 | 31-32             
  TrustDialog.tsx  |     100 |    83.33 |     100 |     100 | 72-87             
  ...ification.tsx |   36.36 |      100 |       0 |   36.36 | 15-22             
  ...Indicator.tsx |    92.5 |     87.5 |     100 |    92.5 | 50-53             
  ...ackDialog.tsx |       0 |        0 |       0 |       0 | 1-134             
  ...xitDialog.tsx |   80.36 |    43.47 |      60 |   80.36 | ...24-238,248-251 
  ...odeVisuals.ts |   97.22 |    85.71 |     100 |   97.22 | 25                
  ...s-helpers.tsx |   66.25 |    81.25 |      50 |   66.25 | 25-32,46-53,62-72 
 ...nts/agent-view |   55.05 |    69.09 |      50 |   55.05 |                   
  ...atContent.tsx |    9.09 |      100 |       0 |    9.09 | 54-275,281-283    
  ...tChatView.tsx |   21.05 |      100 |       0 |   21.05 | 21-39             
  ...tComposer.tsx |   69.48 |    33.33 |   66.66 |   69.48 | ...51,269,277-279 
  AgentFooter.tsx  |   15.38 |      100 |       0 |   15.38 | 28-65             
  AgentHeader.tsx  |   15.38 |      100 |       0 |   15.38 | 27-64             
  AgentTabBar.tsx  |    87.9 |    63.88 |     100 |    87.9 | ...88,110-118,136 
  ...oryAdapter.ts |     100 |    91.83 |     100 |     100 | 103,109-110,138   
  index.ts         |       0 |        0 |       0 |       0 | 1-12              
 ...mponents/arena |    42.3 |    68.69 |   73.68 |    42.3 |                   
  ArenaCards.tsx   |   73.06 |    71.79 |   85.71 |   73.06 | ...83-185,321-326 
  ...ectDialog.tsx |   83.48 |    69.86 |   88.88 |   83.48 | ...88-392,409-410 
  ...artDialog.tsx |       0 |        0 |       0 |       0 | 1-166             
  ...tusDialog.tsx |       0 |        0 |       0 |       0 | 1-288             
  ...topDialog.tsx |       0 |        0 |       0 |       0 | 1-213             
 ...ackground-view |   85.34 |    84.91 |   92.98 |   85.34 |                   
  ...sksDialog.tsx |   81.87 |    82.77 |   85.71 |   81.87 | ...1853,1965-1971 
  ...TasksPill.tsx |   78.84 |    94.28 |     100 |   78.84 | 64,109-129        
  ...gentPanel.tsx |   97.08 |    86.31 |     100 |   97.08 | 132,442-446,520   
  agent-forest.ts  |    99.2 |    93.93 |     100 |    99.2 | 258               
  ...Visibility.ts |     100 |      100 |     100 |     100 |                   
  ...e-overlay.tsx |    88.2 |    76.47 |     100 |    88.2 | ...36-138,140-142 
 ...nts/extensions |   84.32 |    76.78 |   83.33 |   84.32 |                   
  ...gerDialog.tsx |   82.15 |    76.08 |     100 |   82.15 | ...91-198,258,260 
  TabBar.tsx       |   97.29 |    88.88 |     100 |   97.29 | 33                
  index.ts         |       0 |        0 |       0 |       0 | 1-12              
  types.ts         |     100 |      100 |     100 |     100 |                   
 ...tensions/steps |   46.26 |       85 |   58.82 |   46.26 |                   
  ...ctionStep.tsx |   95.12 |    92.85 |   85.71 |   95.12 | 84-86,89          
  ...etailStep.tsx |       0 |        0 |       0 |       0 | 1-145             
  ...nListStep.tsx |   75.26 |    88.37 |   66.66 |   75.26 | ...53,174,203-209 
  ...electStep.tsx |       0 |        0 |       0 |       0 | 1-83              
  ...nfirmStep.tsx |   16.32 |      100 |       0 |   16.32 | 28-74             
  index.ts         |       0 |        0 |       0 |       0 | 1-11              
 ...xtensions/tabs |   71.92 |    68.21 |   70.83 |   71.92 |                   
  DiscoverTab.tsx  |   68.22 |    67.66 |   55.55 |   68.22 | ...93,656-660,664 
  InstalledTab.tsx |   75.49 |    67.44 |   83.33 |   75.49 | ...77,782-783,820 
  SourcesTab.tsx   |   71.67 |    70.47 |   77.77 |   71.67 | ...28,547,621-633 
 ...tensions/views |    50.7 |    52.38 |   20.83 |    50.7 |                   
  ...tionsView.tsx |   73.75 |    56.36 |   66.66 |   73.75 | ...30,353,369-374 
  ...tionsView.tsx |   43.45 |    44.82 |    6.66 |   43.45 | ...98-405,408-420 
  ...etailView.tsx |    9.24 |      100 |       0 |    9.24 | 40-67,70-163      
 ...mponents/hooks |   87.11 |    81.37 |   91.89 |   87.11 |                   
  ...rListBody.tsx |   95.29 |    85.18 |     100 |   95.29 | 95-98             
  ...etailStep.tsx |   75.32 |    71.42 |      60 |   75.32 | ...56-169,173-186 
  ...etailStep.tsx |     100 |      100 |     100 |     100 |                   
  ...rListStep.tsx |     100 |      100 |     100 |     100 |                   
  ...entHeader.tsx |     100 |    85.71 |     100 |     100 | 47                
  ...rListStep.tsx |     100 |      100 |     100 |     100 |                   
  ...etailStep.tsx |     100 |      100 |     100 |     100 |                   
  ...abledStep.tsx |     100 |      100 |     100 |     100 |                   
  ...sListStep.tsx |     100 |      100 |     100 |     100 |                   
  ...entDialog.tsx |   72.29 |    70.49 |     100 |   72.29 | ...51,563-568,572 
  constants.ts     |     100 |      100 |     100 |     100 |                   
  index.ts         |       0 |        0 |       0 |       0 | 1-13              
  ...erGrouping.ts |     100 |      100 |     100 |     100 |                   
  sourceLabels.ts  |     100 |      100 |     100 |     100 |                   
  types.ts         |     100 |      100 |     100 |     100 |                   
 ...components/mcp |   40.91 |    63.44 |   70.58 |   40.91 |                   
  ...ealthPill.tsx |     100 |      100 |     100 |     100 |                   
  ...entDialog.tsx |   32.09 |    26.19 |      40 |   32.09 | ...12,914,927-933 
  ...valDialog.tsx |   15.06 |      100 |       0 |   15.06 | 40-109            
  constants.ts     |     100 |      100 |     100 |     100 |                   
  index.ts         |       0 |        0 |       0 |       0 | 1-35              
  types.ts         |     100 |      100 |     100 |     100 |                   
  utils.ts         |      97 |       95 |     100 |      97 | 24,113-114        
 ...ents/mcp/steps |   53.94 |    73.51 |   57.14 |   53.94 |                   
  ...icateStep.tsx |    5.65 |      100 |       0 |    5.65 | 40-66,69-308      
  ...electStep.tsx |   10.95 |      100 |       0 |   10.95 | 16-88             
  ...etailStep.tsx |     100 |      100 |     100 |     100 |                   
  ...eListStep.tsx |   99.09 |    97.36 |     100 |   99.09 | 71                
  ...etailStep.tsx |   62.83 |       60 |   33.33 |   62.83 | ...87-296,307-332 
  ...rListStep.tsx |   88.53 |    81.25 |     100 |   88.53 | ...64,170,175-180 
  ...etailStep.tsx |    10.3 |      100 |       0 |    10.3 | ...1,67-79,82-140 
  ToolListStep.tsx |   69.29 |       50 |     100 |   69.29 | ...23,126,135-144 
 ...nents/messages |   90.26 |    86.89 |   85.57 |   90.26 |                   
  ...ionDialog.tsx |   89.23 |     84.9 |   81.81 |   89.23 | ...75,593,611-613 
  BtwMessage.tsx   |     100 |      100 |     100 |     100 |                   
  ...upDisplay.tsx |     100 |    94.73 |     100 |     100 | ...43,289,402,432 
  ...onMessage.tsx |   92.06 |    82.35 |     100 |   92.06 | 58-60,62,64       
  ...nMessages.tsx |   94.11 |    95.91 |   76.92 |   94.11 | ...47-349,352-355 
  DiffRenderer.tsx |   93.17 |    86.02 |     100 |   93.17 | ...07,235-236,302 
  ...tsDisplay.tsx |   97.08 |    77.77 |     100 |   97.08 | 95,97,106         
  ...usMessage.tsx |   81.73 |     65.9 |      75 |   81.73 | ...10-214,222,245 
  ...tsDisplay.tsx |   95.52 |    88.31 |     100 |   95.52 | ...40,142,175-180 
  ...ssMessage.tsx |    12.5 |      100 |       0 |    12.5 | 18-59             
  ...edMessage.tsx |   21.05 |      100 |       0 |   21.05 | 23-39             
  ...sMessages.tsx |   59.04 |       50 |    37.5 |   59.04 | ...21-126,147-159 
  ...ryMessage.tsx |   13.63 |      100 |       0 |   13.63 | 23-64             
  ...onMessage.tsx |   91.87 |    82.63 |     100 |   91.87 | ...49-651,658-660 
  ...upMessage.tsx |   98.38 |    95.38 |     100 |   98.38 | 188-191,422       
  ToolMessage.tsx  |   93.06 |    86.32 |   93.75 |   93.06 | ...1037,1082-1084 
 ...ponents/shared |   86.29 |    82.41 |   94.17 |   86.29 |                   
  ...ctionList.tsx |     100 |      100 |      75 |     100 |                   
  ...tonSelect.tsx |     100 |      100 |     100 |     100 |                   
  EnumSelector.tsx |     100 |    96.42 |     100 |     100 | 58                
  ...rBoundary.tsx |     100 |      100 |     100 |     100 |                   
  MaxSizedBox.tsx  |   84.71 |    86.95 |      90 |   84.71 | ...67-568,685-686 
  MultiSelect.tsx  |   93.58 |       75 |     100 |   93.58 | ...43,199-201,211 
  ...tonSelect.tsx |     100 |      100 |     100 |     100 |                   
  ...ontroller.tsx |     100 |    83.33 |     100 |     100 | 73,93-95          
  ...eSelector.tsx |     100 |       60 |     100 |     100 | 40-45             
  ...lableList.tsx |   81.48 |    84.84 |     100 |   81.48 | 46-66,73-76       
  StaticRender.tsx |     100 |      100 |     100 |     100 |                   
  TextInput.tsx    |    80.8 |    67.24 |      80 |    80.8 | ...36-240,252-258 
  ...ontroller.tsx |     100 |    81.81 |     100 |     100 | 59-62             
  ...apsedTime.tsx |     100 |      100 |     100 |     100 |                   
  ...Indicator.tsx |     100 |      100 |     100 |     100 |                   
  ...lizedList.tsx |   91.49 |    86.66 |   83.33 |   91.49 | ...18-846,859,959 
  text-buffer.ts   |   85.98 |    81.81 |   97.91 |   85.98 | ...2664,2762-2763 
  ...er-actions.ts |   73.93 |    67.22 |     100 |   73.93 | ...32-733,934-936 
 ...ponents/skills |       0 |        0 |       0 |       0 |                   
  ...gerDialog.tsx |       0 |        0 |       0 |       0 | 1-681             
 ...ents/subagents |       0 |        0 |       0 |       0 |                   
  constants.ts     |       0 |        0 |       0 |       0 | 1-71              
  index.ts         |       0 |        0 |       0 |       0 | 1-11              
  reducers.tsx     |       0 |        0 |       0 |       0 | 1-190             
  types.ts         |       0 |        0 |       0 |       0 | 1-125             
  utils.ts         |       0 |        0 |       0 |       0 | 1-102             
 ...bagents/create |       0 |        0 |       0 |       0 |                   
  ...ionWizard.tsx |       0 |        0 |       0 |       0 | 1-299             
  ...rSelector.tsx |       0 |        0 |       0 |       0 | 1-85              
  ...onSummary.tsx |       0 |        0 |       0 |       0 | 1-331             
  ...tionInput.tsx |       0 |        0 |       0 |       0 | 1-177             
  ...dSelector.tsx |       0 |        0 |       0 |       0 | 1-63              
  ...nSelector.tsx |       0 |        0 |       0 |       0 | 1-58              
  ...EntryStep.tsx |       0 |        0 |       0 |       0 | 1-78              
  ToolSelector.tsx |       0 |        0 |       0 |       0 | 1-253             
 ...bagents/manage |   14.14 |    53.19 |    37.5 |   14.14 |                   
  ...ctionStep.tsx |       0 |        0 |       0 |       0 | 1-103             
  ...eleteStep.tsx |       0 |        0 |       0 |       0 | 1-62              
  ...tEditStep.tsx |       0 |        0 |       0 |       0 | 1-124             
  ...ctionStep.tsx |   35.61 |    59.52 |     100 |   35.61 | ...21-433,438-440 
  ...iewerStep.tsx |       0 |        0 |       0 |       0 | 1-73              
  ...gerDialog.tsx |       0 |        0 |       0 |       0 | 1-341             
 ...mponents/views |    70.1 |    72.89 |   61.11 |    70.1 |                   
  ContextUsage.tsx |   71.49 |    64.86 |      80 |   71.49 | ...30-436,473-567 
  DoctorReport.tsx |     9.8 |      100 |       0 |     9.8 | 25-54,57-131      
  ...sionsList.tsx |   88.05 |       75 |     100 |   88.05 | 70-77             
  McpStatus.tsx    |   92.01 |     73.8 |     100 |   92.01 | ...36,175-177,262 
  SkillsList.tsx   |   20.51 |      100 |       0 |   20.51 | 17-20,27-57       
  ToolsList.tsx    |     100 |      100 |     100 |     100 |                   
 src/ui/contexts   |   84.16 |    81.83 |   85.13 |   84.16 |                   
  ...ewContext.tsx |   64.83 |    88.88 |      50 |   64.83 | ...16-219,225-235 
  AppContext.tsx   |      80 |       50 |     100 |      80 | 19-20             
  ...ewContext.tsx |   93.83 |    68.51 |   42.85 |   93.83 | ...44,281-285,317 
  ...igContext.tsx |   81.81 |       50 |     100 |   81.81 | 15-16             
  ...ssContext.tsx |   85.65 |    84.85 |     100 |   85.65 | ...1612-1614,1620 
  ...owContext.tsx |   91.07 |    81.81 |     100 |   91.07 | 47-48,60-62       
  ...deContext.tsx |     100 |      100 |      50 |     100 |                   
  ...onContext.tsx |   80.77 |       80 |    92.3 |   80.77 | ...31-434,443-446 
  ...gsContext.tsx |     100 |      100 |     100 |     100 |                   
  ...usContext.tsx |     100 |      100 |     100 |     100 |                   
  ...ngContext.tsx |   71.42 |       50 |     100 |   71.42 | 17-20             
  ...utContext.tsx |   85.71 |      100 |   66.66 |   85.71 | 13-14             
  ...edContext.tsx |     100 |      100 |      50 |     100 |                   
  ...nsContext.tsx |   88.88 |       50 |     100 |   88.88 | 156-157           
  ...teContext.tsx |   86.66 |       50 |     100 |   86.66 | 235-236           
  ...deContext.tsx |      80 |     87.5 |      75 |      80 | ...11-112,118-120 
  ...rtContext.tsx |     100 |      100 |     100 |     100 |                   
 src/ui/daemon     |   88.35 |    73.51 |   95.45 |   88.35 |                   
  ...ui-adapter.ts |   88.35 |    73.51 |   95.45 |   88.35 | ...74,792-793,879 
 src/ui/editors    |       0 |        0 |       0 |       0 |                   
  ...ngsManager.ts |       0 |        0 |       0 |       0 | 1-67              
 src/ui/hooks      |   85.45 |    83.05 |   87.79 |   85.45 |                   
  ...dProcessor.ts |   85.53 |    85.13 |     100 |   85.53 | ...-970,1017-1018 
  ...ention-ref.ts |   97.72 |       84 |     100 |   97.72 | 65                
  keyToAnsi.ts     |    3.92 |      100 |       0 |    3.92 | 19-77             
  ...esourceRef.ts |     100 |      100 |     100 |     100 |                   
  ...completion.ts |     100 |    95.45 |     100 |     100 | 95                
  ...ention-ref.ts |     100 |      100 |     100 |     100 |                   
  ...dProcessor.ts |   94.62 |    73.58 |     100 |   94.62 | ...87-288,293-294 
  ...dProcessor.ts |   85.75 |     68.4 |   81.81 |   85.75 | ...1464,1485-1489 
  ...rt-command.ts |     100 |      100 |     100 |     100 |                   
  ...sced-flush.ts |     100 |      100 |     100 |     100 |                   
  ...ng-enabled.ts |     100 |      100 |     100 |     100 |                   
  ...oice-input.ts |   92.36 |    81.95 |   66.66 |   92.36 | ...00,502-503,658 
  ...ke-repaint.ts |     100 |      100 |     100 |     100 |                   
  ...amingState.ts |   12.22 |      100 |       0 |   12.22 | 54-157            
  ...agerDialog.ts |   88.23 |      100 |     100 |   88.23 | 20,24             
  ...dScrollbar.ts |     100 |      100 |     100 |     100 |                   
  ...ationFrame.ts |      42 |       75 |     100 |      42 | 42-44,53-59,62-87 
  ...odeCommand.ts |   58.82 |      100 |     100 |   58.82 | 28,33-48          
  ...enaCommand.ts |      85 |      100 |     100 |      85 | 23-24,29          
  ...aInProcess.ts |   27.92 |       80 |      25 |   27.92 | ...69-170,173-175 
  ...Completion.ts |   86.44 |    88.48 |     100 |   86.44 | ...14-515,525-541 
  ...ifications.ts |   87.82 |    96.77 |     100 |   87.82 | 138-152           
  ...tIndicator.ts |   88.28 |    81.57 |     100 |   88.28 | ...66,175,179-187 
  ...waySummary.ts |   96.26 |       75 |     100 |   96.26 | 126-128,170       
  ...ndTaskView.ts |   94.89 |    77.55 |     100 |   94.89 | 164-168,257,263   
  ...chedScroll.ts |     100 |      100 |     100 |     100 |                   
  ...ketedPaste.ts |    23.8 |      100 |       0 |    23.8 | 19-37             
  ...nchCommand.ts |   95.53 |    83.01 |     100 |   95.53 | ...64-165,289-292 
  ...ompletion.tsx |   97.09 |    87.09 |     100 |   97.09 | ...23-324,334-335 
  ...dMigration.ts |    92.1 |    88.88 |     100 |    92.1 | 42-44             
  useCompletion.ts |   96.29 |    90.56 |     100 |   96.29 | ...17-218,222-223 
  ...nitMessage.ts |     100 |      100 |     100 |     100 |                   
  ...extualTips.ts |   78.26 |       50 |     100 |   78.26 | ...2,75-79,96-104 
  ...eteCommand.ts |   89.52 |    90.69 |     100 |   89.52 | ...98-106,114-115 
  ...ialogClose.ts |   36.11 |       10 |     100 |   36.11 | ...89-195,202-207 
  useDiffData.ts   |       0 |        0 |       0 |       0 | 1-87              
  ...oublePress.ts |   53.12 |       75 |     100 |   53.12 | 33-35,41-54       
  ...orSettings.ts |     100 |      100 |     100 |     100 |                   
  ...Completion.ts |   99.12 |    97.67 |     100 |   99.12 | 182-183           
  ...ionUpdates.ts |   93.72 |    92.98 |     100 |   93.72 | ...87-291,314-320 
  ...agerDialog.ts |   88.88 |      100 |     100 |   88.88 | 21,25             
  ...backDialog.ts |    63.9 |    76.47 |   66.66 |    63.9 | ...66-168,190-191 
  useFocus.ts      |     100 |      100 |     100 |     100 |                   
  ...olderTrust.ts |     100 |    93.33 |     100 |     100 | 62                
  ...ggestions.tsx |   96.47 |    78.94 |     100 |   96.47 | 121,155-156       
  ...miniStream.ts |   86.08 |    81.23 |   76.92 |   86.08 | ...5198-5200,5202 
  ...BranchName.ts |     100 |    94.44 |     100 |     100 | 54                
  ...oryManager.ts |   98.38 |    98.85 |     100 |   98.38 | 141-144           
  ...ooksDialog.ts |    87.5 |      100 |     100 |    87.5 | 19,23             
  ...stListener.ts |     100 |      100 |     100 |     100 |                   
  ...nAuthError.ts |   76.19 |       50 |     100 |   76.19 | 39-40,43-45       
  ...putHistory.ts |   92.59 |    85.71 |     100 |   92.59 | 63-64,72,94-96    
  ...storyStore.ts |     100 |    94.11 |     100 |     100 | 69                
  useKeypress.ts   |     100 |      100 |     100 |     100 |                   
  ...rdProtocol.ts |   36.36 |      100 |       0 |   36.36 | 24-31             
  ...unchEditor.ts |   22.58 |      100 |      50 |   22.58 | 11-32,44-85       
  ...gIndicator.ts |     100 |    96.66 |     100 |     100 | 109               
  useLogger.ts     |      16 |      100 |       0 |      16 | 15-45             
  useMCPHealth.ts  |   10.52 |      100 |       0 |   10.52 | 36-75             
  ...cpApproval.ts |   93.12 |    86.11 |     100 |   93.12 | ...24-127,139-140 
  useMcpDialog.ts  |    87.5 |      100 |     100 |    87.5 | 19,23             
  ...moryDialog.ts |    87.5 |      100 |     100 |    87.5 | 19,23             
  ...oryMonitor.ts |   83.14 |    78.57 |     100 |   83.14 | 54-63,74-79       
  ...ssageQueue.ts |     100 |     97.4 |     100 |     100 | 175,262           
  ...delCommand.ts |     100 |       96 |     100 |     100 | 61                
  ...ouseEvents.ts |   94.89 |       95 |   83.33 |   94.89 | 78-82             
  ...raseCycler.ts |   84.74 |    76.47 |     100 |   84.74 | ...49,52-53,69-71 
  ...rredEditor.ts |   58.33 |    22.22 |     100 |   58.33 | 23-27,29-33       
  ...derUpdates.ts |   85.29 |    80.28 |    92.3 |   85.29 | ...36,351-361,441 
  useQwenAuth.ts   |     100 |      100 |     100 |     100 |                   
  ...lScheduler.ts |   89.48 |    88.88 |     100 |   89.48 | ...54-456,489-499 
  ...oryCommand.ts |       0 |        0 |       0 |       0 | 1-7               
  ...umeCommand.ts |   95.34 |    77.14 |     100 |   95.34 | 124-125,227-232   
  ...ompletion.tsx |   90.67 |    83.33 |     100 |   90.67 | ...02,105,138-141 
  ...ectionList.ts |   97.12 |    96.22 |     100 |   97.12 | ...92-193,247-250 
  ...sionPicker.ts |   92.87 |    90.35 |     100 |   92.87 | ...99-501,503-505 
  ...earchInput.ts |     100 |    97.29 |     100 |     100 | 82                
  ...ngsCommand.ts |   18.75 |      100 |       0 |   18.75 | 10-25             
  ...ellHistory.ts |   93.28 |    80.95 |     100 |   93.28 | ...96,153-154,164 
  ...oryCommand.ts |   85.48 |    58.33 |     100 |   85.48 | 22-28,40,71       
  ...agerDialog.ts |   88.23 |      100 |     100 |   88.23 | 20,24             
  ...Completion.ts |   82.85 |    85.13 |   94.73 |   82.85 | ...78-680,688-724 
  ...tateAndRef.ts |     100 |      100 |     100 |     100 |                   
  ...tatsDialog.ts |     100 |      100 |     100 |     100 |                   
  useStatusLine.ts |   97.32 |    93.93 |     100 |   97.32 | ...18-422,518-525 
  ...eateDialog.ts |   88.23 |      100 |     100 |   88.23 | 14,18             
  ...mInProcess.ts |   27.35 |       80 |      25 |   27.35 | ...82-183,186-188 
  ...tification.ts |     100 |     87.5 |     100 |     100 | 50                
  ...alProgress.ts |   67.34 |    58.82 |   66.66 |   67.34 | 52-53,61-68,79-85 
  ...rminalSize.ts |     100 |      100 |     100 |     100 |                   
  ...emeCommand.ts |   67.01 |    29.41 |     100 |   67.01 | ...10-111,115-116 
  useTimer.ts      |   97.59 |    94.73 |     100 |   97.59 | 17-18             
  ...lMigration.ts |       0 |        0 |       0 |       0 |                   
  ...rustModify.ts |     100 |    90.47 |     100 |     100 | 112,134           
  useTurnDiffs.ts  |   95.12 |    78.57 |     100 |   95.12 | 133-134,156-157   
  ...elcomeBack.ts |   87.36 |     90.9 |     100 |   87.36 | ...,94-96,114-115 
  ...reeSession.ts |   93.75 |       70 |     100 |   93.75 | 47-48,72          
  vim.ts           |      74 |    67.56 |   69.23 |      74 | ...1854-1861,1869 
 src/ui/layouts    |    91.2 |    89.47 |     100 |    91.2 |                   
  ...AppLayout.tsx |    90.9 |     87.5 |     100 |    90.9 | 60-62,110-115,151 
  ...AppLayout.tsx |   91.66 |    92.85 |     100 |   91.66 | 75-80             
 src/ui/models     |   80.72 |       80 |   71.42 |   80.72 |                   
  ...ableModels.ts |   80.72 |       80 |   71.42 |   80.72 | ...,61-71,125-127 
 ...noninteractive |     100 |      100 |    6.66 |     100 |                   
  ...eractiveUi.ts |     100 |      100 |    6.66 |     100 |                   
 src/ui/selection  |   92.65 |    84.69 |     100 |   92.65 |                   
  screen-buffer.ts |   94.73 |    64.28 |     100 |   94.73 | 51-52             
  ...ion-coords.ts |     100 |      100 |     100 |     100 |                   
  ...ction-span.ts |   93.75 |    91.66 |     100 |   93.75 | 41-42,71-72       
  ...tion-state.ts |     100 |      100 |     100 |     100 |                   
  ...ction-text.ts |   92.85 |    92.59 |     100 |   92.85 | 30-34,114-115     
  ...selection.tsx |   90.26 |    75.32 |     100 |   90.26 | ...75-376,392-393 
 src/ui/state      |      95 |    81.81 |     100 |      95 |                   
  extensions.ts    |      95 |    81.81 |     100 |      95 | 69-70,89          
 src/ui/themes     |    98.5 |    73.17 |     100 |    98.5 |                   
  ansi-light.ts    |     100 |      100 |     100 |     100 |                   
  ansi.ts          |     100 |      100 |     100 |     100 |                   
  atom-one-dark.ts |     100 |      100 |     100 |     100 |                   
  ayu-light.ts     |     100 |      100 |     100 |     100 |                   
  ayu.ts           |     100 |      100 |     100 |     100 |                   
  color-utils.ts   |   99.23 |    97.05 |     100 |   99.23 | 277-278           
  default-light.ts |     100 |      100 |     100 |     100 |                   
  default.ts       |     100 |      100 |     100 |     100 |                   
  ...inal-theme.ts |   88.59 |    85.96 |     100 |   88.59 | ...57-261,266-270 
  dracula.ts       |     100 |      100 |     100 |     100 |                   
  github-dark.ts   |     100 |      100 |     100 |     100 |                   
  github-light.ts  |     100 |      100 |     100 |     100 |                   
  googlecode.ts    |     100 |      100 |     100 |     100 |                   
  no-color.ts      |     100 |      100 |     100 |     100 |                   
  qwen-dark.ts     |     100 |      100 |     100 |     100 |                   
  qwen-light.ts    |     100 |      100 |     100 |     100 |                   
  ...tic-tokens.ts |     100 |      100 |     100 |     100 |                   
  ...-of-purple.ts |     100 |      100 |     100 |     100 |                   
  theme-manager.ts |   88.68 |    84.52 |     100 |   88.68 | ...83-392,397-398 
  theme.ts         |     100 |    38.02 |     100 |     100 | ...34-449,457-461 
  xcode.ts         |     100 |      100 |     100 |     100 |                   
 src/ui/utils      |   87.56 |    85.63 |   95.76 |   87.56 |                   
  ...Colorizer.tsx |   80.31 |    85.41 |     100 |   80.31 | ...00-201,313-339 
  ...nRenderer.tsx |   80.07 |     75.6 |     100 |   80.07 | ...70,274,332-333 
  ...wnDisplay.tsx |   92.87 |    93.46 |     100 |   92.87 | ...,955,1002-1020 
  ...idDiagram.tsx |   87.79 |    95.34 |     100 |   87.79 | 156-179           
  ...eRenderer.tsx |   93.63 |    81.77 |   95.23 |   93.63 | ...47-750,803-808 
  ...odeDisplay.ts |   94.28 |    85.71 |     100 |   94.28 | 23,40             
  asciiCharts.ts   |    96.7 |     87.5 |     100 |    96.7 | 170-177,278       
  ...dWorkUtils.ts |     100 |      100 |     100 |     100 |                   
  ...boardUtils.ts |    52.9 |    74.15 |    92.3 |    52.9 | ...29,632-641,644 
  commandUtils.ts  |   98.38 |    92.38 |     100 |   98.38 | 108,136-137,343   
  computeStats.ts  |     100 |      100 |     100 |     100 |                   
  customBanner.ts  |   90.68 |    91.22 |     100 |   90.68 | ...13,324-327,334 
  displayUtils.ts  |   73.84 |    73.91 |     100 |   73.84 | ...34,36-40,42-46 
  formatters.ts    |   94.87 |    98.24 |     100 |   94.87 | 116-119           
  goal-runtime.ts  |   91.42 |       95 |     100 |   91.42 | 32-34             
  gradientUtils.ts |     100 |      100 |     100 |     100 |                   
  highlight.ts     |     100 |      100 |     100 |     100 |                   
  ...gap-notice.ts |     100 |      100 |     100 |     100 |                   
  ...oryMapping.ts |     100 |       95 |     100 |     100 | 44,103            
  historyUtils.ts  |   96.03 |     97.1 |     100 |   96.03 | 103-106           
  ...mage-parts.ts |   97.75 |    94.87 |     100 |   97.75 | 82-83             
  inline-math.ts   |   98.48 |    95.23 |     100 |   98.48 | 129-130           
  input-mouse.ts   |     100 |    85.71 |     100 |     100 | 48,93             
  isNarrowWidth.ts |     100 |      100 |     100 |     100 |                   
  ...olDetector.ts |   68.81 |       75 |   66.66 |   68.81 | ...27-132,160-161 
  latexRenderer.ts |   94.95 |     73.8 |     100 |   94.95 | ...76-178,184-187 
  layoutUtils.ts   |     100 |      100 |     100 |     100 |                   
  list-mouse.ts    |     100 |      100 |     100 |     100 |                   
  ...ightLoader.ts |     100 |       95 |     100 |     100 | 81                
  ...nUtilities.ts |   98.72 |    94.36 |     100 |   98.72 | 145-146           
  ...t-position.ts |     100 |     87.5 |     100 |     100 | 85                
  ...geRenderer.ts |   86.51 |    70.04 |   95.12 |   86.51 | ...1286,1326-1332 
  ...alRenderer.ts |   86.69 |     71.9 |     100 |   86.69 | ...1476,1513-1519 
  ...lsBySource.ts |     100 |    95.23 |     100 |     100 | 84                
  mouse.ts         |   92.85 |    74.19 |     100 |   92.85 | ...38,145,149-152 
  osc8.ts          |   91.33 |    79.03 |     100 |   91.33 | ...73,273,277-278 
  ...red-height.ts |   98.38 |    97.14 |     100 |   98.38 | 195-197           
  ...mConstants.ts |     100 |      100 |     100 |     100 |                   
  restoreGoal.ts   |     100 |      100 |     100 |     100 |                   
  ...storyUtils.ts |   82.73 |    79.48 |     100 |   82.73 | ...84-606,737-738 
  ...ickerUtils.ts |     100 |      100 |     100 |     100 |                   
  ...evel-label.ts |   77.77 |    66.66 |     100 |   77.77 | 18,22-24          
  ...are-cursor.ts |   89.47 |    85.71 |     100 |   89.47 | 39-44             
  ...ataService.ts |   93.17 |     79.1 |     100 |   93.17 | ...14,227,254-256 
  suggestions.ts   |     100 |      100 |     100 |     100 |                   
  ...izedOutput.ts |   95.19 |      100 |   88.88 |   95.19 | 121-126           
  ...nal-buffer.ts |     100 |      100 |     100 |     100 |                   
  ...e-renderer.ts |   90.61 |    83.44 |     100 |   90.61 | ...80,482-484,607 
  ...ize-reflow.ts |     100 |     92.3 |     100 |     100 | 57,62,209,217,347 
  ...wOptimizer.ts |     100 |    94.11 |     100 |     100 | 33,76             
  terminalSetup.ts |    4.37 |      100 |       0 |    4.37 | 44-393            
  textUtils.ts     |   97.94 |    95.49 |   94.11 |   97.94 | ...82-283,443-444 
  ...background.ts |     100 |      100 |     100 |     100 |                   
  todoSnapshot.ts  |   90.42 |    92.85 |     100 |   90.42 | ...06-207,240-241 
  ...isplay-map.ts |     100 |      100 |     100 |     100 |                   
  updateCheck.ts   |     100 |    92.75 |     100 |     100 | 227-239,331       
  ...ow-keyword.ts |     100 |      100 |     100 |     100 |                   
 ...i/utils/export |   75.03 |     60.3 |   94.59 |   75.03 |                   
  collect.ts       |   71.27 |    66.38 |      96 |   71.27 | ...90-633,655-656 
  index.ts         |     100 |      100 |     100 |     100 |                   
  normalize.ts     |   80.42 |    50.68 |     100 |   80.42 | ...59-364,376-378 
  types.ts         |       0 |        0 |       0 |       0 | 1                 
  utils.ts         |     100 |      100 |     100 |     100 |                   
 ...ort/formatters |   52.92 |    47.22 |   71.42 |   52.92 |                   
  html.ts          |   84.61 |       50 |     100 |   84.61 | ...53,57-58,62-63 
  json.ts          |     100 |      100 |     100 |     100 |                   
  jsonl.ts         |   82.45 |     37.5 |     100 |   82.45 | ...48,50-51,65-66 
  markdown.ts      |   36.32 |    47.05 |      50 |   36.32 | ...16-219,233-295 
 src/ui/voice      |   81.27 |    79.92 |   81.94 |   81.27 |                   
  ...d-recorder.ts |     6.2 |      100 |       0 |     6.2 | ...33-159,162-163 
  ...o-recorder.ts |   84.61 |    93.33 |   57.14 |   84.61 | ...16-117,131-136 
  ...me-session.ts |   91.09 |     92.1 |     100 |   91.09 | ...99,305,316-319 
  sox-recorder.ts  |    92.7 |    71.87 |     100 |    92.7 | ...34-135,153-154 
  ...ailability.ts |     100 |      100 |     100 |     100 |                   
  ...e-keyterms.ts |     100 |      100 |     100 |     100 |                   
  voice-model.ts   |     100 |      100 |     100 |     100 |                   
  ...e-recorder.ts |   88.29 |    67.74 |   81.81 |   88.29 | ...,98-99,112,115 
  voice-refine.ts  |     100 |    93.33 |     100 |     100 | 92                
  ...ream-retry.ts |   86.79 |       70 |     100 |   86.79 | 16-18,48-49,59-60 
  ...am-session.ts |   88.02 |    66.66 |   84.61 |   88.02 | ...26,343-345,363 
  ...ranscriber.ts |     100 |      100 |     100 |     100 |                   
 src/utils         |   81.41 |    87.07 |   92.57 |   81.41 |                   
  ...p-profiler.ts |   98.39 |    92.59 |     100 |   98.39 | 141,185,235       
  acpModelUtils.ts |   97.36 |    95.19 |     100 |   97.36 | ...09-210,214-215 
  apiPreconnect.ts |   96.74 |    94.59 |     100 |   96.74 | 167-170           
  ...ol-call-id.ts |   84.61 |       60 |     100 |   84.61 | 26-27,37-38       
  ...ng-failure.ts |     100 |       95 |     100 |     100 | 72                
  checks.ts        |   33.33 |      100 |       0 |   33.33 | 23-28             
  ...-api-error.ts |     100 |    96.42 |     100 |     100 | 14                
  cleanup.ts       |   84.05 |    94.11 |      80 |   84.05 | 80,111-121        
  commands.ts      |   97.45 |    96.66 |     100 |   97.45 | 153-155           
  ...Calculator.ts |     100 |      100 |     100 |     100 |                   
  cpuProfiler.ts   |   70.73 |    73.23 |   88.88 |   70.73 | ...27,430-431,438 
  deepMerge.ts     |     100 |    89.65 |     100 |     100 | 41-43,49          
  ...re-runtime.ts |     100 |      100 |     100 |     100 |                   
  ...ScopeUtils.ts |   97.56 |    88.88 |     100 |   97.56 | 67                
  doctorChecks.ts  |   70.31 |    74.57 |     100 |   70.31 | ...95-301,325-341 
  ...putCapture.ts |   90.65 |    86.31 |     100 |   90.65 | ...73,371,373-374 
  ...arResolver.ts |   97.14 |    96.55 |     100 |   97.14 | 125-126           
  errors.ts        |   97.56 |    94.64 |     100 |   97.56 | 69-70,304-305     
  events.ts        |     100 |      100 |     100 |     100 |                   
  ...on-mention.ts |   88.48 |     82.6 |     100 |   88.48 | ...56-160,164-168 
  gitUtils.ts      |   92.85 |    86.66 |     100 |   92.85 | ...13-116,164-167 
  ...AutoUpdate.ts |    93.1 |       94 |      90 |    93.1 | 103,108,179-190   
  ...tyWarnings.ts |     100 |      100 |     100 |     100 |                   
  ...lationInfo.ts |   97.68 |    94.28 |     100 |   97.68 | ...64,381-382,427 
  jsonc-editor.ts  |   93.18 |    92.72 |     100 |   93.18 | ...80-381,384-385 
  languageUtils.ts |   98.88 |    97.05 |     100 |   98.88 | 184-185           
  load-undici.ts   |     100 |      100 |     100 |     100 |                   
  ...npm-update.ts |   86.64 |    77.02 |     100 |   86.64 | ...03-304,335-345 
  math.ts          |       0 |        0 |       0 |       0 | 1-15              
  ...er-mention.ts |     100 |    66.66 |     100 |     100 | 14,30,44-46       
  ...iagnostics.ts |   94.57 |    83.01 |   88.88 |   94.57 | ...05,311,315-317 
  ...serMessage.ts |     100 |      100 |     100 |     100 |                   
  ...onfigUtils.ts |   94.25 |    91.17 |     100 |   94.25 | ...30,436,439-443 
  ...iveHelpers.ts |   95.13 |    91.79 |     100 |   95.13 | ...53-454,552,565 
  osc.ts           |   97.18 |      100 |    87.5 |   97.18 | 182-183           
  package.ts       |   88.88 |    85.71 |     100 |   88.88 | 31-32             
  ...uggestions.ts |   84.29 |    70.83 |     100 |   84.29 | 70-76,92-103      
  processUtils.ts  |    92.3 |       80 |     100 |    92.3 | 45-46             
  readStdin.ts     |   93.67 |    94.11 |   85.71 |   93.67 | 79-83             
  relaunch.ts      |   95.87 |    89.28 |     100 |   95.87 | 103-105,131       
  resolvePath.ts   |     100 |      100 |     100 |     100 |                   
  runBudget.ts     |   99.35 |    96.77 |     100 |   99.35 | 119               
  sandbox-path.ts  |     100 |      100 |     100 |     100 |                   
  sandbox.ts       |   45.52 |    57.35 |   76.92 |   45.52 | ...1040,1052-1075 
  ...xImageName.ts |     100 |    77.77 |     100 |     100 | 10,18             
  sandboxMounts.ts |     100 |      100 |     100 |     100 |                   
  sessionPaths.ts  |   90.84 |    90.56 |     100 |   90.84 | ...81-182,185-186 
  settingsUtils.ts |   82.35 |    89.57 |      90 |   82.35 | ...25-743,750-758 
  spawnWrapper.ts  |     100 |      100 |     100 |     100 |                   
  ...ate-verify.ts |     100 |      100 |     100 |     100 |                   
  ...one-update.ts |   39.81 |    77.44 |   62.16 |   39.81 | ...1193,1196-1215 
  ...upProfiler.ts |   98.47 |    94.66 |     100 |   98.47 | 132-133,308       
  ...upWarnings.ts |     100 |      100 |     100 |     100 |                   
  stdioHelpers.ts  |     100 |       90 |     100 |     100 | 23                
  systemInfo.ts    |   95.12 |    90.27 |     100 |   95.12 | ...54-255,260-264 
  ...InfoFields.ts |    87.5 |    65.85 |     100 |    87.5 | ...24-125,146-147 
  ...alSequence.ts |     100 |    97.61 |     100 |     100 | 60                
  ...iffPreview.ts |   76.47 |       25 |     100 |   76.47 | 13,17,23-24       
  ...on-handler.ts |    73.8 |       75 |     100 |    73.8 | 17-18,25-26,67-73 
  ...e-relaunch.ts |   89.61 |    86.66 |      50 |   89.61 | 56-61,83-84       
  ...entEmitter.ts |     100 |      100 |     100 |     100 |                   
  ...ansionHook.ts |     100 |      100 |     100 |     100 |                   
  ...upWarnings.ts |   87.75 |       75 |     100 |   87.75 | 47-48,53-54,57-58 
  version.ts       |     100 |    66.66 |     100 |     100 | 11                
  ...ingHandler.ts |     100 |      100 |     100 |     100 |                   
  windowTitle.ts   |   95.45 |    93.33 |     100 |   95.45 | 54-55             
  ...WithBackup.ts |   65.04 |    77.77 |     100 |   65.04 | 97,112,133-172    
 ...s/housekeeping |   93.51 |    90.95 |   96.96 |   93.51 |                   
  cleanup.ts       |   92.59 |    93.75 |     100 |   92.59 | ...02-205,209-211 
  ...eractionAt.ts |     100 |      100 |     100 |     100 |                   
  scheduler.ts     |      93 |    88.34 |      95 |      93 | ...57-359,411-415 
  throttledOnce.ts |   95.95 |    93.93 |     100 |   95.95 | 77-78,153-154     
-------------------|---------|----------|---------|---------|-------------------
Core Package - Full Text Report
-------------------|---------|----------|---------|---------|-------------------
File               | % Stmts | % Branch | % Funcs | % Lines | Uncovered Line #s 
-------------------|---------|----------|---------|---------|-------------------
All files          |   87.89 |    86.41 |   89.46 |   87.89 |                   
 src               |     100 |      100 |     100 |     100 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
 src/__mocks__/fs  |       0 |        0 |       0 |       0 |                   
  promises.ts      |       0 |        0 |       0 |       0 | 1-48              
 src/agents        |   90.38 |    84.54 |   94.85 |   90.38 |                   
  ...transcript.ts |   87.63 |    83.52 |     100 |   87.63 | ...80,588,594-598 
  ...ent-resume.ts |   85.59 |    77.55 |   83.33 |   85.59 | ...1793-1797,1800 
  ...ound-tasks.ts |   94.63 |    90.13 |   96.38 |   94.63 | ...1773,1793-1796 
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...ent-result.ts |    96.8 |    92.68 |     100 |    96.8 | 106,129-131       
  ...n-registry.ts |   94.79 |     87.7 |     100 |   94.79 | ...1067,1081-1083 
  ...w-snapshot.ts |   92.12 |    77.14 |     100 |   92.12 | ...65,189,196-198 
 src/agents/arena  |   76.32 |    67.71 |   78.94 |   76.32 |                   
  ...gentClient.ts |   79.47 |    88.88 |   81.81 |   79.47 | ...68-183,189-204 
  ArenaManager.ts  |   75.11 |    64.51 |   78.57 |   75.11 | ...1887,1893-1894 
  arena-events.ts  |   64.44 |      100 |      50 |   64.44 | ...71-175,178-183 
  diff-summary.ts  |    87.5 |    72.34 |     100 |    87.5 | ...32-133,137-138 
  index.ts         |     100 |      100 |     100 |     100 |                   
  types.ts         |     100 |      100 |     100 |     100 |                   
 ...gents/backends |   78.09 |    85.23 |   76.28 |   78.09 |                   
  ITermBackend.ts  |   97.97 |    93.93 |     100 |   97.97 | ...78-180,255,307 
  ...essBackend.ts |    90.9 |    85.36 |   93.33 |    90.9 | ...70,672,674-675 
  TmuxBackend.ts   |    90.7 |    76.55 |   97.36 |    90.7 | ...87,697,743-747 
  detect.ts        |   31.25 |      100 |       0 |   31.25 | 34-88             
  index.ts         |     100 |      100 |     100 |     100 |                   
  iterm-it2.ts     |     100 |     92.1 |     100 |     100 | 37-38,106         
  tmux-commands.ts |    6.64 |      100 |    3.03 |    6.64 | ...93-363,386-503 
  types.ts         |     100 |      100 |     100 |     100 |                   
 ...agents/runtime |    91.1 |    86.68 |   89.23 |    91.1 |                   
  agent-context.ts |     100 |      100 |     100 |     100 |                   
  agent-core.ts    |   85.07 |     76.8 |   77.77 |   85.07 | ...2291,2337-2339 
  agent-events.ts  |     100 |      100 |     100 |     100 |                   
  ...t-headless.ts |   93.49 |    89.41 |   83.33 |   93.49 | ...96-497,500-501 
  ...nteractive.ts |   81.01 |    82.35 |   76.66 |   81.01 | ...33,535-538,541 
  ...statistics.ts |   98.29 |    82.55 |     100 |   98.29 | 141,165,206,239   
  agent-types.ts   |     100 |      100 |     100 |     100 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...ool-policy.ts |   98.34 |      100 |    92.3 |   98.34 | 81-82             
  ...low-budget.ts |     100 |      100 |     100 |     100 |                   
  ...-scheduler.ts |   97.43 |    96.36 |     100 |   97.43 | 128-130           
  ...ow-journal.ts |   91.76 |    75.86 |     100 |   91.76 | ...38-139,179-181 
  ...chestrator.ts |    92.4 |       90 |   83.78 |    92.4 | ...1862,1911-1914 
  ...ow-prompts.ts |     100 |      100 |     100 |     100 |                   
  ...low-runner.ts |   94.85 |     87.5 |   92.85 |   94.85 | ...93,260,280-283 
  ...ow-sandbox.ts |   96.85 |    91.28 |     100 |   96.85 | ...1705,1711-1712 
  ...flow-saved.ts |   96.51 |    94.36 |     100 |   96.51 | 134-135,234-237   
  ...flow-stall.ts |    97.9 |    83.33 |     100 |    97.9 | 138-139,236       
 src/agents/tasks  |     100 |      100 |     100 |     100 |                   
  types.ts         |     100 |      100 |     100 |     100 |                   
 src/agents/team   |   82.04 |    84.17 |   88.97 |   82.04 |                   
  TeamManager.ts   |   72.02 |    79.41 |   79.24 |   72.02 | ...1632,1655-1656 
  identity.ts      |     100 |      100 |     100 |     100 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...sionBridge.ts |     100 |      100 |     100 |     100 |                   
  mailbox.ts       |   96.02 |    87.23 |     100 |   96.02 | 352-358           
  ...ptAddendum.ts |     100 |      100 |     100 |     100 |                   
  tasks.ts         |   89.24 |    82.82 |     100 |   89.24 | ...-994,1038-1039 
  team-events.ts   |   60.52 |      100 |      50 |   60.52 | ...40-144,151-155 
  teamHelpers.ts   |   92.02 |    94.91 |   95.23 |   92.02 | ...31-332,368-378 
  types.ts         |     100 |      100 |     100 |     100 |                   
 ...eam/test-utils |   94.39 |    94.26 |   98.21 |   94.39 |                   
  ...on-harness.ts |   96.49 |    84.21 |     100 |   96.49 | 128-129,141-142   
  fake-agent.ts    |   98.49 |    95.08 |     100 |   98.49 | 201-203           
  fake-backend.ts  |   86.46 |    97.61 |   95.83 |   86.46 | 124-146           
 src/config        |    84.8 |    87.18 |   75.42 |    84.8 |                   
  approval-mode.ts |     100 |      100 |     100 |     100 |                   
  ...xtDefaults.ts |     100 |      100 |     100 |     100 |                   
  config.ts        |   84.11 |    86.91 |   73.86 |   84.11 | ...8440,8444-8445 
  constants.ts     |     100 |      100 |     100 |     100 |                   
  models.ts        |     100 |      100 |     100 |     100 |                   
  storage.ts       |   94.39 |    91.57 |   88.23 |   94.39 | ...45-446,449-450 
 ...nfirmation-bus |   98.27 |    97.14 |     100 |   98.27 |                   
  message-bus.ts   |   98.14 |    97.05 |     100 |   98.14 | 42-43             
  types.ts         |     100 |      100 |     100 |     100 |                   
 src/core          |   92.37 |    88.08 |   93.29 |   92.37 |                   
  baseLlmClient.ts |    88.4 |     83.8 |   81.81 |    88.4 | ...59,672,678-680 
  client.ts        |   92.05 |     87.4 |   91.66 |   92.05 | ...3987,4085-4086 
  ...tGenerator.ts |   86.34 |    87.34 |   84.61 |   86.34 | ...96-497,542-548 
  ...lScheduler.ts |   90.04 |    84.67 |   96.15 |   90.04 | ...6215,6243-6259 
  geminiChat.ts    |    94.7 |    90.12 |   95.53 |    94.7 | ...5052,5100-5101 
  geminiRequest.ts |     100 |      100 |     100 |     100 |                   
  genai-compat.ts  |     100 |      100 |     100 |     100 |                   
  ...MediaLimit.ts |     100 |       96 |     100 |     100 | 96                
  ...htProtocol.ts |    9.09 |      100 |       0 |    9.09 | ...9,62-66,69-110 
  ...ream-error.ts |     100 |      100 |     100 |     100 |                   
  logger.ts        |   87.41 |    87.02 |     100 |   87.41 | ...64-568,614-628 
  ...lay-buffer.ts |     100 |      100 |     100 |     100 |                   
  ...dispatcher.ts |     100 |      100 |     100 |     100 |                   
  ...tyDefaults.ts |     100 |      100 |     100 |     100 |                   
  ...olExecutor.ts |   93.54 |    83.33 |      50 |   93.54 | 49-50             
  ...on-helpers.ts |   93.49 |    78.57 |     100 |   93.49 | ...10-211,228-229 
  ...issionFlow.ts |   98.97 |    96.96 |     100 |   98.97 | 107               
  ...try-policy.ts |     100 |      100 |     100 |     100 |                   
  ...ell-policy.ts |   94.89 |    88.54 |     100 |   94.89 | ...51-252,297-298 
  prompts.ts       |   93.64 |    91.42 |   83.33 |   93.64 | ...1209,1412-1413 
  ...ing-effort.ts |     100 |      100 |     100 |     100 |                   
  ...n-recovery.ts |   95.13 |       80 |     100 |   95.13 | ...06-107,142-144 
  ...t-profiler.ts |    97.9 |    81.15 |   88.23 |    97.9 | 117,124-125,130   
  ...port-retry.ts |     100 |      100 |     100 |     100 |                   
  tokenLimits.ts   |     100 |    91.89 |     100 |     100 | 87,122-139        
  ...reparation.ts |     100 |      100 |     100 |     100 |                   
  ...tion-guard.ts |   90.38 |    94.73 |     100 |   90.38 | 68-72             
  ...allIdUtils.ts |   98.41 |    93.47 |     100 |   98.41 | 36,45             
  ...okTriggers.ts |   99.45 |    92.43 |     100 |   99.45 | 182,193           
  ...terruption.ts |     100 |     92.3 |     100 |     100 | 86,104            
  turn.ts          |   98.67 |    93.12 |     100 |   98.67 | ...79,707-708,755 
  ...l-fallback.ts |     100 |      100 |     100 |     100 |                   
 ...ntentGenerator |   96.33 |    88.12 |   96.15 |   96.33 |                   
  ...tGenerator.ts |   97.24 |    86.72 |   94.87 |   97.24 | ...1436,1465,1476 
  converter.ts     |   96.19 |    89.25 |     100 |   96.19 | ...1329,1550-1552 
  index.ts         |       0 |        0 |       0 |       0 | 1-21              
  usage.ts         |     100 |      100 |     100 |     100 |                   
 ...ntentGenerator |   88.78 |    72.36 |   89.47 |   88.78 |                   
  ...tGenerator.ts |   87.18 |    71.83 |   88.88 |   87.18 | ...58-364,382-383 
  index.ts         |     100 |       80 |     100 |     100 | 50                
 ...ntentGenerator |   95.88 |    90.34 |    92.3 |   95.88 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...tGenerator.ts |   95.81 |    89.63 |   91.89 |   95.81 | ...1221-1222,1250 
  ...tDetection.ts |     100 |      100 |     100 |     100 |                   
 ...ntentGenerator |   91.71 |    90.53 |   95.61 |   91.71 |                   
  constants.ts     |     100 |      100 |     100 |     100 |                   
  converter.ts     |    91.3 |    89.49 |   96.87 |    91.3 | ...1942,2111-2126 
  errorHandler.ts  |     100 |      100 |     100 |     100 |                   
  index.ts         |   60.31 |       75 |      50 |   60.31 | ...71,74-78,90-94 
  ...tGenerator.ts |    66.4 |    70.58 |   88.88 |    66.4 | ...51-157,168-169 
  pipeline.ts      |   95.48 |    91.27 |     100 |   95.48 | ...1309,1317,1416 
  ...ix-caching.ts |   95.23 |    92.85 |     100 |   95.23 | 45-46,69-70       
  ...ureContext.ts |     100 |      100 |     100 |     100 |                   
  ...ingOptions.ts |       0 |        0 |       0 |       0 | 1                 
  ...CallParser.ts |   92.24 |     92.4 |     100 |   92.24 | ...28-529,549-552 
  ...kingParser.ts |     100 |    96.87 |     100 |     100 | 42                
  types.ts         |       0 |        0 |       0 |       0 | 1                 
 ...rator/provider |   97.36 |    92.19 |    98.5 |   97.36 |                   
  dashscope.ts     |   98.33 |    94.97 |   96.42 |   98.33 | ...91-692,834-835 
  deepseek.ts      |   94.91 |    89.36 |     100 |   94.91 | ...31-132,145-146 
  default.ts       |   99.18 |    97.05 |     100 |   99.18 | 208               
  index.ts         |     100 |      100 |     100 |     100 |                   
  mimo.ts          |   94.11 |    66.66 |     100 |   94.11 | 29,52-53          
  minimax.ts       |     100 |      100 |     100 |     100 |                   
  mistral.ts       |   96.07 |    73.33 |     100 |   96.07 | 32-33             
  modelscope.ts    |     100 |      100 |     100 |     100 |                   
  types.ts         |       0 |        0 |       0 |       0 |                   
  utils.ts         |     100 |      100 |     100 |     100 |                   
  zai.ts           |   92.13 |    82.14 |     100 |   92.13 | ...,39-40,135-137 
 src/extension     |   87.71 |    84.62 |   92.57 |   87.71 |                   
  ...ive-safety.ts |     100 |      100 |     100 |     100 |                   
  ...-converter.ts |   80.55 |    73.66 |     100 |   80.55 | ...1133,1179-1180 
  corruptFile.ts   |     100 |       50 |     100 |     100 | 40-45             
  ...-converter.ts |     100 |      100 |     100 |     100 |                   
  ...me-refresh.ts |     100 |      100 |     100 |     100 |                   
  ...sion-store.ts |   90.94 |    86.26 |   97.91 |   90.94 | ...1230-1236,1280 
  ...ionManager.ts |   83.89 |    82.86 |   81.72 |   83.89 | ...2832,2861-2862 
  ...references.ts |     100 |     90.9 |     100 |     100 | ...05,129,197,200 
  ...onSettings.ts |    92.3 |     94.4 |     100 |    92.3 | ...98-501,570-571 
  ...-converter.ts |    75.9 |    85.71 |   85.71 |    75.9 | ...98,202,214-248 
  github.ts        |   90.48 |    82.71 |     100 |   90.48 | ...4,994-995,1005 
  http-client.ts   |   84.61 |       80 |     100 |   84.61 | 20-21             
  i18n.ts          |   78.26 |       96 |      50 |   78.26 | 104-110,116-123   
  index.ts         |     100 |      100 |     100 |     100 |                   
  marketplace.ts   |   88.39 |    83.11 |     100 |   88.39 | ...08,494,507-508 
  ...ork-policy.ts |   89.72 |       90 |     100 |   89.72 | ...36,148-154,156 
  npm.ts           |   89.02 |    81.81 |     100 |   89.02 | ...86-688,695-700 
  override.ts      |   94.11 |    93.33 |     100 |   94.11 | 63-64,81-82       
  ...-converter.ts |   94.89 |    90.41 |     100 |   94.89 | ...50-151,222-224 
  redaction.ts     |     100 |      100 |     100 |     100 |                   
  settings.ts      |   66.26 |      100 |      50 |   66.26 | 81-107,141-146    
  ...ceRegistry.ts |   94.01 |    83.14 |     100 |   94.01 | ...38-344,365-366 
  storage.ts       |     100 |      100 |     100 |     100 |                   
  ...ableSchema.ts |     100 |      100 |     100 |     100 |                   
  variables.ts     |   88.95 |    84.21 |     100 |   88.95 | ...32-235,238-241 
  ...extraction.ts |   85.77 |       81 |   89.47 |   85.77 | ...02-205,260-261 
 ...ent-plugins-v1 |   84.94 |    79.51 |     100 |   84.94 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  manifest.ts      |   81.87 |    84.48 |     100 |   81.87 | ...55-156,161-174 
  mcp.ts           |   84.98 |    79.56 |     100 |   84.98 | ...88-389,419-420 
  paths.ts         |     100 |    94.44 |     100 |     100 | 59                
  skills.ts        |   82.31 |    63.88 |     100 |   82.31 | ...38-141,150-151 
 src/followup      |    79.9 |    78.92 |    90.9 |    79.9 |                   
  followupState.ts |   98.44 |    95.74 |     100 |   98.44 | 236-237           
  index.ts         |     100 |      100 |     100 |     100 |                   
  overlayFs.ts     |   96.29 |    88.88 |     100 |   96.29 | 78,108,122        
  speculation.ts   |   71.76 |    64.76 |   71.42 |   71.76 | ...53-654,661-662 
  ...onToolGate.ts |   97.97 |     87.5 |     100 |   97.97 | 105,110           
  ...nGenerator.ts |   72.03 |    81.15 |   83.33 |   72.03 | ...68-219,331-333 
 src/generated     |       0 |        0 |       0 |       0 |                   
  git-commit.ts    |       0 |        0 |       0 |       0 | 1-10              
 src/goals         |    93.3 |    89.05 |    94.6 |    93.3 |                   
  ...eGoalStore.ts |   87.61 |    88.88 |   86.66 |   87.61 | ...85-188,196-204 
  ...t-verifier.ts |   96.27 |     90.9 |     100 |   96.27 | ...20,143-146,163 
  ...checkpoint.ts |   81.48 |    76.19 |     100 |   81.48 | ...02-105,115-118 
  goal-evidence.ts |   88.79 |     88.5 |   96.42 |   88.79 | ...04-805,828-831 
  ...projection.ts |   66.66 |    72.97 |   33.33 |   66.66 | ...83,186,190-192 
  ...ersistence.ts |   87.73 |    84.84 |      80 |   87.73 | ...-94,97,101-106 
  goal-protocol.ts |   95.74 |    93.33 |     100 |   95.74 | 154-155           
  goal-reducer.ts  |    93.4 |    90.65 |   96.96 |    93.4 | ...27,501,519-520 
  goal-runtime.ts  |   97.62 |     89.9 |     100 |   97.62 | ...1049,1169-1170 
  goal-tools.ts    |   98.22 |    93.02 |      95 |   98.22 | ...46-147,248-249 
  ...rn-context.ts |     100 |      100 |     100 |     100 |                   
  goal-verifier.ts |   92.46 |    92.85 |     100 |   92.46 | ...69-172,185-187 
  goal-wire.ts     |       0 |        0 |       0 |       0 | 1-28              
  goalHook.ts      |   96.91 |    92.42 |     100 |   96.91 | 115-120,221-222   
  goalJudge.ts     |   95.84 |    87.09 |     100 |   95.84 | ...55-356,448-449 
  index.ts         |     100 |      100 |     100 |     100 |                   
 src/hooks         |   88.07 |    86.35 |   88.54 |   88.07 |                   
  ...okRegistry.ts |   86.48 |    77.08 |     100 |   86.48 | ...41-344,362-369 
  ...bortSignal.ts |     100 |      100 |     100 |     100 |                   
  context-usage.ts |     100 |      100 |     100 |     100 |                   
  ...terpolator.ts |   96.66 |    93.33 |     100 |   96.66 | 66-67             
  ...HookRunner.ts |   96.68 |    87.23 |     100 |   96.68 | 110-112,231-233   
  ...Aggregator.ts |   96.57 |    91.48 |     100 |   96.57 | ...20-321,402,404 
  ...entHandler.ts |   95.57 |    84.76 |   94.73 |   95.57 | ...1040-1041,1051 
  hookPlanner.ts   |   87.55 |    85.54 |   86.66 |   87.55 | ...22-226,233-244 
  hookRegistry.ts  |   92.53 |    85.43 |     100 |   92.53 | ...39,458,462,466 
  hookRunner.ts    |   62.65 |    72.34 |   66.66 |   62.65 | ...70-771,780-781 
  hookSystem.ts    |   87.64 |     98.5 |   70.83 |   87.64 | ...58-759,765-766 
  ...HookRunner.ts |   79.06 |    66.66 |      80 |   79.06 | ...33-434,452-456 
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...edCallback.ts |     100 |      100 |     100 |     100 |                   
  ...HookRunner.ts |   94.19 |    84.37 |   81.81 |   94.19 | ...76-384,458-459 
  ...SkillHooks.ts |   78.75 |       75 |   66.66 |   78.75 | 62-66,137-152     
  ...oksManager.ts |   94.87 |    88.88 |     100 |   94.87 | ...84,325,327-329 
  ssrfGuard.ts     |   86.45 |    89.13 |     100 |   86.45 | ...85,289-295,301 
  stopHookCap.ts   |     100 |      100 |     100 |     100 |                   
  trustedHooks.ts  |      90 |    52.63 |     100 |      90 | ...53,66-67,97-98 
  types.ts         |   94.25 |    96.09 |   88.88 |   94.25 | ...46-547,632-636 
  urlValidator.ts  |     100 |      100 |     100 |     100 |                   
  ...it-context.ts |     100 |      100 |     100 |     100 |                   
 src/ide           |   76.98 |    85.03 |   79.03 |   76.98 |                   
  constants.ts     |     100 |      100 |     100 |     100 |                   
  detect-ide.ts    |     100 |      100 |     100 |     100 |                   
  ide-client.ts    |   69.16 |    84.65 |   68.29 |   69.16 | ...1068,1097-1105 
  ide-installer.ts |   89.06 |    79.31 |     100 |   89.06 | ...36,143-147,160 
  ideContext.ts    |     100 |      100 |     100 |     100 |                   
  process-utils.ts |   84.84 |    71.79 |     100 |   84.84 | ...37,151,193-194 
  types.ts         |     100 |      100 |     100 |     100 |                   
 src/lsp           |   58.96 |    70.57 |   66.14 |   58.96 |                   
  ...nfigLoader.ts |   80.55 |       72 |   95.45 |   80.55 | ...02-504,508-514 
  ...ionFactory.ts |   42.81 |    73.07 |      50 |   42.81 | ...76-427,433-450 
  ...Normalizer.ts |   23.09 |    13.72 |   30.43 |   23.09 | ...04-905,909-924 
  ...verManager.ts |   75.73 |     80.1 |   79.66 |   75.73 | ...1346,1352-1382 
  ...eLspClient.ts |   32.78 |       80 |   16.66 |   32.78 | ...89-293,299-300 
  ...LspService.ts |      60 |    73.36 |   78.26 |      60 | ...1575,1635-1645 
  configHash.ts    |     100 |      100 |     100 |     100 |                   
  constants.ts     |     100 |      100 |     100 |     100 |                   
  types.ts         |     100 |      100 |     100 |     100 |                   
 src/mcp           |    82.3 |    77.81 |   78.33 |    82.3 |                   
  configHash.ts    |     100 |      100 |     100 |     100 |                   
  constants.ts     |     100 |      100 |     100 |     100 |                   
  ...h-provider.ts |   86.95 |      100 |   33.33 |   86.95 | ...,93,97,101-102 
  ...h-provider.ts |   79.31 |    58.06 |     100 |   79.31 | ...26-933,940-942 
  ...en-storage.ts |   98.78 |    97.95 |     100 |   98.78 | 106-107           
  oauth-utils.ts   |   73.61 |    85.48 |    92.3 |   73.61 | ...46-366,392-421 
  ...n-provider.ts |   89.83 |       96 |   45.45 |   89.83 | ...43,147,151-152 
 .../token-storage |   82.12 |    88.19 |   89.28 |   82.12 |                   
  ...en-storage.ts |     100 |      100 |     100 |     100 |                   
  ...en-storage.ts |   87.08 |    87.03 |   95.23 |   87.08 | ...00-201,214-215 
  ...en-storage.ts |     100 |      100 |     100 |     100 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...en-storage.ts |   68.14 |    82.35 |   64.28 |   68.14 | ...81-295,298-314 
  types.ts         |     100 |      100 |     100 |     100 |                   
 src/memory        |   87.83 |    83.82 |   90.47 |   87.83 |                   
  ...y-document.ts |   89.52 |    84.61 |     100 |   89.52 | ...24-325,329-330 
  ...nel-memory.ts |   97.36 |    96.63 |   96.42 |   97.36 | ...91-293,367-368 
  const.ts         |   94.28 |     92.3 |     100 |   94.28 | 66-67             
  dream.ts         |    64.6 |    72.22 |      50 |    64.6 | ...04-109,124-165 
  ...entPlanner.ts |     100 |    83.33 |     100 |     100 | 136,146           
  entries.ts       |   75.59 |    84.84 |   83.33 |   75.59 | ...56-157,172-180 
  extract.ts       |   92.41 |    79.41 |     100 |   92.41 | 56-61,100,119-122 
  ...entPlanner.ts |   91.59 |    76.74 |     100 |   91.59 | ...05,114-117,293 
  ...ionPlanner.ts |       0 |        0 |       0 |       0 | 1                 
  forget.ts        |   81.83 |       75 |   83.33 |   81.83 | ...51,474,478-507 
  indexer.ts       |   94.14 |       84 |     100 |   94.14 | ...32-233,334,337 
  ...kill-agent.ts |   97.94 |    89.36 |     100 |   97.94 | 82-83,179-180     
  manager.ts       |    78.4 |    82.29 |   77.77 |    78.4 | ...1482,1495-1497 
  ...ent-config.ts |   86.99 |    82.69 |   86.36 |   86.99 | ...69,389,396-402 
  memoryAge.ts     |   90.47 |       80 |     100 |   90.47 | 50-51             
  paths.ts         |     100 |      100 |     100 |     100 |                   
  ...ing-skills.ts |     100 |       72 |     100 |     100 | 31-35,73-78,97    
  prompt.ts        |   97.26 |    87.03 |     100 |   97.26 | ...10-218,222,225 
  recall.ts        |   82.06 |       75 |    90.9 |   82.06 | ...59-364,395-406 
  refresh.ts       |   93.58 |    89.58 |     100 |   93.58 | ...75-176,183-184 
  ...ceSelector.ts |    93.1 |    81.81 |     100 |    93.1 | ...25,127-128,136 
  remember.ts      |   98.89 |    90.19 |     100 |   98.89 | 50,70             
  scan.ts          |   93.12 |    77.41 |     100 |   93.12 | ...08-109,154,157 
  scopes.ts        |     100 |      100 |     100 |     100 |                   
  ...et-scanner.ts |     100 |      100 |     100 |     100 |                   
  ...entPlanner.ts |   77.24 |    74.07 |   72.22 |   77.24 | ...52-456,459,465 
  status.ts        |   10.52 |      100 |       0 |   10.52 | 41-98             
  store.ts         |   92.92 |     82.6 |     100 |   92.92 | ...16-117,147-148 
  ...git-status.ts |     100 |     87.5 |     100 |     100 | 30                
  ...cret-guard.ts |     100 |      100 |     100 |     100 |                   
  ...emory-sync.ts |   94.24 |    82.85 |     100 |   94.24 | ...34-236,246-247 
  types.ts         |     100 |      100 |     100 |     100 |                   
  ...ontextFile.ts |   81.21 |     79.1 |   81.81 |   81.21 | ...63-277,291-296 
 src/mocks         |       0 |        0 |       0 |       0 |                   
  msw.ts           |       0 |        0 |       0 |       0 | 1-9               
 src/models        |   92.55 |    88.62 |   91.13 |   92.55 |                   
  constants.ts     |     100 |      100 |     100 |     100 |                   
  ...tor-config.ts |   97.77 |    91.83 |     100 |   97.77 | 155,161,171       
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...nfigErrors.ts |   74.22 |       44 |   84.61 |   74.22 | ...,67-74,106-117 
  ...igResolver.ts |   98.71 |    93.33 |     100 |   98.71 | 166,328,334       
  modelRegistry.ts |     100 |    98.11 |     100 |     100 | 177,261           
  modelsConfig.ts  |   89.36 |    86.93 |   88.09 |   89.36 | ...1404,1433-1434 
  types.ts         |     100 |      100 |     100 |     100 |                   
 src/output        |     100 |      100 |     100 |     100 |                   
  ...-formatter.ts |     100 |      100 |     100 |     100 |                   
  types.ts         |     100 |      100 |     100 |     100 |                   
 src/permissions   |   83.79 |    91.17 |   71.07 |   83.79 |                   
  autoMode.ts      |   97.66 |    93.13 |     100 |   97.66 | ...82-589,635,712 
  ...transcript.ts |      98 |       84 |     100 |      98 | 200-201           
  classifier.ts    |      94 |    94.54 |     100 |      94 | 158-165,389-393   
  ...erousRules.ts |     100 |    89.36 |     100 |     100 | 110,133,147,175   
  ...alTracking.ts |     100 |      100 |     100 |     100 |                   
  ...e-commands.ts |   86.77 |     73.8 |     100 |   86.77 | 131-141,210-214   
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...on-manager.ts |   86.63 |    89.01 |      80 |   86.63 | ...1111,1217-1221 
  rule-parser.ts   |   94.49 |     92.7 |     100 |   94.49 | ...1447,1481-1483 
  ...-semantics.ts |   70.44 |    91.09 |   46.66 |   70.44 | ...2237,2311-2314 
  types.ts         |     100 |      100 |     100 |     100 |                   
 ...sifier-prompts |   99.04 |    95.23 |     100 |   99.04 |                   
  system-prompt.ts |   99.04 |    95.23 |     100 |   99.04 | 220               
 src/prompts       |   83.63 |      100 |    87.5 |   83.63 |                   
  mcp-prompts.ts   |   18.18 |      100 |       0 |   18.18 | 11-19             
  ...t-registry.ts |     100 |      100 |     100 |     100 |                   
 src/providers     |   83.71 |     78.6 |   81.25 |   83.71 |                   
  all-providers.ts |     100 |      100 |     100 |     100 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  install.ts       |   93.11 |     84.5 |     100 |   93.11 | ...56-257,330-331 
  ...der-config.ts |   75.85 |    74.04 |   78.26 |   75.85 | ...73-474,502-503 
  types.ts         |       0 |        0 |       0 |       0 | 1                 
 ...viders/presets |   97.82 |    91.66 |   63.63 |   97.82 |                   
  ...oding-plan.ts |   87.34 |      100 |       0 |   87.34 | 81-83,86-88,90-93 
  ...a-standard.ts |     100 |      100 |     100 |     100 |                   
  ...token-plan.ts |     100 |      100 |     100 |     100 |                   
  ...m-provider.ts |   97.05 |    81.25 |      75 |   97.05 | 118-119           
  deepseek.ts      |     100 |      100 |     100 |     100 |                   
  grok.ts          |     100 |      100 |     100 |     100 |                   
  idealab.ts       |     100 |      100 |     100 |     100 |                   
  minimax.ts       |     100 |      100 |     100 |     100 |                   
  modelscope.ts    |     100 |      100 |     100 |     100 |                   
  openrouter.ts    |     100 |      100 |     100 |     100 |                   
  requesty.ts      |     100 |      100 |     100 |     100 |                   
  zai.ts           |     100 |      100 |     100 |     100 |                   
 src/qwen          |   85.41 |    78.76 |   95.89 |   85.41 |                   
  ...tGenerator.ts |   98.64 |    98.18 |     100 |   98.64 | 105-106           
  qwenOAuth2.ts    |   82.79 |    73.75 |   90.62 |   82.79 | ...1205-1221,1251 
  ...kenManager.ts |   85.36 |    76.61 |     100 |   85.36 | ...52-757,778-783 
 src/resources     |     100 |      100 |     100 |     100 |                   
  ...e-registry.ts |     100 |      100 |     100 |     100 |                   
 src/services      |    89.8 |    84.73 |   96.92 |    89.8 |                   
  ...ionTrailer.ts |     100 |      100 |     100 |     100 |                   
  ...llRegistry.ts |    98.5 |     87.5 |     100 |    98.5 | 81-82,105,476-477 
  ...ionService.ts |   97.51 |    96.15 |     100 |   97.51 | ...,929,1072-1080 
  ...ingService.ts |   91.41 |    85.15 |   95.65 |   91.41 | ...2116,2143-2144 
  ...ttribution.ts |   91.73 |    87.71 |      90 |   91.73 | ...80-685,826-827 
  ...utSlimming.ts |    97.2 |    93.93 |     100 |    97.2 | ...39-340,378-381 
  cronScheduler.ts |   94.17 |    90.45 |      98 |   94.17 | ...1333,1736-1737 
  cronTasksFile.ts |   96.31 |    91.81 |     100 |   96.31 | ...11,336-337,483 
  cronTasksLock.ts |   94.44 |    89.47 |     100 |   94.44 | ...02-103,132-133 
  ...eryService.ts |   96.22 |    93.54 |      90 |   96.22 | 121,155-156,161   
  ...oryService.ts |   88.17 |    79.02 |    92.3 |   88.17 | ...1303,1344-1347 
  fileReadCache.ts |    97.5 |    96.07 |     100 |    97.5 | 349-350,363-364   
  ...temService.ts |    92.8 |    84.68 |   94.11 |    92.8 | ...53,479-486,531 
  ...ratedFiles.ts |      96 |    88.23 |     100 |      96 | 119-120,146-147   
  gitInit.ts       |     100 |      100 |     100 |     100 |                   
  ...reeService.ts |    73.7 |    68.49 |   95.83 |    73.7 | ...2196,2225-2226 
  ...on-service.ts |   87.38 |       72 |     100 |   87.38 | ...01-305,343-344 
  ...references.ts |   98.39 |    88.76 |     100 |   98.39 | 154-155,215-216   
  ...ionService.ts |   98.26 |    97.35 |     100 |   98.26 | ...13-714,761-762 
  ...ticsDumper.ts |   98.37 |    95.23 |     100 |   98.37 | 185-186           
  ...ureMonitor.ts |   95.82 |    90.47 |   97.05 |   95.82 | ...60,861,875-877 
  ...orRegistry.ts |    97.3 |    91.22 |     100 |    97.3 | ...53-454,611-612 
  ...ttachments.ts |   97.74 |    90.85 |     100 |   97.74 | 298-308,646       
  ...ersistence.ts |   90.95 |    78.75 |     100 |   90.95 | ...78,963-964,992 
  ...on-service.ts |   94.49 |    92.26 |   97.14 |   94.49 | ...98-600,656-664 
  ...ce-service.ts |    98.5 |    94.11 |    90.9 |    98.5 | 64-65             
  ...ipt-reader.ts |   94.55 |    89.78 |   96.66 |   94.55 | ...1353-1354,1422 
  ...est-helper.ts |       0 |        0 |       0 |       0 | 1-65              
  ...iter-lease.ts |   83.14 |    74.47 |   97.61 |   83.14 | ...2433,2445-2448 
  sessionRecap.ts  |   67.56 |    43.47 |     100 |   67.56 | ...60,178,180-183 
  ...ionService.ts |   89.08 |    84.71 |   97.18 |   89.08 | ...2514,2590-2610 
  sessionTitle.ts  |   94.26 |    73.21 |     100 |   94.26 | ...45-248,279-280 
  ...ionService.ts |    84.4 |    78.45 |   97.18 |    84.4 | ...2493,2499-2504 
  ...pInhibitor.ts |   97.42 |    92.77 |     100 |   97.42 | ...30,169,369-370 
  ...Estimation.ts |     100 |    88.23 |     100 |     100 | 118-119           
  ...ageService.ts |   97.76 |    91.59 |   93.75 |   97.76 | ...61-262,366,567 
  ...ite-origin.ts |     100 |    93.33 |     100 |     100 | 32                
  ...UseSummary.ts |   94.63 |    88.46 |     100 |   94.63 | ...62-164,214-215 
  ...rd-service.ts |     100 |    88.37 |     100 |     100 | ...29,145-146,241 
  ...oryService.ts |   90.72 |    84.07 |     100 |   90.72 | ...06-509,561-562 
  ...reeCleanup.ts |   14.42 |      100 |   33.33 |   14.42 | 58-186            
  ...ionService.ts |   88.36 |     87.8 |     100 |   88.36 | ...48-449,465-466 
 ...icrocompaction |    98.9 |    95.08 |     100 |    98.9 |                   
  microcompact.ts  |    98.9 |    95.08 |     100 |    98.9 | ...40,749,758-759 
 ...s/visionBridge |   98.81 |    92.12 |     100 |   98.81 |                   
  ...capability.ts |     100 |      100 |     100 |     100 |                   
  ...part-utils.ts |     100 |      100 |     100 |     100 |                   
  ...ion-bridge.ts |   98.72 |    82.35 |     100 |   98.72 | 65,71             
  ...-constants.ts |     100 |      100 |     100 |     100 |                   
  ...ge-service.ts |   98.61 |     94.7 |     100 |   98.61 | ...06,666,679-680 
 src/skills        |   89.29 |    85.89 |   93.61 |   89.29 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...activation.ts |     100 |    93.33 |     100 |     100 | 93,112            
  skill-curator.ts |   89.71 |    81.54 |     100 |   89.71 | ...01-902,904-907 
  skill-load.ts    |   94.84 |     87.5 |     100 |   94.84 | ...03,223,235-237 
  skill-manager.ts |   84.82 |    85.29 |   83.33 |   84.82 | ...1243,1250-1254 
  skill-paths.ts   |   90.42 |     87.5 |     100 |   90.42 | ...19-120,125-126 
  symlinkScope.ts  |     100 |      100 |     100 |     100 |                   
  types.ts         |   97.91 |    98.03 |     100 |   97.91 | 277-278           
 ...ataviz/scripts |   80.06 |    95.23 |   88.23 |   80.06 |                   
  ...te_palette.js |   80.06 |    95.23 |   88.23 |   80.06 | 261-296,306-328   
 ...s/bundled/loop |   97.48 |    95.77 |     100 |   97.48 |                   
  ...omous-loop.ts |     100 |      100 |     100 |     100 |                   
  ...-task-file.ts |   94.85 |     92.4 |     100 |   94.85 | ...56,367,375-376 
  ...k-resolver.ts |     100 |      100 |     100 |     100 |                   
 src/subagents     |   87.72 |    89.01 |   96.55 |   87.72 |                   
  ...ter-schema.ts |     100 |    98.07 |     100 |     100 | 99                
  ...tin-agents.ts |     100 |      100 |     100 |     100 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...nt-manager.ts |   84.48 |    85.91 |   94.87 |   84.48 | ...1582,1659-1660 
  types.ts         |     100 |      100 |     100 |     100 |                   
  validation.ts    |   92.46 |    95.18 |     100 |   92.46 | 47-52,63-68,71-76 
 src/telemetry     |   81.83 |    83.71 |   84.92 |   81.83 |                   
  ...ty-tracker.ts |     100 |      100 |     100 |     100 |                   
  config.ts        |     100 |      100 |     100 |     100 |                   
  constants.ts     |     100 |      100 |     100 |     100 |                   
  ...on-metrics.ts |   99.08 |    80.95 |     100 |   99.08 | 185,199           
  ...on-tracing.ts |   76.31 |    74.62 |   73.68 |   76.31 | ...80,387-389,405 
  ...attributes.ts |   95.15 |    87.27 |     100 |   95.15 | ...97-198,216-217 
  ...ag-metrics.ts |     100 |    77.77 |     100 |     100 | 21,40             
  ...t-loop-lag.ts |   96.85 |    85.71 |     100 |   96.85 | 170-173           
  ...-exporters.ts |   65.78 |    83.33 |   55.55 |   65.78 | ...04-105,108-109 
  ...ai-content.ts |    74.5 |    66.41 |   91.66 |    74.5 | ...1480,1493-1502 
  ...i-provider.ts |     100 |       99 |     100 |     100 | 99                
  ...ai-request.ts |   87.52 |    92.79 |   83.78 |   87.52 | ...55-561,564-570 
  gen-ai-usage.ts  |     100 |      100 |     100 |     100 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...t.circular.ts |       0 |        0 |       0 |       0 | 1-111             
  ...-processor.ts |    99.1 |    95.72 |      95 |    99.1 | 145,369-370       
  ...t.circular.ts |       0 |        0 |       0 |       0 | 1-128             
  loggers.ts       |   60.25 |    77.03 |   66.66 |   60.25 | ...1492,1509-1529 
  metrics.ts       |   80.37 |    82.35 |   80.95 |   80.37 | ...1150,1153-1164 
  otlp-urls.ts     |     100 |      100 |     100 |     100 |                   
  ...attributes.ts |     100 |      100 |     100 |     100 |                   
  ...ime-config.ts |       0 |        0 |       0 |       0 | 1                 
  sanitize.ts      |      80 |    83.33 |     100 |      80 | 35-36,41-42       
  ...rters-grpc.ts |     100 |      100 |     100 |     100 |                   
  ...rters-http.ts |     100 |      100 |     100 |     100 |                   
  sdk-impl.ts      |   91.06 |    87.15 |   68.75 |   91.06 | ...32,482-483,499 
  sdk.ts           |    82.7 |     90.9 |   66.66 |    82.7 | ...00-204,242-264 
  ...on-context.ts |     100 |      100 |     100 |     100 |                   
  ...ion-events.ts |     100 |      100 |     100 |     100 |                   
  ...on-tracing.ts |    91.1 |    88.68 |   96.77 |    91.1 | ...1737,1768-1771 
  ...etry-utils.ts |     100 |      100 |     100 |     100 |                   
  ...l-decision.ts |     100 |      100 |     100 |     100 |                   
  trace-context.ts |     100 |      100 |     100 |     100 |                   
  ...e-id-utils.ts |     100 |      100 |     100 |     100 |                   
  tracer.ts        |   98.56 |    88.63 |     100 |   98.56 | 52,101            
  types.ts         |   83.09 |    88.31 |   86.36 |   83.09 | ...1467,1471-1478 
  uiTelemetry.ts   |   97.18 |    93.93 |      88 |   97.18 | ...70,314,461-462 
 ...ry/qwen-logger |   74.23 |     80.7 |      70 |   74.23 |                   
  event-types.ts   |       0 |        0 |       0 |       0 |                   
  qwen-logger.ts   |   74.23 |    80.53 |   69.49 |   74.23 | ...1122,1160-1161 
 src/test-utils    |   96.38 |    98.61 |   83.33 |   96.38 |                   
  config.ts        |     100 |      100 |     100 |     100 |                   
  ...st-helpers.ts |   94.11 |       90 |     100 |   94.11 | 69-70             
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...mised-lock.ts |     100 |      100 |     100 |     100 |                   
  mock-tool.ts     |   94.85 |      100 |   78.78 |   94.85 | ...53,227-228,241 
  ...aceContext.ts |     100 |      100 |     100 |     100 |                   
 src/tools         |   86.25 |    85.07 |   88.72 |   86.25 |                   
  ...erQuestion.ts |   89.71 |    80.76 |   91.66 |   89.71 | ...66-367,374-375 
  ...-registrar.ts |    77.7 |    66.66 |   66.66 |    77.7 | ...72-277,292-294 
  ...ub-session.ts |   89.67 |     91.3 |   81.81 |   89.67 | ...03-304,315-322 
  cron-create.ts   |   90.64 |    92.85 |   72.72 |   90.64 | ...,73-74,223-231 
  cron-delete.ts   |   97.56 |      100 |   83.33 |   97.56 | 31-32             
  cron-list.ts     |   98.23 |    95.34 |    87.5 |   98.23 | 57-58             
  diffOptions.ts   |     100 |      100 |     100 |     100 |                   
  display-image.ts |   87.42 |    84.84 |   88.88 |   87.42 | ...29-134,194-195 
  edit.ts          |   82.76 |    86.77 |   81.25 |   82.76 | ...45-746,865-915 
  ...r-worktree.ts |   83.14 |    67.56 |    87.5 |   83.14 | ...84-187,278-279 
  enterPlanMode.ts |      85 |     82.6 |    87.5 |      85 | ...28-133,161-175 
  exit-worktree.ts |   83.29 |    83.65 |   94.44 |   83.29 | ...14-515,537-538 
  exitPlanMode.ts  |      95 |    85.29 |     100 |      95 | ...21-325,344,378 
  ...permission.ts |     100 |      100 |     100 |     100 |                   
  glob.ts          |   96.33 |     88.5 |     100 |   96.33 | ...24-225,373,376 
  grep.ts          |   90.73 |    86.61 |   85.71 |   90.73 | ...76-677,727-728 
  ...adTracking.ts |     100 |      100 |     100 |     100 |                   
  image-gen.ts     |   91.66 |    77.41 |    90.9 |   91.66 | ...13-214,221-222 
  list-agents.ts   |   94.02 |    82.35 |   83.33 |   94.02 | 31-32,47-48       
  loop-wakeup.ts   |   99.27 |    92.85 |     100 |   99.27 | 45                
  ls.ts            |   96.74 |    90.27 |     100 |   96.74 | 176-181,212,216   
  lsp.ts           |   72.71 |     59.5 |   90.32 |   72.71 | ...1212,1214-1215 
  ...nt-manager.ts |   82.13 |    80.47 |   85.71 |   82.13 | ...3234,3236-3237 
  mcp-client.ts    |   80.03 |    86.58 |   89.47 |   80.03 | ...2272,2276-2279 
  ...ry-timeout.ts |     100 |      100 |     100 |     100 |                   
  mcp-errors.ts    |     100 |      100 |     100 |     100 |                   
  ...pool-entry.ts |   79.21 |    85.71 |   81.57 |   79.21 | ...1341,1349-1350 
  ...ool-events.ts |       8 |      100 |       0 |       8 | 132-158           
  mcp-pool-key.ts  |   97.46 |    93.93 |     100 |   97.46 | 176-177           
  ...ce-content.ts |   96.55 |    91.17 |     100 |   96.55 | 80-82             
  mcp-retry.ts     |   97.67 |    95.65 |     100 |   97.67 | 131-132           
  ...ion-config.ts |     100 |      100 |     100 |     100 |                   
  mcp-status.ts    |     100 |      100 |     100 |     100 |                   
  mcp-tool.ts      |   98.35 |    93.71 |     100 |   98.35 | ...-990,1045-1046 
  ...sport-pool.ts |   83.98 |     80.3 |   88.46 |   83.98 | ...1409,1416-1420 
  ...ace-budget.ts |   87.27 |     82.6 |     100 |   87.27 | ...00-305,340-345 
  memory-config.ts |     100 |      100 |     100 |     100 |                   
  ...iable-tool.ts |     100 |    84.61 |     100 |     100 | 101,108           
  monitor.ts       |   91.82 |    83.09 |   88.46 |   91.82 | ...99,612,810-815 
  notebook-edit.ts |   85.71 |    77.08 |   81.25 |   85.71 | ...96-912,958-959 
  ...escendants.ts |   36.17 |    64.51 |   55.55 |   36.17 | ...46-310,385-390 
  ...nforcement.ts |   83.21 |    90.69 |     100 |   83.21 | 147-158,207-220   
  read-file.ts     |   95.49 |    88.52 |   86.66 |   95.49 | ...49,464,536-537 
  ...p-resource.ts |   96.85 |      100 |   91.66 |   96.85 | 92-96             
  ...d-artifact.ts |   91.18 |    86.71 |    87.5 |   91.18 | ...26-427,441-453 
  ripGrep.ts       |    94.6 |    87.26 |   95.23 |    94.6 | ...33-734,740-741 
  ...-transport.ts |   71.42 |    55.55 |   71.42 |   71.42 | ...36-137,143-144 
  send-message.ts  |   81.13 |    89.74 |    62.5 |   81.13 | ...80-286,363-371 
  ...n-mcp-view.ts |   94.07 |    91.89 |    90.9 |   94.07 | 131-139           
  shell.ts         |   78.81 |    84.22 |   91.91 |   78.81 | ...5036,5099-5100 
  skill-utils.ts   |     100 |      100 |     100 |     100 |                   
  skill.ts         |   91.39 |    92.55 |      90 |   91.39 | ...84,488,534-556 
  ...eticOutput.ts |   95.12 |      100 |      80 |   95.12 | 87-88             
  task-create.ts   |    94.4 |    93.33 |   81.81 |    94.4 | 45-49,63-64,95    
  task-list.ts     |   73.38 |    77.77 |   83.33 |   73.38 | ...02,105,109-116 
  task-stop.ts     |   93.14 |    96.15 |   85.71 |   93.14 | 39-40,54-64       
  task-update.ts   |   82.89 |    83.92 |    92.3 |   82.89 | ...14-422,454-465 
  team-create.ts   |   97.22 |    85.71 |   83.33 |   97.22 | 48-49,129-130     
  team-delete.ts   |   86.74 |    83.33 |   83.33 |   86.74 | 37-38,42-48,72-73 
  ...n-approval.ts |   92.14 |    96.77 |   77.77 |   92.14 | 38-39,42-43,93-99 
  todoWrite.ts     |   95.13 |    87.85 |   93.33 |   95.13 | ...23-527,540-545 
  tool-error.ts    |     100 |      100 |     100 |     100 |                   
  tool-names.ts    |     100 |      100 |     100 |     100 |                   
  tool-registry.ts |   78.57 |    79.59 |    82.6 |   78.57 | ...89-990,998-999 
  tool-search.ts   |   96.19 |    89.72 |   93.33 |   96.19 | ...09,259-264,426 
  tools.ts         |   93.11 |    92.53 |   91.66 |   93.11 | ...69-570,586-592 
  ...reapproved.ts |   99.27 |    94.11 |     100 |   99.27 | 170               
  web-fetch.ts     |   96.05 |    90.54 |   96.77 |   96.05 | ...85-786,800-801 
  web-search.ts    |   90.58 |    83.57 |      80 |   90.58 | ...1025,1083-1086 
  write-file.ts    |   86.72 |    84.92 |   88.88 |   86.72 | ...25-828,865-900 
  zoom-image.ts    |   95.76 |    93.75 |      90 |   95.76 | 54-59,203-204     
 src/tools/agent   |   87.22 |    87.68 |   88.69 |   87.22 |                   
  agent.ts         |   85.84 |    86.59 |   86.31 |   85.84 | ...4315,4337-4347 
  fork-profile.ts  |   93.65 |       90 |     100 |   93.65 | ...33-134,171-174 
  fork-subagent.ts |   98.73 |       95 |     100 |   98.73 | 101-102,173       
 ...tools/artifact |   95.78 |    92.51 |   88.63 |   95.78 |                   
  artifact-tool.ts |   91.46 |    88.46 |   71.42 |   91.46 | ...13-314,322-325 
  ...-publisher.ts |     100 |    85.71 |     100 |     100 | 32                
  ...-publisher.ts |   96.74 |    97.72 |    87.5 |   96.74 | 29-30,156-157     
  html.ts          |     100 |    96.77 |     100 |     100 | 122               
  ...-publisher.ts |     100 |       80 |     100 |     100 | 30                
  oss-publisher.ts |    98.1 |    91.48 |     100 |    98.1 | 43-45             
  publisher.ts     |     100 |      100 |     100 |     100 |                   
 ...s/computer-use |   90.21 |    82.17 |   78.08 |   90.21 |                   
  bootstrap.ts     |   59.42 |    80.95 |   41.66 |   59.42 | ...35-339,341-345 
  client.ts        |   80.11 |       90 |   77.77 |   80.11 | ...97,242-243,274 
  constants.ts     |     100 |    94.73 |     100 |     100 | 129,256           
  downloader.ts    |   65.29 |    52.77 |   58.33 |   65.29 | ...99-300,316-355 
  index.ts         |     100 |      100 |     100 |     100 |                   
  install-state.ts |   94.44 |    72.72 |     100 |   94.44 | 44-45             
  ...n-detector.ts |     100 |     87.5 |     100 |     100 | 50                
  schemas.ts       |     100 |      100 |     100 |     100 |                   
  tool.ts          |    96.3 |    85.71 |     100 |    96.3 | 75-76,184,252-258 
 ...tools/workflow |   86.51 |    84.81 |      75 |   86.51 |                   
  workflow.ts      |   86.51 |    84.81 |      75 |   86.51 | ...67,512,514-515 
 src/utils         |   92.89 |    89.63 |   96.88 |   92.89 |                   
  LruCache.ts      |     100 |      100 |     100 |     100 |                   
  ...Controller.ts |     100 |      100 |     100 |     100 |                   
  ...ssageQueue.ts |     100 |      100 |     100 |     100 |                   
  ...cFileWrite.ts |   94.94 |    92.47 |     100 |   94.94 | ...43-544,651-655 
  bareMode.ts      |   81.81 |      100 |      50 |   81.81 | 18-19             
  ...ry-content.ts |   98.45 |    95.45 |     100 |   98.45 | 132-133,159-160   
  browser.ts       |   86.84 |    78.94 |     100 |   86.84 | 34,36-37,65-66    
  btwUtils.ts      |   13.95 |      100 |       0 |   13.95 | 17-31,34-55       
  bundlePaths.ts   |     100 |      100 |     100 |     100 |                   
  ...on-context.ts |     100 |      100 |     100 |     100 |                   
  ...igResolver.ts |     100 |      100 |     100 |     100 |                   
  ...engthError.ts |   91.06 |    89.47 |     100 |   91.06 | ...46-147,154-155 
  ...n-branches.ts |   95.88 |    94.11 |      95 |   95.88 | ...98-499,511-524 
  ...tion-chain.ts |     100 |      100 |     100 |     100 |                   
  cronDisplay.ts   |     100 |    97.61 |     100 |     100 | 46                
  cronParser.ts    |   95.34 |    93.33 |     100 |   95.34 | 41-42,47-48,70-71 
  debugLogger.ts   |   96.66 |    96.61 |   88.88 |   96.66 | 192-196           
  editHelper.ts    |   93.63 |     83.9 |     100 |   93.63 | ...27-428,462-463 
  editor.ts        |   97.65 |    95.45 |     100 |   97.65 | ...35-336,338-339 
  encoding.ts      |     100 |      100 |     100 |     100 |                   
  env.ts           |     100 |      100 |     100 |     100 |                   
  ...arResolver.ts |   94.28 |    88.88 |     100 |   94.28 | 28-29,125-126     
  ...entContext.ts |   96.63 |    90.13 |   96.66 |   96.63 | ...42,444-445,512 
  errorParsing.ts  |     100 |      100 |     100 |     100 |                   
  ...rReporting.ts |   95.65 |    93.33 |     100 |   95.65 | 37-38             
  errors.ts        |   83.39 |    95.17 |    61.9 |   83.39 | ...81-397,401-407 
  fetch.ts         |   90.68 |    82.51 |     100 |   90.68 | ...72,483-484,503 
  file-identity.ts |     100 |      100 |     100 |     100 |                   
  fileUtils.ts     |   94.87 |    92.95 |   96.15 |   94.87 | ...1907,1915-1916 
  forkedAgent.ts   |   92.45 |    82.35 |   93.75 |   92.45 | ...34,642,647-654 
  formatters.ts    |     100 |      100 |     100 |     100 |                   
  ...eUtilities.ts |    92.4 |    86.95 |     100 |    92.4 | ...52-158,168-169 
  ...rStructure.ts |   94.39 |    94.28 |     100 |   94.39 | ...29-132,343-348 
  getPty.ts        |   31.57 |       50 |     100 |   31.57 | 26-38             
  git-branches.ts  |    91.6 |    84.21 |    92.3 |    91.6 | ...90,405-410,570 
  ...fig-safety.ts |   97.01 |       80 |     100 |   97.01 | 53-54             
  gitDiff.ts       |   95.19 |    81.36 |     100 |   95.19 | ...1073,1419-1420 
  gitDirect.ts     |   98.84 |    94.28 |     100 |   98.84 | 234,318           
  ...noreParser.ts |   94.48 |    93.22 |     100 |   94.48 | ...23-124,158-159 
  gitUtils.ts      |   78.02 |    81.25 |   85.71 |   78.02 | ...22-123,147-198 
  github-prs.ts    |   95.74 |    82.27 |     100 |   95.74 | 216,314-322       
  iconvHelper.ts   |     100 |      100 |     100 |     100 |                   
  ...rePatterns.ts |     100 |      100 |     100 |     100 |                   
  image-view.ts    |   95.12 |    93.33 |     100 |   95.12 | ...68-172,240-244 
  ...ionManager.ts |     100 |     90.9 |     100 |     100 | 27                
  ...lPromptIds.ts |     100 |      100 |     100 |     100 |                   
  ...on-context.ts |     100 |      100 |     100 |     100 |                   
  jsonl-utils.ts   |   95.41 |    93.54 |     100 |   95.41 | ...27-328,370-373 
  ...-detection.ts |     100 |      100 |     100 |     100 |                   
  ...iconv-lite.ts |     100 |      100 |     100 |     100 |                   
  ...simple-git.ts |   96.77 |    91.66 |     100 |   96.77 | 38                
  ...m-headless.ts |      96 |    88.88 |     100 |      96 | 34                
  ...iagnostics.ts |    96.4 |     94.2 |     100 |    96.4 | ...66,293-294,376 
  ...yDiscovery.ts |    92.4 |    89.13 |     100 |    92.4 | ...28,331,522-525 
  ...tProcessor.ts |   94.01 |       90 |     100 |   94.01 | ...47-353,445-446 
  ...Inspectors.ts |     100 |      100 |     100 |     100 |                   
  modelId.ts       |   98.96 |    98.21 |     100 |   98.96 | 153               
  ...kerChecker.ts |    90.9 |    91.66 |     100 |    90.9 | 73-79             
  notebook.ts      |   94.57 |    89.91 |   95.83 |   94.57 | ...21,333,385-387 
  openaiLogger.ts  |   91.66 |    89.74 |     100 |   91.66 | ...26-228,251-256 
  osc8.ts          |   54.26 |    64.86 |   83.33 |   54.26 | ...72-195,197-257 
  partUtils.ts     |     100 |    98.64 |     100 |     100 | 211               
  pathReader.ts    |     100 |      100 |     100 |     100 |                   
  paths.ts         |   93.61 |    92.42 |     100 |   93.61 | ...62-563,565-567 
  pdf.ts           |   92.17 |    85.81 |     100 |   92.17 | ...64-565,606-611 
  projectPath.ts   |     100 |      100 |     100 |     100 |                   
  projectRoot.ts   |   71.73 |    78.57 |     100 |   71.73 | 54-66             
  ...ectSummary.ts |   89.62 |    72.41 |     100 |   89.62 | ...40-145,196-199 
  ...tIdContext.ts |     100 |      100 |     100 |     100 |                   
  proxyUtils.ts    |     100 |      100 |     100 |     100 |                   
  ...rDetection.ts |   71.15 |       86 |     100 |   71.15 | ...-90,96-101,147 
  ...noreParser.ts |   92.63 |    91.66 |     100 |   92.63 | ...77-178,197-198 
  rateLimit.ts     |   93.75 |    89.62 |     100 |   93.75 | ...13,218-219,262 
  ...text-range.ts |   96.98 |    87.15 |     100 |   96.98 | ...87-688,763-764 
  readManyFiles.ts |   95.75 |    80.86 |     100 |   95.75 | ...05,558,568-572 
  retry.ts         |   96.09 |    92.52 |     100 |   96.09 | ...67,558-559,577 
  retryContext.ts  |     100 |      100 |     100 |     100 |                   
  ...sification.ts |   97.63 |    97.11 |     100 |   97.63 | ...17,251-252,278 
  retryPolicy.ts   |   97.72 |    90.56 |     100 |   97.72 | 130-131           
  ripgrepUtils.ts  |   90.04 |    93.43 |   95.45 |   90.04 | ...55-565,598-599 
  ...sDiscovery.ts |   97.46 |    93.05 |     100 |   97.46 | ...04,182-183,202 
  ...iagnostics.ts |   83.08 |     67.5 |   92.59 |   83.08 | ...23,543-544,550 
  ...tchOptions.ts |   84.87 |    86.71 |   96.29 |   84.87 | ...71,696,725-734 
  ...odelPrefix.ts |     100 |      100 |     100 |     100 |                   
  runtimeStatus.ts |   97.77 |    91.48 |     100 |   97.77 | 172-173           
  safe-mode.ts     |     100 |      100 |     100 |     100 |                   
  safeJsonParse.ts |     100 |      100 |     100 |     100 |                   
  ...nStringify.ts |     100 |      100 |     100 |     100 |                   
  ...-child-env.ts |     100 |      100 |     100 |     100 |                   
  ...aConverter.ts |   98.03 |    97.75 |     100 |   98.03 | 100,102-103       
  ...aValidator.ts |   92.09 |    83.65 |   90.47 |   92.09 | ...60,882-883,896 
  ...r-launcher.ts |   96.35 |    93.97 |   85.71 |   96.35 | ...35-336,347-348 
  sedEditParser.ts |   91.78 |    92.18 |     100 |   91.78 | ...66-569,645-646 
  ...nIdContext.ts |     100 |      100 |     100 |     100 |                   
  ...orageUtils.ts |   95.98 |    83.96 |     100 |   95.98 | ...70,386,466,485 
  ...-pager-env.ts |     100 |      100 |     100 |     100 |                   
  ...fety-rules.ts |     100 |     89.7 |     100 |     100 | ...01,304,309-311 
  shell-utils.ts   |   86.07 |    88.34 |     100 |   86.07 | ...2269,2276-2280 
  ...lAstParser.ts |   98.27 |    91.38 |     100 |   98.27 | ...1321-1323,1333 
  ...ContextEnv.ts |     100 |       92 |     100 |     100 | 50-52             
  ...nlyChecker.ts |   96.33 |    96.57 |     100 |   96.33 | ...83-284,292-293 
  sideQuery.ts     |   86.82 |    86.66 |     100 |   86.82 | ...79-185,187-193 
  ...pEventSink.ts |     100 |       80 |     100 |     100 | 61                
  ...tGenerator.ts |     100 |      100 |     100 |     100 |                   
  ...ameContext.ts |     100 |      100 |     100 |     100 |                   
  symlink.ts       |   77.77 |       50 |     100 |   77.77 | 44,54-59          
  ...e-encoding.ts |   85.96 |    76.47 |     100 |   85.96 | 58-61,64-65,78-79 
  ...emEncoding.ts |   96.36 |    91.17 |     100 |   96.36 | 59-60,124-125     
  terminalSafe.ts  |     100 |      100 |     100 |     100 |                   
  ...Serializer.ts |   98.72 |       90 |     100 |   98.72 | 42-43,134,201-203 
  testUtils.ts     |   53.33 |      100 |   33.33 |   53.33 | ...53,59-64,70-72 
  ...-constants.ts |     100 |      100 |     100 |     100 |                   
  textUtils.ts     |      65 |      100 |      75 |      65 | 56-75             
  thoughtUtils.ts  |     100 |    95.65 |     100 |     100 | 99                
  ...-converter.ts |   95.23 |    85.71 |     100 |   95.23 | 36-37             
  ...name-utils.ts |     100 |      100 |     100 |     100 |                   
  ...-finalizer.ts |   97.66 |     90.9 |     100 |   97.66 | 165-166,168-172   
  tool-utils.ts    |    95.2 |    93.61 |     100 |    95.2 | ...58-159,162-163 
  ...ultCleanup.ts |   54.62 |       64 |      75 |   54.62 | ...03-105,108-134 
  ...Compaction.ts |   96.13 |    96.42 |     100 |   96.13 | ...34-339,341-346 
  ...pt-records.ts |    87.5 |    86.13 |     100 |    87.5 | ...76-480,510-525 
  truncation.ts    |   90.56 |    90.43 |     100 |   90.56 | ...35-443,480-486 
  windowsPath.ts   |   89.47 |    79.31 |     100 |   89.47 | ...57-58,62,90-91 
  ...aceContext.ts |   95.39 |    89.47 |     100 |   95.39 | ...16-317,321-322 
  xml.ts           |    97.8 |    87.69 |     100 |    97.8 | 98-99             
  yaml-parser.ts   |   83.87 |    77.27 |     100 |   83.87 | ...31-234,239-240 
 ...ils/filesearch |   83.94 |    80.72 |   94.73 |   83.94 |                   
  crawlCache.ts    |     100 |      100 |     100 |     100 |                   
  crawler.ts       |    82.9 |    76.81 |   95.08 |    82.9 | ...1563,1597-1598 
  fileSearch.ts    |   93.78 |    87.67 |     100 |   93.78 | ...71-272,274-275 
  fzfWorker.ts     |       0 |        0 |       0 |       0 | 1-109             
  ...rkerHandle.ts |   84.05 |    75.43 |   89.47 |   84.05 | ...30-334,340-341 
  ignore.ts        |     100 |    97.36 |     100 |     100 | 187               
  result-cache.ts  |     100 |    93.75 |     100 |     100 | 49                
 ...uest-tokenizer |   69.76 |    75.47 |   85.29 |   69.76 |                   
  ...eTokenizer.ts |   65.72 |    74.02 |    92.3 |   65.72 | ...65-466,479-533 
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...tTokenizer.ts |   68.39 |    69.49 |    90.9 |   68.39 | ...24-325,327-328 
  ...ageFormats.ts |   76.92 |      100 |   33.33 |   76.92 | 46-49,56-57       
  textTokenizer.ts |     100 |      100 |     100 |     100 |                   
  types.ts         |       0 |        0 |       0 |       0 | 1                 
-------------------|---------|----------|---------|---------|-------------------

For detailed HTML reports, please see the 'coverage-reports-22.x-ubuntu-latest' artifact from the main CI run.

@qwen-code-ci-bot

qwen-code-ci-bot commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

Code review of 68fe75d3 (re-run; static review — no PR code executed). Independent proposal, as before: demand-driven growth against a daemon-level pool derived from the memory budget, stateless per-request accounting, per-session hard cap, throttle after refusal, safe degradation, fixed-cap eviction when unpooled, explicit-config-wins. The PR still matches that shape point for point — and the three commits since my last full pass are all review-driven improvements, not new scope.

What landed since the last pass, and my read of it:

  • Per-session baseline accounting — the pool now sees {limitBytes, baselineBytes} per session instead of bare caps, and charges growth beyond each session's OWN baseline. This fixes a real mischarge: bridges sharing one daemon-wide pool could run different baselines, and the old global-baseline sum would bill one bridge's untouched high-baseline sessions as growth on another's. The enumerator, aggregator, policy, and defensive requester-not-in-map path all carry the baseline through consistently.
  • Intermediate-grant walk with rollbackmaybeGrowJournalLimits() no longer refuses a single grant that doesn't yet retain more; it applies grants tentatively, re-asks with the raised caps (each ask is what the policy charges), and walks until retention strictly improves, the advisor refuses, or a 64-step budget runs out. A walk that never improves rolls back to the original caps and counts as a refusal, so the pool is never charged for growth that preserves no replay. The budget only guards a misbehaving advisor — well-behaved doubling reaches the hard cap in ~5 steps. I checked the rollback against the stateless re-sum accounting: intermediate caps vanish with it, nothing leaks.
  • Help figures from constants — the serve help text now derives 256 MiB / 5% / 1024 MB / 1024 MB minimum from the exported constants instead of hard-coding them. Cosmetic, but kills a whole class of doc drift.
  • Round-6 findings — both resolved by the new head:
    • R6-1 (valueless journal flags): fixed with nargs: 1 on both options — a bare --max-journal-events / --max-journal-bytes now fails parsing with "Not enough arguments following…" instead of silently leaving the caps unpinned while the help text claims pinning. 25 new test lines pin the rejection across four bare-flag combinations and confirm the valued forms still parse. This is the minimal strict fix.
    • R6-2 (weak retained-window pin): the mid-restore accounting test now asserts r-2 and r-3 alongside r-4/r-5, so an over-eviction past one extra entry can no longer pass it.

No critical findings this pass; nothing blocking. The one standing nit is unchanged and non-blocking: the PR body is stale in three places (per-bridge pools, the [32, 1024] MB clamp that is actually {0} ∪ [51, 1024] MiB, and /daemon/status surfacing listed as out of scope though implemented). Worth a refresh before merge so the description matches what ships.

sequenceDiagram
    participant P1 as Compaction Engine
    participant P2 as Bridge advisor
    participant P3 as Growth Policy
    participant P4 as Daemon-wide aggregator
    P1->>P2: journal breaches a cap, asks before evicting
    P2->>P4: current caps and baselines of every live session, all bridges
    P2->>P3: grant request with that aggregate
    P3-->>P2: doubled caps within the remaining pool, or refusal
    alt grant improves retention
        P2-->>P1: caps raised in place, no eviction needed
    else grant does not yet improve retention
        P1->>P2: applied tentatively, walk re-asks toward an improving grant
        P2-->>P1: rolled back to original caps and evicted if the walk never improves
    else refusal
        P2-->>P1: oldest-first eviction as before, re-ask throttled 10s
    end
Loading
Files changed (29)
File What changed
packages/acp-bridge/src/journalGrowthPolicy.ts daemon-wide growth accounting — grants doublings while growth beyond each session's own baseline fits the pool, never past the hard cap; safe-integer clamp on proportional entries
packages/acp-bridge/src/journalGrowthPolicy.test.ts pins doubling, partial headroom, refusal, hard cap, per-session baseline accounting, safe-integer clamp
packages/acp-bridge/src/compactionEngine.ts consults the advisor before evicting and walks tentative grants until retention improves, rolling back and counting as refusal otherwise; throttle with monotonic clock; caps persist across turns
packages/acp-bridge/src/compactionEngine.test.ts pins grant, refusal, throw, malformed grant, walk-and-rollback, throttle and turn-boundary behavior
packages/acp-bridge/src/daemon-memory-budget.ts journalGrowthPoolMb — 5% of effective budget, capped at 1024 MB and at post-reserve headroom; 0 disables
packages/acp-bridge/src/daemon-memory-budget.test.ts pins pool derivation, clamps, insufficient-host disable, pinned-flag disable
packages/acp-bridge/src/replayWindowLimits.ts 256 MiB growth hard cap, pool normalizer, and the per-session limit-plus-baseline accounting type
packages/acp-bridge/src/replayWindowLimits.test.ts pins normalizer acceptance and rejection cases
packages/acp-bridge/src/eventBus.ts optional journalLimits on the engine interface; byte-cap accessor for the hot path
packages/acp-bridge/src/bridgeOptions.ts pool, shared session-limits view with baselines, and registrar bridge options
packages/acp-bridge/src/bridgeTypes.ts status carries journalGrowth config and per-session effective caps
packages/acp-bridge/src/bridge.ts wires the advisor — enumerates live caps with baselines including in-flight restores, registers with the daemon aggregator, unregisters on shutdown, reports effective caps in status
packages/acp-bridge/src/bridge.test.ts advisor wiring, restore accounting, degradation, status reporting, and the full retained-window pin
packages/cli/src/serve/run-qwen-serve.ts derives the pool once, builds the single daemon-wide aggregator over limit-plus-baseline providers, forwards both at all three bridge sites
packages/cli/src/serve/run-qwen-serve.test.ts daemon-boot tests — pool reaches every bridge incl. secondary and dynamic workspaces; pinned flags and insufficient host disable growth
packages/cli/src/commands/serve.ts drops the yargs defaults so an unpinned fallback boot keeps growth enabled; nargs: 1 rejects valueless flags; help figures derived from constants
packages/cli/src/commands/serve.test.ts pins unpinned-boot undefined, valueless-flag rejection, and valued parsing
packages/cli/src/serve/daemon-status.ts reports limits.memory.journalGrowth from the bridge snapshot
packages/cli/src/serve/daemon-status.test.ts pins enabled and disabled (null) reporting
packages/cli/src/serve/types.ts documents baseline-vs-pinned growth semantics on ServeOptions
packages/sdk-typescript/src/daemon/types.ts optional status fields for growth config and effective session caps
docs/developers/daemon/17-configuration.md flag table — growth contract, memory-budget consumer
docs/developers/daemon/20-quickstart-operations.md operations doc aligned with the growth contract
docs/developers/qwen-serve-protocol.md SSE replay section notes adaptive growth
docs/users/qwen-serve.md user docs — journal flags and memory-budget entry
…and 4 more test files fixture updates for the new status shape

Testing — the PR's own CI on 68fe75d3 (unattended run; no PR code executed here). Fetched once, no polling: the two primary lanes (Test (ubuntu-latest, Node 22.x) and Serve A/B (ubuntu-latest, Node 22.x)) are still running on this head — the push landed ~20 minutes before this pass. Everything settled so far is green (14 success, 8 skipped-and-gated, 0 failures), including the real-daemon E2E and both Desktop Shell lanes; the finalize job will rewrite the table below when CI lands. The prior head a4d0dabe ran fully green, and the delta since is 31 lines of parser strictness and test pins, so I expect no surprises — but the table says what's verified, not what's expected.

Final CI results for 68fe75d (auto-updated by the triage finalize job after CI completed):

Check Conclusion
Classify PR ✅ success
Desktop Shell (ubuntu-22.04) ✅ success
Desktop Shell (windows-2022) ✅ success
Live Host (macos-latest) ✅ success
macos-latest / Java 21 ✅ success
Post Coverage Comment (ubuntu-latest, 22.x) ✅ success
Real daemon E2E / Java 11 ✅ success
Serve A/B (ubuntu-latest, Node 22.x) ✅ success
Test (ubuntu-latest, Node 22.x) ✅ success
ubuntu-latest / Java 11 ✅ success
ubuntu-latest / Java 17 ✅ success
ubuntu-latest / Java 21 ✅ success
web-shell E2E Smoke (ubuntu-latest, Node 22.x) ✅ success
windows-latest / Java 21 ✅ success

One row per check name (latest run); skipped checks omitted; failures sort first. / 每个检查名一行(取最新一次运行),省略 skipped,失败项排在最前。

Sandboxed verification status: the central claim is behavioural, and it is already substantiated — the earlier /verify run passed 41/41 scripted assertions (verdict: merge-ready) on 9613be1d, including the A/B flood test (base truncates at 10 000 entries, PR retains all 60 000; pool-exhaustion falls back to eviction; unpooled behaviour byte-identical to base) and a mutation matrix that kills the growth, throttle, pool-accounting, and wiring removals. The three commits since are test pins, constant-derived help text, and nargs: 1; a fresh /verify run on the current head is already in flight and its report will post on this thread. Real-scenario tmux capture: N/A on the CI path — this run is unattended; the user-visible surface (mid-turn replay retention) is daemon-internal and exercised by the A/B harness above, and a maintainer can still trigger the isolated @qwen-code /tmux job if desired.

中文说明

68fe75d3 的代码审查(重新运行;静态审查——未执行任何 PR 代码)。独立方案同前:对由内存预算派生的 daemon 级池做按需增长、无状态按请求记账、单会话硬顶、拒绝后节流、安全降级、未配池时固定上限驱逐、显式配置优先。PR 与该形态仍逐点对应——且自上轮完整审查以来的三个提交全部是评审驱动的改进,无新增范围。

上轮之后落地的改动及我的判断:

  • 按会话基线记账——池现在看到每个会话的 {limitBytes, baselineBytes} 而非裸上限,按超出各会话自身基线的部分计费。这修复了一个真实的误计费:共享同一 daemon 级池的 bridge 可能运行不同基线,旧的全局基线求和会把一个 bridge 未增长的高基线会话算成另一个 bridge 的增长。枚举器、聚合器、策略与"请求者不在映射中"的防御路径都一致地携带基线。
  • 带中间授予游走与回滚——maybeGrowJournalLimits() 不再拒绝单次不能多保留的授予;它试探性地应用授予、以上调后的上限重新询问(每次询问即策略计费依据),游走直到保留数严格提升、advisor 拒绝、或 64 步预算耗尽。游走始终未改善则回滚原上限并计为拒绝,池不为零收益增长付费。预算仅防范行为异常的 advisor——正常翻倍约 5 步即达硬顶。我对照无状态重求和记账检查了回滚:中间上限随之消失,无泄漏。
  • 帮助文案取自常量——serve 帮助文本现从导出常量派生 256 MiB / 5% / 1024 MB / 1024 MB 下限,不再硬编码。表面改动,但消灭了整类文档漂移。
  • 第六轮两项发现——均已被新 head 解决:
    • **R6-1(无值 journal 标志):**以 nargs: 1 修复——裸 --max-journal-events / --max-journal-bytes 现在解析失败("Not enough arguments following…"),而不是在帮助文案声称"锁定即禁用增长"的同时静默不锁定。25 行新测试固定四种裸标志组合的拒绝,并确认带值形式仍正常解析。这是最小的严格化修复。
    • **R6-2(保留窗口固定不全):**中途 restore 记账测试现在同时断言 r-2r-3r-4/r-5,多驱逐一个条目的回归不再能通过。

本轮无 critical 发现,无阻塞项。唯一持续的非阻塞卫生问题:PR 正文三处过期(per-bridge 池、实为 {0} ∪ [51, 1024] MiB 的 [32, 1024] MB clamp、已实现却仍标为超出范围的 /daemon/status 呈现)。建议合入前刷新,使描述与交付一致。

测试——68fe75d3 上 PR 自身的 CI(无人值守运行;此处未执行 PR 代码)。一次性拉取、不轮询:两条主通道(Test (ubuntu-latest, Node 22.x)Serve A/B (ubuntu-latest, Node 22.x))在该 head 上仍在运行——推送发生在本次审查前约 20 分钟。目前已落定的全部为绿(14 成功、8 跳过且属门禁性、0 失败),含真 daemon E2E 与两条 Desktop Shell 通道;CI 落定后 finalize 任务会改写上方表格。上一 head a4d0dabe 全绿,且其后增量仅为 31 行解析严格化与测试固定,预期无意外——但表格只写已验证的,不写预期的。

**沙箱验证状态:**核心主张是行为性的,且已被证实——更早的 /verify 运行在 9613be1d41/41 断言通过(判定:可合入),包括 A/B 洪峰测试(base 截断于 10 000 条,PR 保留全部 60 000;池耗尽回落驱逐;未配池行为与 base 逐字节一致)与杀死增长/节流/池记账/装配移除的变异矩阵。其后三个提交为测试固定、常量派生帮助文案与 nargs: 1;针对当前 head 的新一轮 /verify 已在途,报告会发布在本帖。真实场景 tmux 抓取:CI 路径不适用——本次为无人值守运行;用户可见面(中途回放保留)是 daemon 内部行为,已由上述 A/B harness 覆盖,maintainer 仍可触发隔离的 @qwen-code /tmux 任务。

Qwen Code · qwen3.8-max

Reviewed at 68fe75d3f63aca88e9290c7ed0c319252330c73a · re-run with @qwen-code /triage

@qwen-code-ci-bot

qwen-code-ci-bot commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

Confidence: 4/5 — clean across every stage on the current head; both round-6 findings resolved with regression tests; the only open items are the two primary CI lanes still running on 68fe75d3 and the stale PR body.

Stepping back: this PR has converged. The approach still matches my independent proposal point for point, and the review process demonstrably worked — six rounds didn't just patch findings, they improved the design: one daemon-wide pool instead of one per bridge, in-flight restores accounted, zero-benefit grants refused, per-session baselines so mixed-baseline bridges can't mischarge each other, the tentative-grant walk with rollback, and now nargs: 1 so a valueless pin is a loud parse error instead of a silent no-op. The sandboxed /verify run independently settled the central behavioural claim (41/41 assertions: base truncates at 10 000 under flood, head retains everything, unpooled is byte-identical to base, and the mutation matrix kills every removal that would silently disable the feature). If I had to maintain this in six months, the stateless accounting and the degrade-to-eviction contract are exactly the shape I'd want.

The honest reservations, both non-blocking: CI on the newest head hasn't landed yet (unit suite and Serve A/B still in flight; everything settled so far is green, and the prior head ran fully green with only 31 lines of parser strictness and test pins added since), and the PR body remains stale in three places. Neither is a reason to hold.

Housekeeping: the outstanding CHANGES_REQUESTED review on this PR is the /review pipeline's round-6 pass on a4d0dabe. Both findings it carried (valueless-flag semantics, weak retained-window pin) are resolved on the current head with tests, so I'm dismissing it as addressed below.

Approval deferred until CI lands green on 68fe75d3f63aca88e9290c7ed0c319252330c73a — the finalize job will post the commit-pinned approval once every check completes, and withhold it if anything lands red.

中文说明

置信度:4/5 —— 当前 head 每个阶段都干净;第六轮两项发现均已带回归测试解决;唯一未落定的是 68fe75d3 上仍在运行的两条主 CI 通道,以及过期的 PR 正文。

整体看:这个 PR 已经收敛。方案与我独立提出的逐点对应;评审过程也证明其有效——六轮不只是修补发现,而是改进了设计:单一 daemon 级池取代 per-bridge 池、在途 restore 计入记账、零收益授予被拒绝、按会话基线使混合基线的 bridge 互不误计费、带试探性授予游走与回滚、以及现在的 nargs: 1——无值锁定会高声报出解析错误,而不是静默失效。沙箱 /verify 运行独立定论了核心行为主张(41/41 断言:base 在洪峰下截断于 10 000,head 全部保留,未配池与 base 逐字节一致,变异矩阵杀死每一种会静默禁用该特性的移除)。六个月后维护这段代码,无状态记账与"降级即驱逐"的契约正是我想要的形态。

诚实的保留意见(均不阻塞):最新 head 的 CI 尚未落定(单测套件与 Serve A/B 仍在运行;目前已落定的全绿,且上一 head 全绿、其后仅新增 31 行解析严格化与测试固定);PR 正文仍有三处过期。两者都不构成搁置理由。

事务性说明:本 PR 上未决的 CHANGES_REQUESTED 评审来自 /review 流水线对 a4d0dabe 的第六轮审查。其携带的两项发现(无值标志语义、保留窗口固定不全)均已在当前 head 带测试解决,下方将以"已处理"为由撤销。

批准将延后至 CI 在 68fe75d3f63aca88e9290c7ed0c319252330c73a 上全绿后——finalize 任务会在所有检查完成后发布固定在提交上的批准;若有检查变红则不予批准。

Qwen Code · qwen3.8-max

Reviewed at 68fe75d3f63aca88e9290c7ed0c319252330c73a · re-run with @qwen-code /triage

@qwen-code-ci-bot

qwen-code-ci-bot commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

🩺 serve daemon A/B

Built the PR base vs this PR head 68fe75d, drove a fixed endpoint set against each, and diffed the JSON responses. Only fields that changed are shown.

No response changes against the PR base across 4 scenario(s).

Qwen Code · serve A/B

@qwen-code-ci-bot qwen-code-ci-bot left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Not reviewed: reverse audit — stopped at the 5-round cap; round 5 returned no new confirmed findings, but two consecutive dry rounds were never established (rounds 1-4 each reported confirmed findings).

Not explored to full depth (tool budget reached): You are review agent reverse-audit — Reverse audit agen...: none — all checks above completed within budget.; You are review agent reverse-audit — Reverse audit agen...: none — all planned checks completed within budget.; You are review agent reverse-audit — Reverse audit agen...: none — all checks above completed within budget..

中文说明

未审查:reverse audit — stopped at the 5-round cap; round 5 returned no new confirmed findings, but two consecutive dry rounds were never established (rounds 1-4 each reported confirmed findings)。

未探索到全部深度(达到工具调用预算):You are review agent reverse-audit — Reverse audit agen...:none — all checks above completed within budget.;You are review agent reverse-audit — Reverse audit agen...:none — all planned checks completed within budget.;You are review agent reverse-audit — Reverse audit agen...:none — all checks above completed within budget.

— qwen3.8-max via Qwen Code /review (v0.21.9)

Comment thread packages/cli/src/serve/run-qwen-serve.ts Outdated
Comment thread docs/developers/qwen-serve-protocol.md Outdated
Comment thread packages/cli/src/commands/serve.ts Outdated
Comment thread docs/developers/qwen-serve-protocol.md Outdated
Comment thread docs/users/qwen-serve.md Outdated
Comment thread packages/acp-bridge/src/bridge.ts Outdated
Comment thread docs/users/qwen-serve.md Outdated
Comment thread packages/cli/src/serve/run-qwen-serve.ts Outdated
Comment thread packages/cli/src/serve/run-qwen-serve.ts
Comment thread packages/acp-bridge/src/compactionEngine.ts Outdated
@wenshao

wenshao commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator Author

@qwen-code /takeover

@qwen-code-dev-bot

Copy link
Copy Markdown
Collaborator

🤝 Takeover engaged: the autofix loop now manages this PR — it will address new review feedback and resolve base conflicts until the label is removed or the round cap is reached. Remove the autofix/takeover label (or comment @qwen-code /takeover stop) to release.

中文说明

🤝 已接管:autofix 循环现在管理此 PR —— 将持续处理新的评审反馈与 base 冲突,直到移除标签或达到轮次上限。移除 autofix/takeover 标签(或评论 @qwen-code /takeover stop)即可释放。

@qwen-code-dev-bot qwen-code-dev-bot added the autofix/takeover Summon the autofix loop to manage this PR (remove to release; needs triage+) label Aug 11, 2026
@qwen-code-dev-bot

qwen-code-dev-bot commented Aug 12, 2026

Copy link
Copy Markdown
Collaborator

AutoFix round 7 finishedview run. See this round's report below.

中文说明

AutoFix 第 7 轮已完成 —— 查看运行。本轮报告见下方。

@qwen-code-dev-bot

Copy link
Copy Markdown
Collaborator

🤖 Addressed the latest review feedback (round 1/100). What changed, and what I pushed back on: · 已处理最新评审反馈(第 1/100 轮)。改动内容与我反驳保留之处如下:

Review feedback addressed — PR #8905 (round: address-review)

Commit: 804b6c4ba9fix(serve): address adaptive live-journal growth review feedback (#8905) (single additive commit on the PR head branch; no base merge, --conflict false).

All 18 inline findings (1 Critical, 17 Suggestions) were verified against the code and resolved in code. Nothing was declined, deferred, or escalated. The issue-level serve daemon A/B comment is an informational check (no response changes) and needed no action.

Critical

  • [rc:3755587633] Adaptive growth silently disabled on the yargs serve path — FIXED. Verified: serve.ts declared yargs default: values for both journal options and the handler forwarded them unconditionally, so on any boot reaching the yargs fallback handler both values were always defined and the undefined-keyed growth gate never derived a pool. Fix: dropped both yargs defaults (normalizeMaxJournalEvents/normalizeMaxJournalBytes already supply the baselines downstream), widened ServeArgs to optional, and forward conditionally — the same pattern already used for memory-budget-mb. The defaults remain visible in --help via the descriptions. Added three regression tests the finding said were missing: a parse-level test pinning that unpinned argv leaves both keys undefined, a handler-level test asserting runQwenServe receives neither key on an unpinned boot, and a handler-level test asserting pinned values are forwarded.

Suggestions — code behavior

  • [rc:3755587738] Byte-breach growth trigger missing the liveJournal.length > 1 guard — FIXED. The growth trigger now mirrors the eviction loop condition exactly, so a single-entry journal (where eviction cannot drop anything) no longer consults the advisor and permanently charges the shared pool for zero eviction avoidance. Added a short comment stating the invariant.
  • [rc:3755587723] Restore-window pool over-grant — FIXED. During a restore the requesting session's bus exists but its entry is not yet in byId, so allSessionLimitBytes omitted the requester's already-granted growth. The bridge now appends the requester's current caps when it is not registered, matching the JournalGrowthRequest contract ("INCLUDING the requester's").

Suggestions — tests

  • [rc:3755587661] NaN fixture never consumed — FIXED. The refusal test now uses a mutable clock advanced past the re-ask interval between breaches (both fixtures are actually consumed, asserted via empty fixture queue) and replaces NaN with Number.POSITIVE_INFINITY, which passes the > size comparisons so only the Number.isSafeInteger guards can refuse it.
  • [rc:3755587666] maxEvents >= acceptance clause uncovered — FIXED. Added a test whose advisor grows bytes but shrinks the entry cap; the grant is refused, caps stay unchanged, and eviction stamps the marker.
  • [rc:3755587703] No byte-cap-breach growth trigger test — FIXED. Added an engine test with a small maxJournalBytes (300), explicit per-event byte lengths, and a doubling advisor: no marker, both events retained, caps grown to exactly double.
  • [rc:3755587711] Marker never asserted against grown caps — FIXED. Added a grown-then-evicted test: the advisor grants once then refuses, and the marker's maxBytes/maxEvents are asserted equal to the grown caps.
  • [rc:3755587707] Disable test only pinned the byte flag — FIXED. Added the symmetric test pinning only maxJournalEvents and asserting no journalGrowthPoolBytes reaches the bridge.
  • [rc:3755587735] Secondary-workspace pool spread unasserted — FIXED. Added a multi-workspace variant (workspace: [primary, secondary]) asserting ≥2 bridge constructions and journalGrowthPoolBytes on every one of them.
  • [rc:3755587695] Bridge-side growth wiring untested — FIXED. Added two bridge-level tests using the in-memory channel harness: one session breaching its caps grows from the pool instead of truncating (no marker, all events retained), and with a pool equal to the baseline byte cap a second session's growth is refused once the first session's doubling consumes the pool (marker on the second session only). A mutation emptying allSessionLimitBytes fails the second test.

Suggestions — docs, help text, comments

  • [rc:3755587637] Pool misattributed to the --memory-budget-mb flag value — FIXED in the protocol doc: the pool is now documented as 5% of the daemon's effective memory budget (the flag value when passed, otherwise auto-detected, capped at available memory), clamped to [32, 1024] MB. The same misattribution in the --max-journal-bytes row of the user doc was fixed identically.
  • [rc:3755587641] Same misattribution in qwen serve --help — FIXED. The help text now reads "within a growth pool derived from the daemon memory budget (see --memory-budget-mb)".
  • [rc:3755587645] Protocol doc truncation condition too narrow — FIXED. Reworded to "When the journal still exceeds its (possibly grown) caps after the growth the pool allows — including when no headroom is granted or a grant covers only part of the overshoot — …".
  • [rc:3755587657] User doc truncation condition too narrow — FIXED in both rows: the events row now says "if no headroom is granted or the grant does not cover the overshoot", and the bytes row lists refused / pool exhausted / partial grant.
  • [rc:3755587717] Retired "observation only" contract still stated in three sibling locations — FIXED. Both developer-docs tables (17-configuration.md, 20-quickstart-operations.md) and the --memory-budget-mb help text now name adaptive live-journal growth as the consumer; the quickstart row's "Required when" column is no longer "Observation only".
  • [rc:3755587726] "daemon-wide pool" in the user doc — FIXED. Now documents a per-bridge pool (one per workspace bridge). The same stale "daemon-wide" wording in this PR's own comments/docstrings was aligned too: run-qwen-serve.ts, daemon-memory-budget.ts, journalGrowthPolicy.ts, eventBus.ts, bridge.ts.
  • [rc:3755587730] Same "daemon-wide" wording in the run-qwen-serve.ts comment — FIXED ("per-bridge pool (derived once from the daemon memory budget and handed to each bridge)").
  • [rc:3755587669] Comment arithmetic error — FIXED. 327 680 → 320 000 in journalGrowthPolicy.ts, matching the policy's own hard-cap tests.

Conflict notes

None — --conflict false; no base merge performed.

Verification

Commands actually run (all on the final committed tree unless noted):

  • npm run build — passed (exit 0; full workspace build)
  • npm run typecheck — passed (exit 0; run twice, before and after the final test additions)
  • npm run lint — passed (exit 0; run twice)
  • npx prettier --check on the four changed docs — clean after --write normalized table alignment
  • cd packages/acp-bridge && npx vitest run — 27 files, 1226 passed (includes the new engine, policy, and bridge growth tests)
  • cd packages/cli && npx vitest run src/serve/run-qwen-serve.test.ts src/serve/fast-path.test.ts333 passed
  • cd packages/cli && npx vitest run src/commands/serve.test.ts58 passed (includes the three new yargs-path regression tests; exercises the real yargs parser and handler)
  • cd packages/cli && npx vitest run src/serve — 147 files, 4277 passed, 1 pre-existing skip
  • Final combined run cd packages/cli && npx vitest run src/serve src/commands/serve.test.ts — 148 files, 4335 passed, 1 pre-existing skip

Integration tests after npm run bundle were not run: the touched behavior is exercised by the unit/integration harnesses above (the yargs fallback path is driven through the real parser and handler in commands/serve.test.ts, and the bridge wiring through the in-memory channel harness), not only through the bundled CLI.

中文说明

已处理的评审反馈 — PR #8905(轮次:address-review)

提交:804b6c4ba9fix(serve): address adaptive live-journal growth review feedback (#8905)(在 PR head 分支上的单个追加提交;--conflict false,未合并 base)。

全部 18 条 inline 发现(1 条 Critical、17 条 Suggestion)均已对照代码核实并在代码中解决。没有拒绝、推迟或升级任何条目。issue 级评论 serve daemon A/B 是信息性检查(响应无变化),无需处理。

Critical

  • [rc:3755587633] yargs serve 路径静默禁用自适应增长 — 已修复。 核实:serve.ts 为两个 journal 选项声明了 yargs default: 值,且 handler 无条件转发,因此凡是走 yargs 回落 handler 启动的 daemon,两个值恒有定义,以 undefined 为键的增长 gate 永远不会派生池。修复:移除两个 yargs 默认值(下游 normalizeMaxJournalEvents/normalizeMaxJournalBytes 已提供基线),将 ServeArgs 放宽为可选,并改为条件转发——与 memory-budget-mb 已采用的模式一致。默认值仍通过描述文本在 --help 中可见。新增了发现中指出缺失的三个回归测试:parse 级测试钉死未钉 flag 时 argv 中两个键均为 undefined;handler 级测试断言未钉启动时 runQwenServe 不会收到这两个键;handler 级测试断言钉住的值会被转发。

Suggestion — 代码行为

  • [rc:3755587738] 字节越限增长触发缺少 liveJournal.length > 1 守卫 — 已修复。 增长触发条件现在与驱逐循环条件完全一致,因此单条目 journal(驱逐不可能丢弃任何条目)不再咨询 advisor,也不会为零的驱逐避免而永久记账共享池。附了一句简短注释说明该不变量。
  • [rc:3755587723] 恢复窗口内的池超额授予 — 已修复。 restore 期间请求方会话的 bus 已存在但其 entry 尚未进入 byId,导致 allSessionLimitBytes 漏掉请求方已获授的增长。bridge 现在在请求方未注册时补上其当前上限,符合 JournalGrowthRequest 契约("INCLUDING the requester's")。

Suggestion — 测试

  • [rc:3755587661] NaN 用例从未被消费 — 已修复。 拒绝测试改用可变时钟,并在两次越限之间推进到超过 re-ask 间隔(两个用例确实都被消费,以队列清空断言),同时把 NaN 换成 Number.POSITIVE_INFINITY——它能通过 > 比较,只有 Number.isSafeInteger 守卫能拒绝它。
  • [rc:3755587666] maxEvents >= 接受子句无覆盖 — 已修复。 新增测试:advisor 增大字节上限但缩小条目上限,授权被拒绝、上限不变、驱逐打上标记。
  • [rc:3755587703] 缺少字节上限越限触发增长的测试 — 已修复。 新增 engine 测试:小 maxJournalBytes(300)、显式每事件字节长度、翻倍 advisor;无标记、两个事件都保留、上限恰好翻倍。
  • [rc:3755587711] 标记从未按增长后上限断言 — 已修复。 新增"先增长后驱逐"测试:advisor 先授权一次然后拒绝,断言标记的 maxBytes/maxEvents 等于增长后的上限。
  • [rc:3755587707] 禁用测试只钉了字节 flag — 已修复。 新增对称测试:只钉 maxJournalEvents,断言 bridge 收不到 journalGrowthPoolBytes
  • [rc:3755587735] secondary-workspace 池 spread 无断言 — 已修复。 新增多 workspace 变体(workspace: [primary, secondary]),断言至少 2 次 bridge 构造且每次都带 journalGrowthPoolBytes
  • [rc:3755587695] bridge 侧增长装配无测试 — 已修复。 使用 in-memory channel 测试台新增两个 bridge 级测试:一个会话越限时从池增长而非截断(无标记、事件全保留);池等于基线上限字节数时,第一个会话的首次翻倍耗尽池后,第二个会话的增长被拒绝(只有第二个会话出现标记)。把 allSessionLimitBytes 突变为空数组会使第二个测试失败。

Suggestion — 文档、帮助文本、注释

  • [rc:3755587637] 池被误归因于 --memory-budget-mb flag 值 — 已修复(协议文档):现在写明池为 daemon 有效内存预算的 5%(传 flag 时用该值,否则自动探测,且以可用内存为上限),clamp 到 [32, 1024] MB。用户文档 --max-journal-bytes 行的同类误归因也一并修复。
  • [rc:3755587641] qwen serve --help 中的同类误归因 — 已修复。 帮助文本改为 "within a growth pool derived from the daemon memory budget (see --memory-budget-mb)"。
  • [rc:3755587645] 协议文档截断条件过窄 — 已修复。 改为 "When the journal still exceeds its (possibly grown) caps after the growth the pool allows — including when no headroom is granted or a grant covers only part of the overshoot — …"。
  • [rc:3755587657] 用户文档截断条件过窄 — 已修复(两行):events 行改为 "if no headroom is granted or the grant does not cover the overshoot";bytes 行列出 refused / pool exhausted / 部分授权三种情形。
  • [rc:3755587717] 三处仍保留已作废的 "observation only" 契约 — 已修复。 两个开发者文档表格(17-configuration.md20-quickstart-operations.md)与 --memory-budget-mb 帮助文本均写明自适应增长这一消费者;quickstart 表中该行的 "Required when" 列不再是 "Observation only"。
  • [rc:3755587726] 用户文档中的 "daemon-wide pool" — 已修复。 现改为每 bridge 一份池(每个 workspace bridge 一份)。本 PR 自身注释/docstring 中同样的 "daemon-wide" 过时措辞也一并对齐:run-qwen-serve.tsdaemon-memory-budget.tsjournalGrowthPolicy.tseventBus.tsbridge.ts
  • [rc:3755587730] run-qwen-serve.ts 注释中同样的 "daemon-wide" 措辞 — 已修复("per-bridge pool (derived once from the daemon memory budget and handed to each bridge)")。
  • [rc:3755587669] 注释算术错误 — 已修复。 journalGrowthPolicy.ts 中 327 680 → 320 000,与 policy 自身的硬顶测试一致。

冲突说明

无 — --conflict false,未执行 base 合并。

验证

实际执行的命令(除注明外在最终提交的代码树上运行):

  • npm run build — 通过(exit 0;全 workspace 构建)
  • npm run typecheck — 通过(exit 0;运行两次,分别在最后一次新增测试前后)
  • npm run lint — 通过(exit 0;运行两次)
  • 对 4 个改动的文档执行 npx prettier --check — 经 --write 规范化表格对齐后干净
  • cd packages/acp-bridge && npx vitest run — 27 个文件,1226 通过(含新增的 engine、policy、bridge 增长测试)
  • cd packages/cli && npx vitest run src/serve/run-qwen-serve.test.ts src/serve/fast-path.test.ts333 通过
  • cd packages/cli && npx vitest run src/commands/serve.test.ts58 通过(含三个新增 yargs 路径回归测试;使用真实 yargs parser 与 handler)
  • cd packages/cli && npx vitest run src/serve — 147 个文件,4277 通过,1 个既有 skip
  • 最终合并运行 cd packages/cli && npx vitest run src/serve src/commands/serve.test.ts — 148 个文件,4335 通过,1 个既有 skip

未运行 npm run bundle 后的集成测试:上述单元/集成测试台已覆盖所改行为(yargs 回落路径由 commands/serve.test.ts 通过真实 parser 与 handler 驱动,bridge 装配由 in-memory channel 测试台驱动),该行为并非只能靠打包后的 CLI 验证。

Base-conflict check · 基分支冲突检查: no conflict with main. · 与 main 无冲突。

Re-review when you have a moment. After round 100 this bot stops and leaves the PR for a human. · 有空请复审;第 100 轮后本 bot 停止并将 PR 交给人工。


🧠 Handled by Qwen Code · model/模型 qwen3.8-max

@qwen-code-ci-bot qwen-code-ci-bot left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Not reviewed: build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally.

Not reviewed: reverse audit — stopped at the 5-round cap without two consecutive dry rounds (rounds 1-5 each reported findings); the cap-round finding was verified separately.

Not explored to full depth (tool budget reached): chunk 8: executing the four new tests via npx vitest run — blocked by missing node_modules in the review worktree (startup error ERR_MODULE_NOT_FOUND for vitest )…; You are review agent reverse-audit — Reverse audit agen...: none — all checks above completed (~12 of ~46 tool calls used).; You are review agent reverse-audit — Reverse audit agen...: none — all checks above completed within budget.; chunk 5: running the new tests ( npx vitest run src/compactionEngine.test.ts -t 'adaptive live-journal growth' ) — the worktree has no node_modules and a full monorepo i….

Test Plan (not a blocker): 1221 tests pass — this review observed 1226, 18910, 1502, 481, 3069, 473 passed.

中文说明

未审查:build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally。

未审查:reverse audit — stopped at the 5-round cap without two consecutive dry rounds (rounds 1-5 each reported findings); the cap-round finding was verified separately。

未探索到全部深度(达到工具调用预算):chunk 8:executing the four new tests via npx vitest run — blocked by missing node_modules in the review worktree (startup error ERR_MODULE_NOT_FOUND for vitest )…;You are review agent reverse-audit — Reverse audit agen...:none — all checks above completed (~12 of ~46 tool calls used).;You are review agent reverse-audit — Reverse audit agen...:none — all checks above completed within budget.;chunk 5:running the new tests ( npx vitest run src/compactionEngine.test.ts -t 'adaptive live-journal growth' ) — the worktree has no node_modules and a full monorepo i…

Test Plan(非阻断):1221 tests pass — this review observed 1226, 18910, 1502, 481, 3069, 473 passed

— qwen3.8-max via Qwen Code /review (v0.21.10)

Comment thread packages/acp-bridge/src/bridge.ts Outdated
Comment thread packages/acp-bridge/src/compactionEngine.ts Outdated
Comment thread docs/developers/daemon/17-configuration.md Outdated
Comment thread docs/developers/daemon/20-quickstart-operations.md Outdated
Comment thread packages/cli/src/serve/run-qwen-serve.ts
Comment thread docs/users/qwen-serve.md Outdated
Comment thread packages/acp-bridge/src/journalGrowthPolicy.test.ts
Comment thread packages/acp-bridge/src/compactionEngine.test.ts
Comment thread packages/acp-bridge/src/journalGrowthPolicy.test.ts
Comment thread packages/acp-bridge/src/compactionEngine.test.ts
@wenshao

wenshao commented Aug 12, 2026

Copy link
Copy Markdown
Collaborator Author

@qwen-code /resolve

…rnal-growth

# Conflicts:
#	docs/developers/daemon/17-configuration.md
)

Concurrent restores hold their buses in pendingRestoreEvents rather than
byId, so each advisor ask only saw its own caps and concurrent restores
could each draw a full doubling from the same pool. Sum the current caps
of every in-flight restore bus into allSessionLimitBytes.

Also skip the growth ask when the breaching append is a turn boundary —
compactCurrentTurn discards the journal immediately afterwards, so the
grant would be charged to the pool while buying zero eviction.

Pin the previously untested contracts with tests: restore-window
accounting, concurrent-restore accounting, headroom release on session
close, the hard-cap clamp term, partial-grant eviction, requester
discrimination in the policy fixtures, the maxEvents safe-integer
conjunct, and the dynamic-workspace bridge pool wiring. Fix the docs:
add the missing journal-flag rows to the daemon configuration and
operations pages, and correct the effective-budget definition.
@qwen-code-dev-bot

Copy link
Copy Markdown
Collaborator

Qwen Code did not run conflict resolution for this request.

PR #8905 does not currently have merge conflicts with main.

…8905)

The merge of main pulled in #8933, which gates historyPageSize on
historyReplay === 'response'. The 'transport failure marks the channel
dying before process exit' test (from #8947) passes historyPageSize with
the default stream replay, so the paged transcript fetch it waits on is
never issued and the test times out — a cross-PR interaction between two
main commits, failing deterministically on main. Pin the response replay
mode the paged fetch requires.
@qwen-code-dev-bot

Copy link
Copy Markdown
Collaborator

🤖 Reviewed the latest feedback — no changes needed. Why, point by point: · 已审阅最新反馈——无需改动。逐点说明原因如下:

Autofix round: no code changes needed — every actionable finding in this round's feedback was already fixed at HEAD (d08466b, 193b70ce), and each fix was re-verified this round by code inspection plus running the tests that pin it.

Round-2 review findings — all resolved in code at HEAD

  • rc:3763421673 (Critical) concurrent in-flight restores over-grant the pool — fixed: the advisor now sums the current caps of other in-flight restore buses held in pendingRestoreEvents into allSessionLimitBytes; pinned by accounts concurrent in-flight restores against the shared pool (bridge.test.ts), which passes.
  • rc:3763421676 growth ask fired on turn_complete/turn_error boundary appends — fixed: the growth hook skips TURN_BOUNDARY_TYPES appends since compactCurrentTurn() discards the journal immediately after; pinned by does not ask for growth when the breaching append is a turn boundary, which passes.
  • rc:3763421677 / rc:3763421679 dangling (see --max-journal-bytes) pointers — fixed: both daemon docs pages (17-configuration.md, 20-quickstart-operations.md) now carry --max-journal-events / --max-journal-bytes rows with defaults, baseline-vs-hard-cap semantics, and the pinning-disables-growth note.
  • rc:3763421680 dynamic-workspace bridge pool wiring untested — fixed: the dynamic-registration test asserts createBridge.mock.calls[1]?.[0].journalGrowthPoolBytes parity with the boot bridge; passes.
  • rc:3763421683 restore-window accounting branch untested — fixed: charges a mid-restore session for growth granted before registration breaches twice during a gated restore and asserts the second ask is refused; passes.
  • rc:3763421686 headroom release on session close untested — fixed: returns granted headroom to the pool when the grown session is closed passes.
  • rc:3763421687 / rc:3763421690 wrong "effective memory budget" parenthetical — fixed in both docs/users/qwen-serve.md and docs/developers/qwen-serve-protocol.md: the flag value capped at resolved available memory when passed, otherwise 50% of auto-detected memory.
  • rc:3763421691 stale "separately capped" row — fixed: the row now says baseline caps that adaptive growth can raise.
  • rc:3763421694 hard-cap clamp term unpinned — fixed: clamps a partial grant to the hard cap when doubling overshoots it (192 MiB current, 512 MiB pool → exactly 256 MiB / 320 000); passes.
  • rc:3763421698 partial-grant eviction unpinned — fixed: evicts down to the raised cap when a partial grant does not resolve the breach; passes.
  • rc:3763421701 requester-inclusion contract undiscriminating — fixed: fixture now pool 20 MiB / current 16 MiB → expects {28 MiB, 35 000}, which fails if the requester is filtered out; passes.
  • rc:3763421704 maxEvents safe-integer conjunct unpinned — fixed: third malformed fixture { maxEvents: Number.POSITIVE_INFINITY, maxBytes: 16 MiB }; passes.

Failed check: ubuntu-latest / Java 11 (SDK Java workflow, test matrix job)

Diagnosed from evidence; not reproducible on this runner (no Java/Maven installed), and the evidence shows this PR's diff cannot be the cause:

  • The PR diff touches no input of that job: no packages/sdk-java/**, no package.json / package-lock.json, no packages/cli/src/acp-integration/**, no workflow files (verified with git diff origin/main...HEAD --name-only). The workflow triggers on packages/acp-bridge/** and packages/cli/src/serve/**, but the test job compiles and runs only the Java SDK's own sources.
  • The Java unit tests are purely client-side: no process spawning, no test resources/fixtures, and the only daemon-touching class (DaemonServeE2ETest) is disabled unless QWEN_DAEMON_E2E_BASE_URL is set, which the test job does not set.
  • There is therefore no code path through which this diff changes the mvn clean test outcome, and no code-level hypothesis to implement. The failure sits in job setup on the self-hosted runner (workspace ownership / checkout / head-SHA verification steps) or Maven infrastructure. The workflow's independent CI remains the final gate; a re-run at the same head should confirm.

Review-body note: integration tests skipped in CI

Integration Tests (CLI, No Sandbox) is gated on github.event_name == 'merge_group' in ci.yml — it never runs on PR pushes by design, only in the merge queue. The behaviors this PR changes are covered by the focused suites run locally this round (see below).

Verification

Commands actually run this round at HEAD (193b70ce52):

  • npm run build — passed (the checkout's dist/ was stale relative to HEAD; rebuilt before the CLI focused tests — CI builds clean, so this is local-only)
  • npm run typecheck — passed
  • npm run lint — passed
  • npx vitest run src/journalGrowthPolicy.test.ts src/compactionEngine.test.ts (packages/acp-bridge) — 125 passed (8 + 117)
  • npx vitest run src/bridge.test.ts (packages/acp-bridge) — 573 passed
  • npx vitest run src/serve/run-qwen-serve.test.ts src/commands/serve.test.ts (packages/cli) — 310 passed
  • ubuntu-latest / Java 11 SDK Java check — unavailable locally (no Java/Maven); evidence-based diagnosis above, no code-level fix applies
  • Integration Tests (CLI, No Sandbox) — merge-queue-only by design, not applicable on a PR push
中文说明

Autofix 本轮:无需代码改动 —— 本轮反馈中所有可处理的发现均已在 HEAD(d08466b193b70ce)修复,且本轮逐条通过代码检查加运行钉死对应行为的测试重新验证。

第 2 轮审查发现 —— 均已在 HEAD 的代码中解决

  • rc:3763421673(Critical) 并发 in-flight restore 超额授予增长池 —— 已修复:advisor 现在把 pendingRestoreEvents 中其他处于 restore 中的 bus 的当前 cap 计入 allSessionLimitBytes;由 accounts concurrent in-flight restores against the shared pool(bridge.test.ts)钉死,测试通过。
  • rc:3763421676 增长询问在 turn_complete/turn_error 边界 append 上触发 —— 已修复:由于 compactCurrentTurn() 随后立即丢弃 journal,增长钩子现在跳过 TURN_BOUNDARY_TYPES 的 append;由 does not ask for growth when the breaching append is a turn boundary 钉死,测试通过。
  • rc:3763421677 / rc:3763421679 悬空的 (see --max-journal-bytes) 指针 —— 已修复:两个 daemon 文档页(17-configuration.md20-quickstart-operations.md)均已补上 --max-journal-events / --max-journal-bytes 行,含默认值、基线 vs 硬顶语义、钉住即禁用增长的说明。
  • rc:3763421680 动态 workspace bridge 的池接线无测试 —— 已修复:动态注册测试断言 createBridge.mock.calls[1]?.[0].journalGrowthPoolBytes 与启动 bridge 一致;通过。
  • rc:3763421683 restore 窗口记账分支无测试 —— 已修复:charges a mid-restore session for growth granted before registration 在门控 restore 期间越限两次,断言第二次询问被拒绝;通过。
  • rc:3763421686 会话关闭释放额度的契约无测试 —— 已修复:returns granted headroom to the pool when the grown session is closed 通过。
  • rc:3763421687 / rc:3763421690 错误的"有效内存预算"括注 —— 已在 docs/users/qwen-serve.mddocs/developers/qwen-serve-protocol.md 两处修复:传 flag 时取该值(以解析出的可用内存为上限),否则为自动探测内存的 50%。
  • rc:3763421691 过时的"separately capped"行 —— 已修复:该行现说明这是自适应增长可提高的基线上限。
  • rc:3763421694 硬顶 clamp 项无测试钉死 —— 已修复:clamps a partial grant to the hard cap when doubling overshoots it(当前 192 MiB、池 512 MiB → 恰好 256 MiB / 320 000);通过。
  • rc:3763421698 部分授予后的驱逐无测试钉死 —— 已修复:evicts down to the raised cap when a partial grant does not resolve the breach;通过。
  • rc:3763421701 "含请求方自身 cap"契约无法判别 —— 已修复:用例改为池 20 MiB / 当前 16 MiB → 期望 {28 MiB, 35 000},若把请求方过滤掉则测试失败;通过。
  • rc:3763421704 maxEvents 安全整数条件无测试钉死 —— 已修复:新增第三个畸形用例 { maxEvents: Number.POSITIVE_INFINITY, maxBytes: 16 MiB };通过。

失败检查:ubuntu-latest / Java 11(SDK Java workflow 的 test 矩阵 job)

基于证据诊断;本 runner 无法复现(未安装 Java/Maven),且证据表明本 PR 的 diff 不可能是原因:

  • 本 PR 的 diff 未触及该 job 的任何输入:没有 packages/sdk-java/**、没有 package.json / package-lock.json、没有 packages/cli/src/acp-integration/**、没有 workflow 文件(已用 git diff origin/main...HEAD --name-only 验证)。workflow 因 packages/acp-bridge/**packages/cli/src/serve/** 触发,但 test job 只编译并运行 Java SDK 自身的源码。
  • Java 单元测试是纯客户端的:不起任何进程、没有测试资源/fixture,唯一接触 daemon 的类(DaemonServeE2ETest)在未设置 QWEN_DAEMON_E2E_BASE_URL 时禁用,而 test job 不设置该变量。
  • 因此本 diff 不存在任何能改变 mvn clean test 结果的代码路径,也没有可实施的代码层面假设。失败位于自托管 runner 的 job 准备步骤(workspace 所有权 / checkout / head SHA 校验)或 Maven 基础设施。workflow 的独立 CI 仍是最终验证门槛;在同一 head 上重跑应可确认。

审查正文备注:CI 中跳过集成测试

Integration Tests (CLI, No Sandbox)ci.yml 中以 github.event_name == 'merge_group' 为条件 —— 按设计从不在 PR push 上运行,只在合并队列中运行。本 PR 改动的行为由本轮本地运行的聚焦测试套件覆盖(见下文)。

验证

本轮在 HEAD(193b70ce52)实际运行的命令:

  • npm run build —— 通过(检出目录的 dist/ 相对 HEAD 已过期,在跑 CLI 聚焦测试前重新构建 —— CI 是干净构建,故此问题仅限本地)
  • npm run typecheck —— 通过
  • npm run lint —— 通过
  • npx vitest run src/journalGrowthPolicy.test.ts src/compactionEngine.test.ts(packages/acp-bridge)—— 125 通过(8 + 117)
  • npx vitest run src/bridge.test.ts(packages/acp-bridge)—— 573 通过
  • npx vitest run src/serve/run-qwen-serve.test.ts src/commands/serve.test.ts(packages/cli)—— 310 通过
  • ubuntu-latest / Java 11 SDK Java 检查 —— 本地不可用(无 Java/Maven);基于证据的诊断见上,无适用的代码层面修复
  • Integration Tests (CLI, No Sandbox) —— 按设计仅合并队列运行,PR push 不适用

Base-conflict check · 基分支冲突检查: no conflict with main. · 与 main 无冲突。


🧠 Handled by Qwen Code · model/模型 qwen3.8-max

@wenshao

wenshao commented Aug 12, 2026

Copy link
Copy Markdown
Collaborator Author

@qwen-code /resolve

@qwen-code-dev-bot

Copy link
Copy Markdown
Collaborator

Qwen Code resolved the merge conflicts and pushed the branch update.

Merge resolution: PR #8905 ← origin/main

Root cause

Main merged ec3b2cbb66 (#8984), which added historyReplay: 'response' to the
transport failure marks the channel dying before process exit test in
packages/acp-bridge/src/bridge.test.ts. This PR's own final commit 193b70ce52
made the same one-line addition to the same loadSession call. Both fixes
were needed because 962dc8eadc (#8933, already on main) made historyPageSize
effective only in response-mode replay — without historyReplay: 'response' the
request silently degrades to 'stream', no transcript page is requested, and the
vi.waitFor in that test times out. Git aligned the common historyReplay line
and flagged the comment main added above it as the only conflict.

Textual or semantic

Neither logic collided — the two sides were functionally identical. The HEAD
side of the single conflict hunk was empty; origin/main's side contributed only a
5-line explanatory comment. The resolved block (comment adopted verbatim):

const replayAttach = bridge.loadSession({
  sessionId: first.sessionId,
  workspaceCwd: WS_A,
  // historyPageSize only takes effect in response-mode replay (#8933);
  // without historyReplay the request silently degrades to 'stream',
  // no transcript page is ever requested, and the waitFor below times
  // out. This test predates that gating (logical merge conflict — both
  // PRs were green on their own branches).
  historyReplay: 'response',
  historyPageSize: 10,
  clientId: 'rejected-load-client',
});

Verified: the resolved test now matches origin/main's copy byte-for-byte, and the
merged file's diff vs main equals the PR's intended diff minus the deduplicated
historyReplay line. All other files auto-merged.

What is load-bearing

The comment documents the invariant: historyReplay: 'response' must stay paired
with historyPageSize: 10 in this loadSession call. Removing historyReplay
makes the test hang (waitFor timeout), not fail fast — the silent degradation
#8933 introduced.

Not verified here

No build/tests run per instructions. Note for CI: the merged tree now contains
both #8933's restore-request-shape gating and this PR's journal-growth changes in
bridge.ts (auto-merged, no conflict); the transport-failure test exercises both
paths together, which never ran on either branch in combination.

中文说明

根因:main 合入了 ec3b2cbb66#8984),在 bridge.test.ts
transport-failure 测试里给 loadSession 加了 historyReplay: 'response'
本 PR 的最后一个提交 193b70ce52 对同一调用做了完全相同的修改。两者都是
因为 #8933962dc8eadc)把 historyPageSize 限定为仅在 response 模式回放时
生效——缺了 historyReplay 请求会静默降级为 'stream',测试里的 vi.waitFor
就会超时。Git 对齐了双方共有的 historyReplay 行,只把 main 新增的注释标记为
冲突。

文本还是语义:两边功能完全一致,无逻辑碰撞。冲突中 HEAD 一侧为空,
origin/main 一侧仅多出 5 行解释性注释,已原样保留(见上方代码块)。已验证:
解决后的测试与 origin/main 逐字节一致;合并文件相对 main 的差异等于 PR 原本
的差异去掉去重后的 historyReplay 行。其余文件全部自动合并。

关键约束:该测试中 historyReplay: 'response' 必须与 historyPageSize: 10
成对保留;删掉 historyReplay 会导致测试挂起(waitFor 超时)而非快速失败。

未验证:按指令未运行构建/测试。提醒 CI:合并后的树同时包含 #8933
restore 请求形状门控与本 PR 的 journal 增长逻辑(bridge.ts 自动合并无冲突),
transport-failure 测试会同时走到这两条路径,而任一分支上均未做过该组合的运行。

@doudouOUC doudouOUC left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

⚠️ Downgraded from Approve to Comment: CI failing: review-pr; PR head advanced during review: reviewed 193b70c, PR is now at b93cbaf (+6 unreviewed commit(s) touching 24 file(s)). Reviewed.

Not explored to full depth (tool budget reached): You are review agent reverse-audit — Reverse audit agen...: none** — all planned checks completed within the tool budget..

Test Plan (not a blocker): 1221 tests pass — this review observed 1309, 1510, 499, 3277, 523 passed.

中文说明

⚠️ 已从批准降级为评论:CI failing: review-pr; PR head advanced during review: reviewed 193b70c, PR is now at b93cbaf (+6 unreviewed commit(s) touching 24 file(s))。 已审查。

未探索到全部深度(达到工具调用预算):You are review agent reverse-audit — Reverse audit agen...:none** — all planned checks completed within the tool budget.

Test Plan(非阻断):1221 tests pass — this review observed 1309, 1510, 499, 3277, 523 passed

— deepseek-v4-flash via Qwen Code /review (v0.21.10)

@qwen-code-dev-bot

Copy link
Copy Markdown
Collaborator

🔀 Base updated: red check(s) [Test (ubuntu-latest, Node 22.x)] pass on current main — merged current main via update-branch; CI will re-run.

中文说明

🔀 已更新 base:红色检查 [Test (ubuntu-latest, Node 22.x)] 在当前 main 上通过 —— 已通过 update-branch 合入当前 main,CI 将重新运行。

@wenshao wenshao left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

⚠️ Downgraded from Request changes to Comment: self-PR; CI failing: review-pr; PR head advanced during review: reviewed 193b70c, PR is now at 0c0c221 (+8 unreviewed commit(s) touching 25 file(s)). Reviewed. Suggestions are inline.

Not reviewed: reverse audit — stopped at the 5-round cap without global two-consecutive-dry convergence.

Test Plan (not a blocker): 1221 tests pass — this review observed 1309, 1510, 499, 3277 passed.

中文说明

⚠️ 已从请求修改降级为评论:self-PR; CI failing: review-pr; PR head advanced during review: reviewed 193b70c, PR is now at 0c0c221 (+8 unreviewed commit(s) touching 25 file(s))。 已审查。 建议见行内评论。

未审查:reverse audit — stopped at the 5-round cap without global two-consecutive-dry convergence。

Test Plan(非阻断):1221 tests pass — this review observed 1309, 1510, 499, 3277 passed

— qwen3.7-max via Qwen Code /review (v0.21.10)

Comment on lines +2561 to +2563
const journalGrowthPoolBytes =
opts.maxJournalEvents === undefined &&
opts.maxJournalBytes === undefined &&

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

[Critical] Make the growth pool daemon-scoped rather than allocating the full value to every bridge. Each startup or dynamic workspace receives this same 5% pool, and the 32 MiB floor remains active even when the resolved budget has no usable headroom. Concurrent large turns across workspaces can therefore retain more journal memory than the configured daemon budget permits and drive the process into memory pressure/OOM. Please share one allocator across bridges (or partition one aggregate pool), and disable/bound growth when the budget resolution reports insufficient memory or no post-reserve headroom.

中文翻译

[严重] 请将增长池改为 daemon 级共享,而不是给每个 bridge 分配完整额度。当前每个启动或动态 workspace 都得到同一个 5% 池,并且即使解析后的预算没有可用余量,32 MiB 下限仍会生效。多个 workspace 同时出现大 turn 时,保留的 journal 内存可能超过 daemon 配置预算并导致内存压力或 OOM。建议所有 bridge 共享一个分配器(或切分一个总池),且当预算解析报告内存不足或预留后无余量时禁用或限制增长。

— qwen3.7-max via Qwen Code /review (v0.21.10)

Comment on lines +515 to +517
if (
this.journalGrowthDeniedAt !== undefined &&
now - this.journalGrowthDeniedAt < JOURNAL_GROWTH_REASK_INTERVAL_MS

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

[Critical] Use a monotonic clock for the refusal throttle. now defaults to Date.now(), so after a denied grant an NTP/manual backward correction makes this difference negative and suppresses advisor calls until wall time catches up. During that interval the engine evicts replay history even if pool headroom has become available. Please use an injectable monotonic elapsed-time source such as performance.now() and cover a backward wall-clock correction.

中文翻译

[严重] 拒绝后的节流应使用单调时钟。now 默认来自 Date.now(),因此一次拒绝后若 NTP 或人工将系统时间向后校正,该差值会变成负数,直到墙上时间追上前都不会再次调用 advisor。在此期间,即使增长池已有余量,引擎仍会淘汰 replay 历史。请使用可注入的单调耗时源(如 performance.now()),并覆盖系统时间回拨的测试。

— qwen3.7-max via Qwen Code /review (v0.21.10)

Comment on lines +2561 to +2563
const journalGrowthPoolBytes =
opts.maxJournalEvents === undefined &&
opts.maxJournalBytes === undefined &&

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

[Critical] Update /daemon/status for the new ownership and semantics. Once this pool is active, limits.memory.enforced: false no longer accurately describes the memory budget as wholly observational, while bridge status still publishes the closed-over 10,000/8 MiB baselines as maxJournalEvents/maxJournalBytes after sessions can grow beyond them. Operators and SDK clients will underestimate retained memory and misdiagnose whether --memory-budget-mb has runtime effect. Please expose the baseline, adaptive-growth enablement, aggregate pool ownership/size, hard cap, and effective/current session limits, and scope enforced: false specifically to the child-heap model.

中文翻译

[严重] 请同步更新 /daemon/status 的所有权与语义。启用该池后,limits.memory.enforced: false 已不能准确表示内存预算完全只是观测值;同时 bridge 状态仍把闭包中的 10,000/8 MiB 基线作为 maxJournalEvents/maxJournalBytes 返回,即使 session 已能增长到更高。运维人员和 SDK 客户端会低估保留内存,并错误判断 --memory-budget-mb 是否产生运行时效果。请暴露基线、自适应增长开关、总池所有权/大小、硬上限及 session 当前有效上限,并将 enforced: false 明确限定为 child-heap 模型。

— qwen3.7-max via Qwen Code /review (v0.21.10)

Comment on lines +66 to +68
const hardCapEvents = Math.max(
opts.baselineEvents,
Math.ceil((opts.hardCapBytes / opts.baselineBytes) * opts.baselineEvents),

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

[Critical] Clamp the proportional event hard cap to Number.MAX_SAFE_INTEGER. baselineEvents and the other inputs may each be valid safe integers, but their product/ratio can exceed the safe range here. The policy then returns an unsafe maxEvents, which the engine rejects together with an otherwise useful byte grant, causing truncation despite available headroom. Add a regression case with a large valid baseline.

中文翻译

[严重] 请将按比例计算的事件硬上限限制在 Number.MAX_SAFE_INTEGERbaselineEvents 及其他输入单独都可能是合法安全整数,但这里的乘除结果仍可能超出安全范围。policy 随后会返回不安全的 maxEvents,引擎会连同本来可用的 byte grant 一起拒绝,从而在仍有余量时发生截断。请增加大合法基线的回归测试。

— qwen3.7-max via Qwen Code /review (v0.21.10)

Comment on lines +479 to +481
if (
!TURN_BOUNDARY_TYPES.has(event.type) &&
(this.liveJournal.length > this.maxJournalEvents ||

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

[Critical] Do not commit/account growth unless it improves retention. For an event larger than the 256 MiB hard cap, this path repeatedly asks for and permanently accounts larger session caps up to 256 MiB, but eviction still retains exactly one oversized event after every append. A stream of such events can consume the shared pool without preserving any additional replay and deny useful headroom to other sessions. Evaluate the post-grant retained set before accepting/accounting the grant, or otherwise refuse grants that cannot change the eviction result.

中文翻译

[严重] 只有增长确实改善保留结果时才应提交并记账。对于大于 256 MiB 硬上限的事件,此路径会反复申请并永久计入更大的 session 上限直至 256 MiB,但每次追加后淘汰仍只保留一个超大事件。连续此类事件会耗尽共享池,却没有多保留任何 replay,并挤占其他 session 的有效余量。请在接受/记账 grant 前评估增长后的保留集合,或拒绝无法改变淘汰结果的 grant。

— qwen3.7-max via Qwen Code /review (v0.21.10)

Comment on lines +65 to +67
export function normalizeJournalGrowthPoolBytes(
value: number | undefined,
): number | undefined {

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

[Suggestion] Add focused tests for this new validation boundary. Please cover undefined, valid safe integers, zero, negatives, fractions, NaN, both infinities, and unsafe integers so a future change cannot silently admit values that break pool accounting.

中文翻译

[建议] 请为这个新增的校验边界补充专门测试。建议覆盖 undefined、合法安全整数、零、负数、小数、NaN、正负无穷及不安全整数,避免未来修改静默接收会破坏增长池记账的值。

— qwen3.7-max via Qwen Code /review (v0.21.10)

| `--enable-session-shell` | boolean | `false` | Enables direct `POST /session/:id/shell` execution. Requires bearer token, and every call must carry a session-bound `X-Qwen-Client-Id`. |
| `--event-ring-size <n>` | number | `8000` | Per-session SSE replay ring; soft cap is `1_000_000`. |
| `--compacted-replay-max-bytes <n>` | positive integer | `4194304` | Byte cap for the bounded in-memory replay snapshot returned by `POST /session/:id/load`; hard cap is `268435456`. |
| `--max-journal-events <n>` | positive integer | `10000` | Per-session baseline cap on in-flight `liveJournal` replay entries for the unfinished turn. Adaptive growth can raise it (see `--max-journal-bytes`); pinning this flag disables growth. |

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

[Suggestion] Document this as a positive safe integer, matching the CLI validation. positive integer still appears to permit values above Number.MAX_SAFE_INTEGER, which startup rejects; please apply the same wording to both journal rows in this table.

中文翻译

[建议] 请按 CLI 的实际校验将类型写为 positive safe integerpositive integer 看起来仍允许超过 Number.MAX_SAFE_INTEGER 的值,但启动时会拒绝;请对本表两个 journal 参数使用一致表述。

— qwen3.7-max via Qwen Code /review (v0.21.10)

| `--max-total-sessions <n>` | number | derived for multiple startup/restored workspaces | - | Daemon-wide active session cap. When omitted, a finite default is derived once from the per-workspace cap and startup/restored workspace count; dynamic registration does not recompute it. `0` means unlimited. |
| `--memory-budget-mb <n>` | integer in `[1024, 1048576]` | 50% of cgroup/host memory | Observation only | Total memory budget for the daemon process tree, capped at resolved available memory. Reported under `limits.memory`; modeled into a partition that nothing applies. |
| `--memory-budget-mb <n>` | integer in `[1024, 1048576]` | 50% of cgroup/host memory | - | Total memory budget for the daemon process tree, capped at resolved available memory. No child is sized from it; the one consumer today is the adaptive live-journal growth pool (see `--max-journal-bytes`). Reported under `limits.memory`, including a modeled per-child partition. |
| `--max-journal-events <n>` | number | `10000` | - | Per-session baseline cap on in-flight `liveJournal` replay entries. Adaptive growth can raise it (see `--max-journal-bytes`); pinning this flag disables growth. |

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

[Suggestion] Use positive safe integer for both journal options here. The current number wording appears to allow zero, fractions, and unsafe integers, all of which the CLI rejects at startup.

中文翻译

[建议] 此处两个 journal 参数都应写为 positive safe integer。当前的 number 表述看起来允许零、小数和不安全整数,但 CLI 会在启动时拒绝这些值。

— qwen3.7-max via Qwen Code /review (v0.21.10)

Comment on lines 398 to 400
.option('max-journal-events', {
type: 'number',
default: DEFAULT_MAX_JOURNAL_EVENTS,
description:

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

[Suggestion] Keep the public ServeOptions contract aligned with these CLI descriptions. Its maxJournalEvents/maxJournalBytes documentation still describes fixed caps and does not explain that omitting both enables adaptive growth while specifying either pins both dimensions. Embedders can otherwise opt into or disable growth unintentionally.

中文翻译

[建议] 请同步更新公开的 ServeOptions 契约。其 maxJournalEvents/maxJournalBytes 文档仍描述为固定上限,也未说明同时省略两项会启用自适应增长,而指定任意一项会固定两个维度。否则嵌入方可能无意启用或关闭增长。

— qwen3.7-max via Qwen Code /review (v0.21.10)

| `--event-ring-size <n>` | number | `8000` | Per-session SSE replay ring; soft cap is `1_000_000`. |
| `--compacted-replay-max-bytes <n>` | positive integer | `4194304` | Byte cap for the bounded in-memory replay snapshot returned by `POST /session/:id/load`; hard cap is `268435456`. |
| `--max-journal-events <n>` | positive integer | `10000` | Per-session baseline cap on in-flight `liveJournal` replay entries for the unfinished turn. Adaptive growth can raise it (see `--max-journal-bytes`); pinning this flag disables growth. |
| `--max-journal-bytes <n>` | positive integer | `8388608` (8 MiB) | Per-session baseline byte cap on the in-flight `liveJournal`. When a turn breaches it, adaptive growth doubles the session's caps on demand — within a per-bridge pool of 5% of the effective `--memory-budget-mb`, clamped to `[32, 1024]` MB, and never past a 256 MiB per-session hard cap; without headroom the oldest entries are dropped with a `history_truncated` marker. Pinning either journal flag disables growth. |

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

[Suggestion] Avoid promising that every growth step doubles the caps. The policy can grant only the remaining pool headroom, so another session may leave this turn with an increase smaller than 2× and earlier truncation than this wording implies. Say that caps grow toward double, limited by remaining pool headroom and the per-session hard cap.

中文翻译

[建议] 不要承诺每次增长都会将上限翻倍。policy 只能授予池中剩余余量,因此其他 session 占用大部分池后,本 turn 的增幅可能小于 2 倍,并比当前文档暗示的更早截断。建议表述为上限会“朝两倍增长”,同时受剩余池余量和每 session 硬上限限制。

— qwen3.7-max via Qwen Code /review (v0.21.10)

Address the automated review of adaptive live-journal growth:

- The growth pool is now one daemon-wide aggregate shared by every
  workspace bridge instead of a full pool per bridge, and growth is
  disabled when the budget is insufficient or leaves no headroom after
  the root reserve.
- Grants that cannot retain any additional journal entries (an oversized
  event survives as the sole entry either way) are refused so the pool
  is never charged for growth that preserves no replay.
- The refusal throttle defaults to a monotonic clock and treats a
  backward clock jump as an elapsed window.
- The proportional event hard cap is clamped to MAX_SAFE_INTEGER so a
  valid-but-extreme baseline cannot poison every grant.
- /daemon/status reports the growth semantics: limits.memory.journalGrowth
  (pool size, hard cap, baselines), per-session effective caps in full
  diagnostics, and enforced:false scoped to the child-heap model.
- Validation-boundary tests for the growth-pool normalizer and doc fixes
  (positive safe integer types; growth toward double, limited by pool
  headroom).
@qwen-code-dev-bot

Copy link
Copy Markdown
Collaborator

🤖 Addressed the latest review feedback (round 4/100). What changed, and what I pushed back on: · 已处理最新评审反馈(第 4/100 轮)。改动内容与我反驳保留之处如下:

Addressed review feedback for PR #8905 (round: inline findings R2-1 … R2-6)

All six inline findings were verified against the code, addressed in code, and committed as
fix(serve): account growth per session baseline and walk intermediate grants (#8905) (72f07a5).
No conflicts (--conflict false, no merge performed).

Critical

  • [Critical] rc:3768972276 — shared-pool accounting applied this bridge's baseline to every session (bridge.ts). Confirmed: the policy computed Σ max(0, limit − opts.baselineBytes) over the daemon-wide provider's caps, so a sibling bridge's untouched 16 MiB-baseline session was mischarged as 8 MiB of granted growth by an 8 MiB-baseline policy, which can exhaust an unused pool. Fixed by reporting each session's own starting baseline alongside its current cap: new JournalGrowthSessionLimit { limitBytes, baselineBytes } type; the provider, daemon aggregator, and JournalGrowthRequest.allSessionLimits now carry pairs, and the policy charges Σ max(0, limitBytes − baselineBytes). Covered by new policy tests (untouched larger baseline not charged; grown session charged by its own baseline) and a new two-bridge integration test (does not mischarge an untouched sibling baseline against the shared pool) that fails under the old math.
  • [Critical] rc:3768972286 — intermediate grants had to immediately retain an extra entry (compactionEngine.ts). Confirmed: with an 8 MiB baseline, a ~6 MiB event followed by a ~20 MiB event needs 32 MiB to retain both; the first 16 MiB grant retains no more than 8 MiB, so it was refused, the older event was evicted, and the engine could never reach 32 MiB despite pool headroom. Fixed: maybeGrowJournalLimits now walks reachable grants — each grant is applied tentatively (so the next ask reports and is charged for it), continuing until a grant retains strictly more than the pre-breach caps, the advisor refuses, or a 64-step budget runs out. A walk that never improves retention rolls back to the original caps and records a refusal, so the pool is still never charged for growth that preserves no replay. Covered by new engine tests (walks through intermediate grants to reach a later grant that retains more, never charges growth when no reachable cap can retain more) and updated call-count expectations in the existing refusal test.

Suggestions

  • [Suggestion] rc:3768972294 — bridge-level regression exercised only one tiny growth step. Implemented: added keeps granting across repeated doublings for one runaway turn — 40 events at a two-entry baseline force five policy grants (2→4→8→16→32→64 entries) up to the 256 MiB hard cap, and the test asserts no truncation marker, retained head/middle/tail chunks, and that the daemon status snapshot reports the fully grown caps — so an integration that stops granting or stops propagating effective limits after the first doubling fails.
  • [Suggestion] rc:3768972298 — mockTotalMemBytes leak when runQwenServe rejects before its try/finally. Implemented: the file-level afterEach now unconditionally resets mockTotalMemBytes.value, so a startup rejection cannot leak the pinned 8 GiB host-memory figure into later memory-budget tests.
  • [Suggestion] rc:3768972307 — hook identity assertions pass when both hooks are undefined. Implemented: the hot-remove test now asserts toBeTypeOf('function') for journalGrowthSessionLimits and registerJournalGrowthSessionLimits on the boot bridge before the identity comparisons, so a regression that unwires the pool from both bridges at once can no longer hide behind undefined === undefined.
  • [Suggestion] rc:3768972315 — pinned-cap tests did not control detected host/cgroup memory. Implemented: both pinned-flag tests (--max-journal-bytes pin and --max-journal-events pin) now pin totalmem() to 8 GiB and process.constrainedMemory() to 0 with cleanup in finally, matching the sibling tests, so only the pinned-flag gate can disable growth regardless of the runner's own memory.

Declined / escalated

None — all findings were actionable and in scope.

Verification

Commands actually run (all in the PR checkout, commit 72f07a5):

  • npm run build — passed (exit 0)
  • npm run typecheck — passed (exit 0)
  • npm run lint — passed (exit 0; eslint . --ext .ts,.tsx && eslint integration-tests)
  • npx prettier --check on the ten changed files — passed
  • cd packages/acp-bridge && npx vitest run src/journalGrowthPolicy.test.ts src/compactionEngine.test.ts — 133 passed
  • cd packages/acp-bridge && npx vitest run src/bridge.test.ts — 577 passed
  • cd packages/acp-bridge && npx vitest run (full package) — 28 files, 1353 passed
  • cd packages/cli && npx vitest run src/serve/run-qwen-serve.test.ts — 255 passed
  • cd packages/cli && npx vitest run on the other PR-touched serve test files (commands/serve, serve/daemon-status, serve/multi-workspace-sessions, serve/server, serve/routes/workspace-qualified-extensions, serve/workspace-qualified-rest) — 6 files, 1206 passed

Integration tests after npm run bundle were not run: the touched behavior (pool accounting, growth walk, daemon wiring) is fully exercised by the in-process bridge/daemon unit tests above, not only through the bundled CLI or integration harness. No settings source changed, so npm run generate:settings-schema was not required.

中文说明

已处理 PR #8905 的评审反馈(本轮:行内发现 R2-1 … R2-6)

六条行内发现全部经代码核实、在代码中处理完毕,并已提交为
fix(serve): account growth per session baseline and walk intermediate grants (#8905)(72f07a5009)。
无冲突(--conflict false,未执行合并)。

严重(Critical)

  • [严重] rc:3768972276 — 共享池会计把当前 bridge 的 baseline 套用到所有 session(bridge.ts)。 已确认:policy 对 daemon 级 provider 返回的所有 cap 计算 Σ max(0, limit − opts.baselineBytes),因此兄弟 bridge 上未增长的 16 MiB baseline session 会被 8 MiB baseline 的 policy 误算为已授予 8 MiB 增长,可能在池未使用时耗尽全部余量。已修复:每个 session 在上报当前 cap 的同时上报自己的起始 baseline —— 新增 JournalGrowthSessionLimit { limitBytes, baselineBytes } 类型;provider、daemon 聚合器与 JournalGrowthRequest.allSessionLimits 均改为携带该二元组,policy 按 Σ max(0, limitBytes − baselineBytes) 计费。新增 policy 测试(未增长的更大 baseline 不计费;已增长 session 按其自身 baseline 计费)以及双 bridge 集成测试(does not mischarge an untouched sibling baseline against the shared pool,旧算法下必然失败)覆盖。
  • [严重] rc:3768972286 — 中间 grant 必须立刻多保留一个 entry(compactionEngine.ts)。 已确认:8 MiB baseline 下,约 6 MiB 事件后跟约 20 MiB 事件需要 32 MiB 才能同时保留;第一次 16 MiB grant 与 8 MiB 一样无法多保留,因此被拒绝、旧事件被淘汰,即使池余量充足也永远到不了 32 MiB。已修复maybeGrowJournalLimits 现在会遍历可达 grant —— 每个 grant 先临时应用(使下一次询问上报并按其计费),持续直到某个 grant 相对越界前 cap 严格多保留、advisor 拒绝或达到 64 步预算。整条路径都未改善保留时回滚到原 cap 并记为一次拒绝,池仍不会为未保留任何回放的 growth 计费。新增引擎测试(walks through intermediate grants to reach a later grant that retains morenever charges growth when no reachable cap can retain more)覆盖,并更新了既有拒绝测试的调用次数断言。

建议(Suggestions)

  • [建议] rc:3768972294 — bridge 级回归测试只覆盖一次很小的增长。 已实现:新增 keeps granting across repeated doublings for one runaway turn —— 两条 baseline 下发送 40 条事件,需要五次 policy grant(2→4→8→16→32→64 条)直至 256 MiB 硬上限;测试断言无截断标记、头/中/尾 chunk 均保留,且 daemon 状态快照报告完全增长后的 cap —— 若集成在第一次翻倍后停止授予或停止传播有效上限,该测试将失败。
  • [建议] rc:3768972298 — runQwenServe 在进入 try/finally 前拒绝时 mockTotalMemBytes 泄漏。 已实现:文件级 afterEach 现在无条件重置 mockTotalMemBytes.value,启动失败不会把 8 GiB 的虚假宿主内存泄漏给后续 memory-budget 测试。
  • [建议] rc:3768972307 — 两个 hook 均为 undefined 时 identity 断言也能通过。 已实现:hot-remove 测试现在先断言启动 bridge 的 journalGrowthSessionLimitsregisterJournalGrowthSessionLimits 均为函数(toBeTypeOf('function')),再做 identity 比较;同时从两个 bridge 拆除池的回归无法再靠 undefined === undefined 蒙混过关。
  • [建议] rc:3768972315 — pinned-cap 测试未固定探测到的 host/cgroup 内存。 已实现:两个 pinned-flag 测试(--max-journal-bytes--max-journal-events)现在都固定 totalmem() 为 8 GiB、process.constrainedMemory()0,并在 finally 中清理,与相邻测试保持一致;无论 runner 自身内存如何,只有 pinned-flag gate 能禁用增长。

拒绝 / 升级

无 —— 所有发现均可处理且在范围内。

验证

实际执行的命令(均在 PR 检出上,提交 72f07a5):

  • npm run build — 通过(exit 0)
  • npm run typecheck — 通过(exit 0)
  • npm run lint — 通过(exit 0;eslint . --ext .ts,.tsx && eslint integration-tests
  • 对十个改动文件执行 npx prettier --check — 通过
  • cd packages/acp-bridge && npx vitest run src/journalGrowthPolicy.test.ts src/compactionEngine.test.ts — 133 通过
  • cd packages/acp-bridge && npx vitest run src/bridge.test.ts — 577 通过
  • cd packages/acp-bridge && npx vitest run(整包)— 28 个文件,1353 通过
  • cd packages/cli && npx vitest run src/serve/run-qwen-serve.test.ts — 255 通过
  • cd packages/cli && npx vitest run 其余 PR 触及的 serve 测试文件(commands/serveserve/daemon-statusserve/multi-workspace-sessionsserve/serverserve/routes/workspace-qualified-extensionsserve/workspace-qualified-rest)— 6 个文件,1206 通过

未运行 npm run bundle 后的集成测试:本次触及的行为(池会计、增长遍历、daemon 接线)已由上述进程内 bridge/daemon 单元测试完整覆盖,并非只能通过打包 CLI 或集成测试框架验证。未改动任何 settings 源,因此无需 npm run generate:settings-schema

Base-conflict check · 基分支冲突检查: no conflict with main. · 与 main 无冲突。

Re-review when you have a moment. After round 100 this bot stops and leaves the PR for a human. · 有空请复审;第 100 轮后本 bot 停止并将 PR 交给人工。


🧠 Handled by Qwen Code · model/模型 qwen3.8-max

@qwen-code-ci-bot qwen-code-ci-bot left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Reviewed. Suggestions are inline.

Not reviewed: reverse audit — stopped at the 5-round cap; rounds 1-5 each reported confirmed findings, so two consecutive dry rounds were never established.

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): You are review agent reverse-audit — Reverse audit agen...: none — all checks I started were completed; I did not run the test suite/typecheck since every premise was verifiable by source inspection and no candidate surv…; You are review agent reverse-audit — Reverse audit agen...: none — all checks completed within budget.; chunk 8: run compactionEngine.test.ts under vitest — no node_modules installed in the worktree or parent checkout; verification is by manual trace against the implem…; You are review agent reverse-audit — Reverse audit agen...: none — all checks above completed within budget.; You are review agent reverse-audit — Reverse audit agen...: none — all checks above completed within budget., and 6 more.

Test Plan (not a blocker): 1221 tests pass — this review observed 1353, 19151, 1511, 494, 3289, 551 passed.

中文说明

已审查。 建议见行内评论。

未审查:reverse audit — stopped at the 5-round cap; rounds 1-5 each reported confirmed findings, so two consecutive dry rounds were never established。

未审查:build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally。

未探索到全部深度(达到工具调用预算):You are review agent reverse-audit — Reverse audit agen...:none — all checks I started were completed; I did not run the test suite/typecheck since every premise was verifiable by source inspection and no candidate surv…;You are review agent reverse-audit — Reverse audit agen...:none — all checks completed within budget.;chunk 8:run compactionEngine.test.ts under vitest — no node_modules installed in the worktree or parent checkout; verification is by manual trace against the implem…;You are review agent reverse-audit — Reverse audit agen...:none — all checks above completed within budget.;You are review agent reverse-audit — Reverse audit agen...:none — all checks above completed within budget.,另有 6 条。

Test Plan(非阻断):1221 tests pass — this review observed 1353, 19151, 1511, 494, 3289, 551 passed

— qwen3.8-max via Qwen Code /review (v0.21.10)

Comment on lines +5361 to +5368
const snapA = await bridge.loadSession({
sessionId: 'restore-a',
workspaceCwd: WS_A,
historyReplay: 'response',
});
expect(
snapA.liveJournal?.find((event) => event.type === 'history_truncated'),
).toBeUndefined();

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[Suggestion] Three tests assert the grown session's outcome only via the absence of a history_truncated marker — refuses growth for a second session… (session 1), accounts concurrent in-flight restores… (this snapshot), and accounts growth across bridges… (session A). The negative check also passes on an empty journal — the exact vacuous pass this diff guards against elsewhere: returns granted headroom… documents the hazard ("the negative marker check also passes on an empty journal") and adds a positive content loop; these three omit it. — Failure scenario: probe-verified — a regression that empties or reseeds the grown session's journal without emitting a marker (e.g. the restore-completion path dropping the pending bus's buffered live events) leaves these tests green while the grown session — the feature's beneficiary — silently retains nothing.

Suggested change
const snapA = await bridge.loadSession({
sessionId: 'restore-a',
workspaceCwd: WS_A,
historyReplay: 'response',
});
expect(
snapA.liveJournal?.find((event) => event.type === 'history_truncated'),
).toBeUndefined();
const snapA = await bridge.loadSession({
sessionId: 'restore-a',
workspaceCwd: WS_A,
historyReplay: 'response',
});
expect(
snapA.liveJournal?.find((event) => event.type === 'history_truncated'),
).toBeUndefined();
for (const text of ['a-1', 'a-2', 'a-3']) {
expect(JSON.stringify(snapA.liveJournal)).toContain(text);
}
中文说明

[建议] 三个测试仅通过 history_truncated 标记的缺失来断言增长后会话的结果(refuses growth for a second session… 的 session 1、accounts concurrent in-flight restores… 的该快照、accounts growth across bridges… 的 session A)。负向检查在 journal 为时同样通过——这正是本 diff 在其他地方已防范的空洞通过:returns granted headroom… 明确记录了该风险(“负向标记检查在空 journal 下也能通过”)并补充了正向内容断言,而这三处遗漏了。— 失败场景(已用探针验证):若某个回归在不发出标记的情况下清空或重置增长后会话的 journal(例如 restore 完成路径丢弃了 pending bus 缓冲的 live 事件),这些测试仍为绿色,而增长后的会话——该功能的受益者——已悄悄不保留任何内容。

修复:按上方 suggestion 补充同级测试已使用的正向内容断言。

— qwen3.8-max via Qwen Code /review (v0.21.10)

Comment on lines +5244 to +5248
expect(
secondSnap.liveJournal?.find(
(event) => event.type === 'history_truncated',
),
).toMatchObject({ data: { scope: 'live_journal' } });

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[Suggestion] Four truncation-outcome assertions here and at lines 5300, 5377, 5650 pin only the marker's presence (toMatchObject({ data: { scope: 'live_journal' } })), never the retained window — the mirror-image vacuity of the marker-absence finding: these pass on an over-eviction. — Failure scenario: probe-verified — an over-eviction mutation that drops one extra entry whenever eviction ran leaves all nine bridge growth tests green (the engine control test evicts down to the raised cap… fails under the identical mutation), while events the cap should retain (b-2/b-3 at cap 2 here; r-5; b-3 in the other three) are silently dropped.

Suggested change
expect(
secondSnap.liveJournal?.find(
(event) => event.type === 'history_truncated',
),
).toMatchObject({ data: { scope: 'live_journal' } });
expect(
secondSnap.liveJournal?.find(
(event) => event.type === 'history_truncated',
),
).toMatchObject({ data: { scope: 'live_journal' } });
expect(JSON.stringify(secondSnap.liveJournal)).toContain('b-3');
中文说明

[建议] 此处及 5300、5377、5650 行的四个截断结果断言只钉住了标记的存在,从未钉住保留窗口——这是“标记缺失”类发现的镜像空洞:这类断言在过度驱逐下也能通过。— 失败场景(已用探针验证):一个在驱逐发生时多丢一条 entry 的变异会让全部九个 bridge 增长测试保持绿色(引擎侧对照测试 evicts down to the raised cap… 在相同变异下会失败),而按 cap 本应保留的事件(此处 cap 2 下的 b-2/b-3,以及另外三处的 r-5、b-3)被悄悄丢弃。

修复:按上方 suggestion 在标记断言后补充保留窗口断言(模式与 grows a breaching session…returns granted headroom… 一致)。

— qwen3.8-max via Qwen Code /review (v0.21.10)

await bridge.shutdown();
});

it('charges a mid-restore session for growth granted before registration', async () => {

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[Suggestion] Mid-restore growth accounting is only tested on the restore-success exit; no test covers a restore that FAILs or times out after its pending bus has already grown. Pool correctness for that exit rests solely on the two pendingRestoreEvents.delete() cleanup sites (bridge.ts:6133 abandon-timeout, bridge.ts:6392 .finally()), and every existing restore test resolves its deferred loadSession successfully. — Failure scenario: a refactor dropping/skipping the failure-path delete leaves the dead session's grown cap enumerated forever: grant() then computes extraGranted including the dead session, available stays permanently shrunk, and every sibling session sharing the daemon-wide pool is truncated instead of grown until daemon restart. All nine growth tests stay green; the abandon path (a restore timing out mid event-flood — exactly the condition growth exists for) has zero coverage.

Suggested fix — a sibling test:

// hold the restore, breach the pending bus so it grows, then FAIL the load
load.reject(new Error('restore failed'));
// spawn a second session, breach it, assert it grows from the returned
// headroom: no history_truncated marker + the positive content loop
中文说明

[建议] restore 期间的增长记账只在 restore 成功出口有测试;没有测试覆盖 pending bus 已经增长后 restore 失败或超时的情形。该出口的池正确性完全依赖两处 pendingRestoreEvents.delete() 清理点(bridge.ts:6133 超时放弃、bridge.ts:6392 .finally()),而现有 restore 测试全部成功 resolve 了延迟的 loadSession。— 失败场景:若重构删除/跳过了失败路径的 delete,死会话已增长的 cap 会被永久计入枚举:grant() 计算的 extraGranted 包含该死会话,available 被永久压低,daemon 级共享池的所有兄弟会话都会被截断而非增长,直到 daemon 重启。全部九个增长测试仍为绿色;放弃路径(restore 在事件洪流中超时——正是增长功能存在的场景)零覆盖。

修复:新增一个同级测试——挂起 restore、让 pending bus 超限增长、然后 reject 加载;再创建第二个会话并使其超限,断言它用归还的余量完成增长(无截断标记 + 正向内容断言)。

— qwen3.8-max via Qwen Code /review (v0.21.10)

Comment on lines +5108 to +5112
const bridge = makeBridge({
channelFactory: async () => handle.channel,
maxJournalEvents: 2,
journalGrowthPoolBytes: 256 * 1024 * 1024,
});

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[Suggestion] Pattern: growth tests calibrating against the unpinned DEFAULT_MAX_JOURNAL_* constants (location 1 of 8). This test pins the entry baseline but leaves the byte baseline implicit, while its terminal assertions are exact multiples of the default — five doublings land exactly on the 256 MiB hard cap only because the default is 8 MiB (ceil((256 MiB / 8 MiB) × 2) === 64). The sibling locations: bridge.test.ts:5179, 5399, compactionEngine.test.ts:1343, 1503, 1541, 1762, run-qwen-serve.test.ts:7767. walks through intermediate grants… already pins maxJournalBytes explicitly — that is the intended pattern. — Failure scenario: probe-verified — moving DEFAULT_MAX_JOURNAL_BYTES fails the test with cryptic doubling-arithmetic mismatches pointing at nothing in the test (at 4 MiB the pool also funds two doublings, so scripted outcomes silently change).

Suggested change
const bridge = makeBridge({
channelFactory: async () => handle.channel,
maxJournalEvents: 2,
journalGrowthPoolBytes: 256 * 1024 * 1024,
});
const bridge = makeBridge({
channelFactory: async () => handle.channel,
maxJournalEvents: 2,
maxJournalBytes: 8 * 1024 * 1024,
journalGrowthPoolBytes: 256 * 1024 * 1024,
});
中文说明

[建议] 模式:增长测试隐式依赖未钉住的 DEFAULT_MAX_JOURNAL_* 常量(共 8 处,此处为第 1 处)。该测试钉住了条目基线但未钉住字节基线,而结尾断言恰是默认值的整数倍——只有默认值为 8 MiB 时五次翻倍才恰好落在 256 MiB 硬顶(ceil((256 MiB / 8 MiB) × 2) === 64)。同类位置:bridge.test.ts:5179、5399,compactionEngine.test.ts:1343、1503、1541、1762,run-qwen-serve.test.ts:7767。walks through intermediate grants… 已显式钉住 maxJournalBytes——那才是预期模式。— 失败场景(已用探针验证):改动 DEFAULT_MAX_JOURNAL_BYTES 会让测试以莫名其妙的翻倍算术不匹配失败,指向不到测试中任何内容(改为 4 MiB 时池还会资助两次翻倍,脚本化的结果会被悄悄改变)。

修复:按上方 suggestion 在 options 中显式钉住 maxJournalBytes

— qwen3.8-max via Qwen Code /review (v0.21.10)

Comment on lines +5179 to +5181
sessionScope: 'thread',
maxJournalEvents: 2,
journalGrowthPoolBytes: 8 * 1024 * 1024,

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[Suggestion] Pattern: growth tests calibrating against the unpinned DEFAULT_MAX_JOURNAL_* constants (location 2 of 8). refuses growth for a second session… and its three pool-calibrated siblings (charges a mid-restore session… ~5267, accounts concurrent in-flight restores… ~5319, accounts growth across bridges… ~5558, and does not mischarge… ~5696 via its literals) size the pool at exactly one unpinned DEFAULT_MAX_JOURNAL_BYTES baseline. — Failure scenario: probe-verified — at a 4 MiB default the 8 MiB pool funds TWO doublings instead of one: the scripted refusal becomes a grant, and the marker assertion fails pointing at nothing about the calibration; at a grown default the mischarge test degrades to a loud but misleading failure. The tests are sound only while the default stays 8 MiB.

Suggested change
sessionScope: 'thread',
maxJournalEvents: 2,
journalGrowthPoolBytes: 8 * 1024 * 1024,
sessionScope: 'thread',
maxJournalEvents: 2,
maxJournalBytes: 8 * 1024 * 1024,
journalGrowthPoolBytes: 8 * 1024 * 1024,
中文说明

[建议] 模式:增长测试隐式依赖未钉住的 DEFAULT_MAX_JOURNAL_* 常量(共 8 处,此处为第 2 处)。refuses growth for a second session… 及其三个按池校准的同类测试(charges a mid-restore session… ~5267、accounts concurrent in-flight restores… ~5319、accounts growth across bridges… ~5558,以及 does not mischarge… ~5696 的字面量)把池大小恰好设为一个未钉住的 DEFAULT_MAX_JOURNAL_BYTES 基线。— 失败场景(已用探针验证):默认值变为 4 MiB 时,8 MiB 的池会资助两次翻倍而非一次:脚本化的拒绝变成授予,标记断言失败却指向不到校准问题;默认值变大时 mischarge 测试退化为响亮但误导的失败。这些测试只有在默认值保持 8 MiB 时才有效。

修复:按上方 suggestion 钉住基线(does not mischarge… 测试须钉在 bridgeA 自己的 options 上,勿放入最后展开进 bridgeB 的 sharedGrowthOpts)。

— qwen3.8-max via Qwen Code /review (v0.21.10)

Comment thread packages/cli/src/commands/serve.ts Outdated
Comment on lines +414 to +416
'Per-session baseline source-event byte cap on the in-flight live ' +
'journal. When a turn outgrows it, adaptive growth raises the ' +
"session's caps (per-session hard cap 256 MiB) within a growth " +

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[Suggestion] The new help text hard-codes growth figures that exist as exported constants — 256 MiB here vs JOURNAL_GROWTH_HARD_CAP_BYTES, and in the adjacent --memory-budget-mb text 5% / capped at 1024 MB vs JOURNAL_GROWTH_POOL_FRACTION / MAX_JOURNAL_GROWTH_POOL_MB — even though this file already imports both modules (lines 20-24, 27-30) and interpolates DEFAULT_MAX_JOURNAL_EVENTS / DEFAULT_MAX_JOURNAL_BYTES in the very same descriptions. — Failure scenario: when someone changes JOURNAL_GROWTH_HARD_CAP_BYTES (or the pool fraction/cap), qwen serve --help keeps advertising the old numbers: an operator sizing daemon memory relies on a hard cap that no longer matches the enforced one, and the help text contradicts GET /daemon/status, which reports hardCapBytes live from the same constant.

Suggested change
'Per-session baseline source-event byte cap on the in-flight live ' +
'journal. When a turn outgrows it, adaptive growth raises the ' +
"session's caps (per-session hard cap 256 MiB) within a growth " +
'Per-session baseline source-event byte cap on the in-flight live ' +
'journal. When a turn outgrows it, adaptive growth raises the ' +
`session's caps (per-session hard cap ${JOURNAL_GROWTH_HARD_CAP_BYTES / (1024 * 1024)} MiB) within a growth ` +

(and interpolate JOURNAL_GROWTH_POOL_FRACTION * 100 / MAX_JOURNAL_GROWTH_POOL_MB in the --memory-budget-mb text)

中文说明

[建议] 新的帮助文本把已有导出常量的增长参数硬编码了——此处的 256 MiB 对应 JOURNAL_GROWTH_HARD_CAP_BYTES,相邻 --memory-budget-mb 文本中的 5% / capped at 1024 MB 对应 JOURNAL_GROWTH_POOL_FRACTION / MAX_JOURNAL_GROWTH_POOL_MB——而本文件已导入这两个模块(20-24、27-30 行),并且在同样的描述里对 DEFAULT_MAX_JOURNAL_EVENTS / DEFAULT_MAX_JOURNAL_BYTES 做了插值。— 失败场景:一旦有人修改 JOURNAL_GROWTH_HARD_CAP_BYTES(或池比例/上限),qwen serve --help 会继续宣传旧数字:按此规划 daemon 内存的运维人员依赖的硬顶将与实际执行值不符,帮助文本也会与 GET /daemon/status(从同一常量实时上报 hardCapBytes)矛盾。

修复:按上方 suggestion 插值(并在 --memory-budget-mb 文本中同样插值池比例与上限)。

— qwen3.8-max via Qwen Code /review (v0.21.10)

Comment on lines +463 to +465
await startServeHandlerWithArgs(
'--no-web --max-journal-events 5000 --max-journal-bytes 1048576',
);

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[Suggestion] The new conditional-forwarding logic in serve.ts (two independent argv['max-journal-X'] !== undefined spreads) has forwarding tests only for the two pinned-together extremes — neither pinned (above) and both pinned (here) — but none for pinning a single journal flag, which is the case where the independence of the two spreads is load-bearing. (run-qwen-serve.test.ts tests the events-only pin at the runQwenServe options level, which bypasses this yargs handler layer.) — Failure scenario: probe-verified — a refactor coupling the two spreads (&& joining both conditions) passes both existing forwarding tests unchanged. An operator who pins only --max-journal-events 5000 then has that cap silently dropped and growth left enabled with the 10 000 default baseline — the exact opposite of the documented "Pinning this flag (or --max-journal-bytes) disables adaptive growth" contract — and no test turns red.

Suggested fix — boot with one flag pinned and assert the other key is absent:

await startServeHandlerWithArgs('--no-web --max-journal-events 5000');
expect(mockRunQwenServe).toHaveBeenCalledWith(
  expect.objectContaining({ maxJournalEvents: 5000 }),
);
expect(mockRunQwenServe.mock.calls[0]?.[0]).not.toHaveProperty('maxJournalBytes');
// mirror for a single --max-journal-bytes pin
中文说明

[建议] serve.ts 新的条件转发逻辑(两个独立的 argv['max-journal-X'] !== undefined 展开)只有“都不钉住”(上方用例)与“都钉住”(此处)两个极端的转发测试,缺少只钉住一个 journal flag 的用例——而这恰是两个展开相互独立性起决定作用的场景。(run-qwen-serve.test.ts 中只钉条目 cap 的测试走的是 runQwenServe options 层,绕过了这个 yargs handler 层。)— 失败场景(已用探针验证):把两个展开耦合的重构(用 && 连接两个条件)能让两个既有转发测试原样通过。此时只传 --max-journal-events 5000 的运维会发现该 cap 被悄悄丢弃、增长保持开启且基线仍是默认 10 000——与文档承诺的“钉住此 flag(或 --max-journal-bytes)即禁用自适应增长”完全相反——且没有任何测试变红。

修复:按上方代码新增单 flag 钉住用例(两个方向各一)。

— qwen3.8-max via Qwen Code /review (v0.21.10)

Comment on lines +1671 to +1674
// The growth-parity assertions below derive the budget from host
// memory; pin the figure so a small or cgroup-constrained runner
// cannot flip this test red.
mockTotalMemBytes.value = 8 * 1024 * 1024 * 1024;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[Suggestion] The host-memory pin (8 GiB + constrainedMemory → 0) is active for the whole telemetry test — boot AND dynamic attach — which makes the growth-pool parity assertion below (createBridge.mock.calls[1] pool toBe the boot bridge's) blind to the regression it was written to catch: budget/pool re-derivation at attach time. resolveDaemonMemoryBudget reads exactly os.totalmem() and process.constrainedMemory(), both pinned identically from before runQwenServe until the finally cleanup. — Failure scenario: a future change re-deriving the pool at POST /workspaces reads the same pinned inputs, produces the same figure, and the parity assertion still passes — while in production host/cgroup readings drift between boot and attach, so the attached bridge would be constructed with a different journalGrowthPoolBytes; since grant() computes available = opts.poolBytes − extraGranted against each bridge's own poolBytes while extraGranted enumerates daemon-wide sessions, the larger-pool bridge grants growth beyond the single modeled budget — the over-grant the daemon-wide pool exists to prevent.

Suggested fix: shift the pin between the two derivation points — keep 8 GiB before boot, then set mockTotalMemBytes.value = 16 * 1024 * 1024 * 1024 after runQwenServe resolves and before the POST /workspaces attach. The correct boot-closure implementation never re-reads host memory, so it stays green; a re-deriving regression computes a different pool and fails the existing parity assertion. (No other assertion after boot depends on host-memory-derived figures.)

中文说明

[建议] 宿主内存钉住(8 GiB + constrainedMemory → 0)在整个遥测测试期间有效——启动与动态挂载都是——这使得下方的增长池一致性断言(createBridge.mock.calls[1] 的池 toBe 启动 bridge 的池)对它本要捕获的回归(挂载时重新推导预算/池)视而不见。resolveDaemonMemoryBudget 恰好只读 os.totalmem()process.constrainedMemory(),两者从 runQwenServe 之前到 finally 清理被钉成完全相同的值。— 失败场景:未来若在 POST /workspaces 时重新推导池,重推导读到相同的钉住输入、得出相同数值,一致性断言照样通过——而生产中宿主/cgroup 读数在启动与挂载之间会漂移,挂载的 bridge 会带着不同的 journalGrowthPoolBytes 构造;由于 grant() 按每个 bridge 自己的 poolBytes 计算 available = opts.poolBytes − extraGranted、而 extraGranted 枚举的是 daemon 级全部会话,池更大的 bridge 会授予超出单一建模预算的增长——正是 daemon 级池要防止的超额授予。

修复:在两个推导点之间换钉住值——启动前保持 8 GiB,runQwenServe resolve 之后、POST /workspaces 挂载之前改为 16 GiB。正确的“启动期闭包”实现不会重读宿主内存,仍为绿色;重推导的回归会算出不同的池并使现有一致性断言失败。(启动之后没有其他依赖宿主内存推导值的断言。)

— qwen3.8-max via Qwen Code /review (v0.21.10)

Comment on lines +2704 to +2705
it('derives an adaptive journal growth pool into every bridge', async () => {
mockTotalMemBytes.value = 8 * 1024 * 1024 * 1024;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[Suggestion] The 8 GiB host pin makes the derived budget arithmetically identical to the flag budget (floor(8192 MiB × 0.5) = 4096 MB == this test's memoryBudgetMb: 4096), so the pool-parity assertion cannot tell whether the daemon actually consumed --memory-budget-mb when deriving the growth pool. The secondary-workspace sibling (derives the adaptive journal growth pool into secondary-workspace bridges too, ~2854) has the same structure. — Failure scenario: probe-verified — replacing the wiring with resolveDaemonMemoryBudget({}) (dropping budgetMb) leaves both tests green. In production, on any host where derived ≠ flag (e.g. a 16 GiB host with --memory-budget-mb 4096: pool 409 MB instead of 204 MB), the daemon would fund journal growth from a budget the operator never granted.

Suggested change
it('derives an adaptive journal growth pool into every bridge', async () => {
mockTotalMemBytes.value = 8 * 1024 * 1024 * 1024;
it('derives an adaptive journal growth pool into every bridge', async () => {
mockTotalMemBytes.value = 16 * 1024 * 1024 * 1024;

(derived 8192 MB ≠ flag 4096 MB; the existing recompute reads the same pin and stays correct — apply the same shift to the sibling test)

中文说明

[建议] 8 GiB 的宿主钉住使推导预算与 flag 预算在算术上完全相同(floor(8192 MiB × 0.5) = 4096 MB == 本测试的 memoryBudgetMb: 4096),因此池一致性断言无法分辨 daemon 推导增长池时是否真的消费了 --memory-budget-mb。二级 workspace 同类测试(~2854)结构相同。— 失败场景(已用探针验证):把接线替换为 resolveDaemonMemoryBudget({})(丢弃 budgetMb)后两个测试仍绿。生产中任何“推导 ≠ flag”的主机(例如 16 GiB 主机传 --memory-budget-mb 4096:池应为 204 MB 而非 409 MB)上,daemon 会从一个运维从未授予的预算里为 journal 增长出资。

修复:按上方 suggestion 把宿主钉住改为 16 GiB(推导 8192 ≠ flag 4096;既有的重算读同一钉住值仍正确——同类测试做同样调整)。

— qwen3.8-max via Qwen Code /review (v0.21.10)

Comment on lines +3014 to +3016
for (const unregister of unregisters) {
unregister?.();
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[Suggestion] The shared-pool test unregisters both providers before reading the views again, so it verifies only the bulk end state — a mutation that wipes the entire shared Set on any unregister call is indistinguishable from the correct per-provider delete in the production hook (run-qwen-serve.ts:2615-2622). No other test exercises this implementation's unregister behavior (the bridge.test.ts multi-bridge tests use a test-local Set/registrar). — Failure scenario: probe-verified — changing the production handle body to journalGrowthSessionLimitProviders.clear() leaves this test green. In a multi-workspace daemon, closing one workspace's bridge would then delete every surviving bridge's provider, so their live grown sessions drop out of sibling bridges' grant() accounting (extraGranted undercounted → available overcounted): each remaining bridge grants headroom past the pool's true remainder, and aggregate journal growth exceeds the daemon-wide budget — the over-grant the single shared pool exists to prevent.

Suggested fix — unregister one handle at a time with a view assertion between:

unregisters[0]?.();
// assert every view still enumerates the OTHER bridge's provider
// (e.g. [{ limitBytes: 1001, baselineBytes: 8 * 1024 * 1024 }])
unregisters[1]?.();
// assert the views are now []
中文说明

[建议] 共享池测试在重新读取视图前把两个 provider 都注销了,因此只验证了批量终态——“任何一次注销都清空整个共享 Set”的变异与生产钩子(run-qwen-serve.ts:2615-2622)中正确的按 provider delete 无法区分。没有其他测试验证该实现的注销行为(bridge.test.ts 的多 bridge 测试用的是测试本地的 Set/registrar)。— 失败场景(已用探针验证):把生产钩子主体改成 journalGrowthSessionLimitProviders.clear() 后该测试仍绿。在多 workspace daemon 中,关闭某个 workspace 的 bridge 会删掉所有幸存 bridge 的 provider,它们已增长的 live 会话将从兄弟 bridge 的 grant() 记账中消失(extraGranted 少计 → available 多计):每个剩余 bridge 都会授予超出池真实余量的额度,journal 增长总量超出 daemon 级预算——正是单一共享池要防止的超额授予。

修复:按上方代码逐个注销并在中间断言视图。

— qwen3.8-max via Qwen Code /review (v0.21.10)

@qwen-code-dev-bot

Copy link
Copy Markdown
Collaborator

🤖 Addressed the latest review feedback (round 5/100). What changed, and what I pushed back on: · 已处理最新评审反馈(第 5/100 轮)。改动内容与我反驳保留之处如下:

Autofix review round summary — PR #8905

All 19 inline findings this round were Suggestions from the automated reviewer, and all 19 were resolved in code in a single commit (a4d0dabe78). No finding was declined, deferred, or escalated. No base-conflict work (--conflict false).

Vacuous-pass hardening (bridge growth tests)

  • [rc:3770626771] — Added the positive content loop (already used by returns granted headroom…) to the three grown-session assertions that relied only on marker absence: refuses growth for a second session… (session 1), accounts concurrent in-flight restores… (restore-a), accounts growth across bridges… (session A). An emptied/reseeded grown journal can no longer pass silently.
  • [rc:3770626783] — Added retained-window assertions next to the four marker-presence assertions (bridge.test.ts refuses growth…, charges a mid-restore…, accounts concurrent…, accounts growth across bridges…). Each now pins the exact events the cap retains (b-2/b-3 or r-4/r-5), so an over-eviction dropping one extra entry fails these tests.
  • [rc:3770626786] — New bridge test releases granted growth when the mid-restore session fails: holds a restore, breaches its pending bus so it grows and consumes the pool, then rejects the load; a sibling session breaching afterwards must grow from the returned headroom (no truncation marker + positive content). Covers the failure-path pendingRestoreEvents.delete() cleanup that previously had zero coverage.

Unpinned DEFAULT_MAX_JOURNAL_* calibration (8-location pattern)

  • [rc:3770626793] — Pinned maxJournalBytes: 8 MiB in keeps granting across repeated doublings… so the five-doublings-to-hard-cap arithmetic no longer depends on the unpinned default.
  • [rc:3770626805] — Pinned the 8 MiB byte baseline in refuses growth for a second session…, charges a mid-restore session…, accounts concurrent in-flight restores…, accounts growth across bridges… (shared opts), and on bridgeA's own options in does not mischarge… (kept out of sharedGrowthOpts so it cannot override bridgeB's distinct 16 MiB baseline).
  • [rc:3770626817] — Pinned the byte baseline in returns granted headroom…, keeping "pool = exactly one baseline" true under any default.
  • [rc:3770626826] — Pinned maxJournalBytes: 8 MiB in the seven compactionEngine growth tests that assert byte caps as exact default multiples (grows the caps…, passes the current caps…, treats a non-growing or malformed grant…, refuses a grant that grows bytes but shrinks…, does not ask for growth… turn boundary, stamps the truncation marker…, keeps grown caps across turn boundaries).
  • [rc:3770626831] — Pinned maxJournalEvents (describe-scoped ENTRY_BASELINE = 10_000) in grows the caps on a byte-cap breach…; the grown-cap assertion now derives from the pinned value (ENTRY_BASELINE * 2).
  • [rc:3770626836] — Pinned the entry baseline alongside the byte baseline in the four fixture-coupled tests (refuses a grant that cannot retain more…, evicts down to the raised cap…, walks through intermediate grants…, never charges growth…); all advisor fixtures and grown-cap assertions derive from ENTRY_BASELINE.
  • [rc:3770626841] — Pinned maxJournalBytes: 8 MiB in clears the refusal throttle when a re-ask is granted, keeping its 16 MiB grant fixture valid under any default.
  • [rc:3770626846] — Bootstrap daemon-status test now reads baselineMaxEvents / baselineMaxBytes from DEFAULT_MAX_JOURNAL_EVENTS / DEFAULT_MAX_JOURNAL_BYTES instead of raw literals, matching the other derived fields in the same block.

Structural / coverage gaps

  • [rc:3770626851] — Extracted the duplicated ~20-line daemon-wide aggregator fake into a test-local makeGrowthAggregator() helper (fresh instance per call); both multi-bridge tests now model the runQwenServe aggregator contract through one definition.
  • [rc:3770626856] — New compactionEngine test for the growth walk's third exit: an advisor granting strictly-growing-but-non-retaining caps exhausts the 64-step budget; asserts exactly 64 advisor calls, caps rolled back to baseline, and a throttled second breach that does not re-ask.
  • [rc:3770626860] — New journalGrowthPoolMb test with a capped-down budget (budgetMb: 8192 on a 4096 MB host): pins effectiveBudgetMb as the pool denominator (204 MB, not 409 MB).
  • [rc:3770626865]qwen serve --help now interpolates the exported constants instead of hard-coding growth figures: JOURNAL_GROWTH_HARD_CAP_BYTES (per-session hard cap), and JOURNAL_GROWTH_POOL_FRACTION / MAX_JOURNAL_GROWTH_POOL_MB / MIN_MEMORY_BUDGET_MB in the --memory-budget-mb text. The rendered help text is byte-identical (verified: 256 MiB, 5%, 1024 MB, 1024 MB minimum).

Forwarding / wiring mutation-safety (serve + runQwenServe)

  • [rc:3770626876] — Two new serve.test.ts cases boot with exactly ONE journal flag pinned and assert the other key is absent, so coupling the two independent conditional spreads can no longer pass silently.
  • [rc:3770626890] — The hot-remove test now shifts the host-memory pin (8 GiB → 16 GiB) between boot and the dynamic POST /workspaces attach, so the pool-parity assertion actually detects re-derivation of the budget at attach time (the correct boot-closure implementation never re-reads host memory and stays green).
  • [rc:3770626902] — Both pool-derivation tests (…into every bridge, …into secondary-workspace bridges too) now pin a 16 GiB host so the derived budget (8192 MB) differs from the --memory-budget-mb flag (4096 MB); dropping budgetMb from resolveDaemonMemoryBudget now changes the pool (409 vs 204 MB) and fails.
  • [rc:3770626912] — The shared-pool test now unregisters one provider at a time with a view assertion between, so a clear()-style unregister hook fails instead of passing a bulk end-state check.

Mutation probes

Five of the new/strengthened assertions were probe-verified against the exact production mutations they claim to catch (each mutation was applied, the targeted test run, then the file restored): the restore-failure cleanup delete, a clear()-style shared-pool unregister, a 64→65 step budget, the configured-vs-effective pool denominator, and coupling the two serve flag spreads — all five were caught.

Verification

  • npm run build — passed
  • npm run typecheck — passed (all workspaces, tsc --noEmit)
  • npm run lint — passed (repo-wide eslint . + integration-tests)
  • npx vitest run src/bridge.test.ts src/compactionEngine.test.ts src/daemon-memory-budget.test.ts (packages/acp-bridge) — 754 passed
  • npx vitest run src/journalGrowthPolicy.test.ts src/replayWindowLimits.test.ts (packages/acp-bridge) — 38 passed
  • npx vitest run src/commands/serve.test.ts src/serve/run-qwen-serve.test.ts (packages/cli) — 315 passed
  • npx prettier --write on all six changed files — no formatting changes needed
  • Five mutation probes (apply mutation → targeted test fails → restore) — all caught
  • Integration tests (CLI) — not run: this round touches only test files plus byte-identical serve --help text, nothing exercised solely through the bundled CLI; the CLI integration suite was also skipped in CI this round.
中文说明

Autofix 审查轮次总结 — PR #8905

本轮全部 19 条行内发现均为自动审查器提出的建议(Suggestion),全部 19 条已在单次提交(a4d0dabe78)中于代码层面解决。没有拒绝、推迟或升级任何发现。无基线冲突处理(--conflict false)。

空洞通过加固(bridge 增长测试)

  • [rc:3770626771] — 为三个仅依赖标记缺失的增长后会话断言补充了正向内容循环(returns granted headroom… 已在用的模式):refuses growth for a second session…(session 1)、accounts concurrent in-flight restores…(restore-a)、accounts growth across bridges…(session A)。被清空/重置的增长后 journal 不再能悄悄通过。
  • [rc:3770626783] — 在四处标记存在断言旁补充保留窗口断言(bridge.test.ts 的 refuses growth…charges a mid-restore…accounts concurrent…accounts growth across bridges…)。每处现在都钉住 cap 本应保留的确切事件(b-2/b-3 或 r-4/r-5),多丢一条 entry 的过度驱逐会令这些测试失败。
  • [rc:3770626786] — 新增 bridge 测试 releases granted growth when the mid-restore session fails:挂起一个 restore、让其 pending bus 超限增长并耗尽池,然后 reject 加载;随后超限的兄弟会话必须用归还的余量完成增长(无截断标记 + 正向内容断言)。覆盖了此前零覆盖的失败路径 pendingRestoreEvents.delete() 清理。

未钉住的 DEFAULT_MAX_JOURNAL_* 校准(8 处模式)

  • [rc:3770626793] — 在 keeps granting across repeated doublings… 中钉住 maxJournalBytes: 8 MiB,使"五次翻倍到硬顶"的算术不再依赖未钉住的默认值。
  • [rc:3770626805] — 在 refuses growth for a second session…charges a mid-restore session…accounts concurrent in-flight restores…accounts growth across bridges…(共享 opts)以及 does not mischarge… 的 bridgeA 自身 options 上钉住 8 MiB 字节基线(刻意不放入 sharedGrowthOpts,以免覆盖 bridgeB 不同的 16 MiB 基线)。
  • [rc:3770626817] — 在 returns granted headroom… 中钉住字节基线,使"池 = 恰好一个基线"在任何默认值下都成立。
  • [rc:3770626826] — 在七个把字节 cap 断言为默认值精确倍数的 compactionEngine 增长测试中钉住 maxJournalBytes: 8 MiBgrows the caps…passes the current caps…treats a non-growing or malformed grant…refuses a grant that grows bytes but shrinks…does not ask for growth… turn boundarystamps the truncation marker…keeps grown caps across turn boundaries)。
  • [rc:3770626831] — 在 grows the caps on a byte-cap breach… 中钉住 maxJournalEvents(describe 级 ENTRY_BASELINE = 10_000);增长后 cap 的断言改由钉住值推导(ENTRY_BASELINE * 2)。
  • [rc:3770626836] — 在四个 fixture 耦合测试(refuses a grant that cannot retain more…evicts down to the raised cap…walks through intermediate grants…never charges growth…)的构造参数中同时钉住条目与字节基线;所有 advisor fixture 与增长后 cap 断言均由 ENTRY_BASELINE 推导。
  • [rc:3770626841] — 在 clears the refusal throttle when a re-ask is granted 中钉住 maxJournalBytes: 8 MiB,使其 16 MiB grant fixture 在任何默认值下都有效。
  • [rc:3770626846] — bootstrap daemon-status 测试改用 DEFAULT_MAX_JOURNAL_EVENTS / DEFAULT_MAX_JOURNAL_BYTES 取代裸字面量,与同一代码块中其他推导字段保持一致。

结构性 / 覆盖缺口

  • [rc:3770626851] — 把重复的约 20 行 daemon 级聚合器假实现抽取为测试本地的 makeGrowthAggregator() 辅助函数(每次调用返回新实例);两个多 bridge 测试现在通过同一定义模拟 runQwenServe 的聚合器契约。
  • [rc:3770626856] — 新增 compactionEngine 测试覆盖增长遍历的第三个出口:advisor 持续授予"增长但不改善保留"的 cap 直至耗尽 64 步预算;断言 advisor 恰好被调用 64 次、cap 回滚到基线、且第二次立即超限被节流而不再询问。
  • [rc:3770626860] — 新增 journalGrowthPoolMb 用例,构造被压低的预算(4096 MB 主机上传 budgetMb: 8192):钉住池以 effectiveBudgetMb 为分母(204 MB,而非 409 MB)。
  • [rc:3770626865]qwen serve --help 现在插值导出常量而非硬编码增长参数:JOURNAL_GROWTH_HARD_CAP_BYTES(单会话硬顶),以及 --memory-budget-mb 文本中的 JOURNAL_GROWTH_POOL_FRACTION / MAX_JOURNAL_GROWTH_POOL_MB / MIN_MEMORY_BUDGET_MB。渲染出的帮助文本逐字节一致(已验证:256 MiB、5%、1024 MB、1024 MB 最低值)。

转发 / 接线的变异安全性(serve + runQwenServe)

  • [rc:3770626876] — 新增两个 serve.test.ts 用例,只钉住一个 journal flag 启动并断言另一个键不存在,使"把两个独立条件展开耦合"的重构不再能悄悄通过。
  • [rc:3770626890] — hot-remove 测试现在在启动与动态 POST /workspaces 挂载之间换宿主内存钉住值(8 GiB → 16 GiB),使池一致性断言真正能检测到挂载时重新推导预算的回归(正确的"启动期闭包"实现不会重读宿主内存,保持绿色)。
  • [rc:3770626902] — 两个池推导测试(…into every bridge…into secondary-workspace bridges too)现在钉住 16 GiB 宿主,使推导预算(8192 MB)与 --memory-budget-mb flag(4096 MB)不同;丢弃 resolveDaemonMemoryBudgetbudgetMb 现在会改变池(409 vs 204 MB)并导致失败。
  • [rc:3770626912] — 共享池测试现在逐个注销 provider 并在中间断言视图,使 clear() 式的注销钩子失败,而不是通过批量终态检查。

变异探针

对五个新增/加固断言所声称捕获的确切生产变异做了探针验证(逐一应用变异、运行目标测试、再还原文件):restore 失败路径的清理 delete、clear() 式共享池注销、64→65 步数预算、池分母取 configured 而非 effective、耦合 serve 两个 flag 展开——五者全部被捕获。

验证

  • npm run build — 通过
  • npm run typecheck — 通过(全部 workspace,tsc --noEmit
  • npm run lint — 通过(仓库级 eslint . + integration-tests)
  • npx vitest run src/bridge.test.ts src/compactionEngine.test.ts src/daemon-memory-budget.test.ts(packages/acp-bridge)— 754 通过
  • npx vitest run src/journalGrowthPolicy.test.ts src/replayWindowLimits.test.ts(packages/acp-bridge)— 38 通过
  • npx vitest run src/commands/serve.test.ts src/serve/run-qwen-serve.test.ts(packages/cli)— 315 通过
  • 对六个改动文件运行 npx prettier --write — 无需任何格式调整
  • 五个变异探针(应用变异 → 目标测试失败 → 还原)— 全部捕获
  • 集成测试(CLI)— 未运行:本轮只改测试文件与逐字节一致的 serve --help 文本,没有仅经打包 CLI 行使的行为;本轮 CI 中 CLI 集成套件同样被跳过。

Base-conflict check · 基分支冲突检查: no conflict with main. · 与 main 无冲突。

Re-review when you have a moment. After round 100 this bot stops and leaves the PR for a human. · 有空请复审;第 100 轮后本 bot 停止并将 PR 交给人工。


🧠 Handled by Qwen Code · model/模型 qwen3.8-max

doudouOUC
doudouOUC previously approved these changes Aug 13, 2026

@doudouOUC doudouOUC left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Reviewed current head a4d0dab. No blocking issues found.\n\nI re-verified the previously unresolved Critical concerns against the current code: one daemon-wide pool is shared across all runtime bridge construction paths; each live or restoring session is charged against its own baseline; intermediate grants are walked until retention actually improves and otherwise rolled back; refusal throttling uses a monotonic clock; proportional event limits stay within the safe-integer range; and daemon status plus SDK types distinguish baseline limits from per-session effective caps.\n\nIndependent verification:\n- acp-bridge targeted suites: bridge, compaction engine, memory-budget, growth-policy, and replay-window tests passed\n- CLI targeted suites: serve command, run-qwen-serve, and daemon-status — 366 tests passed\n- changed-file ESLint and Prettier checks passed\n- acp-bridge and TypeScript SDK typechecks passed\n\nThe head remained unchanged throughout review and the required CI jobs on this commit are green.

@qwen-code-ci-bot qwen-code-ci-bot left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

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): You are review agent reverse-audit — Reverse audit agen...: none — all checks above completed within budget.; PR #8905 makes the daemon's live-journal caps adaptive: w...: none — all planned checks completed within budget.; You are review agent reverse-audit — Reverse audit agen...: none — all checks above completed within budget.; chunk 14: none — all checks I intended completed within budget.; PR #8905 makes the daemon's live-journal caps adaptive: w...: none — all planned checks completed within the tool budget..

Test Plan (not a blocker): 1221 tests pass — this review observed 1356, 1511, 494, 3289, 551 passed.

中文说明

未审查:build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally。

未探索到全部深度(达到工具调用预算):You are review agent reverse-audit — Reverse audit agen...:none — all checks above completed within budget.;PR #8905 makes the daemon's live-journal caps adaptive: w...:none — all planned checks completed within budget.;You are review agent reverse-audit — Reverse audit agen...:none — all checks above completed within budget.;chunk 14:none — all checks I intended completed within budget.;PR #8905 makes the daemon's live-journal caps adaptive: w...:none — all planned checks completed within the tool budget.

Test Plan(非阻断):1221 tests pass — this review observed 1356, 1511, 494, 3289, 551 passed

— qwen3.8-max via Qwen Code /review (v0.21.10)

Comment on lines +822 to +824
...(argv['max-journal-events'] !== undefined
? { maxJournalEvents: argv['max-journal-events'] }
: {}),

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[Critical] R6-1: A bare --max-journal-events / --max-journal-bytes (flag present, no value) is silently treated as "not pinned" — yargs yields undefined for a valueless type: 'number' option, so the pin never reaches runQwenServe and adaptive growth stays enabled, contradicting the new help text ("Pinning this flag (or --max-journal-bytes) disables adaptive growth") with no error or warning. — Failure scenario: probe-confirmed against this repo's yargs 17.7.2: parseSync('--max-journal-events') yields undefined with zero parse errors (also when followed by another flag, both flags bare, or realistic --no-web invocations); the fast path falls back to yargs for the valueless number flag, so this is the production path. With both options undefined, serveJournalGrowthPoolMb skips both pin gates and wires the derived growth pool into every bridge — the operator expected fixed caps with growth off, but growth stays enabled, with no signal at any layer (observable only after the fact via GET /daemon/status). Pre-diff, the yargs default: made a bare flag resolve to the default value, so flag presence had no behavioral meaning; this diff introduces the silent drop by keying growth-disable on argv presence with no nargs/demandOption guard. (--max-journal-events= with = parses to 0 and fails loudly in normalization — the silent path is specifically the bare flag without =.) Probe flip: adding nargs: 1 to both options turns every bare case into "Not enough arguments following: max-journal-events" while leaving valid invocations unchanged.

Suggested fix — add nargs: 1 to both option declarations so yargs fails loudly instead of silently unpining:

.option('max-journal-events', {
  type: 'number',
  nargs: 1,
  // ...rest unchanged
})
// and the same on 'max-journal-bytes'
中文说明

[严重] R6-1:裸传 --max-journal-events / --max-journal-bytes(有 flag、无值)会被静默当作"未钉住"——yargs 对无值的 type: 'number' 选项返回 undefined,因此 pin 永远不会传到 runQwenServe,自适应增长保持启用,这与新增的帮助文本("Pinning this flag (or --max-journal-bytes) disables adaptive growth")矛盾,且没有任何报错或警告。— 失败场景:已用本仓库的 yargs 17.7.2 probe 确认:parseSync('--max-journal-events') 返回 undefined 且零解析错误(后接其他 flag、两个 flag 都裸传、以及真实的 --no-web 调用均相同);fast-path 对无值 number flag 会回落到 yargs,因此这就是生产路径。两个选项都为 undefined 时,serveJournalGrowthPoolMb 跳过两个 pin 判断,把派生的增长池接入每个 bridge——operator 期望固定上限并关闭增长,但增长仍然启用,任何一层都没有信号(只能事后通过 GET /daemon/status 观察到)。改动前 yargs 的 default: 使裸 flag 解析为默认值,flag 的出现没有行为含义;本次改动把"禁用增长"键控在 argv 是否出现上、又没有 nargs/demandOption 保护,从而引入了这个静默丢弃。(--max-journal-events=(带 =)会解析为 0 并在 normalization 中大声失败——静默路径专指不带 = 的裸 flag。)Probe 翻转:给两个选项加上 nargs: 1 后,所有裸传场景都会报 "Not enough arguments following: max-journal-events",合法调用不受影响。

修复建议:在两个选项声明处加上 nargs: 1,让 yargs 大声报错而不是静默取消钉住。

— qwen3.8-max via Qwen Code /review (v0.21.10)

Comment on lines +5348 to +5351
// Pin the retained window too: marker presence alone also passes on
// an over-eviction that drops one extra entry.
expect(JSON.stringify(snap.liveJournal)).toContain('r-4');
expect(JSON.stringify(snap.liveJournal)).toContain('r-5');

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[Suggestion] R6-2: The retained-window pin in 'charges a mid-restore session for growth granted before registration' is weaker than the sibling tests' pins: it pins only r-4/r-5 of the expected 4-entry retained window (r-2, r-3, r-4, r-5), so it cannot catch an over-eviction past one extra entry. — Failure scenario: probe-confirmed: a regression that resets the effective cap toward the 2-entry baseline on a denied grant (retaining only r-4, r-5) passes the test as written, even though it violates the invariant the test's own comment states ("the second breach must observe the grown cap"). Adding the r-2/r-3 pins makes the same regression fail. No other test in this block covers "grown caps survive a denied grant": tests 3/6/9 deny sessions that never grew, and test 2 never hits a denial.

Suggested change
// Pin the retained window too: marker presence alone also passes on
// an over-eviction that drops one extra entry.
expect(JSON.stringify(snap.liveJournal)).toContain('r-4');
expect(JSON.stringify(snap.liveJournal)).toContain('r-5');
// Pin the retained window too: marker presence alone also passes on
// an over-eviction that drops one extra entry.
expect(JSON.stringify(snap.liveJournal)).toContain('r-2');
expect(JSON.stringify(snap.liveJournal)).toContain('r-3');
expect(JSON.stringify(snap.liveJournal)).toContain('r-4');
expect(JSON.stringify(snap.liveJournal)).toContain('r-5');
中文说明

[建议] R6-2:'charges a mid-restore session for growth granted before registration' 中的保留窗口钉扎弱于兄弟测试:期望的保留窗口是 4 条(r-2、r-3、r-4、r-5),但只钉了 r-4/r-5,因此超过"多丢一条"的过度驱逐无法被捕获。— 失败场景:probe 确认:一个在拒绝授权时把有效上限重置回 2 条基线的回归(只保留 r-4、r-5)在当前写法下能通过测试,尽管它违反了该测试自己的注释所声明的不变量("the second breach must observe the grown cap")。补上 r-2/r-3 钉扎后,同一回归即会失败。本块中没有其他测试覆盖"增长后的上限在被拒绝后仍然有效":测试 3/6/9 拒绝的是从未增长的会话,测试 2 不会触发拒绝。

— qwen3.8-max via Qwen Code /review (v0.21.10)

@wenshao

wenshao commented Aug 13, 2026

Copy link
Copy Markdown
Collaborator Author

@qwen-code /triage

@qwen-code-ci-bot

qwen-code-ci-bot commented Aug 13, 2026

Copy link
Copy Markdown
Collaborator

Sandboxed verification: ✅ passed — merge-ready (agent verdict) - workflow run

Ran the PR in an isolated, token-free container: A/B against the base build, mock-free harness assertions, targeted gates. Advisory evidence for human reviewers — not a review, an approval, or a CI check.

Scripted assertions: 94 passed · 0 failed · 94 total

中文 — 判定:✅ 通过 · 可合入(agent 判定)

沙箱验证在隔离、无凭证的容器中执行了该 PR 的代码(与 base 构建 A/B 对照、无 mock harness 断言、定向门禁)。仅作为评审证据,不构成评审、批准或 CI 检查

脚本断言:94 通过 · 0 失败 · 94 总计

Verification report

PR 8905 — feat(serve): adaptively grow live-journal caps before truncating mid-turn replay

Verdict: merge-ready — 94/94 scripted assertions passed (35 A/B cells, 43 delta probes, 11 mutation-matrix checks, 5 gate/typecheck checks; 0 unexpected failures). Follow-up round: previous verdict at head 9613be1 was merge-ready; two commits landed since (72f07a5 per-session-baseline accounting + intermediate-grant walk, a4d0dab test hardening + help figures from constants). Every carried measurement was rebuilt and re-run at the new head — nothing was diffed from the old report. Verified head: a4d0dabe786f1b2b73f2e608f0ac4e63ddf6b178 (merge-ref base tip 4a281f2efcde865b578bbe09e46f1e311112015a).

中文摘要
  • 结论merge-ready(第二轮)。94/94 脚本断言通过,0 意外失败。上一轮在 head 9613be1 已判 merge-ready;此后新增两个提交(按会话基线记账 + 中间授权步进与回滚;测试加固 + help 文案数字改由常量推导)。所有沿用测量均在新 head 上重建重跑。
  • A/B 结论(真实编译产物,引擎级中途快照,见证图 01-ab-base-vs-head.png):60k×200B 洪峰下 base 保留 10 000 并盖 history_truncated 标记;head 经 8→16→32→64 MiB 三次授权保留全部 60 000;head 未配置池时与 base 逐字节一致。300k×400B + 32 MiB 小池下 head 增长到恰好 baseline+pool(40 MiB/50k)后回落驱逐、以上涨后上限盖标记。两个 10 MiB 事件 + 64 MiB 池:新增的中间步进授权(8→16 不足 → 32 接受)使 head 保留两条事件(base 仅 1 条)——这是本轮新提交带来的有意行为变化。两个 300 MiB 事件:步进无法改善保留 → 整体回滚、按原始上限盖标记、池不被计费(同池兄弟会话随即获得完整额度)。
  • 第二轮新守卫探针(见证图 02-delta-probes-guards.png):跨 bridge 按会话自身基线记账(含可区分"单一共享基线"缺陷的判例)、64 步步进预算精确终止并回滚、拒绝节流恰在 10 s 后释放、回合边界不询问顾问且重置节流、增长上限跨回合保留;抛异常/非法授权(非安全整数、不升反降)一律降级为普通驱逐。
  • 变异矩阵(见证图 03-mutation-matrix.png):5/5 变异被杀死——移除增长调用(19 个增长测试中的 17 个)、移除回滚+节流记录(6 个,恰为回滚语义测试)、单一共享基线(2 个,恰为按会话基线测试)、移除 runQwenServe 池装配(4 个装配测试)、仅移除回合边界条件(恰好杀死边界跳过测试,裁决 M1 的幸存)。M1 的两个幸存均为结构性合法(断言"无增长"回退路径,对整体移除不敏感),其中边界跳过测试已被细粒度变异 M5 单独钉死;未变异对照全绿。
  • 门禁:acp-bridge 全量 28 文件 / 1364 通过;cli serve 面 7 文件 / 1464 通过;acp-bridge 与 cli 类型检查干净(种入类型错误验证门禁活性后被报告)。
  • Findings:无阻塞。纠偏(承上轮):PR 正文(中英)仍称池 "clamp 到 [32, 1024] MB",新 head 重测包络仍为 {0} ∪ [51, 1024] MiB(32 不可达)——docs 与 help 文案准确,仅 PR 描述需修正(见证图 04-pool-envelope-and-help.png)。
  • 未覆盖:逐 commit 归因(浅克隆,11 个提交仅 1 个本地可达);真实 ACP 子进程的全 daemon E2E;TUI/Web 对增长上限的展示;Windows/macOS;bundle 闭包 fast-path 套件与 sdk normalizer 套件(CI 覆盖)。

Previous-finding status (follow-up round)

# Finding (round 1, head 9613be1) Severity Status at new head a4d0dab
1 Correction: PR body claims pool "clamped to [32, 1024] MB"; measured envelope {0} ∪ [51, 1024] MiB; docs correct, description-only nit Stands. Envelope re-measured at the new head (P6, 43-probe harness + 04-pool-envelope-and-help.png): identical reachable set {0} ∪ [51, 1024], 32 unreachable across the entire valid flag range. The PR body (both languages) still says [32, 1024]; docs and the new constant-derived help text are accurate.
2 Informational: refusal throttle re-asks during >20 s wall-clock floods (by design, monotonic clock) info Stands (by design). Re-run with an injected deterministic clock: scenario B now shows exactly 4 advisor calls (3 grants + 1 refusal, no wall-clock re-asks); throttle release pinned at exactly 10 000 ms by probe P2.
3 Informational: PR body suite counts stale vs landed merge base info Stands. New head counts: acp-bridge 28 files / 1364 tests (was 1348 at round-1 head; body says 27/1221); cli serve surface 7 files / 1464 (body says 245 for run-qwen-serve.test.ts, now 255).
4 M1's two survivors (assert the no-growth path; legitimate) note Carried, one escalated. Matrix rebuilt for the new head: M1 (growth call removed) is killed by 17 of the 19 growth tests. The two survivors are the same structural shape as round 1 — falls back to eviction when the advisor refuses and does not ask for growth when the breaching append is a turn boundary assert no-growth behavior that feature removal trivially satisfies. The boundary one was escalated to a finer mutant (M5, boundary condition removed only) and is killed by exactly its test — pinned, not vacuous (see Mutation matrix).
5 Not-covered list (per-commit attribution, real-ACP-child E2E, TUI/web rendering, Win/macOS, bundle fast-path) Stands — re-listed under Not covered below.

Central claim + A/B

Central claim: when an in-flight turn outgrows the per-session live-journal caps, the daemon grows that session's caps (doubling toward a 256 MiB hard cap, within a daemon-wide pool derived from the memory budget) and retains more of the turn for mid-turn replay; with no pool configured, behavior is exactly the pre-change fixed-cap eviction. Round-2 delta: growth is accounted per session's OWN baseline across bridges sharing one pool, and the engine walks intermediate grants on a breach — rolling back and counting a refusal when no reachable grant retains more.

Harness ab-journal-growth.mjs drives the real compiled TurnBoundaryCompactionEngine from the head build (real createJournalGrowthPolicy, real JOURNAL_GROWTH_HARD_CAP_BYTES, injected deterministic clock) and from a base build at HEAD^1 (rebuilt in a scratch worktree — see Methodology), flooding an in-flight turn with no turn_complete so the snapshot is exactly the mid-turn reload view. Witness: 01-ab-base-vs-head.png. Base cells encode predictions — base truncating as predicted is a PASSING assertion.

Scenario Build retained truncated marker caps after advisor
A: 60k × 200 B (pool 409 MiB = 16 GiB-host derived) base 10 000 50 000 YES (8 MiB/10k) fixed
head (growth) 60 000 no 64 MiB / 80k 3 calls, 3 grants (8→16→32→64)
head (no pool) 10 000 50 000 YES — field-identical to base fixed
B: 300k × 400 B, 32 MiB pool base 10 000 290 000 YES fixed
head (growth) 50 000 250 000 YES, stamped at grown 40 MiB/50k 40 MiB / 50k 4 calls (grants 16/32/40, refusal at avail=0)
head (no pool) 10 000 290 000 YES — field-identical to base fixed
C: two 10 MiB events, 64 MiB pool base 1 1 YES fixed
head (growth) 2 no 32 MiB / 40k 2 calls (tentative 16, accepted 32)
D: two 300 MiB events, 64 MiB pool base 1 1 YES fixed
head (growth) 1 1 YES, stamped at original 8 MiB/10k rolled back to 8 MiB 5 calls (16/32/64/72 granted, refusal at avail=0)

Reading the cells: A proves the central claim (6× retention, no marker). B proves graceful degradation — the final grant lands exactly at baseline+pool (40 MiB) and eviction resumes with the marker stamped at the grown caps. C is the round-2 walk working as the new commit intends: the 16 MiB intermediate grant alone retains nothing extra, so the walk continues and the 32 MiB grant retains both events (round 1 refused here — deliberate behavior change, now covered by walks through intermediate grants…). D proves the walk's fail-safe: doublings plus a pool-limited partial (72 MiB) cannot retain more than eviction keeps, so the whole walk rolls back, the marker is stamped at the original caps, the pool is never charged (a sibling ask immediately afterwards received the full 64 MiB headroom), and retained/truncated counts match base. Both head (no pool) arms are field-identical to base on every marker field — the "byte-for-byte pre-change behavior without a pool" claim holds at the engine level. Scripted: 35/35.

Round-2 delta probes (43/43, witness 02-delta-probes-guards.png)

Probe Guard under test Result
P1 Per-session baseline accounting (the 72f07a5 core): two bridges (baselines 10k/8 MiB and 5k/4 MiB) share one 10 MiB pool. b1 grows 8→16 (charged 8); b2 gets the partial grant 4→6 (charged 2, entries scaled against its OWN 4 MiB baseline → 7 500); b1's re-ask is refused at exactly pool exhaustion. Discriminator: a single-shared-baseline mutant charges max(0, 6−8)=0 for b2 and would grant b1 16→18 MiB here — this assertion kills mutant M3 independently pass
P2 Step budget + rollback: advisor granting +1 byte hits exactly 64 calls, caps roll back to baseline, plain eviction runs; no re-ask before 10 000 ms, re-ask resumes at exactly 10 000 ms pass
P3 Throwing advisor → degrades to fixed-cap eviction, never propagates pass
P4 Malformed grants rejected whole (non-safe-integer bytes; events below current; bytes not strictly larger) → caps unchanged, plain eviction (3 shapes) pass
P5 Turn-boundary skip: a breaching turn_complete append never asks the advisor and the journal is discarded (no pool charged for a journal about to vanish); grown caps persist across the boundary; the refusal throttle resets at a turn boundary pass
P6 Pool envelope re-measurement (carry-over Correction, below) pass
P7 serve --help derives its figures from the exported constants (256 MiB hard cap, 5% fraction, 1024 MB cap, 1024 MB minimum budget, 10 000 / 8 388 608 defaults) pass

Corrections

  1. (carried over, stands) The PR body's pool envelope is wrong. Both the English and 中文 bodies and the Reviewer Test Plan state the pool is "clamped to [32, 1024] MB". Re-measured at the new head (print-envelope.mjs, witness 04-pool-envelope-and-help.png): journalGrowthPoolMb = min(floor(5% × effectiveBudgetMb), 1024, childPoolMb), 0 on insufficientMemory. Host sweep: 512/1024 MB → 0 (disabled); 2048 → 51; 4096 → 102; 8192 → 204; 16384 → 409; 32768 → 819; flag max → 1024. A sweep of the entire valid flag range [1024, 1048576] found 32 unreachable (it would require an effective budget of ~640–659 MB, below the 1024 MB minimum where growth is disabled instead). Reachable set {0} ∪ [51, 1024] MiB. docs/ and the new constant-derived help text are accurate; only the PR description needs the fix. Severity: nit, description-only — no behavioral consequence.

Findings

No blocking findings, and no new findings this round. Notes:

  • The round-2 commits changed one user-relevant behavior on purpose and it is covered: a breach whose first doubling does not yet retain an extra entry no longer counts as an immediate refusal — the engine walks intermediate grants within the same breach (scenario C: 10 MiB + 10 MiB now retains both at a 32 MiB grant; round 1 refused and evicted). The fail-safe side (scenario D: nothing reachable helps → full rollback, refusal, no pool charge) is equally pinned, by both the A/B cell and mutant M2.
  • The PR body's suite counts remain stale (see status table row 3) — not a code issue.

Targeted gates (pristine, pre-mutation)

  • packages/acp-bridge: npx vitest run28 files, 1364 passed, 0 failed (logs/gate-acp-bridge-pristine.log). Includes the bridge-level growth tests: grows a breaching session from the pool instead of truncating, refuses growth for a second session once the first consumes the pool, charges a mid-restore session for growth granted before registration, releases granted growth when the mid-restore session fails, accounts concurrent in-flight restores against the shared pool.
  • packages/cli serve surface (7 files: serve.test, run-qwen-serve.test, daemon-status.test, server.test, multi-workspace-sessions.test, workspace-qualified-rest.test, routes/workspace-qualified-extensions.test) → 1464 passed, 0 failed (logs/gate-cli-serve-pristine.log).
  • tsc --noEmit clean for both packages/acp-bridge and packages/cli; liveness proven by planting a type error in journalGrowthPolicy.ts that was reported (TS2322) and then removed with sha256 verification (logs/typecheck-liveness.log).

Mutation matrix (vacuity, witness 03-mutation-matrix.png)

Each mutant was applied as an exact-string scratch edit, the named suite run against it, and the file restored from git with sha256 verification. Positive control: unmutated suites green (134 passed across the two engine/policy files; 255 in run-qwen-serve.test.ts).

Mutant Guard Suite Result — killed by
M1 growth call in appendLiveJournal compactionEngine.test.ts 17 of the 19 growth tests — e.g. grows the caps instead of evicting… failed on journalLimits() expected {maxBytes: 33554432, maxEvents: 8} received baseline {8388608, 2} (behavioral mismatch, not import breakage); two survivors, adjudicated below
M2 (round-2 guard) rollback + refusal stamp after a fruitless walk compactionEngine.test.ts 6 tests — exactly the rollback/throttle set: rolls back and records a refusal when the walk exhausts its step budget, never charges growth when no reachable cap can retain more, refuses a grant that cannot retain more than eviction already keeps, throttles re-asks after a refusal until the interval elapses, degrades to eviction when the advisor throws, passes the current (already grown) caps to the advisor
M3 (round-2 guard) per-session baseline → single shared opts.baselineBytes journalGrowthPolicy.test.ts 2 tests — exactly the per-session-baseline tests added by 72f07a5: charges a grown session by its own baseline, not the policy baseline, does not charge an untouched session that started at a larger baseline; independently discriminated by probe P1
M4 runQwenServe → bridge pool wiring (primary site; pattern occurs 2×, first mutated) run-qwen-serve.test.ts 4 testsderives an adaptive journal growth pool into every bridge, …into secondary-workspace bridges too, wires every bridge to one shared daemon-wide growth-pool view, adds, advertises, and hot-removes a dynamic workspace runtime
M5 turn-boundary condition only (!TURN_BOUNDARY_TYPES.has(event.type)true), growth otherwise intact — the finer escalation of M1's boundary survivor compactionEngine.test.ts exactly 1 test, 1 failed | 122 passeddoes not ask for growth when the breaching append is a turn boundary
ctrl none all three green (counts above)

Attribution is clean: every mutant was killed by exactly the tests the commits say pin that guard. Survivor adjudication (M1's two): both assert the no-growth side of the engine and are structurally insensitive to removing the growth call entirely — falls back to eviction when the advisor refuses (eviction happens with or without the call) and does not ask for growth when the breaching append is a turn boundary (no ask happens at all). Neither is a coverage gap: the boundary test kills the directional mutant M5 cleanly, and the refusal-fallback test runs a real refusal scenario against the live walk in the control while the refusal-side state changes (rollback, throttle stamp) are pinned by M2's kill set. No dead-code survivors.

Not covered

  • Per-commit attribution: the checkout is depth 2 — git rev-list HEAD^1..HEAD^2 returns 1 (a plausible small number at the shallow boundary) while the metadata lists 11 commits; the round-1 head 9613be1 and 72f07a5 are not object-reachable, so the round-1→round-2 delta is known from commit messages and the aggregate diff, not from a direct 9613be1..a4d0dab diff. Verified the aggregate HEAD^1..HEAD diff.
  • Full-daemon E2E with a real ACP child under growth pressure: bridge-level accounting is covered by the repo's own bridge tests (green in the gate) and the engine+policy harnesses drove the real compiled modules; no qwen --acp child was spawned.
  • TUI/web rendering of grown caps (maxJournalEvents/maxJournalBytes on session diagnostics, journalGrowth in status): types, status assembly, and SDK type additions are covered by tests + typecheck; no client was exercised. The sdk normalizer suite was not re-run here (CI covers it).
  • Windows/macOS (Linux container); npm run bundle fast-path/bundle-closure suite — CI covers these. Repo-wide lint/format not run; targeted typecheck + the two suite gates above were run.
  • The A/B harness models the bridge's advisor seam faithfully (requester accounted at its live cap, siblings at theirs, per-session baselines) but is single/multi-engine at the engine+policy level, not a live HTTP daemon; the wiring half is pinned by M4 and the wiring tests instead.

Methodology

Environment: CI verify container (node:22-bookworm), merge-ref checkout at depth 2; npm ci + npm run build pre-ran at HEAD (dist verified fresh: maybeGrowJournalLimits present in dist/compactionEngine.js). Base arm: git worktree add tmp/base-tree HEAD^1; package.json/package-lock.json/packages/core are byte-identical across the PR (git diff HEAD^1..HEAD empty for all three), so the root node_modules is a clean control; per-package node_modules (version-conflict copies) were symlinked from the head tree into the base worktree — without them the base rebuild resolves ignore/ajv against root copies and fails with typing errors, the same class as the pre-existing @lydell/node-pty TS7016 in core/src/services/shellExecutionService.ts that reproduces identically on base and is unrelated to this PR. With the links in place the base acp-bridge emitted cleanly; realpath check: @qwen-code/qwen-code-core resolves to /__w/qwen-code/qwen-code/packages/core (head tree) and the exercised engine modules import only relative siblings, so no confound. The base arm was removed (git worktree remove --force) after the A/B capture and the tree verified pristine. Harnesses (lib.mjs, ab-journal-growth.mjs, probe-delta.mjs, print-envelope.mjs, run-mutations.sh) import only compiled dist/ output and use the engine's injected now seam for deterministic clocks — no mocks of code under test; raw logs in logs/ (gate outputs, per-mutant vitest runs, typecheck liveness, sha256 records), captures in evidence/ (01-ab-base-vs-head.png, 02-delta-probes-guards.png, 03-mutation-matrix.png, 04-pool-envelope-and-help.png).

Evidence images

01-ab-base-vs-head

02-delta-probes-guards

03-mutation-matrix

04-pool-envelope-and-help

Harness scripts and raw logs are in the workflow run artifacts (7-day retention).

Qwen Code · sandboxed verification

@wenshao
wenshao enabled auto-merge August 13, 2026 01:43
@qwen-code-dev-bot

Copy link
Copy Markdown
Collaborator

🤖 Addressed the latest review feedback (round 6/100). What changed, and what I pushed back on: · 已处理最新评审反馈(第 6/100 轮)。改动内容与我反驳保留之处如下:

Review feedback addressed — round 6

Feedback points and dispositions

R6-1 [Critical] — bare --max-journal-events / --max-journal-bytes silently unpins (rc:3771531140)

Disposition: fixed (resolved in code).

Verified the finding against this branch: both options are declared type: 'number' with no default (deliberately, so unpinned boots don't look pinned), and yargs 17 yields undefined for a valueless number option with no parse error. The handler keys the pin — and therefore "adaptive growth disabled" — on argv['max-journal-events'] !== undefined, so a bare flag silently left growth enabled, contradicting the help text. The serve fast path does not hide this either: its readOptionValue returns null for a valueless flag and falls back to the yargs path, so the silent drop is the production path.

Minimal fix applied exactly as suggested: added nargs: 1 to both option declarations in packages/cli/src/commands/serve.ts, so yargs now fails loudly with "Not enough arguments following: max-journal-events/bytes" for every bare form. Added a regression test in packages/cli/src/commands/serve.test.ts covering all four bare shapes (single bare flag, trailing bare flag, bare flag followed by another flag, both flags bare) plus a check that the --flag=value spellings still parse with nargs: 1 in place. The fast-path suite, which cross-checks the fast-path mirror against the yargs option surface, stays green.

R6-2 [Suggestion] — weak retained-window pin in 'charges a mid-restore session for growth granted before registration' (rc:3771531143)

Disposition: implemented (resolved in code).

Applied the suggested change verbatim: the expected retained window after the denied second grant is 4 entries (r-2, r-3, r-4, r-5 — the grown cap of 2×2), but the test only pinned r-4/r-5, so a regression resetting the effective cap to the 2-entry baseline on a denied grant would have passed. The test now pins all four entries; it passes, confirming the grown cap survives the denial.

Review-level CHANGES_REQUESTED — "Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally"

Disposition: addressed by running the suite locally; one environment-specific failure documented below.

After npm run build && npm run bundle, ran npm run test:integration:cli:sandbox:none: 195 passed, 18 skipped, 1 failed. The single failure is cli/qwen-config-dir.test.ts ("1d: CLI functions normally when QWEN_HOME is not set") with EACCES: permission denied, mkdir '/home/github-runner/.qwen'. This runner's home directory is owned by root while the tests run as uid 1000, so the real-home fallback cannot be created here. The failing source (packages/cli/src/utils/languageUtils.ts) and the test itself have a zero-line diff against origin/main, so the failure is independent of this PR and reproduces identically on the base branch. All serve-related integration tests in the suite passed.

Other notes

  • No conflict resolution was needed (--conflict false); no merge of origin/main was performed.
  • Both inline findings are resolved in code; no findings were declined, deferred, or escalated this round. The Deferred non-Critical feedback section was empty.

Verification

  • npm run build — passed
  • npm run typecheck — passed
  • npm run lint — passed
  • npx vitest run src/commands/serve.test.ts (packages/cli) — 61 passed (includes the new valueless-flag regression test)
  • npx vitest run src/serve/fast-path.test.ts (packages/cli) — 86 passed
  • npx vitest run src/serve src/commands/serve.test.ts (packages/cli, focused) — 149 files, 4413 passed | 1 skipped
  • npx vitest run (packages/acp-bridge, all) — 28 files, 1356 passed
  • npm run bundle — passed
  • npm run test:integration:cli:sandbox:none — 195 passed | 18 skipped | 1 failed (environment-specific EACCES on /home/github-runner/.qwen, detailed above; unrelated to this PR)
中文说明

已处理的评审反馈 — 第 6 轮

反馈条目及处理结论

R6-1 [Critical] — 裸传 --max-journal-events / --max-journal-bytes 会静默取消钉住(rc:3771531140)

处理结论:已修复(已在代码中解决)。

已在本分支上核实该问题:两个选项都声明为 type: 'number' 且没有默认值(这是刻意为之,避免未钉住的启动看起来像被钉住),而 yargs 17 对无值的 number 选项会返回 undefined 且不报任何解析错误。handler 以 argv['max-journal-events'] !== undefined 作为钉住(即"禁用自适应增长")的依据,因此裸传 flag 会静默地让增长保持启用,与帮助文本矛盾。serve fast path 也没有掩盖这个问题:其 readOptionValue 对无值 flag 返回 null 并回落到 yargs 路径,因此这条静默丢弃正是生产路径。

按建议原样施加了最小修复:在 packages/cli/src/commands/serve.ts 的两个选项声明处加上 nargs: 1,使 yargs 对所有裸传形式都大声报出 "Not enough arguments following: max-journal-events/bytes"。并在 packages/cli/src/commands/serve.test.ts 中新增回归测试,覆盖全部四种裸传形态(单个裸 flag、末尾裸 flag、裸 flag 后接其他 flag、两个 flag 都裸传),同时验证加上 nargs: 1--flag=value 写法仍正常解析。fast-path 测试套件(将 fast-path 镜像与 yargs 选项面交叉校验)保持全绿。

R6-2 [Suggestion] — 'charges a mid-restore session for growth granted before registration' 中保留窗口钉扎过弱(rc:3771531143)

处理结论:已实现(已在代码中解决)。

按建议原样应用:第二次授权被拒绝后,期望的保留窗口是 4 条(r-2、r-3、r-4、r-5 —— 增长后的上限为 2×2),但原测试只钉了 r-4/r-5,因此一个在拒绝授权时把有效上限重置回 2 条基线的回归也能通过。现在测试钉住全部 4 条,且测试通过,确认增长后的上限在拒绝后仍然有效。

评审级 CHANGES_REQUESTED — "Integration Tests (CLI, No Sandbox) 在 CI 中被跳过,且其套件未在本地运行"

处理结论:已在本地运行该套件予以回应;其中 1 个环境特有失败记录如下。

npm run build && npm run bundle 之后运行 npm run test:integration:cli:sandbox:none:195 通过、18 跳过、1 失败。唯一失败是 cli/qwen-config-dir.test.ts("1d: CLI functions normally when QWEN_HOME is not set"),报错为 EACCES: permission denied, mkdir '/home/github-runner/.qwen'。该 runner 的 home 目录属主为 root,而测试以 uid 1000 运行,因此真实 home 回落路径在此无法创建目录。失败的源码(packages/cli/src/utils/languageUtils.ts)与测试本身相对 origin/main 均为零行差异,故该失败与本 PR 无关,在基线分支上会同样复现。套件中所有 serve 相关集成测试均通过。

其他说明

  • 无需解决冲突(--conflict false);未执行 origin/main 合并。
  • 两条行内反馈均已在代码中解决;本轮没有拒绝、延后或升级任何反馈。Deferred non-Critical feedback 区域为空。

验证

  • npm run build — 通过
  • npm run typecheck — 通过
  • npm run lint — 通过
  • npx vitest run src/commands/serve.test.ts(packages/cli)— 61 通过(含新增的无值 flag 回归测试)
  • npx vitest run src/serve/fast-path.test.ts(packages/cli)— 86 通过
  • npx vitest run src/serve src/commands/serve.test.ts(packages/cli,聚焦)— 149 个文件,4413 通过 | 1 跳过
  • npx vitest run(packages/acp-bridge,全部)— 28 个文件,1356 通过
  • npm run bundle — 通过
  • npm run test:integration:cli:sandbox:none — 195 通过 | 18 跳过 | 1 失败(/home/github-runner/.qwen 上的环境特有 EACCES,详见上文;与本 PR 无关)

Deferred non-Critical feedback

Critical-only mode is active after 5 change-producing rounds. The workflow excluded the non-Critical feedback below from this round's actionable sections; the items remain open for human follow-up. Maintainer feedback is deferred only after its author has used 2 regular feedback batches in this window's Critical-only tail; authors at that budget, if any, are named below. (@qwen-code /retry starts a fresh counting window.)

中文说明

完成 5 个产生改动的轮次后进入仅处理 Critical 的模式。本轮可执行区域已排除下方非 Critical 反馈;这些条目保持开放,留待人工跟进。维护者反馈仅在其本人于本窗口 Critical-only 阶段已使用 2 批常规反馈预算后才会延后;达到预算的作者(如有)在下方点名。(评论 @qwen-code /retry 可开启新的计数窗口。)

Base-conflict check · 基分支冲突检查: no conflict with main. · 与 main 无冲突。

Re-review when you have a moment. After round 100 this bot stops and leaves the PR for a human. · 有空请复审;第 100 轮后本 bot 停止并将 PR 交给人工。


🧠 Handled by Qwen Code · model/模型 qwen3.8-max

@qwen-code-ci-bot
qwen-code-ci-bot dismissed their stale review August 13, 2026 02:02

Round-6 findings resolved on 68fe75d: R6-1 — valueless journal flags now rejected via nargs: 1 with 25 lines of parser tests; R6-2 — retained-window pin now asserts the full 4-entry window (r-2 through r-5). Dismissed by qwen-triage re-run.

@qwen-code-ci-bot

Copy link
Copy Markdown
Collaborator

Triage re-run completed without a new review.

⚠️ The bot has neither a verdict nor a deferral on 68fe75d3f63aca88e9290c7ed0c319252330c73a — no APPROVED, CHANGES_REQUESTED, or COMMENTED review of its own. A DISMISSED one does not count: dismiss_stale_reviews voids the bot's approval on every push, which is exactly when a fresh one is needed. If this re-run was meant to review or approve, it did not, and an approval left by another account is a separate vote that does not count as the bot's own.

⚠️ 机器人在 68fe75d3f63aca88e9290c7ed0c319252330c73a既没有裁决也没有 defer —— 没有属于它自己的 APPROVEDCHANGES_REQUESTEDCOMMENTED 评审。DISMISSED 不算:dismiss_stale_reviews 会在每次推送时作废机器人的批准,而那恰恰是需要一次新批准的时刻。如果这次重跑本应评审或批准,那么它没有做到;而其他账号留下的批准是另一张票,不能算作机器人自己的。

The stage comments above were updated with the latest result. View workflow run.

上方各阶段评论已更新为最新结果。查看工作流运行

@qwen-code-ci-bot qwen-code-ci-bot left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM, looks ready to ship — CI landed green after the review. ✅

@qwen-code-dev-bot

Copy link
Copy Markdown
Collaborator

🤖 Reviewed the latest feedback — no changes needed. Why, point by point: · 已审阅最新反馈——无需改动。逐点说明原因如下:

Autofix round summary — no action taken

This round ran in Critical-only mode (the PR has completed five change-producing rounds). After triaging all feedback newer than the last evaluation (2026-08-13T00:54:34Z), there was nothing actionable:

  • Reviews: none new.
  • Inline comments: none new.
  • Issue-level comments: none new from trusted maintainers or the automated reviewer.
  • Failed checks: none. All completed checks are SUCCESS or SKIPPED; the only in-progress check is this round's own review workflow.
  • Base conflicts: none reported (--conflict false), so no merge of origin/main was performed.

The one item listed under Deferred non-Critical feedback (a PR comment by @qwen-code-ci-bot) is an audit record of the Critical-only filter, not work for this round. Per policy, no code was changed for it, its thread was not resolved, and no reply was posted — it remains open for human follow-up.

Result: no commit was created. The PR head remains at 68fe75d3f63aca88e9290c7ed0c319252330c73a, exactly as verified by the previous round's deterministic gate.

中文说明

Autofix 轮次总结 — 未采取任何操作

本轮运行于仅处理 Critical 的模式(该 PR 已完成五个产生改动的轮次)。对上次评估(2026-08-13T00:54:34Z)之后的所有反馈进行分类处理后,没有任何可执行事项:

  • Reviews(评审):无新内容。
  • Inline comments(行内评论):无新内容。
  • Issue-level comments(议题级评论):来自可信维护者或自动评审器的均无新内容。
  • Failed checks(失败的检查):无。所有已完成的检查均为 SUCCESS 或 SKIPPED;唯一处于进行中的检查是本轮自身的评审工作流。
  • 基础分支冲突:未报告(--conflict false),因此未执行 origin/main 的合并。

**Deferred non-Critical feedback(已延后的非 Critical 反馈)**中列出的唯一条目(@qwen-code-ci-bot 的一条 PR 评论)只是 Critical-only 过滤器的审计记录,不属于本轮的工作内容。按策略,未针对它修改任何代码、未关闭其话题、也未发布回复——它保持开放状态,留待人工跟进。

结果:未创建任何提交。PR 头部仍为 68fe75d3f63aca88e9290c7ed0c319252330c73a,与上一轮确定性校验门所验证的状态完全一致。

Deferred non-Critical feedback

Critical-only mode is active after 5 change-producing rounds. The workflow excluded the non-Critical feedback below from this round's actionable sections; the items remain open for human follow-up. Maintainer feedback is deferred only after its author has used 2 regular feedback batches in this window's Critical-only tail; authors at that budget, if any, are named below. (@qwen-code /retry starts a fresh counting window.)

中文说明

完成 5 个产生改动的轮次后进入仅处理 Critical 的模式。本轮可执行区域已排除下方非 Critical 反馈;这些条目保持开放,留待人工跟进。维护者反馈仅在其本人于本窗口 Critical-only 阶段已使用 2 批常规反馈预算后才会延后;达到预算的作者(如有)在下方点名。(评论 @qwen-code /retry 可开启新的计数窗口。)

Base-conflict check · 基分支冲突检查: no conflict with main. · 与 main 无冲突。


🧠 Handled by Qwen Code · model/模型 qwen3.8-max

@wenshao

wenshao commented Aug 13, 2026

Copy link
Copy Markdown
Collaborator Author

Local real-stack verification (macOS) — behavior confirmed, recommend merge

I verified this PR end to end on a real daemon rather than from the unit tests alone: two full bundles (base 1570e6c vs head 68fe75d, each npm ci && npm run build && npm run bundle), a scripted OpenAI-compatible model that streams one enormous in-flight turn, an isolated QWEN_HOME per arm, and measurement through the actual cold-restore surface (POST /session/:id/load, which returns compactedReplay + liveJournal) plus the real Web Shell UI.

Bundle provenance was checked first: journalGrowthPoolBytes / live journal growth session= appear in the head dist/ chunks and are absent from the base dist/.

Host / derived figures observed live: effective budget 32768 MB (derived, 64 GB host) → growth pool 1073741824 B (5% clamped at the 1024 MB cap), per-session hard cap 268435456 B, baselines 10000 / 8388608 — exactly what limits.memory.journalGrowth reports.

Workload

One session, one prompt, one turn that never ends during measurement: the mock streams 20 000 text deltas (~40.9 MB, 20 002 source events), each carrying a monotonic marker [[C000001]]…[[C020000]], then holds the turn open. That parks the daemon in exactly the state a user hits when reloading mid-turn, and the markers make it exact which slice of the turn survived.

A/B/C — same workload, three daemons

base 1570e6c head 68fe75d (defaults) head + --max-journal-bytes 8388608
replay entries returned 15 81 15
source events retained 3 576 / 20 002 (17.9%) 20 000 / 20 000 (100%) 3 576 / 20 002
marker window C016425 … C020000 C000001 … C020000 C016425 … C020000
retained text 7 309 344 B 40 880 104 B 7 309 344 B
history_truncated yes — dropped 16 426 none yes — dropped 16 426
session effective caps n/a (field absent) 80000 / 67108864 10000 / 8388608
limits.memory.journalGrowth absent pool 1073741824, hardCap 268435456 null
growth log lines 0 3 0

The head daemon's growth ladder is visible in QWEN_SERVE_DEBUG=1 output, and /daemon/status?detail=full reported the grown caps live while the turn was still running:

live journal growth session="d8e956e1…":  8388608 -> 16777216 bytes, 10000 -> 20000 entries
live journal growth session="d8e956e1…": 16777216 -> 33554432 bytes, 20000 -> 40000 entries
live journal growth session="d8e956e1…": 33554432 -> 67108864 bytes, 40000 -> 80000 entries

The pinned-flag arm is the control I care about most: on the head build, pinning one journal flag reproduces base byte for byte — same 15 entries, same C016425…C020000 window, same 7 309 344 retained bytes, same marker payload, journalGrowth: null, zero growth asks. "Explicit config wins" holds, and the no-pool path is genuinely the pre-change code path.

Pool is a real, shared, aggregate ceiling

Two more arms with --memory-budget-mb 1024 (pool = 53477376 B / 51 MiB), each session wanting ~40 MB — i.e. one session alone would exhaust the pool:

arm session caps after growth granted total vs pool
2 sessions, one workspace (one bridge) 33554432 + 36700160 53477376 = pool exactly, not over
2 sessions, two workspaces (two bridges) 36700160 + 33554432 53477376 = pool exactly, not over

Both arms saturate the pool to the byte and stop. The 36700160 cap is not a doubling — that is the "take only what the pool has left" partial-grant clamp firing on the real stack. The cross-workspace arm is the one that matters for the final design: two independent bridges, one aggregate. Both sessions still truncated (they wanted more than the pool), but retained 14 320–15 648 source events each versus base's 3 576 — degraded gracefully rather than falling off a cliff.

Web Shell — what a user actually sees on a mid-turn reload

Same experiment driven entirely from the UI (12.3 MB turn, 6 004 source events), then the page reloaded while the turn is still in flight:

base — truncation banner, content starts at [[C002561]]:

base mid-turn reload

History truncated for live turn replay: kept the latest 3440 source events and dropped 2564 older source events (limits: 10000 replay entries / 8388608 bytes). Complete content remains available after the turn finishes.

head — no banner, content starts at [[C000001]], turn still streaming:

head mid-turn reload

Suites re-run locally on the head worktree

  • packages/acp-bridge: compactionEngine + journalGrowthPolicy + daemon-memory-budget + replayWindowLimits + bridge + eventBus6 files / 850 tests pass
  • packages/cli: serve/run-qwen-serve + commands/serve + serve/daemon-status3 files / 367 tests pass

Notes for reviewers (non-blocking)

  1. Whoever asks first wins the pool. A single session can legitimately consume the entire pool (arm 4/5 show one session taking 27 MiB of a 51 MiB pool while the other took 24 MiB). With the default 1024 MB pool and the 256 MiB per-session hard cap that is at most 4 fully-grown sessions; the 5th breaching session silently falls back to fixed-cap eviction. That is the documented design, not a defect — flagging it as an operational expectation.
  2. Granted headroom is derivable but not surfaced. limits.memory.journalGrowth reports the pool, and detail=full session rows report each session's effective caps, so sum(effective − baseline) gives the consumed pool — but there is no aggregate figure. The PR already lists pool exposure as out of scope; worth a follow-up for operators.
  3. limits.memory.enforced stays false while journalGrowth does have runtime effect. The field docs in this PR carve that out explicitly, so clients reading enforced alone are not misled — just noting it survived review deliberately.

Not covered locally

  • The 256 MiB per-session hard cap (needs a single turn larger than 256 MB; the pool ceiling was exercised instead).
  • The insufficientMemory → pool 0 path (this host is too large to reach it naturally).
  • Windows / Linux — macOS only (Darwin 25.6.0, Node 24).

Verdict: every user-visible claim in the description reproduces on a real daemon, the disable path is byte-identical to base, and the memory bound holds exactly at the pool on both single-bridge and cross-bridge contention. Merging looks safe to me.

中文版

本地真实环境验证(macOS)——行为符合描述,建议合并

我没有只依赖单测,而是在真实 daemon 上端到端验证了这个 PR:构建了两套完整 bundle(base 1570e6c vs head 68fe75d,各自 npm ci && npm run build && npm run bundle),用一个脚本化的 OpenAI 兼容 mock 模型制造单个超大进行中回合,每条腿独立 QWEN_HOME,并通过真实的冷启动回放面(POST /session/:id/load,返回 compactedReplay + liveJournal)以及真实 Web Shell UI 进行测量。

先做了 bundle 溯源核对:head 的 dist/ chunk 里能搜到 journalGrowthPoolBytes / live journal growth session=,base 的 dist/ 里没有。

实测到的宿主机/派生数值: 有效预算 32768 MB(derived,64 GB 宿主机)→ 增长池 1073741824 B(5% 后被 1024 MB 上限截断),单会话硬顶 268435456 B,基线 10000 / 8388608——与 limits.memory.journalGrowth 上报的完全一致。

负载

一个会话、一个提示词、一个在测量期间永不结束的回合:mock 流式发出 20 000 个文本增量(约 40.9 MB,20 002 个 source 事件),每个带单调递增标记 [[C000001]]…[[C020000]],发完后把回合挂住不结束。这正好把 daemon 停在"用户中途刷新页面"的状态,而标记让"到底保留了回合的哪一段"变得可精确判定。

A/B/C 三个 daemon,同一负载

base 1570e6c head 68fe75d(默认) head + --max-journal-bytes 8388608
返回的回放条目 15 81 15
保留的 source 事件 3 576 / 20 002(17.9%) 20 000 / 20 000(100%) 3 576 / 20 002
标记窗口 C016425 … C020000 C000001 … C020000 C016425 … C020000
保留文本 7 309 344 B 40 880 104 B 7 309 344 B
history_truncated 有——丢弃 16 426 有——丢弃 16 426
会话有效上限 不适用(无该字段) 80000 / 67108864 10000 / 8388608
limits.memory.journalGrowth pool 1073741824,hardCap 268435456 null
增长日志行数 0 3 0

head 侧的增长阶梯在 QWEN_SERVE_DEBUG=1 输出里可见,且回合仍在进行时 /daemon/status?detail=full 就实时上报了已增长的上限:

live journal growth session="d8e956e1…":  8388608 -> 16777216 bytes, 10000 -> 20000 entries
live journal growth session="d8e956e1…": 16777216 -> 33554432 bytes, 20000 -> 40000 entries
live journal growth session="d8e956e1…": 33554432 -> 67108864 bytes, 40000 -> 80000 entries

我最看重的是 pin flag 那条对照腿:在 head 构建上钉住任一 journal flag,结果与 base 逐字节一致——同样 15 条、同样 C016425…C020000 窗口、同样 7 309 344 保留字节、同样的 marker 负载、journalGrowth: null、零次增长询问。"显式配置优先"成立,且未配置池时走的确实是改动前那条代码路径。

池是真实、共享、聚合的天花板

另外两条腿使用 --memory-budget-mb 1024(池 = 53477376 B / 51 MiB),每个会话都想要约 40 MB——即单个会话就足以吃光整个池:

增长后的会话上限 已授总量 对比池
2 会话 / 1 个 workspace(单 bridge) 33554432 + 36700160 53477376 恰好等于池,未超
2 会话 / 2 个 workspace(双 bridge) 36700160 + 33554432 53477376 恰好等于池,未超

两条腿都把池精确授满到字节然后停住。其中 36700160 不是整倍翻倍——这正是"只取池里剩下的那部分"的部分授权 clamp 在真实链路上生效。跨 workspace 那条对最终设计最关键:两个独立 bridge,一个聚合池。两个会话仍然发生了截断(它们要的比池多),但各自保留了 14 320–15 648 个 source 事件,而 base 只有 3 576——是平滑降级,不是断崖。

Web Shell——用户中途刷新真正看到的东西

同样的实验完全从 UI 驱动(12.3 MB 回合,6 004 个 source 事件),然后在回合仍进行中刷新页面:

base——截断横幅,内容从 [[C002561]] 开始:

base 中途重载

History truncated for live turn replay: kept the latest 3440 source events and dropped 2564 older source events (limits: 10000 replay entries / 8388608 bytes). Complete content remains available after the turn finishes.

head——无横幅,内容从 [[C000001]] 开始,回合仍在流式输出:

head 中途重载

在 head worktree 上重跑的套件

  • packages/acp-bridgecompactionEngine + journalGrowthPolicy + daemon-memory-budget + replayWindowLimits + bridge + eventBus——6 文件 / 850 测试通过
  • packages/cliserve/run-qwen-serve + commands/serve + serve/daemon-status——3 文件 / 367 测试通过

给评审者的观察(不阻塞合并)

  1. 先要先得。 单个会话完全可以合法地吃掉整个池(第 4/5 条腿里一个会话拿了 51 MiB 池中的 27 MiB,另一个拿 24 MiB)。按默认 1024 MB 池和 256 MiB 单会话硬顶算,最多只有 4 个会话能长满,第 5 个触碰上限的会话会静默退回固定上限驱逐。这是文档化的设计而非缺陷,这里只是把它作为运维预期点出来。
  2. 已授额度可推导但未直接暴露。 limits.memory.journalGrowth 报告池大小,detail=full 的会话行报告每个会话的有效上限,所以 sum(有效 − 基线) 可以算出已消耗的池——但没有聚合数值。PR 已把池的暴露列为范围外;对运维而言值得作为后续项。
  3. limits.memory.enforced 仍为 false,而 journalGrowth 确实有运行时效果。本 PR 的字段文档已明确把这一点单独切出来,因此只读 enforced 的客户端不会被误导——这里只是说明它是有意保留的。

本地未覆盖

  • 256 MiB 单会话硬顶(需要单个回合超过 256 MB;这次改为压测了池上限)。
  • insufficientMemory → pool 0 路径(本机内存太大,自然触达不到)。
  • Windows / Linux——仅 macOS(Darwin 25.6.0,Node 24)。

结论: 描述里每一条用户可见的主张都在真实 daemon 上复现了,关闭路径与 base 逐字节一致,内存上界在单 bridge 与跨 bridge 争用下都精确停在池边界。我认为可以安全合并。

@qwen-code-dev-bot

Copy link
Copy Markdown
Collaborator

🤖 Reviewed the latest feedback — no changes needed. Why, point by point: · 已审阅最新反馈——无需改动。逐点说明原因如下:

Autofix round summary — no action taken

No changes were made this round; the branch remains at 68fe75d3f6.

Feedback triage:

  • Reviews: none received this round.
  • Inline comments: none received this round.
  • Failed checks: none. Still-red checks: none.
  • Issue-level comments (1): @wenshao posted a comprehensive local real-stack verification report (A/B/C daemon arms, pool-ceiling contention across one and two bridges, Web Shell mid-turn reload, byte-identical pinned-flag control arm), concluding that every user-visible claim in the PR description reproduces on a real daemon and recommending merge. It reports no defects and requests no changes.
    • Its three reviewer notes are explicitly non-blocking and require no code change in this PR:
      1. First-ask-first-served pool semantics (a 5th fully-grown session falls back to fixed-cap eviction) — documented design, flagged as an operational expectation, not a defect.
      2. Granted pool headroom is derivable but not surfaced as an aggregate figure — already listed as out of scope in the PR description; noted as a follow-up for operators.
      3. limits.memory.enforced stays false while journalGrowth has runtime effect — deliberate; the field documentation in this PR explicitly carves this out so clients reading enforced alone are not misled.

Critical-only mode: active after five change-producing rounds. The Deferred non-Critical feedback section contains no items and is an audit record only — no code modifications, thread resolutions, or comment replies were made for it, per the workflow rules.

Result: nothing actionable this round — no commits, no thread resolutions, no reply comments. The PR stays at its current verified head for maintainer review.

中文说明

Autofix 轮次总结 — 本轮未采取任何行动

本轮未做任何改动;分支保持在 68fe75d3f6

反馈分类处理:

  • Reviews: 本轮没有收到。
  • Inline 评论: 本轮没有收到。
  • 失败的检查: 无。持续失败的检查: 无。
  • Issue 级评论(1 条): @wenshao 发布了一份完整的本地真实环境验证报告(A/B/C 三个 daemon 对照、单 bridge 与双 bridge 下的池上限争用、Web Shell 中途刷新、pin flag 对照腿与 base 逐字节一致),结论是 PR 描述中每一条用户可见的主张都在真实 daemon 上复现,并建议合并。该报告没有报告任何缺陷,也没有提出任何改动请求。
    • 其中三条给评审者的观察均明确标注为不阻塞合并,且本 PR 无需任何代码改动:
      1. 池的先要先得语义(第 5 个触碰上限的会话会退回固定上限驱逐)——文档化的设计,仅作为运维预期点出,并非缺陷。
      2. 已授池额度可推导但没有聚合数值直接暴露——PR 描述已将其列为范围外;记录为面向运维人员的后续跟进项。
      3. limits.memory.enforcedjournalGrowth 有运行时效果的情况下仍为 false——有意为之;本 PR 的字段文档已明确将该点单独切出,只读 enforced 的客户端不会被误导。

仅处理 Critical 模式: 在完成 5 个产生改动的轮次后已激活。Deferred non-Critical feedback 区块不含任何条目,仅为审计记录——按工作流规则,未对其做任何代码修改、线程 resolve 或评论回复。

结果: 本轮没有可执行事项——没有提交、没有 resolve 线程、没有回复评论。PR 保持在当前已验证的 head,等待维护者审阅。

Deferred non-Critical feedback

Critical-only mode is active after 5 change-producing rounds. The workflow excluded the non-Critical feedback below from this round's actionable sections; the items remain open for human follow-up. Maintainer feedback is deferred only after its author has used 2 regular feedback batches in this window's Critical-only tail; authors at that budget, if any, are named below. (@qwen-code /retry starts a fresh counting window.)

中文说明

完成 5 个产生改动的轮次后进入仅处理 Critical 的模式。本轮可执行区域已排除下方非 Critical 反馈;这些条目保持开放,留待人工跟进。维护者反馈仅在其本人于本窗口 Critical-only 阶段已使用 2 批常规反馈预算后才会延后;达到预算的作者(如有)在下方点名。(评论 @qwen-code /retry 可开启新的计数窗口。)

Base-conflict check · 基分支冲突检查: no conflict with main. · 与 main 无冲突。


🧠 Handled by Qwen Code · model/模型 qwen3.8-max

@qwen-code-ci-bot qwen-code-ci-bot left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Reviewed.

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): You are review agent reverse-audit — Reverse audit agen...: none — all planned checks completed within budget.; chunk 10: none — vitest was unavailable in this worktree (no node_modules), but the pure-policy execution above covered the test file's assertions directly.; PR #8905 makes the daemon's live-journal caps adaptive: a...: none — all checks above completed within budget.; chunk 8: could not execute npx vitest run src/compactionEngine.test.ts — node_modules is absent in the review worktree and a full install exceeded the tool budget; v…; You are review agent reverse-audit — Reverse audit agen...: none — all checks I started reached a verdict., and 2 more.

Not reviewed: reverse audit — did not converge within the reverse-audit round cap of 5.

Test Plan (not a blocker): 1221 tests pass — this review observed 1356, 19157, 1511, 494, 3289, 551 passed.

中文说明

已审查。

未审查:build-and-test — Integration Tests (CLI, No Sandbox) was skipped in CI and its suite did not run locally。

未探索到全部深度(达到工具调用预算):You are review agent reverse-audit — Reverse audit agen...:none — all planned checks completed within budget.;chunk 10:none — vitest was unavailable in this worktree (no node_modules), but the pure-policy execution above covered the test file's assertions directly.;PR #8905 makes the daemon's live-journal caps adaptive: a...:none — all checks above completed within budget.;chunk 8:could not execute npx vitest run src/compactionEngine.test.ts — node_modules is absent in the review worktree and a full install exceeded the tool budget; v…;You are review agent reverse-audit — Reverse audit agen...:none — all checks I started reached a verdict.,另有 2 条。

未审查:反向审计——在 5 轮的反审轮数上限内未收敛。

Test Plan(非阻断):1221 tests pass — this review observed 1356, 19157, 1511, 494, 3289, 551 passed

— qwen3.8-max via Qwen Code /review (v0.21.10)

@qwen-code-dev-bot

Copy link
Copy Markdown
Collaborator

🤖 Reviewed the latest feedback — no changes needed. Why, point by point: · 已审阅最新反馈——无需改动。逐点说明原因如下:

No action taken this round

The review feedback for this round contains no actionable items:

  • Reviews: none listed.
  • Inline comments: none listed.
  • Issue-level comments: none listed.
  • Failed checks: none.
  • Still-red checks: none.

The PR is in Critical-only mode after five change-producing rounds. The single
item in the Deferred non-Critical feedback section (a review by
@qwen-code-ci-bot) is an audit record excluded by the deterministic filter, not
work for this round, so no code was modified, no threads were resolved, and no
comment replies were written for it. It remains open for human follow-up.

No conflict resolution was needed (--conflict false), and the branch stays
at commit 68fe75d3f6 with a clean working tree.

中文说明

本轮未采取任何操作

本轮审查反馈中没有可处理的事项:

  • 审查(Reviews): 无。
  • 行内评论(Inline comments): 无。
  • Issue 级评论(Issue-level comments): 无。
  • 失败的检查(Failed checks): 无。
  • 持续失败的检查(Still-red checks): 无。

该 PR 在经历五个产生改动的轮次后已进入仅处理 Critical 的模式。Deferred non-Critical feedback(延后的非 Critical 反馈)部分中的唯一条目(来自 @qwen-code-ci-bot 的一次审查)是被确定性过滤器排除的审计记录,不属于本轮工作,因此未修改任何代码、未解决任何线程,也未为其撰写评论回复。该条目保持开放,留待人工跟进。

无需解决冲突(--conflict false),分支保持在提交 68fe75d3f6,工作树干净。

Deferred non-Critical feedback

Critical-only mode is active after 5 change-producing rounds. The workflow excluded the non-Critical feedback below from this round's actionable sections; the items remain open for human follow-up. Maintainer feedback is deferred only after its author has used 2 regular feedback batches in this window's Critical-only tail; authors at that budget, if any, are named below. (@qwen-code /retry starts a fresh counting window.)

中文说明

完成 5 个产生改动的轮次后进入仅处理 Critical 的模式。本轮可执行区域已排除下方非 Critical 反馈;这些条目保持开放,留待人工跟进。维护者反馈仅在其本人于本窗口 Critical-only 阶段已使用 2 批常规反馈预算后才会延后;达到预算的作者(如有)在下方点名。(评论 @qwen-code /retry 可开启新的计数窗口。)

Base-conflict check · 基分支冲突检查: no conflict with main. · 与 main 无冲突。


🧠 Handled by Qwen Code · model/模型 qwen3.8-max

@doudouOUC doudouOUC left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Reviewed current head 68fe75d3f63aca88e9290c7ed0c319252330c73a. No blocking issues found.

I rechecked the still-open Critical and Suggestion threads against the exact commit. The current code walks retention-neutral intermediate grants and rolls them back when no replay is gained, accounts every live or restoring session against its own baseline through one daemon-wide pool, preserves grown caps across later denials, rejects valueless journal flags with nargs: 1, forwards either pinned flag independently, and pins the effective-budget and retained-window cases in tests. The remaining open anchors no longer describe the current code.

Scope reviewed: compaction and growth-policy arithmetic; live, restore, close, reap, channel-exit, and shutdown accounting; startup, secondary, and dynamically attached workspace bridge wiring; CLI pin semantics and fast-path fallback; daemon-status and SDK compatibility; documentation; and all changed tests.

Independent verification:

  • acp-bridge suites: 6 files / 850 tests passed
  • CLI serve, run-qwen-serve, and daemon-status suites: 3 files / 367 tests passed
  • changed-file ESLint and Prettier checks passed
  • git diff --check passed
  • TypeScript SDK typecheck passed
  • all non-skipped checks reported by gh pr checks are green

The head remained unchanged through the final audit. Approved.

@wenshao
wenshao added this pull request to the merge queue Aug 13, 2026
Merged via the queue into main with commit 407cf0a Aug 13, 2026
79 checks passed
qwen-code-dev-bot pushed a commit that referenced this pull request Aug 13, 2026
Merge origin/main — adaptive live-journal growth (#8905) — into the
summary live-replay branch: the growth advisor now operates on the
shared journal state object and measures retention against whichever
journal (full or summary) breaches its caps.

Review feedback addressed:

- Critical R1-1: a summary load that coalesces onto an in-flight full
  restore recomputes its own-mode replay fields from the registered
  entry instead of inheriting the owner's unprojected full journal,
  which could carry nested frames and a history_truncated marker the
  summary journal never earned. Extended the coalesce test to flood a
  capped journal and pin the waiter's projected, marker-free view.
- Mirror the UI normalizer's self-reference guard in the summary
  journal filter: a tool frame whose parentToolCallId equals its own
  toolCallId renders as a root block live, so it must survive a
  mid-turn summary refresh.
- R1-2: cover the parented non-chunk exclusion branch (nested
  tool_call/tool_call_update frames) with a capped engine test; the
  branch previously had no test and the reviewer's mutation survived.
- Document the usage carve-out exceptions in the design doc (it
  contradicted the implementation), and document the 2x per-session
  journal memory ceiling (full + summary share one cap pair) in
  replayWindowLimits, the engine options, and daemon diagnostics.
@qwen-code-ci-bot

Copy link
Copy Markdown
Collaborator

Released in v0.21.12.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

autofix/takeover Summon the autofix loop to manage this PR (remove to release; needs triage+)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants