Skip to content

feat(integrations): add retrieval-only external context search - #7586

Merged
doudouOUC merged 7 commits into
mainfrom
agent/direct-external-context-provider
Jul 25, 2026
Merged

feat(integrations): add retrieval-only external context search#7586
doudouOUC merged 7 commits into
mainfrom
agent/direct-external-context-provider

Conversation

@doudouOUC

@doudouOUC doudouOUC commented Jul 23, 2026

Copy link
Copy Markdown
Collaborator

What this PR does

This PR adds Phase 1 of the private Direct External Context Provider integration for the narrow deployment profile where one interactive Qwen CLI process serves trusted collaborators and the external provider can issue a credential restricted to one intended corpus.

The integration exposes exactly one on-demand, retrieval-only MCP tool, context_search({ query }). It has no hooks, automatic recall, write tools, personal memory, or runtime provider plugin system. Provider selection and all corpus selectors are fixed by administrator-controlled configuration before the MCP server starts; the model supplies only the search query.

Two explicit adapters are included. Mem0 Platform V3 Search fixes app_id, result count, threshold, and reranking in the adapter. Generic HTTP Search V1 sends only a normalized query and fixed result limit to /v1/context/search, allowing an existing knowledge base, RAG service, or enterprise search endpoint to provide the same normalized result contract.

Requests use a bounded timeout without retries or caching, and client cancellation aborts the in-flight provider request. Redirects are rejected, HTTPS is required except for loopback development, provider responses are capped and strictly validated, and the final untrusted JSON envelope is bounded. Provider failures return a stable local error. Phase 1 emits no local per-request audit record and does not write queries, results, credentials, provider errors, or operation metadata to stderr.

The managed deployment pins the reviewed MCP command through an administrator-owned --mcp-config, because a settings or project server with the same name would otherwise replace the extension manifest contribution while retaining the same permission-rule name. The managed launcher constructs the complete Qwen argument vector without passing through arbitrary caller arguments, starts from an administrator-approved environment, and supplies a launcher-specific system settings path that disables /cd and allows only the pinned search tool. The Node executable, checkout, dependency tree, provider configuration, and credential binding remain administrator-controlled and immutable for the session. The extension manifest remains available for local trusted trials but is not the managed source binding.

The design documents the actual trust boundary. The provider-side credential, project, index, or corpus must enforce single-corpus access; Mem0 app_id and other client-side filters are classification rather than authorization. The Direct Profile requires the repository, its .env and .qwen/.env files, and same-UID code to be trusted. It does not provide DLP, credential or process isolation from the CLI user, trusted user identity, per-document ACL enforcement, non-bypassable confirmation, compliance audit, or protection from prompt injection in retrieved content. Deployments needing those controls use the governed Gateway/Orchestrator Profile in #7449.

The repository lint configuration now applies the normal TypeScript and Vitest house rules to private integration workspaces, and the implementation removes the earlier single-use runtime wrapper and dead provider-binding metadata.

Why it's needed

Teams that already have repository-scoped memory or knowledge services need a low-deployment-cost way to retrieve that context from Qwen Code without changing Qwen Core or first operating the full governed gateway.

Exposing an unrestricted provider MCP server is too broad because model-controlled tenant, project, namespace, endpoint, or filter parameters can defeat the intended corpus boundary. This integration provides the minimum reviewed wrapper for trusted-team retrieval while deferring automatic recall, writes, personal identity, and policy enforcement whose authorization, privacy, latency, and lifecycle semantics require the governed profile or a separate phase.

Reviewer Test Plan

How to verify

  1. Build the private integration and configure the managed MCP entry with administrator-controlled absolute paths. Add different external-context servers in user settings and the repository MCP configuration, then start the managed profile. Confirm the command-line MCP entry wins and only the reviewed context_search tool is exposed.
  2. Confirm the managed launcher accepts no arbitrary Qwen arguments, starts from its approved environment, and points QWEN_CODE_SYSTEM_SETTINGS_PATH only at the managed profile settings. Confirm /cd is hidden and refused and the exact pinned search tool is allowed. Unmanaged Qwen sessions must not inherit this automatic allow rule.
  3. Search through the Generic HTTP adapter against a loopback fake provider. Confirm extra whitespace is normalized, the provider receives only {"query":"normalized query","limit":5} at /v1/context/search, and Qwen receives bounded JSON under untrusted_external_context.
  4. Exercise the Mem0 adapter through its test-only loopback origin. Confirm the request fixes the configured app_id, top_k: 5, threshold: 0.1, and rerank: false, and no add, update, or delete surface exists. Production configuration must use the fixed Mem0 API origin.
  5. Return redirects, declared and streamed oversized bodies, invalid UTF-8, invalid JSON, invalid envelopes, 429, 5xx, and delayed responses, then cancel an in-flight request. Confirm every provider failure returns only External context search failed., cancellation aborts the provider request, there is no retry, and stderr remains empty of per-request data or metadata.
  6. Review the tool schema and both outbound request bodies. Confirm structured tool arguments cannot override tenant, user, repository, namespace, application ID, filter, endpoint, or credential values; extra arguments do not enter the adapter.
  7. Restart the MCP process with the same immutable configuration and confirm it remains on the same corpus. Terminate Qwen and start a new managed process with a new configuration path to switch corpora.
  8. For a local trusted trial only, link the extension manifest and confirm it exposes the same single retrieval tool with no hook or write surface; do not treat this manifest path as the managed source binding.

Evidence (Before & After)

N/A. This is a non-UI private integration, tests, deployment examples, lint coverage, and design documentation.

Tested on

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

Environment (optional)

Node.js 22.22.3, npm 10.9.8, Qwen Code monorepo workspace. Verified 42/42 workspace tests with real loopback providers, workspace and repository build/typecheck/lint, lockfile validation, formatting, dry-run packaging, and a compiled stdio MCP fake-provider E2E with empty stderr.

Risk & Scope

  • Main risk or tradeoff: Search is an outbound data channel, retrieved content remains prompt-injection-capable untrusted input, provider search may retain logs or access state, the Direct Profile trusts repository environment files and same-UID code, permissions.ask is bypassed by YOLO, and a mutable configuration path could change the corpus binding after an MCP restart; the profile is appropriate only when the provider credential is already restricted to one intended corpus and every managed input remains controlled for the session.
  • Not validated / out of scope: Automatic recall, writes, personal identity, per-user or per-document authorization, OAuth brokerage, DLP, credential/process isolation, compliance audit, hostile repositories, multi-workspace serving, Windows runtime behavior, Linux runtime behavior, and a standalone packaged extension artifact.
  • Breaking changes / migration notes: No released interface changes. This narrows the earlier draft implementation to on-demand retrieval-only search and removes its unreleased hook, automatic-recall, repository-root, write, operational-logging, and single-use runtime abstractions.

Linked Issues

Related to #7585

Related to #7449

中文说明

本 PR 做了什么

本 PR 增加私有 Direct External Context Provider 集成的第一阶段,面向一个交互式 Qwen CLI 进程服务可信协作者,且外部 Provider 能够签发仅限一个目标语料库凭证的窄场景。

该集成只暴露一个按需、仅检索的 MCP 工具 context_search({ query })。它不包含 Hook、自动召回、写入工具、个人记忆或运行时 Provider 插件系统。Provider 选择和所有语料库 selector 都在 MCP Server 启动前由管理员控制的配置固定;模型只能提供搜索 query。

本 PR 包含两个显式 Adapter。Mem0 Platform V3 Search 在 Adapter 中固定 app_id、结果数量、threshold 和 reranking。Generic HTTP Search V1 只向 /v1/context/search 发送归一化 query 和固定结果上限,使现有知识库、RAG 服务或企业搜索端点能够提供相同的归一化结果契约。

请求使用有界超时,不重试也不缓存;客户端取消会中止正在进行的 Provider 请求。重定向会被拒绝;除 loopback 开发外必须使用 HTTPS;Provider 响应具有大小上限并经过严格校验;最终的非可信 JSON envelope 也受到边界限制。Provider 故障只返回稳定的本地错误。Phase 1 不产生本地逐请求审计记录,也不会向 stderr 写入 query、结果、凭证、Provider 错误或操作元数据。

受管部署通过管理员拥有的 --mcp-config 固定经过审阅的 MCP 命令,因为同名 settings 或 project server 否则可以替换扩展 manifest 的贡献,同时继续使用相同的权限规则名。受管启动器完整构造 Qwen 参数,不透传任意调用方参数;从管理员批准的环境启动;并提供仅供该启动器使用的 system settings 路径,用于禁用 /cd 且只允许固定的搜索工具。Node 可执行文件、checkout、依赖树、Provider 配置和凭证绑定在会话期间都由管理员控制并保持不可变。扩展 manifest 仍可用于本地可信试用,但不是受管模式的来源绑定。

设计文档明确记录真实信任边界。Provider 侧凭证、Project、Index 或 Corpus 必须强制单语料库访问;Mem0 app_id 和其他客户端 filter 只是分类信息,不是鉴权。Direct Profile 要求仓库、其 .env.qwen/.env 文件以及同 UID 代码可信。它不提供 DLP、对 CLI 用户的凭证或进程隔离、可信用户身份、逐文档 ACL 强制、不可绕过的确认、合规审计,也不能防止召回内容中的提示注入。需要这些控制的部署应使用 #7449 中的受管 Gateway/Orchestrator Profile。

仓库 lint 配置现在会把常规 TypeScript 和 Vitest 规则应用到私有 integration workspace;实现同时删除了早期仅使用一次的 runtime wrapper 和无读取方的 Provider binding 元数据。

为什么需要

已经拥有仓库级记忆或知识服务的团队,需要一种低部署成本的方式从 Qwen Code 中检索这些上下文,同时不修改 Qwen Core,也不要求先运维完整的受管 Gateway。

直接暴露无限制的 Provider MCP Server 范围过大,因为模型可控的 tenant、project、namespace、endpoint 或 filter 参数可能破坏预期语料库边界。该集成为可信团队检索提供最小的经过审阅的封装,同时将自动召回、写入、个人身份和策略执行推迟到后续阶段或受管 Profile,因为这些能力的鉴权、隐私、延迟和生命周期语义需要单独设计。

Reviewer 测试计划

如何验证

  1. 构建私有集成,并使用管理员控制的绝对路径配置受管 MCP 入口。在 user settings 和仓库 MCP 配置中添加不同的 external-context server,然后启动受管 Profile。确认命令行 MCP 入口胜出,并且只暴露经过审阅的 context_search 工具。
  2. 确认受管启动器不接受任意 Qwen 参数,从批准的环境启动,并且只在受管 Profile 中将 QWEN_CODE_SYSTEM_SETTINGS_PATH 指向对应 settings。确认 /cd 被隐藏并拒绝执行,且精确匹配的固定搜索工具被允许。非受管 Qwen 会话不得继承该自动 allow 规则。
  3. 使用 Generic HTTP Adapter 连接 loopback Fake Provider 执行搜索。确认多余空白被归一化,Provider 在 /v1/context/search 收到的内容只有 {"query":"normalized query","limit":5},同时 Qwen 在 untrusted_external_context 下收到有界 JSON。
  4. 通过仅用于测试的 loopback origin 验证 Mem0 Adapter。确认请求固定配置的 app_idtop_k: 5threshold: 0.1rerank: false,并且不存在 add、update 或 delete 接口。生产配置必须使用固定的 Mem0 API origin。
  5. 返回重定向、声明和流式超大响应体、非法 UTF-8、非法 JSON、非法 envelope、429、5xx 和延迟响应,再取消一个正在进行的请求。确认每种 Provider 故障都只返回 External context search failed.,取消会中止 Provider 请求,不发生重试,且 stderr 中不包含逐请求数据或元数据。
  6. 检查工具 schema 和两个出站请求 body。确认结构化工具参数不能覆盖 tenant、user、repository、namespace、application ID、filter、endpoint 或 credential;额外参数不会进入 Adapter。
  7. 使用相同且不可变的配置重启 MCP 进程,确认它仍绑定同一语料库。终止 Qwen,再使用新的配置路径启动新的受管进程以切换语料库。
  8. 仅针对本地可信试用,链接扩展 manifest 并确认它暴露相同的单一检索工具,且不存在 Hook 或写入接口;不要把该 manifest 路径当作受管来源绑定。

证据(Before & After)

N/A。这是非 UI 的私有集成、测试、部署示例、lint 覆盖和设计文档。

已测试平台

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

环境(可选)

Node.js 22.22.3、npm 10.9.8、Qwen Code monorepo workspace。已验证使用真实 loopback Provider 的 42/42 workspace 测试、workspace 与仓库级 build/typecheck/lint、lockfile 校验、格式检查、dry-run 打包,以及编译后 stdio MCP Fake Provider E2E,且 stderr 为空。

风险与范围

  • 主要风险或权衡:搜索是一条出站数据通道,召回内容仍是可能包含提示注入的非可信输入,Provider 搜索可能保留日志或访问状态,Direct Profile 信任仓库环境文件和同 UID 代码,YOLO 会绕过 permissions.ask,可变配置路径还可能在 MCP 重启后改变语料库绑定;该 Profile 仅适用于 Provider 凭证已经限制到一个目标语料库且所有受管输入在会话期间都保持受控的场景。
  • 未验证 / 不在范围内:自动召回、写入、个人身份、逐用户或逐文档授权、OAuth 代理、DLP、凭证/进程隔离、合规审计、恶意仓库、多 workspace serving、Windows 运行时行为、Linux 运行时行为和独立打包的扩展产物。
  • 破坏性变更 / 迁移说明:没有已发布接口变更。本次将早期 Draft 实现收敛为按需仅检索搜索,并移除其尚未发布的 Hook、自动召回、repository-root、写入、操作日志和单次使用的 runtime 抽象。

关联 Issue

关联 #7585

关联 #7449

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
@doudouOUC

doudouOUC commented Jul 23, 2026

Copy link
Copy Markdown
Collaborator Author

E2E test report

Tested commit: 44e00de5b0aa2db8b727f0ff74cf0024113922c5

Extension loading

  • Built the external-context workspace and linked integrations/external-context into an isolated Qwen home with Qwen Code 0.20.0.
  • Disabled the link at user scope and enabled it at an isolated workspace scope. qwen extensions list reported Enabled (User): false, Enabled (Workspace): true, External Context 1.0.0, and its external-context MCP server.

Behavioral verification

  • The integration test suite passed all 47 tests across configuration, sanitization/rendering, Hook behavior, Provider request/response mapping, HTTP limits and timeout classification, invalid UTF-8 handling, Mem0 write outcomes and unknown-status handling, and MCP tool registration.
  • The focused Qwen Core scheduler tests passed all 3 relevant cases: interactive PreToolUse ask bounce, non-interactive denial, and background denial.
  • Fake Generic HTTP and Mem0 providers verified fixed corpus selectors, no model-controlled tenant/repository/filter fields, equivalent normalized context, redirect and 1 MiB response rejection, no retries, fail-open automatic recall, and conditional write-tool registration.
  • A real-process Fake Provider E2E started the compiled stdio MCP child and command Hook, then verified configuration/credential inheritance, tool discovery, request mapping, automatic query sanitization, and additionalContext injection.

Repository verification

  • npm run build — passed.
  • npm run typecheck — passed.
  • npm run lint — passed.
  • npm run check:lockfile — passed.
  • npm pack --dry-run --workspace=integrations/external-context — passed and included the compiled extension, manifests, hooks, examples, and README.

Limitations

  • No live Mem0 Project or enterprise knowledge service credential was used; network behavior was verified against local fake providers.
  • Windows and Linux were not tested locally.
中文测试报告

测试提交:44e00de5b0aa2db8b727f0ff74cf0024113922c5

扩展加载

  • 完成 external-context workspace 构建,并使用 Qwen Code 0.20.0 将 integrations/external-context 链接到隔离的 Qwen home。
  • 在 user scope 禁用该链接,并在隔离的 workspace scope 启用。qwen extensions list 显示 Enabled (User): falseEnabled (Workspace): trueExternal Context 1.0.0 及其 external-context MCP server。

行为验证

  • Integration 测试共 47 个,全部通过,覆盖配置、清洗/渲染、Hook 行为、Provider 请求/响应映射、HTTP 限制与超时分类、非法 UTF-8、Mem0 写入结果与未知状态处理,以及 MCP 工具注册。
  • Qwen Core scheduler 的 3 个相关定向测试全部通过:交互式 PreToolUse ask bounce、非交互拒绝和后台拒绝。
  • Fake Generic HTTP 与 Mem0 Provider 验证了固定语料 selector、没有模型可控 tenant/repository/filter 字段、相同归一化上下文、redirect 与 1 MiB 响应拒绝、无重试、自动召回 fail-open 以及条件写入工具注册。
  • 真实进程 Fake Provider E2E 启动了编译后的 stdio MCP 子进程和 command Hook,并验证配置/凭证继承、工具发现、请求映射、自动查询清洗及 additionalContext 注入。

仓库验证

  • npm run build——通过。
  • npm run typecheck——通过。
  • npm run lint——通过。
  • npm run check:lockfile——通过。
  • npm pack --dry-run --workspace=integrations/external-context——通过,打包清单包含已编译扩展、manifest、Hook、示例和 README。

限制

  • 未使用真实 Mem0 Project 或企业知识服务凭证;网络行为通过本地 Fake Provider 验证。
  • 未在本地测试 Windows 和 Linux。

@github-actions

github-actions Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Code Coverage Summary

Package Lines Statements Functions Branches
CLI 82.63% 82.63% 88.78% 82.3%
Core 87.04% 87.04% 88.45% 86.15%
CLI Package - Full Text Report
-------------------|---------|----------|---------|---------|-------------------
File               | % Stmts | % Branch | % Funcs | % Lines | Uncovered Line #s 
-------------------|---------|----------|---------|---------|-------------------
All files          |   82.63 |     82.3 |   88.78 |   82.63 |                   
 src               |   84.12 |    80.71 |   88.88 |   84.12 |                   
  cli.ts           |   94.54 |    84.07 |     100 |   94.54 | ...86-487,497-498 
  gemini.tsx       |   73.89 |    76.49 |    82.6 |   73.89 | ...1183-1187,1308 
  ...ractiveCli.ts |   85.02 |    80.82 |   86.84 |   85.02 | ...2363,2369,2421 
  ...liCommands.ts |   88.34 |    83.87 |      90 |   88.34 | ...63,480,514,635 
  ...ActiveAuth.ts |     100 |     87.5 |     100 |     100 | 66-80             
 ...cp-integration |   68.02 |    70.81 |   88.79 |   68.02 |                   
  acpAgent.ts      |   67.63 |    70.62 |   88.79 |   67.63 | ...18,10623-10625 
  authMethods.ts   |      92 |       60 |     100 |      92 | 33-34             
  errorCodes.ts    |       0 |        0 |       0 |       0 | 1-22              
  ...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.04 |    95.71 |   93.33 |   97.04 |                   
  filesystem.ts    |   97.04 |    95.71 |   93.33 |   97.04 | ...21-122,238-239 
 ...ration/session |    91.4 |    85.27 |   95.86 |    91.4 |                   
  Session.ts       |   90.93 |    83.91 |   95.05 |   90.93 | ...8196,8223-8227 
  ...entTracker.ts |   91.87 |    89.18 |   88.88 |   91.87 | ...33,197,280-289 
  ...stop-guard.ts |     100 |    97.05 |     100 |     100 | 37,127,247        
  ...eplay-page.ts |   92.27 |    88.09 |     100 |   92.27 | ...83,108-118,121 
  ...y-replayer.ts |    98.5 |    95.38 |     100 |    98.5 | 229-231           
  index.ts         |       0 |        0 |       0 |       0 | 1-40              
  ...ssionUtils.ts |   89.76 |    86.76 |     100 |   89.76 | ...54-270,326-328 
  tasksSnapshot.ts |   94.26 |     87.5 |     100 |   94.26 | 65-71             
  ...on-tracker.ts |     100 |      100 |     100 |     100 |                   
  types.ts         |     100 |      100 |     100 |     100 |                   
 ...ssion/emitters |   95.68 |     93.7 |   96.66 |   95.68 |                   
  ...ageEmitter.ts |   95.34 |    94.11 |     100 |   95.34 | 52-59             
  PlanEmitter.ts   |     100 |    83.33 |     100 |     100 | 59                
  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.17 |    97.43 |     100 |   99.17 | 352-353           
 ...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/commands      |   88.74 |    73.18 |   64.51 |   88.74 |                   
  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        |   97.77 |      100 |      50 |   97.77 | 56                
  serve.ts         |   86.44 |     67.3 |     100 |   86.44 | ...08-611,625-629 
  sessions.ts      |     100 |      100 |      50 |     100 |                   
  update.ts        |   98.13 |    94.44 |   66.66 |   98.13 | 82-83             
 ...mmands/channel |    86.7 |    87.22 |   90.11 |    86.7 |                   
  channel-cwd.ts   |     100 |      100 |     100 |     100 |                   
  ...l-registry.ts |   79.31 |    84.61 |      80 |   79.31 | 35-38,47-50,61-64 
  ...entry-path.ts |      75 |       50 |     100 |      75 | 8-9               
  config-utils.ts  |   95.85 |    96.29 |     100 |   95.85 | ...08-213,271-274 
  configure.ts     |    14.7 |      100 |       0 |    14.7 | 18-21,23-84       
  daemon-worker.ts |   94.69 |    85.77 |   97.61 |   94.69 | ...90-991,995-996 
  ...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       |   72.85 |      100 |      50 |   72.85 | 22-28,57-68       
  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       |   81.22 |    87.27 |     100 |   81.22 | ...65-169,229-231 
  set.ts           |   75.72 |    85.71 |      50 |   75.72 | 65-83,111-116     
  start.ts         |   75.68 |    75.28 |   66.66 |   75.68 | ...56,562-565,577 
  ...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.82 |    87.82 |   87.09 |   88.82 |                   
  consent.ts       |   72.53 |       90 |   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 |    55.55 |     100 |      75 | ...27-131,133-137 
 ...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.17 |    84.39 |   83.33 |   90.17 |                   
  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          |   92.59 |    83.87 |      80 |   92.59 | ...62-164,180-181 
  reconnect.ts     |   78.85 |    66.66 |   85.71 |   78.85 | 42-55,169-191     
  remove.ts        |     100 |       80 |     100 |     100 | 21-25             
 ...ommands/review |   79.87 |    86.45 |   80.15 |   79.87 |                   
  agent-prompt.ts  |   90.85 |    92.78 |      96 |   90.85 | ...1256,1710-1779 
  capture-local.ts |   72.16 |     90.9 |      75 |   72.16 | 101-105,152-174   
  ...k-coverage.ts |   48.38 |    14.28 |   66.66 |   48.38 | ...21-226,239-249 
  cleanup.ts       |   64.28 |    45.45 |      50 |   64.28 | ...33-138,140-141 
  ...ose-review.ts |   95.42 |    92.13 |   91.66 |   95.42 | ...1099,1127-1143 
  fetch-pr.ts      |   24.78 |      100 |    12.5 |   24.78 | ...27-326,367-369 
  load-rules.ts    |   26.41 |      100 |   16.66 |   26.41 | ...41-153,155-156 
  parse-args.ts    |   99.25 |       96 |     100 |   99.25 | 341,413           
  plan-diff.ts     |    67.9 |      100 |   66.66 |    67.9 | 121-148           
  pr-context.ts    |   84.02 |    76.37 |   91.66 |   84.02 | ...22-903,932-934 
  presubmit.ts     |   74.32 |       82 |   85.71 |   74.32 | ...46-347,399-429 
  ...ve-anchors.ts |   77.02 |    88.46 |      75 |   77.02 | ...70-175,187-204 
  submit.ts        |   74.44 |    80.82 |      80 |   74.44 | ...48-584,586-587 
  test-efficacy.ts |   80.68 |    69.41 |    92.3 |   80.68 | ...93-594,602-622 
 ...nds/review/lib |   95.46 |    92.65 |   94.81 |   95.46 |                   
  agent-briefs.ts  |   98.68 |      100 |       0 |   98.68 | 493-494           
  anchors.ts       |     100 |    94.79 |     100 |     100 | ...33,169,178,225 
  coverage.ts      |   95.37 |    94.08 |   95.45 |   95.37 | ...98,335,429-446 
  diff-flags.ts    |     100 |        0 |     100 |     100 | 63                
  diff-plan.ts     |   98.73 |    92.93 |     100 |   98.73 | ...41,264,290-291 
  gh.ts            |   85.27 |     87.5 |   69.23 |   85.27 | ...01,238-239,266 
  git.ts           |   97.64 |    95.65 |     100 |   97.64 | 180-181           
  heavy.ts         |     100 |      100 |     100 |     100 |                   
  inline-counts.ts |     100 |      100 |     100 |     100 |                   
  local-diff.ts    |    84.4 |    88.46 |     100 |    84.4 | ...63-473,475-483 
  merge-base.ts    |     100 |      100 |     100 |     100 |                   
  path-rules.ts    |     100 |      100 |     100 |     100 |                   
  paths.ts         |    92.3 |    83.33 |   83.33 |    92.3 | 76-77             
  prompt-record.ts |   94.73 |    88.23 |     100 |   94.73 | ...28,151-152,156 
  report.ts        |   92.13 |    86.66 |     100 |   92.13 | 170-171,173-177   
  roster.ts        |     100 |    92.85 |     100 |     100 | 104,118,163       
  shell-quote.ts   |     100 |      100 |     100 |     100 |                   
  transcripts.ts   |   96.27 |    93.18 |     100 |   96.27 | ...83,269-270,294 
  workspaces.ts    |   97.76 |     91.3 |     100 |   97.76 | 186-187,212-213   
 ...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.49 |    88.58 |   95.48 |   94.49 |                   
  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 
  config.ts        |   88.29 |    88.03 |   84.84 |   88.29 | ...2375,2377-2385 
  ...heme-names.ts |     100 |      100 |     100 |     100 |                   
  environment.ts   |   94.18 |     89.4 |   94.73 |   94.18 | ...22-626,642-643 
  ...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.74 |     100 |     100 | 47,160,220        
  keyBindings.ts   |   97.24 |       50 |     100 |   97.24 | 221-224           
  ...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.96 |     100 |   98.97 | 85                
  mcpApprovals.ts  |   96.55 |    95.65 |     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 |   61.64 |    71.87 |   66.66 |   61.64 | ...54-68,73,77-89 
  ...ings-cache.ts |   96.52 |    93.93 |     100 |   96.52 | 90-91,201-202     
  settings.ts      |    90.6 |    91.84 |   89.65 |    90.6 | ...61,963,965-966 
  ...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 |                   
  ...paths-lite.ts |   89.47 |       88 |     100 |   89.47 | 43-44,53-54,56-57 
  ...tedFolders.ts |   94.46 |    95.68 |     100 |   94.46 | ...53-354,390-401 
 ...nfig/migration |   95.23 |    77.77 |   83.33 |   95.23 |                   
  index.ts         |   95.65 |     87.5 |     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/i18n          |   85.83 |    81.92 |   89.65 |   85.83 |                   
  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 |    76.31 |   81.35 |      80 |                   
  session.ts       |   84.08 |    75.27 |   93.61 |   84.08 | ...1007,1016-1026 
  types.ts         |    42.5 |      100 |   33.33 |    42.5 | ...24-625,628-629 
 ...active/control |   76.11 |    89.09 |      80 |   76.11 |                   
  ...rolContext.ts |    6.45 |        0 |       0 |    6.45 | 56-95             
  ...Dispatcher.ts |   91.79 |    92.45 |   88.88 |   91.79 | ...49-367,387,390 
  ...rolService.ts |     7.4 |        0 |       0 |     7.4 | 46-185            
 ...ol/controllers |   39.72 |    62.93 |   47.22 |   39.72 |                   
  ...Controller.ts |   39.49 |      100 |      80 |   39.49 | 88-92,127-210     
  ...Controller.ts |       0 |        0 |       0 |       0 | 1-56              
  ...Controller.ts |   49.11 |    62.96 |   54.54 |   49.11 | ...63-568,570-575 
  ...Controller.ts |   14.06 |      100 |       0 |   14.06 | ...82-117,130-133 
  ...Controller.ts |    37.8 |       60 |   46.66 |    37.8 | ...40-652,661-690 
 .../control/types |       0 |        0 |       0 |       0 |                   
  serviceAPIs.ts   |       0 |        0 |       0 |       0 | 1                 
 ...Interactive/io |   98.14 |     94.4 |   95.23 |   98.14 |                   
  ...putAdapter.ts |   98.09 |    93.65 |   98.07 |   98.09 | ...1319,1422-1423 
  ...putAdapter.ts |      96 |    91.66 |   85.71 |      96 | 51-52             
  ...nputReader.ts |     100 |    94.73 |     100 |     100 | 67                
  ...putAdapter.ts |   98.38 |      100 |   90.47 |   98.38 | 84-85,125-126     
  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/serve         |   87.87 |    83.94 |   90.95 |   87.87 |                   
  ...tp-enabled.ts |     100 |      100 |     100 |     100 |                   
  ...ion-bridge.ts |     100 |      100 |     100 |     100 |                   
  auth.ts          |    93.4 |    92.95 |     100 |    93.4 | ...19-320,323-325 
  ...em-adapter.ts |     100 |      100 |     100 |     100 |                   
  capabilities.ts  |     100 |    97.77 |     100 |     100 | 603               
  ...cp-command.ts |     100 |      100 |     100 |     100 |                   
  ...-selection.ts |     100 |      100 |     100 |     100 |                   
  ...ings-store.ts |   85.85 |    91.78 |   95.83 |   85.85 | ...94-206,366-369 
  ...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 |   90.97 |    85.34 |     100 |   90.97 | ...80-684,690-694 
  ...er-manager.ts |   95.12 |    88.82 |   94.28 |   95.12 | ...68,492,503-505 
  ...tartup-ipc.ts |   97.72 |    96.66 |     100 |   97.72 | 82-83             
  ...supervisor.ts |   96.57 |     86.9 |   96.49 |   96.57 | ...1026,1134-1138 
  ...e-grouping.ts |     100 |    94.11 |     100 |     100 | 69,132            
  ...ub-session.ts |   92.04 |    77.77 |     100 |   92.04 | ...36-445,470,508 
  daemon-logger.ts |    82.2 |    77.31 |   91.76 |    82.2 | ...1720,1747-1753 
  ...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.37 |    90.06 |     100 |   98.37 | ...1037,1039-1040 
  debug-mode.ts    |     100 |      100 |     100 |     100 |                   
  demo.ts          |     100 |      100 |     100 |     100 |                   
  env-snapshot.ts  |    91.3 |       80 |     100 |    91.3 | ...24-127,205-212 
  ...-scheduler.ts |   87.34 |    83.87 |     100 |   87.34 | 33-36,48-50,79-81 
  ...-path-argv.ts |     100 |      100 |     100 |     100 |                   
  ...h-settings.ts |   94.39 |    88.75 |     100 |   94.39 | ...22,700,716,726 
  fast-path.ts     |    91.3 |    81.98 |   95.45 |    91.3 | ...65-474,540-541 
  ...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-143             
  ...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 | ...27-128,139-140 
  ...iders-edit.ts |     100 |    82.14 |     100 |     100 | 58-60,65,81       
  ...sion-audit.ts |     100 |      100 |   93.33 |     100 |                   
  rate-limit.ts    |   92.77 |    88.42 |     100 |   92.77 | ...93-295,307-309 
  ...qwen-serve.ts |   84.78 |     80.8 |   72.68 |   84.78 | ...5593,5598-5599 
  ...tup-errors.ts |     100 |      100 |     100 |     100 |                   
  ...-keepalive.ts |   96.03 |    90.72 |     100 |   96.03 | ...36,498-500,540 
  ...-lifecycle.ts |     100 |      100 |     100 |     100 |                   
  server.ts        |   95.62 |    93.09 |   78.94 |   95.62 | ...1784,1804-1807 
  ...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 |                   
  ...erver-name.ts |     100 |      100 |     100 |     100 |                   
  ...ion-limits.ts |     100 |      100 |     100 |     100 |                   
  ...t-sessions.ts |   93.34 |    76.57 |     100 |   93.34 | ...17,820,833-835 
  ...l-resolver.ts |   90.32 |    66.66 |     100 |   90.32 | 16,45-46          
  ...ell-static.ts |   91.07 |    86.66 |     100 |   91.07 | ...79-182,216-219 
  ...ace-agents.ts |   64.79 |    71.33 |   91.66 |   64.79 | ...2125,2135-2145 
  ...generation.ts |    95.4 |    82.35 |   66.66 |    95.4 | 55-56,78,92       
  ...-git-state.ts |     100 |       90 |    87.5 |     100 | 61,121            
  ...ace-inputs.ts |     100 |      100 |     100 |     100 |                   
  ...-constants.ts |     100 |      100 |     100 |     100 |                   
  ...-summaries.ts |   86.66 |       50 |     100 |   86.66 | 11,19             
  ...ace-memory.ts |   82.19 |    75.28 |     100 |   82.19 | ...82-489,549-556 
  ...ers-status.ts |   98.52 |       79 |     100 |   98.52 | 94,122,162,165    
  ...tion-store.ts |   89.63 |    88.27 |   92.59 |   89.63 | ...91-400,411-414 
  ...e-registry.ts |   91.26 |     90.8 |     100 |   91.26 | ...93-294,300-301 
  ...ber-errors.ts |     100 |    95.32 |     100 |     100 | 53,93-94,172,192  
  ...e-remember.ts |   97.94 |    94.33 |     100 |   97.94 | ...00,304-309,350 
  ...te-runtime.ts |   93.14 |    87.71 |     100 |   93.14 | ...-88,92,145-150 
  ...management.ts |   71.84 |    71.67 |      96 |   71.84 | ...65-866,873-877 
  ...ls-mapping.ts |     100 |      100 |     100 |     100 |                   
  ...lls-status.ts |     100 |    94.73 |     100 |     100 | 109               
 ...serve/acp-http |   75.83 |     78.3 |   93.85 |   75.83 |                   
  ...r-registry.ts |     100 |    95.45 |     100 |     100 | 191               
  client-mcp-ws.ts |   54.85 |    58.62 |   72.72 |   54.85 | ...99-300,304-305 
  ...n-registry.ts |   98.19 |    88.55 |     100 |   98.19 | 1015,1037-1048    
  dispatch.ts      |   69.34 |    74.79 |     100 |   69.34 | ...4525,4573-4579 
  index.ts         |   82.04 |    78.69 |   89.58 |   82.04 | ...2197,2228-2230 
  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 |   85.73 |    73.17 |    97.5 |   85.73 |                   
  ...r-emulator.ts |   88.57 |    63.63 |     100 |   88.57 | ...72-175,194-195 
  ...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 |       0 |        0 |       0 |       0 |                   
  ...mcp-smoke.mjs |       0 |        0 |       0 |       0 | 1-119             
  ...cceptance.mjs |       0 |        0 |       0 |       0 | 1-473             
  real-tab.mjs     |       0 |        0 |       0 |       0 | 1-218             
 src/serve/fs      |   85.68 |    80.09 |     100 |   85.68 |                   
  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 |     73.8 |     100 |   77.64 | ...65,594-598,611 
  policy.ts        |   90.32 |    89.18 |     100 |   90.32 | 142-150           
  ...ile-system.ts |   85.19 |     78.6 |     100 |   85.19 | ...2094,2104-2105 
 src/serve/routes  |   85.39 |    79.74 |   95.91 |   85.39 |                   
  a2ui-action.ts   |   99.49 |    94.52 |    87.5 |   99.49 | 250               
  capabilities.ts  |     100 |      100 |     100 |     100 |                   
  ...l-webhooks.ts |   93.56 |    84.09 |     100 |   93.56 | ...42,292,332,334 
  daemon-status.ts |   85.45 |    83.33 |     100 |   85.45 | 98-105            
  goals.ts         |    98.8 |    88.46 |     100 |    98.8 | 134               
  health-demo.ts   |   94.17 |    83.33 |     100 |   94.17 | 62-66,143         
  permission.ts    |     100 |     92.3 |     100 |     100 | 50,98             
  ...uled-tasks.ts |    84.2 |    83.18 |     100 |    84.2 | ...55-863,980-981 
  ...on-runtime.ts |     100 |     87.5 |     100 |     100 | 43,79             
  session.ts       |   86.24 |    81.76 |   94.82 |   86.24 | ...3824,3826-3827 
  sse-events.ts    |   84.45 |     87.5 |   77.77 |   84.45 | ...36,453-456,485 
  usage-stats.ts   |     100 |    95.65 |     100 |     100 | 116               
  ...space-auth.ts |    83.7 |       75 |     100 |    83.7 | ...23,328,340-344 
  ...el-control.ts |   86.26 |    78.94 |     100 |   86.26 | ...17-318,339-347 
  ...d-contacts.ts |     100 |      100 |     100 |     100 |                   
  ...controller.ts |    82.1 |    77.17 |      90 |    82.1 | ...1000,1006,1009 
  ...extensions.ts |   87.44 |    72.76 |   95.74 |   87.44 | ...1788,1830-1831 
  ...-file-read.ts |   92.32 |       80 |     100 |   92.32 | ...94-595,598-599 
  ...file-write.ts |   84.44 |    64.13 |     100 |   84.44 | ...73-275,355-357 
  ...e-git-diff.ts |   94.11 |    91.89 |     100 |   94.11 | ...54-155,201-206 
  ...ce-git-log.ts |     100 |    92.68 |     100 |     100 | 51,76,182         
  workspace-git.ts |   62.19 |    83.33 |     100 |   62.19 | 71-81,87-107      
  ...-lifecycle.ts |   96.85 |       75 |     100 |   96.85 | 130-131,161-162   
  ...management.ts |   87.43 |    85.13 |     100 |   87.43 | ...1441,1461-1466 
  ...cp-control.ts |   71.29 |       67 |     100 |   71.29 | ...67-573,582-583 
  ...ace-models.ts |   95.87 |    92.42 |     100 |   95.87 | 38-39,136-141     
  ...ermissions.ts |   74.66 |    69.23 |     100 |   74.66 | ...25-233,254-271 
  ...e-settings.ts |   72.81 |     69.9 |     100 |   72.81 | ...85-589,594-604 
  ...tup-github.ts |   77.58 |    70.27 |   84.21 |   77.58 | ...88,310,354-355 
  ...ace-skills.ts |   69.87 |    78.12 |     100 |   69.87 | ...59-284,290-324 
  ...ace-status.ts |   75.41 |    63.51 |     100 |   75.41 | ...35-336,360-361 
  ...pace-tools.ts |   74.82 |    69.23 |     100 |   74.82 | ...41-146,175-176 
  ...pace-trust.ts |   76.08 |       50 |   66.66 |   76.08 | ...01-206,214-215 
  ...pace-voice.ts |   91.45 |    82.35 |     100 |   91.45 | ...21-624,627-629 
 src/serve/server  |   90.53 |    89.41 |      95 |   90.53 |                   
  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 |    86.95 |     100 |    98.8 | 107               
  ...r-handlers.ts |   97.14 |    71.42 |     100 |   97.14 | 16                
  ...r-response.ts |    85.4 |    76.16 |     100 |    85.4 | ...91,708,771-780 
  fs-factory.ts    |     100 |    92.59 |     100 |     100 | 33,41,100,156     
  ...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.11 |    95.09 |     100 |   95.11 | ...65-167,422-427 
  self-origin.ts   |   76.19 |       80 |     100 |   76.19 | 45-54             
  ...e-features.ts |    94.3 |       92 |     100 |    94.3 | 159-165           
  ...on-archive.ts |   89.61 |    90.38 |   88.23 |   89.61 | ...36-441,513-523 
  ...ion-export.ts |     100 |    94.44 |     100 |     100 | 64                
  session-list.ts  |   93.55 |    91.01 |     100 |   93.55 | ...79,681-687,827 
  telemetry.ts     |   98.72 |     97.4 |     100 |   98.72 | ...26-628,769-771 
 src/serve/voice   |   85.15 |     93.1 |   90.47 |   85.15 |                   
  ...ice-config.ts |   96.77 |       30 |     100 |   96.77 | 85-86             
  voice-ws.ts      |   77.97 |    96.39 |   83.33 |   77.97 | ...55,470,508-510 
  ...oordinator.ts |     100 |    98.11 |     100 |     100 | 171               
 ...kspace-service |   89.53 |     83.4 |   89.47 |   89.53 |                   
  index.ts         |   89.05 |     82.9 |   87.87 |   89.05 | ...1158-1162,1165 
  types.ts         |     100 |      100 |     100 |     100 |                   
 src/services      |   91.96 |    88.37 |   97.81 |   91.96 |                   
  ...mandLoader.ts |     100 |    88.88 |     100 |     100 | 104-117           
  ...killLoader.ts |   97.14 |    87.87 |     100 |   97.14 | 140,151-152       
  ...andService.ts |   98.73 |      100 |     100 |   98.73 | 107               
  ...mandLoader.ts |   86.83 |    83.87 |     100 |   86.83 | ...30-335,340-345 
  ...omptLoader.ts |   77.36 |    85.52 |   83.33 |   77.36 | ...43,168,210-211 
  ...mandLoader.ts |   97.36 |    92.68 |     100 |   97.36 | 153,160-161       
  ...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 |    93.75 |     100 |   96.66 | 34-35             
  ...tree-lease.ts |   88.29 |    86.11 |     100 |   88.29 | ...91-196,229-230 
  ...low-loader.ts |     100 |    96.15 |     100 |     100 | 88                
  setup-github.ts  |    90.5 |    81.81 |     100 |    90.5 | ...37-438,445-446 
  ...-args-file.ts |   93.54 |    90.47 |    87.5 |   93.54 | 201-203,217-223   
  types.ts         |     100 |      100 |     100 |     100 |                   
  ...e-keyterms.ts |   98.64 |    95.71 |     100 |   98.64 | 116,142-143       
  voice-model.ts   |     100 |      100 |     100 |     100 |                   
  voice-service.ts |   88.14 |    87.69 |     100 |   88.14 | ...80,287,352-357 
  ...e-settings.ts |     100 |    95.23 |     100 |     100 | 19                
  ...ranscriber.ts |   90.46 |    82.11 |      96 |   90.46 | ...66-668,671-673 
 ...ght/generators |   88.86 |    85.78 |   96.29 |   88.86 |                   
  DataProcessor.ts |   88.23 |    85.71 |      95 |   88.23 | ...1348,1352-1359 
  ...tGenerator.ts |   98.21 |    85.71 |     100 |   98.21 | 46                
  ...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 | 95-98             
  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.04 |    83.33 |      80 |   94.04 |                   
  ...omMatchers.ts |   69.69 |       50 |      50 |   69.69 | 32-35,37-39,45-47 
  ...andContext.ts |     100 |      100 |     100 |     100 |                   
  render.tsx       |     100 |      100 |     100 |     100 |                   
 src/ui            |   71.01 |    73.07 |   66.66 |   71.01 |                   
  App.tsx          |   33.33 |       75 |   33.33 |   33.33 | 32-86             
  AppContainer.tsx |   72.24 |     70.1 |   66.66 |   72.24 | ...4026,4030-4034 
  ...tionNudge.tsx |    9.58 |      100 |       0 |    9.58 | 24-94             
  ...ackDialog.tsx |   29.23 |      100 |       0 |   29.23 | 25-75             
  ...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 |   62.73 |    47.22 |   66.66 |   62.73 | ...95-296,313-318 
  ...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.45 |    66.18 |   51.06 |   58.45 |                   
  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.03 |    70.73 |   57.69 |   60.03 | ...87,791,800,803 
  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   |   80.75 |    83.26 |   88.83 |   80.75 |                   
  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  |   62.81 |    58.73 |   65.21 |   62.81 | ...90-595,680-688 
  authCommand.ts   |     100 |      100 |     100 |     100 |                   
  branchCommand.ts |     100 |      100 |     100 |     100 |                   
  btwCommand.ts    |   94.32 |    77.41 |     100 |   94.32 | 35-36,114-119     
  bugCommand.ts    |     100 |    77.77 |     100 |     100 | 27,61             
  cdCommand.ts     |    92.1 |     84.9 |     100 |    92.1 | ...4-69,94-99,178 
  clearCommand.ts  |    80.9 |    70.83 |     100 |    80.9 | ...24-125,133-142 
  ...essCommand.ts |   67.95 |    55.88 |      75 |   67.95 | ...86-187,201-204 
  ...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 |   67.81 |    69.69 |   84.61 |   67.81 | ...59-592,603-604 
  copyCommand.ts   |   98.49 |    95.78 |     100 |   98.49 | ...80,280,321,327 
  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 |   82.97 |    78.57 |     100 |   82.97 | 47-52,67-70,91-96 
  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   |   91.13 |    83.72 |      90 |   91.13 | ...81-184,196-199 
  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 |   93.45 |    89.06 |     100 |   93.45 | ...68-169,196-206 
  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  |    81.1 |     89.5 |   88.23 |    81.1 | ...80-793,827-832 
  ...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.9 |    86.04 |     100 |    90.9 | ...41-146,176-177 
  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.6 |    77.95 |     100 |    90.6 | ...91-694,785-792 
  ...ineCommand.ts |     100 |      100 |     100 |     100 |                   
  ...aryCommand.ts |    6.43 |      100 |      50 |    6.43 | 31-330            
  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 |   91.82 |    78.87 |   66.66 |   91.82 | ...59-160,169-174 
 src/ui/components |   69.54 |    78.22 |   76.11 |   69.54 |                   
  AboutBox.tsx     |     100 |      100 |     100 |     100 |                   
  ...ateScreen.tsx |   97.29 |     87.5 |   66.66 |   97.29 | 49                
  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 |   86.72 |    86.66 |     100 |   86.72 | ...00-302,355-359 
  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 | 18                
  ...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-596             
  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       |   78.71 |     62.5 |     100 |   78.71 | ...28-233,251-255 
  ...ngSpinner.tsx |   68.42 |    85.71 |      50 |   68.42 | 35-52,73,80-81    
  GoalPill.tsx     |   83.33 |    76.92 |     100 |   83.33 | 24-30             
  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 |   78.22 |    64.28 |     100 |   78.22 | ...94,497,500-506 
  ...ngeDialog.tsx |     100 |      100 |     100 |     100 |                   
  InputPrompt.tsx  |   82.25 |    79.81 |      80 |   82.25 | ...2161,2187,2247 
  ...Shortcuts.tsx |   20.65 |      100 |       0 |   20.65 | ...7,50-52,68-126 
  ...Indicator.tsx |   98.18 |    97.82 |     100 |   98.18 | 161-162           
  ...firmation.tsx |   91.42 |      100 |      50 |   91.42 | 26-31             
  MainContent.tsx  |   95.54 |    93.84 |      50 |   95.54 | ...93,436-440,443 
  MemoryDialog.tsx |   86.59 |    80.15 |     100 |   86.59 | ...34-435,485,553 
  ...geDisplay.tsx |       0 |        0 |       0 |       0 | 1-41              
  ModelDialog.tsx  |   86.41 |       73 |     100 |   86.41 | ...74,876,881-897 
  ...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 |   72.56 |       80 |      40 |   72.56 | ...06-109,114-117 
  ...tedDialog.tsx |     100 |      100 |     100 |     100 |                   
  ...ngsDialog.tsx |   71.47 |    73.89 |   69.23 |   71.47 | ...1243,1249-1250 
  ...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 |    5.46 |      100 |       0 |    5.46 | 24-215            
  ...ineDialog.tsx |    93.5 |    85.18 |     100 |    93.5 | ...05,267,287-289 
  ...yTodoList.tsx |   96.33 |    88.23 |     100 |   96.33 | 137-140           
  ...nsDisplay.tsx |   92.95 |       85 |     100 |   92.95 | ...79,182,209-211 
  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             
  ...criptView.tsx |   98.27 |    84.21 |     100 |   98.27 | 45,53             
  TrustDialog.tsx  |     100 |    81.81 |     100 |     100 | 71-86             
  ...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 |   53.72 |    70.87 |   42.85 |   53.72 |                   
  ...atContent.tsx |    9.09 |      100 |       0 |    9.09 | 54-275,281-283    
  ...tChatView.tsx |   21.05 |      100 |       0 |   21.05 | 21-39             
  ...tComposer.tsx |   64.78 |    29.41 |   33.33 |   64.78 | ...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.38 |    68.69 |   73.68 |   42.38 |                   
  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-164             
  ...tusDialog.tsx |       0 |        0 |       0 |       0 | 1-288             
  ...topDialog.tsx |       0 |        0 |       0 |       0 | 1-213             
 ...ackground-view |    82.2 |    81.36 |    90.9 |    82.2 |                   
  ...sksDialog.tsx |   77.53 |     76.9 |   80.76 |   77.53 | ...1781,1803-1809 
  ...TasksPill.tsx |   67.03 |     86.2 |     100 |   67.03 | ...02-122,130-138 
  ...gentPanel.tsx |   97.08 |    86.31 |     100 |   97.08 | 132,442-446,520   
  agent-forest.ts  |    99.2 |    93.93 |     100 |    99.2 | 256               
  ...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.86 |    68.14 |   70.83 |   71.86 |                   
  DiscoverTab.tsx  |   68.22 |    67.66 |   55.55 |   68.22 | ...93,656-660,664 
  InstalledTab.tsx |   75.45 |    67.28 |   83.33 |   75.45 | ...76,781-782,819 
  SourcesTab.tsx   |   71.52 |    70.47 |   77.77 |   71.52 | ...27,546,618-630 
 ...tensions/views |   50.97 |    52.38 |   20.83 |   50.97 |                   
  ...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.56 |      100 |       0 |    9.56 | 40-67,70-158      
 ...mponents/hooks |   86.99 |    81.37 |   91.89 |   86.99 |                   
  ...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.04 |    61.53 |   70.58 |   40.04 |                   
  ...ealthPill.tsx |   68.42 |    85.71 |     100 |   68.42 | 40-46             
  ...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.9 |    73.51 |   57.14 |    53.9 |                   
  ...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.46 |    81.25 |     100 |   88.46 | ...63,169,174-179 
  ...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 |   89.88 |       86 |   86.86 |   89.88 |                   
  ...ionDialog.tsx |   89.23 |    84.27 |   81.81 |   89.23 | ...75,593,611-613 
  BtwMessage.tsx   |     100 |      100 |     100 |     100 |                   
  ...upDisplay.tsx |     100 |    94.79 |     100 |     100 | 38,42,44,290,366  
  ...onMessage.tsx |   91.93 |    82.35 |     100 |   91.93 | 57-59,61,63       
  ...nMessages.tsx |    96.7 |    97.77 |   91.66 |    96.7 | 222-232           
  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 |   76.31 |     42.1 |   66.66 |   76.31 | ...99,101,124,155 
  ...tsDisplay.tsx |    95.5 |    88.31 |     100 |    95.5 | ...39,141,174-179 
  ...ssMessage.tsx |    12.5 |      100 |       0 |    12.5 | 18-59             
  ...edMessage.tsx |   16.66 |      100 |       0 |   16.66 | 22-38             
  ...sMessages.tsx |   58.65 |       50 |    37.5 |   58.65 | ...20-125,146-158 
  ...ryMessage.tsx |   14.28 |      100 |       0 |   14.28 | 23-62             
  ...onMessage.tsx |   89.75 |     79.1 |     100 |   89.75 | ...33-635,642-644 
  ...upMessage.tsx |   98.32 |    95.16 |     100 |   98.32 | 183-186,413       
  ToolMessage.tsx  |   92.43 |    84.84 |   93.33 |   92.43 | ...56-961,988-990 
 ...ponents/shared |   85.73 |    82.05 |   94.05 |   85.73 |                   
  ...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.86 |      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 |   72.72 |      100 |     100 |   72.72 | 31-33             
  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 |   88.51 |    85.11 |   81.81 |   88.51 | ...51-779,792,887 
  text-buffer.ts   |   85.94 |    81.73 |   97.91 |   85.94 | ...2651,2749-2750 
  ...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-678             
 ...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.04 |    53.19 |    37.5 |   14.04 |                   
  ...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.42 |    59.52 |     100 |   35.42 | ...20-432,437-439 
  ...iewerStep.tsx |       0 |        0 |       0 |       0 | 1-73              
  ...gerDialog.tsx |       0 |        0 |       0 |       0 | 1-341             
 ...mponents/views |   69.81 |    72.64 |   61.11 |   69.81 |                   
  ContextUsage.tsx |   70.88 |    63.88 |      80 |   70.88 | ...20-426,463-557 
  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   |    82.3 |    80.15 |   84.37 |    82.3 |                   
  ...ewContext.tsx |   64.83 |    88.88 |      50 |   64.83 | ...16-219,225-235 
  AppContext.tsx   |      80 |       50 |     100 |      80 | 19-20             
  ...ewContext.tsx |   92.45 |    62.79 |      50 |   92.45 | ...69-270,272-276 
  ...igContext.tsx |   81.81 |       50 |     100 |   81.81 | 15-16             
  ...ssContext.tsx |   83.43 |    84.58 |     100 |   83.43 | ...1313,1321-1323 
  ...owContext.tsx |   91.07 |    81.81 |     100 |   91.07 | 47-48,60-62       
  ...deContext.tsx |     100 |      100 |      50 |     100 |                   
  ...onContext.tsx |   78.68 |    73.77 |   91.66 |   78.68 | ...86-389,398-401 
  ...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 | 150-151           
  ...teContext.tsx |   86.66 |       50 |     100 |   86.66 | 233-234           
  ...deContext.tsx |      80 |     87.5 |      75 |      80 | ...11-112,118-120 
 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      |   84.29 |    82.13 |   89.06 |   84.29 |                   
  ...dProcessor.ts |   81.73 |    81.69 |     100 |   81.73 | ...41-742,748-753 
  ...ention-ref.ts |   97.67 |       84 |     100 |   97.67 | 65                
  keyToAnsi.ts     |    3.92 |      100 |       0 |    3.92 | 19-77             
  ...esourceRef.ts |     100 |      100 |     100 |     100 |                   
  ...dProcessor.ts |   94.62 |    73.58 |     100 |   94.62 | ...86-287,292-293 
  ...dProcessor.ts |   85.14 |    66.27 |   81.81 |   85.14 | ...1400,1421-1425 
  ...rt-command.ts |     100 |      100 |     100 |     100 |                   
  ...sced-flush.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 |   89.83 |    88.97 |     100 |   89.83 | ...49-456,496-505 
  ...ifications.ts |   87.82 |    96.77 |     100 |   87.82 | 138-152           
  ...tIndicator.ts |   88.28 |    81.08 |     100 |   88.28 | ...66,175,179-187 
  ...waySummary.ts |   96.22 |    69.69 |     100 |   96.22 | 125-127,169       
  ...ndTaskView.ts |   94.73 |    76.59 |     100 |   94.73 | 162-166,255,261   
  ...chedScroll.ts |     100 |      100 |     100 |     100 |                   
  ...ketedPaste.ts |    23.8 |      100 |       0 |    23.8 | 19-37             
  ...nchCommand.ts |   94.85 |    80.76 |     100 |   94.85 | ...54,229,292-295 
  ...ompletion.tsx |   96.75 |    81.81 |     100 |   96.75 | ...78-279,289-290 
  ...dMigration.ts |    92.1 |    88.88 |     100 |    92.1 | 42-44             
  useCompletion.ts |   94.11 |    89.65 |     100 |   94.11 | ...32-133,137-138 
  ...nitMessage.ts |     100 |      100 |     100 |     100 |                   
  ...extualTips.ts |   78.26 |       50 |     100 |   78.26 | ...2,75-79,96-104 
  ...eteCommand.ts |   78.53 |    88.57 |     100 |   78.53 | ...96-104,112-113 
  ...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.7 |     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 |      100 |     100 |     100 |                   
  ...ggestions.tsx |   96.47 |    78.94 |     100 |   96.47 | 121,155-156       
  ...miniStream.ts |   85.04 |    80.81 |   96.15 |   85.04 | ...3878,4040-4048 
  ...BranchName.ts |     100 |    91.66 |     100 |     100 | 30                
  ...oryManager.ts |   98.01 |    98.36 |     100 |   98.01 | 139-142           
  ...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 |    9.67 |      100 |       0 |    9.67 | 11-32,39-90       
  ...gIndicator.ts |     100 |    96.66 |     100 |     100 | 109               
  useLogger.ts     |      16 |      100 |       0 |      16 | 15-45             
  useMCPHealth.ts  |   63.15 |       80 |      50 |   63.15 | 42-52,64-67       
  ...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 |    96.77 |     100 |     100 | 75                
  ...delCommand.ts |     100 |    92.85 |     100 |     100 | 48                
  ...ouseEvents.ts |   94.31 |    97.43 |   83.33 |   94.31 | 76-80             
  ...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 |    87.4 |    78.78 |     100 |    87.4 | ...71,321-333,381 
  useQwenAuth.ts   |     100 |      100 |     100 |     100 |                   
  ...lScheduler.ts |   91.16 |     90.9 |     100 |   91.16 | ...35-338,453-463 
  ...oryCommand.ts |       0 |        0 |       0 |       0 | 1-7               
  ...tleRepaint.ts |     100 |      100 |     100 |     100 |                   
  ...umeCommand.ts |   94.67 |    74.28 |     100 |   94.67 | ...19,174,233-238 
  ...ompletion.tsx |   90.67 |    83.33 |     100 |   90.67 | ...02,105,138-141 
  ...ectionList.ts |   97.12 |    96.19 |     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 |       0 |        0 |       0 |       0 | 1-73              
  ...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.13 |    93.33 |     100 |   97.13 | ...78-382,478-485 
  ...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 |   53.06 |       50 |   66.66 |   53.06 | ...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 |      100 |     100 |     100 |                   
  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.24 |    79.16 |   71.42 |   80.24 |                   
  ...ableModels.ts |   80.24 |    79.16 |   71.42 |   80.24 | ...,61-71,123-125 
 ...noninteractive |     100 |      100 |    6.66 |     100 |                   
  ...eractiveUi.ts |     100 |      100 |    6.66 |     100 |                   
 src/ui/selection  |   86.47 |    79.88 |   96.66 |   86.47 |                   
  screen-buffer.ts |   94.73 |    64.28 |     100 |   94.73 | 51-52             
  ...ion-coords.ts |     100 |      100 |     100 |     100 |                   
  ...ction-span.ts |   92.72 |       90 |     100 |   92.72 | 37-38,67-68       
  ...tion-state.ts |   85.71 |      100 |   88.88 |   85.71 | 51-58             
  ...ction-text.ts |   92.85 |    92.45 |     100 |   92.85 | 30-34,114-115     
  ...selection.tsx |   80.31 |    59.64 |     100 |   80.31 | ...13-314,330-331 
 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      |   86.01 |     84.9 |   94.67 |   86.01 |                   
  ...Colorizer.tsx |   80.31 |    85.41 |     100 |   80.31 | ...00-201,313-339 
  ...nRenderer.tsx |   68.83 |    70.14 |      50 |   68.83 | ...52-254,274-293 
  ...wnDisplay.tsx |   92.85 |    93.46 |     100 |   92.85 | ...,953,1000-1018 
  ...idDiagram.tsx |   87.79 |    95.34 |     100 |   87.79 | 156-179           
  ...eRenderer.tsx |   92.68 |    82.35 |   95.23 |   92.68 | ...34-737,790-795 
  ...odeDisplay.ts |   94.28 |    85.71 |     100 |   94.28 | 23,40             
  asciiCharts.ts   |   96.77 |    87.62 |     100 |   96.77 | 173-180,281       
  ...dWorkUtils.ts |     100 |      100 |     100 |     100 |                   
  ...boardUtils.ts |   52.52 |    73.25 |   91.66 |   52.52 | ...23,626-635,638 
  commandUtils.ts  |    96.1 |    88.77 |     100 |    96.1 | ...73,175-176,320 
  computeStats.ts  |     100 |      100 |     100 |     100 |                   
  customBanner.ts  |   90.68 |    91.22 |     100 |   90.68 | ...13,324-327,334 
  displayUtils.ts  |   90.38 |    73.91 |     100 |   90.38 | 23,25,29,31,33    
  formatters.ts    |    95.4 |    98.41 |     100 |    95.4 | 123-126           
  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  |    95.4 |    95.08 |     100 |    95.4 | 96-99             
  input-mouse.ts   |     100 |    85.71 |     100 |     100 | 48,93             
  isNarrowWidth.ts |     100 |      100 |     100 |     100 |                   
  ...olDetector.ts |   69.47 |       75 |   66.66 |   69.47 | ...24-129,157-158 
  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.59 |     100 |   98.72 | 145-146           
  ...t-position.ts |     100 |     87.5 |     100 |     100 | 85                
  ...geRenderer.ts |   86.23 |    69.06 |   95.12 |   86.23 | ...1284,1324-1330 
  ...alRenderer.ts |   86.69 |     71.9 |     100 |   86.69 | ...1476,1513-1519 
  ...lsBySource.ts |     100 |    95.23 |     100 |     100 | 84                
  mouse.ts         |   92.85 |    73.77 |     100 |   92.85 | ...38,145,149-152 
  osc8.ts          |   94.84 |    88.74 |     100 |   94.84 | ...57,442,446-447 
  ...red-height.ts |   96.85 |    95.45 |     100 |   96.85 | 71-73,201-203     
  ...mConstants.ts |     100 |      100 |     100 |     100 |                   
  restoreGoal.ts   |     100 |      100 |     100 |     100 |                   
  ...storyUtils.ts |   71.02 |    78.86 |   93.75 |   71.02 | ...03-525,655-656 
  ...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 |   94.94 |      100 |   88.88 |   94.94 | 112-117           
  ...wOptimizer.ts |     100 |    96.77 |     100 |     100 | 69                
  terminalSetup.ts |    4.37 |      100 |       0 |    4.37 | 44-393            
  textUtils.ts     |   95.97 |    93.22 |   94.44 |   95.97 | ...21-322,482-483 
  ...background.ts |     100 |      100 |     100 |     100 |                   
  todoSnapshot.ts  |   89.65 |       92 |     100 |   89.65 | ...83-184,217-218 
  ...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 |    59.89 |   94.59 |      75 |                   
  collect.ts       |   71.21 |    65.81 |      96 |   71.21 | ...88-631,653-654 
  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      |   80.94 |    72.69 |   80.55 |   80.94 |                   
  ...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 |   89.72 |    65.33 |   93.75 |   89.72 | ...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 |    68.42 |     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         |   80.64 |    86.85 |   92.27 |   80.64 |                   
  ...p-profiler.ts |   98.39 |    90.56 |     100 |   98.39 | 141,185,235       
  acpModelUtils.ts |    97.3 |    95.09 |     100 |    97.3 | ...04-205,209-210 
  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      |   96.96 |    97.95 |     100 |   96.96 | 123-125           
  commentJson.ts   |   91.37 |    94.87 |     100 |   91.37 | 67-76             
  ...Calculator.ts |     100 |      100 |     100 |     100 |                   
  cpuProfiler.ts   |   70.73 |    73.23 |   88.88 |   70.73 | ...27,430-431,438 
  deepMerge.ts     |     100 |       90 |     100 |     100 | 41-43,49          
  ...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.17 |     100 |   90.65 | ...72,370,372-373 
  ...arResolver.ts |   97.14 |    96.55 |     100 |   97.14 | 125-126           
  errors.ts        |   97.56 |    94.73 |     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 |   92.39 |    92.23 |     100 |   92.39 | ...52,369-370,415 
  languageUtils.ts |   98.88 |    97.01 |     100 |   98.88 | 184-185           
  load-undici.ts   |     100 |      100 |     100 |     100 |                   
  ...npm-update.ts |   85.55 |       74 |     100 |   85.55 | ...39-240,268-278 
  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.5 |      100 |   88.88 |    97.5 | 195-196           
  package.ts       |   88.88 |    85.71 |     100 |   88.88 | 31-32             
  ...uggestions.ts |   74.38 |    69.56 |     100 |   74.38 | ...92-103,105-116 
  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.67 |    56.93 |   76.92 |   45.67 | ...1034,1046-1069 
  ...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 |     87.5 |     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       
  ...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 |   91.63 |    91.02 |      95 |   91.63 |                   
  cleanup.ts       |   95.77 |    95.83 |     100 |   95.77 | 70-72             
  ...eractionAt.ts |     100 |      100 |     100 |     100 |                   
  scheduler.ts     |   91.91 |    90.47 |    87.5 |   91.91 | 58-62,73,131-135  
  throttledOnce.ts |   86.66 |     86.2 |     100 |   86.66 | ...99,105,137-138 
-------------------|---------|----------|---------|---------|-------------------
Core Package - Full Text Report
-------------------|---------|----------|---------|---------|-------------------
File               | % Stmts | % Branch | % Funcs | % Lines | Uncovered Line #s 
-------------------|---------|----------|---------|---------|-------------------
All files          |   87.04 |    86.15 |   88.45 |   87.04 |                   
 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        |   89.97 |    83.82 |   94.02 |   89.97 |                   
  ...transcript.ts |   88.15 |    84.61 |     100 |   88.15 | ...99,607,613-617 
  ...ent-resume.ts |   84.53 |    76.01 |   78.26 |   84.53 | ...1674-1678,1681 
  ...ound-tasks.ts |   96.14 |     90.1 |   98.76 |   96.14 | ...1728,1748-1751 
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...ent-result.ts |    96.8 |    92.68 |     100 |    96.8 | 106,129-131       
  ...n-registry.ts |   95.65 |    89.28 |     100 |   95.65 | ...12-413,485-489 
  ...w-snapshot.ts |   91.86 |       75 |     100 |   91.86 | ...54,178,185-187 
 src/agents/arena  |   76.27 |    67.71 |   78.94 |   76.27 |                   
  ...gentClient.ts |   79.47 |    88.88 |   81.81 |   79.47 | ...68-183,189-204 
  ArenaManager.ts  |   75.05 |    64.51 |   78.57 |   75.05 | ...1876,1882-1883 
  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.02 |    85.19 |   76.28 |   78.02 |                   
  ITermBackend.ts  |   97.97 |    93.93 |     100 |   97.97 | ...78-180,255,307 
  ...essBackend.ts |    90.8 |    85.24 |   93.33 |    90.8 | ...64,666,668-669 
  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 |   89.22 |     86.2 |   86.86 |   89.22 |                   
  agent-context.ts |     100 |      100 |     100 |     100 |                   
  agent-core.ts    |    81.3 |    76.49 |    74.5 |    81.3 | ...2137,2164-2211 
  agent-events.ts  |     100 |      100 |     100 |     100 |                   
  ...t-headless.ts |   93.49 |    88.09 |   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 |                   
  ...ow-journal.ts |   91.76 |    75.86 |     100 |   91.76 | ...38-139,179-181 
  ...chestrator.ts |   91.79 |    87.79 |   82.35 |   91.79 | ...1774,1823-1826 
  ...ow-prompts.ts |     100 |      100 |     100 |     100 |                   
  ...ow-sandbox.ts |   96.87 |    94.51 |     100 |   96.87 | ...24-325,330-331 
  ...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   |   81.83 |    84.09 |    87.4 |   81.83 |                   
  TeamManager.ts   |   72.04 |     79.6 |   78.84 |   72.04 | ...1629,1652-1653 
  identity.ts      |     100 |      100 |     100 |     100 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...sionBridge.ts |     100 |      100 |     100 |     100 |                   
  mailbox.ts       |   94.76 |    86.36 |   92.85 |   94.76 | 86-87,348-354     
  ...ptAddendum.ts |     100 |      100 |     100 |     100 |                   
  tasks.ts         |   88.85 |    82.56 |   96.29 |   88.85 | ...-990,1034-1035 
  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        |   83.46 |    86.65 |   72.34 |   83.46 |                   
  approval-mode.ts |     100 |      100 |     100 |     100 |                   
  ...xtDefaults.ts |     100 |      100 |     100 |     100 |                   
  config.ts        |   82.57 |    86.26 |   70.14 |   82.57 | ...7197,7201-7202 
  constants.ts     |     100 |      100 |     100 |     100 |                   
  models.ts        |     100 |      100 |     100 |     100 |                   
  storage.ts       |   94.11 |    91.95 |      88 |   94.11 | ...25-426,429-430 
 ...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          |    91.5 |     87.9 |   92.65 |    91.5 |                   
  baseLlmClient.ts |   88.28 |    82.48 |   81.81 |   88.28 | ...47,660,666-668 
  client.ts        |   91.07 |    86.46 |   90.27 |   91.07 | ...3202,3298-3299 
  ...tGenerator.ts |   85.81 |     85.5 |   80.95 |   85.81 | ...23-424,469-475 
  ...lScheduler.ts |   89.98 |    86.14 |   95.83 |   89.98 | ...5346,5374-5385 
  geminiChat.ts    |   91.83 |    89.27 |   95.69 |   91.83 | ...4075,4123-4124 
  geminiRequest.ts |     100 |      100 |     100 |     100 |                   
  genai-compat.ts  |     100 |      100 |     100 |     100 |                   
  ...MediaLimit.ts |     100 |    95.83 |     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.33 |    83.33 |      50 |   93.33 | 46-47             
  ...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 |   95.19 |    89.47 |     100 |   95.19 | ...44-245,290-291 
  prompts.ts       |   93.31 |    91.34 |   81.25 |   93.31 | ...1109,1312-1313 
  ...ing-effort.ts |     100 |      100 |     100 |     100 |                   
  ...n-recovery.ts |   95.13 |       80 |     100 |   95.13 | ...06-107,142-144 
  ...t-profiler.ts |   96.89 |    80.88 |   88.23 |   96.89 | ...10,117-118,123 
  ...port-retry.ts |     100 |      100 |     100 |     100 |                   
  tokenLimits.ts   |     100 |     92.1 |     100 |     100 | 87,122-123        
  ...reparation.ts |     100 |      100 |     100 |     100 |                   
  ...allIdUtils.ts |   98.41 |    93.02 |     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.49 |    91.17 |     100 |   98.49 | ...94,622-623,669 
 ...ntentGenerator |   96.15 |    87.11 |   95.38 |   96.15 |                   
  ...tGenerator.ts |   97.05 |    86.94 |   94.44 |   97.05 | ...1309,1338,1349 
  converter.ts     |   96.04 |    87.15 |     100 |   96.04 | ...,931,1086-1088 
  index.ts         |       0 |        0 |       0 |       0 | 1-21              
  usage.ts         |     100 |      100 |     100 |     100 |                   
 ...ntentGenerator |   89.93 |    71.83 |   93.33 |   89.93 |                   
  ...tGenerator.ts |    88.3 |    71.21 |   92.85 |    88.3 | ...19-325,343-344 
  index.ts         |     100 |       80 |     100 |     100 | 50                
 ...ntentGenerator |   95.16 |    86.79 |    92.5 |   95.16 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...tGenerator.ts |   95.07 |    85.81 |    92.1 |   95.07 | ...1203-1204,1232 
  ...tDetection.ts |     100 |      100 |     100 |     100 |                   
 ...ntentGenerator |   91.52 |    90.02 |   95.09 |   91.52 |                   
  constants.ts     |     100 |      100 |     100 |     100 |                   
  converter.ts     |   91.03 |    89.12 |   96.87 |   91.03 | ...1909,2078-2093 
  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      |   96.76 |    90.53 |     100 |   96.76 | ...1052,1060,1128 
  ...ureContext.ts |     100 |      100 |     100 |     100 |                   
  ...ingOptions.ts |       0 |        0 |       0 |       0 | 1                 
  ...CallParser.ts |    92.2 |     92.4 |     100 |    92.2 | ...15-516,536-539 
  ...kingParser.ts |     100 |    96.87 |     100 |     100 | 42                
  types.ts         |       0 |        0 |       0 |       0 | 1                 
 ...rator/provider |   96.49 |    89.61 |   96.55 |   96.49 |                   
  dashscope.ts     |   97.48 |    91.91 |      95 |   97.48 | ...85-386,528-529 
  deepseek.ts      |   94.91 |    89.36 |     100 |   94.91 | ...31-132,145-146 
  default.ts       |    97.5 |    96.55 |   88.88 |    97.5 | 123-124,198       
  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     |   86.08 |    82.95 |   92.19 |   86.08 |                   
  ...ive-safety.ts |     100 |      100 |     100 |     100 |                   
  ...-converter.ts |   78.32 |    71.83 |     100 |   78.32 | ...1122,1168-1169 
  corruptFile.ts   |     100 |       50 |     100 |     100 | 40-45             
  ...-converter.ts |   80.39 |     87.5 |     100 |   80.39 | 50-59             
  ...me-refresh.ts |     100 |      100 |     100 |     100 |                   
  ...sion-store.ts |   90.69 |    85.42 |   97.82 |   90.69 | ...1189-1195,1239 
  ...ionManager.ts |   80.56 |    77.97 |   80.23 |   80.56 | ...2577,2599-2600 
  ...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 |    84.61 |   85.71 |    75.9 | ...98,202,214-248 
  github.ts        |   88.55 |    82.13 |     100 |   88.55 | ...58,948-949,959 
  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       
  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 |    83.78 |     100 |   88.95 | ...32-235,238-241 
  ...extraction.ts |   85.77 |    80.61 |   89.47 |   85.77 | ...02-205,260-261 
 src/followup      |   77.38 |    79.84 |    90.9 |   77.38 |                   
  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   |   65.26 |    62.63 |   71.42 |   65.26 | ...17-618,625-626 
  ...onToolGate.ts |     100 |    96.55 |     100 |     100 | 97                
  ...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         |      95 |    88.94 |   95.83 |      95 |                   
  ...eGoalStore.ts |   87.61 |    88.88 |   86.66 |   87.61 | ...85-188,196-204 
  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         |   87.41 |    85.82 |   88.38 |   87.41 |                   
  ...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.43 |     83.5 |   94.59 |   95.43 | ...1010-1011,1021 
  hookPlanner.ts   |    87.5 |    85.36 |   86.66 |    87.5 | ...21-225,232-243 
  hookRegistry.ts  |   92.53 |    85.43 |     100 |   92.53 | ...39,458,462,466 
  hookRunner.ts    |   62.42 |    72.04 |   66.66 |   62.42 | ...64-765,774-775 
  hookSystem.ts    |    87.5 |      100 |   70.21 |    87.5 | ...43-744,750-751 
  ...HookRunner.ts |   75.51 |     61.9 |      80 |   75.51 | ...05-406,424-425 
  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     |   77.22 |    86.74 |     100 |   77.22 | ...57,261-267,273 
  stopHookCap.ts   |     100 |      100 |     100 |     100 |                   
  trustedHooks.ts  |      90 |    52.63 |     100 |      90 | ...53,66-67,97-98 
  types.ts         |   94.24 |    96.09 |   88.88 |   94.24 | ...42-543,628-632 
  urlValidator.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.39 |    77.81 |   78.33 |   82.39 |                   
  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.52 |    58.06 |     100 |   79.52 | ...33-940,947-949 
  ...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        |   86.88 |    82.56 |   90.06 |   86.88 |                   
  ...y-document.ts |   89.52 |    84.61 |     100 |   89.52 | ...24-325,329-330 
  ...nel-memory.ts |   97.11 |    95.72 |   96.29 |   97.11 | ...85-287,361-362 
  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 |    81.81 |     100 |     100 | 126,136           
  entries.ts       |   75.59 |    84.84 |   83.33 |   75.59 | ...56-157,172-180 
  extract.ts       |   91.48 |    75.75 |     100 |   91.48 | ...99,118-121,189 
  ...entPlanner.ts |   91.51 |    76.19 |     100 |   91.51 | ...04,113-116,290 
  ...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 |     100 |      100 |     100 |     100 |                   
  manager.ts       |   78.44 |    82.29 |   77.77 |   78.44 | ...1482,1495-1497 
  ...ent-config.ts |   82.27 |    77.92 |   83.33 |   82.27 | ...66,285,292-298 
  memoryAge.ts     |   90.47 |       80 |     100 |   90.47 | 50-51             
  paths.ts         |   94.73 |    95.94 |     100 |   94.73 | ...35-336,357-358 
  ...ing-skills.ts |     100 |       72 |     100 |     100 | 31-35,73-78,97    
  prompt.ts        |   96.96 |    85.71 |     100 |   96.96 | ...22,225,560-561 
  recall.ts        |   82.06 |       75 |    90.9 |   82.06 | ...59-364,395-406 
  refresh.ts       |   89.85 |    82.92 |     100 |   89.85 | ...54-155,162-163 
  ...ceSelector.ts |    93.1 |    81.81 |     100 |    93.1 | ...25,127-128,136 
  remember.ts      |   98.89 |    89.79 |     100 |   98.89 | 50,70             
  scan.ts          |   93.12 |    74.19 |     100 |   93.12 | ...08-109,154,157 
  ...et-scanner.ts |     100 |      100 |     100 |     100 |                   
  ...entPlanner.ts |   71.68 |    65.51 |   68.75 |   71.68 | ...90-394,397,403 
  status.ts        |   10.52 |      100 |       0 |   10.52 | 41-98             
  store.ts         |   93.33 |    81.25 |     100 |   93.33 | ...,94-95,119-120 
  ...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 |   79.38 |    81.03 |   81.81 |   79.38 | ...58-272,286-291 
 src/mocks         |       0 |        0 |       0 |       0 |                   
  msw.ts           |       0 |        0 |       0 |       0 | 1-9               
 src/models        |   92.43 |    88.36 |   91.13 |   92.43 |                   
  constants.ts     |     100 |      100 |     100 |     100 |                   
  ...tor-config.ts |   97.69 |    91.11 |     100 |   97.69 | 150,156,166       
  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.13 |     100 |     100 | 177,259           
  modelsConfig.ts  |   89.23 |    86.49 |   88.09 |   89.23 | ...1393,1422-1423 
  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.54 |    91.01 |   70.71 |   83.54 |                   
  autoMode.ts      |   97.64 |    93.13 |     100 |   97.64 | ...78-585,631,708 
  ...transcript.ts |      98 |    84.61 |     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.53 |    89.57 |      80 |   86.53 | ...1095,1201-1205 
  rule-parser.ts   |   94.14 |    91.89 |     100 |   94.14 | ...1335,1369-1371 
  ...-semantics.ts |   70.36 |    91.04 |   46.66 |   70.36 | ...2237,2300-2303 
  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.68 |    78.87 |   81.25 |   83.68 |                   
  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.78 |    74.41 |   78.26 |   75.78 | ...72-473,501-502 
  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 | 82-84,87-89,91-94 
  ...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.3 |    78.57 |   95.89 |    85.3 |                   
  ...tGenerator.ts |   98.64 |    98.18 |     100 |   98.64 | 105-106           
  qwenOAuth2.ts    |   82.55 |    73.24 |   90.62 |   82.55 | ...1183-1199,1229 
  ...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.52 |    84.99 |   96.29 |   89.52 |                   
  ...ionTrailer.ts |     100 |      100 |     100 |     100 |                   
  ...llRegistry.ts |   97.35 |    85.34 |     100 |   97.35 | ...94,117,417-418 
  ...ionService.ts |   96.71 |    95.79 |     100 |   96.71 | ...83,699,832-840 
  ...ingService.ts |   87.48 |     81.4 |   89.83 |   87.48 | ...1840,1867-1868 
  ...ttribution.ts |   91.73 |    87.71 |      90 |   91.73 | ...80-685,826-827 
  ...utSlimming.ts |    97.2 |       94 |     100 |    97.2 | ...39-340,378-381 
  cronScheduler.ts |   94.29 |    91.06 |   97.91 |   94.29 | ...1274,1673-1674 
  cronTasksFile.ts |   95.71 |    91.01 |     100 |   95.71 | ...93,318-319,437 
  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 |     100 |      100 |     100 |     100 |                   
  ...temService.ts |   92.07 |    85.93 |    90.9 |   92.07 | ...09,211,323-330 
  ...ratedFiles.ts |      96 |    88.23 |     100 |      96 | 119-120,146-147   
  gitInit.ts       |     100 |      100 |     100 |     100 |                   
  ...reeService.ts |   74.05 |       69 |   95.74 |   74.05 | ...2170,2198-2199 
  ...references.ts |   98.39 |    88.88 |     100 |   98.39 | 154-155,215-216   
  ...ionService.ts |   98.22 |    97.32 |     100 |   98.22 | ...63-664,711-712 
  ...ticsDumper.ts |   98.37 |    95.23 |     100 |   98.37 | 185-186           
  ...ureMonitor.ts |   95.82 |    90.52 |   97.05 |   95.82 | ...60,861,875-877 
  ...orRegistry.ts |   97.27 |    91.22 |     100 |   97.27 | ...50-451,606-607 
  ...ttachments.ts |   97.74 |     90.8 |     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 
  ...ipt-reader.ts |   94.49 |    89.16 |   97.95 |   94.49 | ...1038,1049-1050 
  ...est-helper.ts |       0 |        0 |       0 |       0 | 1-65              
  ...iter-lease.ts |   76.81 |    73.71 |    92.1 |   76.81 | ...15-816,820-827 
  sessionRecap.ts  |   67.56 |    43.47 |     100 |   67.56 | ...60,178,180-183 
  ...ionService.ts |   88.73 |     83.5 |    97.1 |   88.73 | ...2401,2471-2491 
  sessionTitle.ts  |   94.19 |    73.21 |     100 |   94.19 | ...43-246,277-278 
  ...ionService.ts |   84.21 |    78.16 |   97.14 |   84.21 | ...2452,2458-2463 
  ...pInhibitor.ts |   97.42 |    92.68 |     100 |   97.42 | ...30,169,369-370 
  ...Estimation.ts |     100 |    86.66 |     100 |     100 | 96-97             
  ...ageService.ts |   97.76 |    91.59 |   93.75 |   97.76 | ...61-262,366,567 
  ...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.56 |      100 |   33.33 |   14.56 | 58-185            
  ...ionService.ts |   87.98 |    86.84 |     100 |   87.98 | ...38-439,455-456 
 ...icrocompaction |   99.41 |    96.06 |     100 |   99.41 |                   
  microcompact.ts  |   99.41 |    96.06 |     100 |   99.41 | 244-245,677       
 ...s/visionBridge |    98.6 |    94.08 |     100 |    98.6 |                   
  ...capability.ts |     100 |      100 |     100 |     100 |                   
  ...part-utils.ts |     100 |      100 |     100 |     100 |                   
  ...-constants.ts |     100 |      100 |     100 |     100 |                   
  ...ge-service.ts |   98.31 |    92.59 |     100 |   98.31 | ...21,645,658-659 
 src/skills        |   88.37 |    87.22 |   90.16 |   88.37 |                   
  index.ts         |     100 |      100 |     100 |     100 |                   
  ...activation.ts |     100 |    93.33 |     100 |     100 | 93,112            
  skill-load.ts    |   94.84 |     87.5 |     100 |   94.84 | ...03,223,235-237 
  skill-manager.ts |   83.78 |    82.63 |   82.35 |   83.78 | ...1218,1225-1229 
  skill-paths.ts   |   89.65 |    86.95 |     100 |   89.65 | ...11-112,117-118 
  symlinkScope.ts  |     100 |      100 |     100 |     100 |                   
  types.ts         |   97.91 |       98 |     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.28 |    88.63 |   96.42 |   87.28 |                   
  ...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 |   83.55 |    85.01 |   94.59 |   83.55 | ...1501,1578-1579 
  types.ts         |     100 |      100 |     100 |     100 |                   
  validation.ts    |   92.46 |    95.18 |     100 |   92.46 | 47-52,63-68,71-76 
 src/telemetry     |   81.28 |    88.39 |   83.17 |   81.28 |                   
  ...ty-tracker.ts |     100 |      100 |     100 |     100 |                   
  config.ts        |     100 |      100 |     100 |     100 |                   
  constants.ts     |     100 |      100 |     100 |     100 |                   
  ...on-metrics.ts |   99.07 |    80.95 |     100 |   99.07 | 183,197           
  ...on-tracing.ts |   76.31 |    74.62 |   73.68 |   76.31 | ...80,387-389,405 
  ...attributes.ts |   97.47 |    93.15 |     100 |   97.47 | 39-44             
  ...ag-metrics.ts |     100 |    77.77 |     100 |     100 | 21,40             
  ...t-loop-lag.ts |     100 |    90.47 |     100 |     100 | 49,76             
  ...-exporters.ts |   65.78 |    83.33 |   55.55 |   65.78 | ...04-105,108-109 
  ...i-provider.ts |     100 |       99 |     100 |     100 | 99                
  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.09 |    95.61 |      95 |   99.09 | 141,365-366       
  ...t.circular.ts |       0 |        0 |       0 |       0 | 1-128             
  loggers.ts       |   55.35 |    71.56 |   63.46 |   55.35 | ...1350,1367-1387 
  metrics.ts       |   78.44 |    79.62 |   79.66 |   78.44 | ...1079,1082-1093 
  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,478-479,495 
  sdk.ts           |   79.22 |    89.18 |   63.63 |   79.22 | ...57-161,199-221 
  ...on-context.ts |     100 |      100 |     100 |     100 |                   
  ...on-tracing.ts |    90.3 |    89.15 |   96.66 |    90.3 | ...1602,1633-1636 
  ...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         |      82 |    86.95 |   85.71 |      82 | ...1328,1332-1339 
  uiTelemetry.ts   |   93.07 |    92.59 |   83.33 |   93.07 | ...62,290,410-411 
 ...ry/qwen-logger |   73.62 |    81.08 |   69.49 |   73.62 |                   
  event-types.ts   |       0 |        0 |       0 |       0 |                   
  qwen-logger.ts   |   73.62 |     80.9 |   68.96 |   73.62 | ...1095,1133-1134 
 src/test-utils    |      94 |    98.24 |   78.94 |      94 |                   
  config.ts        |     100 |      100 |     100 |     100 |                   
  ...st-helpers.ts |   94.11 |       90 |     100 |   94.11 | 69-70             
  index.ts         |     100 |      100 |     100 |     100 |                   
  mock-tool.ts     |   92.57 |      100 |   75.75 |   92.57 | ...63,227-228,241 
  ...aceContext.ts |     100 |      100 |     100 |     100 |                   
 src/tools         |   85.42 |    84.36 |   87.97 |   85.42 |                   
  ...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 |                   
  edit.ts          |    82.7 |    86.77 |   81.25 |    82.7 | ...43-744,863-913 
  ...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  |   94.04 |    82.53 |     100 |   94.04 | ...92,311,342-344 
  glob.ts          |   96.33 |     88.5 |     100 |   96.33 | ...24-225,373,376 
  grep.ts          |   83.21 |    86.66 |   80.95 |   83.21 | ...65-666,716-717 
  ...adTracking.ts |     100 |      100 |     100 |     100 |                   
  list-agents.ts   |   94.02 |    82.35 |   83.33 |   94.02 | 31-32,47-48       
  loop-wakeup.ts   |   99.24 |    92.85 |     100 |   99.24 | 44                
  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 |   81.63 |       79 |   85.41 |   81.63 | ...3221,3223-3224 
  mcp-client.ts    |   79.58 |    84.81 |   88.88 |   79.58 | ...2186,2190-2193 
  ...ry-timeout.ts |     100 |      100 |     100 |     100 |                   
  mcp-errors.ts    |     100 |      100 |     100 |     100 |                   
  ...pool-entry.ts |   77.56 |    84.11 |   77.14 |   77.56 | ...1291,1299-1300 
  ...ool-events.ts |       8 |        0 |       0 |       8 | 132-158           
  mcp-pool-key.ts  |   97.46 |    93.93 |     100 |   97.46 | 175-176           
  ...ce-content.ts |   96.55 |    91.17 |     100 |   96.55 | 80-82             
  mcp-retry.ts     |   97.67 |    95.65 |     100 |   97.67 | 131-132           
  mcp-status.ts    |     100 |      100 |     100 |     100 |                   
  mcp-tool.ts      |   95.43 |    93.89 |     100 |   95.43 | ...79-780,830-831 
  ...sport-pool.ts |   83.49 |    80.15 |   84.61 |   83.49 | ...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.74 |    84.28 |   88.46 |   91.74 | ...93,606,804-809 
  notebook-edit.ts |   85.55 |    77.39 |   81.25 |   85.55 | ...86-902,948-949 
  ...escendants.ts |   36.17 |    64.51 |   55.55 |   36.17 | ...46-310,385-390 
  ...nforcement.ts |   82.57 |    89.74 |     100 |   82.57 | 174-185,234-247   
  read-file.ts     |   95.64 |    88.88 |   86.66 |   95.64 | ...74,489,561-562 
  ...p-resource.ts |   96.85 |      100 |   91.66 |   96.85 | 92-96             
  ...d-artifact.ts |    90.9 |    86.71 |    87.5 |    90.9 | ...13-414,428-440 
  ripGrep.ts       |    95.9 |     88.4 |   94.73 |    95.9 | ...61-662,668-669 
  ...-transport.ts |   71.42 |    55.55 |   71.42 |   71.42 | ...36-137,143-144 
  send-message.ts  |    81.2 |    89.74 |    62.5 |    81.2 | ...80-286,369-377 
  ...n-mcp-view.ts |   93.57 |     92.3 |      90 |   93.57 | 122-130           
  shell.ts         |   78.45 |    83.42 |   91.75 |   78.45 | ...4960,5023-5024 
  skill-utils.ts   |     100 |      100 |     100 |     100 |                   
  skill.ts         |   91.06 |    93.33 |   89.47 |   91.06 | ...71,475,520-542 
  ...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     |   93.92 |    83.13 |   92.85 |   93.92 | ...86-391,413-414 
  tool-error.ts    |     100 |      100 |     100 |     100 |                   
  tool-names.ts    |     100 |      100 |     100 |     100 |                   
  tool-registry.ts |   77.13 |    76.47 |   82.22 |   77.13 | ...23-924,932-933 
  tool-search.ts   |   96.19 |    89.72 |   93.33 |   96.19 | ...09,259-264,426 
  tools.ts         |   92.74 |    91.52 |    91.3 |   92.74 | ...63-564,580-586 
  ...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.53 |    83.57 |      80 |   90.53 | ...1007,1065-1068 
  write-file.ts    |   85.66 |    85.04 |   85.71 |   85.66 | ...53-756,793-828 
 src/tools/agent   |   85.04 |    85.02 |   86.66 |   85.04 |                   
  agent.ts         |   84.87 |    84.77 |   86.17 |   84.87 | ...4082,4104-4114 
  fork-subagent.ts |   88.32 |       90 |    90.9 |   88.32 | ...05-123,200-201 
 ...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 |   87.46 |    79.41 |   85.71 |   87.46 |                   
  workflow.ts      |   87.46 |    79.41 |   85.71 |   87.46 | ...51-652,664-667 
 src/utils         |   92.53 |    89.69 |   96.58 |   92.53 |                   
  LruCache.ts      |     100 |      100 |     100 |     100 |                   
  ...Controller.ts |     100 |      100 |     100 |     100 |                   
  ...ssageQueue.ts |     100 |      100 |     100 |     100 |                   
  ...cFileWrite.ts |   94.76 |     93.3 |     100 |   94.76 | ...30-531,634-638 
  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 |                   
  ...ncyLimiter.ts |   94.64 |    95.23 |     100 |   94.64 | 64-66             
  ...igResolver.ts |     100 |      100 |     100 |     100 |                   
  ...engthError.ts |   91.11 |    89.47 |     100 |   91.11 | ...46-147,154-155 
  ...n-branches.ts |   95.81 |    93.95 |      95 |   95.81 | ...91-492,504-517 
  ...tion-chain.ts |     100 |      100 |     100 |     100 |                   
  cronDisplay.ts   |     100 |    91.66 |     100 |     100 | 15,43,57          
  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 
  env.ts           |     100 |      100 |     100 |     100 |                   
  ...arResolver.ts |   94.28 |    88.88 |     100 |   94.28 | 28-29,125-126     
  ...entContext.ts |   96.63 |    90.06 |   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        |   82.23 |    92.95 |    61.9 |   82.23 | ...56-372,376-382 
  fetch.ts         |   90.68 |    82.51 |     100 |   90.68 | ...72,483-484,503 
  fileUtils.ts     |   95.33 |       92 |   96.15 |   95.33 | ...1747,1772-1773 
  forkedAgent.ts   |   92.45 |    82.35 |   93.75 |   92.45 | ...34,642,647-654 
  formatters.ts    |   81.81 |       75 |     100 |   81.81 | 15-16             
  ...eUtilities.ts |    92.4 |    86.95 |     100 |    92.4 | ...52-158,168-169 
  ...rStructure.ts |   94.36 |    94.28 |     100 |   94.36 | ...17-120,331-336 
  getPty.ts        |   31.57 |       50 |     100 |   31.57 | 26-38             
  gitDiff.ts       |   95.12 |    81.03 |     100 |   95.12 | ...1073,1390-1391 
  gitDirect.ts     |   98.46 |    90.17 |     100 |   98.46 | 148,268,352       
  ...noreParser.ts |   94.59 |    92.59 |     100 |   94.59 | ...05-106,140-141 
  gitUtils.ts      |      75 |    88.88 |   83.33 |      75 | ...,78-79,103-154 
  iconvHelper.ts   |     100 |      100 |     100 |     100 |                   
  ...rePatterns.ts |     100 |      100 |     100 |     100 |                   
  ...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.27 |    93.18 |     100 |   95.27 | ...16-317,356-359 
  ...-detection.ts |     100 |      100 |     100 |     100 |                   
  ...iagnostics.ts |    96.4 |     94.2 |     100 |    96.4 | ...66,293-294,376 
  ...yDiscovery.ts |    92.4 |    89.01 |     100 |    92.4 | ...28,331,522-525 
  ...tProcessor.ts |   93.77 |    89.15 |     100 |   93.77 | ...13-319,406-407 
  ...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 
  partUtils.ts     |     100 |    98.61 |     100 |     100 | 206               
  pathReader.ts    |   97.77 |       90 |     100 |   97.77 | 93,121            
  paths.ts         |   93.95 |    92.79 |     100 |   93.95 | ...78-479,481-483 
  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 |   59.15 |    76.92 |     100 |   59.15 | ...5,89-90,96-101 
  ...noreParser.ts |   92.63 |    91.52 |     100 |   92.63 | ...72-173,192-193 
  rateLimit.ts     |   93.75 |    89.62 |     100 |   93.75 | ...13,218-219,262 
  ...text-range.ts |   97.73 |    93.24 |     100 |   97.73 | 85-86,107,262-263 
  readManyFiles.ts |   96.29 |     87.5 |     100 |   96.29 | 225,275,286-290   
  retry.ts         |   95.93 |    92.23 |     100 |   95.93 | ...33,524-525,543 
  retryContext.ts  |     100 |      100 |     100 |     100 |                   
  ...sification.ts |   97.65 |    96.96 |     100 |   97.65 | ...00,250-251,277 
  retryPolicy.ts   |   97.72 |    90.56 |     100 |   97.72 | 130-131           
  ripgrepUtils.ts  |   50.94 |    85.71 |      70 |   50.94 | ...54-255,268-346 
  ...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 |   83.59 |    86.25 |      96 |   83.59 | ...08,633,662-671 
  ...odelPrefix.ts |     100 |      100 |     100 |     100 |                   
  runtimeStatus.ts |    97.5 |    89.74 |     100 |    97.5 | 162-163           
  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 |   94.77 |     94.2 |     100 |   94.77 | ...41-42,96,98-99 
  ...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.72 |    92.12 |     100 |   91.72 | ...36-539,615-616 
  ...nIdContext.ts |     100 |      100 |     100 |     100 |                   
  ...orageUtils.ts |   95.98 |     83.8 |     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.05 |    88.57 |     100 |   86.05 | ...2246,2253-2257 
  ...lAstParser.ts |   98.16 |    91.91 |     100 |   98.16 | ...1244-1246,1256 
  ...ContextEnv.ts |     100 |    90.47 |     100 |     100 | 46-48             
  ...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          
  ...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.82 |     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 |    30.76 |      75 |   54.62 | ...03-105,108-134 
  ...Compaction.ts |   96.11 |    96.33 |     100 |   96.11 | ...22-327,329-334 
  ...pt-records.ts |   85.78 |    83.63 |     100 |   85.78 | ...84-388,418-433 
  truncation.ts    |   90.44 |    89.09 |     100 |   90.44 | ...18-426,463-469 
  windowsPath.ts   |   89.47 |    79.31 |     100 |   89.47 | ...57-58,62,90-91 
  ...aceContext.ts |   95.81 |    89.39 |     100 |   95.81 | ...74-275,299-301 
  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.68 |    80.38 |   94.69 |   83.68 |                   
  crawlCache.ts    |     100 |      100 |     100 |     100 |                   
  crawler.ts       |   82.47 |    76.22 |      95 |   82.47 | ...1525,1559-1560 
  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.

Preserve provider timeout classification, reject ambiguous Mem0 statuses, release rejected response bodies, and clarify credential and workspace deployment boundaries.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
@doudouOUC

Copy link
Copy Markdown
Collaborator Author

Final broad audit

Audited commit: 44e00de5b0aa2db8b727f0ff74cf0024113922c5

The final implementation and proposal were re-audited across architecture boundaries, provider-side authorization, repository isolation, configuration and credential handling, HTTP failure paths, Mem0 semantics, Hook/MCP behavior, deployment scope, packaging, tests, compatibility, maintainability, and simpler alternatives.

The audit fixed four concrete classes of problems:

  • Provider timeouts now retain a stable timeout classification through the HTTP adapter, while invalid UTF-8 is classified as an invalid provider response and rejected/error response bodies are cancelled.
  • Mem0 responses with an explicit unknown or invalid status are no longer treated as accepted merely because they contain an event_id.
  • Mem0 documentation now requires administrators to verify that the API key's effective current Project and permissions are restricted to the repository-only Project; app_id and a client-selected current Project remain classification, not authorization.
  • Deployment now explicitly disables the linked extension at user scope, enables it only at the intended workspace scope, and injects configuration and credentials through that repository's managed launcher. The documentation also makes clear that the private v1 workspace is not a self-contained copied/npm artifact without separately packaged runtime dependencies.

Verification passed: 47 integration tests, 3 focused Core scheduler tests, compiled stdio MCP plus command Hook Fake Provider E2E, isolated Qwen extension link/user-disable/workspace-enable discovery, full repository build, typecheck, lint, lockfile check, package dry-run, and diff/format checks. The runtime critical-advisory threshold passed; npm reported existing non-critical repository dependency advisories, but no newly reachable issue was found in this stdio-only integration.

After the last fix, two consecutive open-ended reviews of the final diff found no new clear, actionable issue.

中文审计说明

审计提交:44e00de5b0aa2db8b727f0ff74cf0024113922c5

最终实现与 proposal 已从架构边界、Provider 端鉴权、仓库隔离、配置与凭证处理、HTTP 故障路径、Mem0 语义、Hook/MCP 行为、部署 scope、打包、测试、兼容性、可维护性和更简单替代方案等维度重新完成全面审计。

本轮修复了四类明确问题:

  • Provider 超时现在能穿过 HTTP Adapter 保留稳定的 timeout 分类;非法 UTF-8 被正确归类为 Provider 响应非法;被拒绝或报错响应的 body 会被取消。
  • Mem0 响应若包含明确但未知或非法的 status,不再仅因为带有 event_id 就被误判为 accepted
  • Mem0 文档现在要求管理员验证 API key 的有效 current Project 和权限确实限制在仓库独占 Project;app_id 和客户端选择的 current Project 仍只是分类,不是鉴权。
  • 部署流程现在明确要求在 user scope 禁用链接扩展、只在目标 workspace scope 启用,并通过该仓库的受管启动器注入配置和凭证;文档也明确私有 v1 workspace 若未另行打包运行时依赖,则复制目录/npm 制品并非自包含部署。

验证全部通过:47 个 integration 测试、3 个 Core scheduler 定向测试、编译后 stdio MCP 与 command Hook 的真实进程 Fake Provider E2E、隔离 Qwen 环境中的 link/user-disable/workspace-enable 发现验证、全仓 build、typecheck、lint、lockfile check、package dry-run,以及 diff/format 检查。运行时 critical 漏洞阈值通过;npm 报告了仓库已有的非 critical 依赖公告,但未发现该 stdio-only integration 新增的可达问题。

最后一次修复后,又对最终 diff 完成两轮连续的无方向复审,没有发现新的明确可执行问题。

@gwinthis gwinthis 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.

Architecture Review: COMMENT (C=0)

Summary

Large feature (+2980/-0) adding a Direct External Context Provider integration — a read-only context_search MCP tool with optional context_remember write tool, adapter-based provider support (Mem0 V3, Generic HTTP V1), and admin-owned security selectors.

Architecture Assessment

Strengths:

  1. Extension, not Core API — built from monorepo as a Qwen extension, not a Core API. Keeps Core unchanged, enables per-workspace opt-in.
  2. Admin-owned security selectors — model tool arguments cannot set tenant, user, repository, namespace, app_id, or arbitrary filters. These are fixed by configuration, not model discretion. This is the key security boundary.
  3. Trust boundary explicitly documented — one process, one configured provider, one repository corpus, no model-controlled security selectors. Explicitly does NOT claim trusted personal identity, per-user audit, per-document ACL, DLP, credential isolation from same-UID tools, retention/deletion governance, or multi-workspace serving.
  4. Untrusted JSON rendering — provider responses are rendered as bounded JSON under UserPromptSubmit.additionalContext, not as trusted system instructions.
  5. Fail-open automatic recall — provider failures skip recall and the Qwen request continues. Sanitized bounded query: fenced code and credential-shaped values are stripped before sending to provider.
  6. Write safety — Mem0 writes never retried or polled, report only accepted or unknown. Generic HTTP has no write protocol. PreToolUse confirmation hook for shared-memory writes. YOLO mode required for non-interactive.

Scope observations (non-blocking):

  • "Direct Profile v1" requires built monorepo checkout — not self-contained as npm tarball
  • Credential visible to same-UID processes is acknowledged as a known limitation
  • Decision boundary with governed Gateway/Orchestrator Profile (#7449) is clearly drawn

Pattern

Admin-owned security selectors for model-facing tools: When a tool exposes provider-specific parameters (tenant, user, namespace) that are authorization boundaries, fix them in admin-owned configuration — never let the model choose them. The model can choose query and limit; it cannot choose tenant_id or app_id. This turns the tool's parameter surface into a non-authorization boundary, keeping the trust model simple.

中文说明

架构评审:COMMENT (C=0)

概要

大型功能(+2980/-0):Direct External Context Provider 集成。只读 context_search MCP 工具 + 可选 context_remember 写入工具,适配器支持 Mem0 V3 和 Generic HTTP V1。

架构评估

  • 扩展而非 Core API — 从 monorepo 构建为 Qwen 扩展
  • 管理员拥有的安全选择器 — 模型不能设置 tenant/user/repository/namespace — 由配置固定
  • 信任边界明确文档化 — 一个进程、一个 provider、一个仓库语料库
  • 不可信 JSON 渲染 — provider 响应作为有界 JSON 渲染

模式

模型工具的管理员拥有安全选择器: 工具暴露的授权边界参数(tenant、user、namespace)由管理员配置固定,不让模型选择。模型只能选 querylimit

— qwen3.7-max via Qwen Code /review

gwinthis pushed a commit that referenced this pull request Jul 23, 2026
Limit Phase 1 to one provider-bound search tool, remove hooks and writes, and document the direct profile's actual permission and isolation boundaries.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
@doudouOUC doudouOUC changed the title feat(integrations): add direct external context provider feat(integrations): add retrieval-only external context search Jul 23, 2026
@doudouOUC

Copy link
Copy Markdown
Collaborator Author

Phase 1 E2E validation

This report supersedes the earlier E2E comment for commit 44e00de (comment 5056679511). The implementation was intentionally narrowed after that report. The evidence below applies to the current Phase 1 head, aa70bbe.

  • The external-context workspace tests pass: 5 files, 36 tests.
  • Repository build, typecheck, lint, lockfile validation, and git diff --check pass.
  • A real compiled stdio MCP session against a loopback Generic HTTP provider exposed exactly context_search, sent {"query":"normalized query","limit":5} to /v1/context/search, included the bearer credential only in the outbound request, and returned a valid untrusted_external_context envelope. The test output and stderr contained metadata only.
  • An isolated Qwen home test linked the extension, disabled it at user scope, enabled it only in the target workspace, and confirmed it remained disabled in an unrelated workspace beneath the OS user home. A workspace outside the OS user home was also checked and confirmed the documented limitation: path-based user-scope disablement does not cover that location, so it must be explicitly disabled or use a separate Qwen home.
  • npm pack --dry-run included 30 intended files and no Hook, automatic-recall, or write artifact.
  • Failure, boundary, redaction, cancellation, fixed-selector, and adapter normalization paths are covered by the automated tests.

Not validated here: a live production Mem0 project, Windows runtime behavior, Linux runtime behavior, or a standalone tarball deployment. The integration remains a private monorepo workspace.


第一阶段 E2E 验证

本报告替代基于提交 44e00de 的旧 E2E 评论(评论 5056679511)。该报告发布后,实现已按评审结论主动收敛。以下证据适用于当前第一阶段 head aa70bbe

  • external-context workspace 测试通过:5 个文件,共 36 个测试。
  • 仓库 build、typecheck、lint、lockfile 校验和 git diff --check 均通过。
  • 使用编译后产物和 loopback Generic HTTP Provider 完成了真实 stdio MCP 会话:只暴露 context_search,向 /v1/context/search 发送 {"query":"normalized query","limit":5},Bearer 凭证只存在于出站请求中,并返回合法的 untrusted_external_context envelope;测试输出和 stderr 只包含元数据。
  • 使用隔离的 Qwen home 完成扩展作用域验证:扩展在 user scope 禁用,只在目标 workspace 启用,并确认在 OS 用户主目录下的另一个无关 workspace 中保持禁用。还验证了 OS 用户主目录之外的 workspace,结果符合文档中的限制:基于路径的 user-scope 禁用不会覆盖该位置,因此必须显式禁用或使用独立 Qwen home。
  • npm pack --dry-run 只包含 30 个预期文件,不包含 Hook、自动召回或写入产物。
  • 自动化测试覆盖故障、边界、日志脱敏、取消传播、固定 selector 和 Adapter 归一化路径。

本轮未验证:真实生产 Mem0 Project、Windows 运行时、Linux 运行时或独立 tarball 部署。该集成仍是 monorepo 内的私有 workspace。

@doudouOUC

Copy link
Copy Markdown
Collaborator Author

Phase 1 scope and final audit

This comment supersedes the earlier final-audit comment for commit 44e00de (comment 5056980317) and any review conclusion based on that broader implementation. The current head, aa70bbe, is a materially smaller Phase 1.

The PR now provides only on-demand external retrieval through context_search. Hooks, automatic recall, context_remember, write configuration, repository-root checks, and PreToolUse confirmation logic were removed. The model controls only the query; provider choice, endpoint, credential reference, Mem0 app_id, and result limits are fixed before server startup.

The audit corrected several boundary and compatibility issues:

  • Removed readOnlyHint: retrieval has no write tool, but provider search can still record access state or affect ranking, including Mem0 Memory Decay behavior.
  • Documented that Qwen permissions.ask is interactive UX, not a non-bypassable security boundary; YOLO and in-session approval-mode changes can bypass ordinary confirmation.
  • Required both the effective endpoint and credential capabilities to be restricted to one corpus, and documented the immutable-config-for-session operational requirement.
  • Propagated MCP request cancellation to the provider request.
  • Rejected inherited/prototype configuration and environment properties.
  • Enforced HTTPS except loopback, no redirects, bounded responses and fields, fixed selectors, stable local errors, and metadata-only logs.
  • Corrected extension-scope guidance for workspaces outside the OS user home.

After the last tracked fix, two consecutive independent, broad diff audits found no remaining clear, actionable local code or documentation issue. The final tracked diff and its verification were reviewed together; 36/36 tests and all build, typecheck, lint, lockfile, packaging, and fake-provider checks pass.

This is deliberately not the full governed design from #7449 or the complete roadmap in #7585. Identity, per-user or per-document authorization, DLP, writes, automatic recall, immutable approvals, compliance audit, and multi-workspace serving remain outside this PR.


第一阶段范围与最终审计

本评论替代基于提交 44e00de 的旧最终审计评论(评论 5056980317),也替代所有基于此前更大实现范围的评审结论。当前 head aa70bbe 是显著收敛后的第一阶段。

本 PR 现在只通过 context_search 提供按需外部检索。Hook、自动召回、context_remember、写入配置、repository-root 检查和 PreToolUse 确认逻辑均已移除。模型只能控制 query;Provider 选择、endpoint、凭证引用、Mem0 app_id 和结果上限都在 Server 启动前固定。

审计修正了以下边界与兼容性问题:

  • 移除 readOnlyHint:虽然没有写入工具,但 Provider 搜索仍可能记录访问状态或影响排序,包括 Mem0 Memory Decay 行为。
  • 明确 Qwen permissions.ask 是交互 UX,而不是不可绕过的安全边界;YOLO 和会话中的 approval mode 切换可以绕过普通确认。
  • 要求有效 endpoint 和凭证能力都限制到单一 corpus,并记录“配置在会话期间保持不可变”的运维要求。
  • 将 MCP 请求取消传播到 Provider 请求。
  • 拒绝继承自 prototype 的配置和环境属性。
  • 强制除 loopback 外使用 HTTPS、禁止 redirect、限制响应与字段大小、固定 selector、返回稳定本地错误,并确保日志只记录元数据。
  • 修正 OS 用户主目录之外 workspace 的扩展作用域部署说明。

最后一次受跟踪修复完成后,两轮连续、独立、无方向的完整 diff 审计均未发现剩余的明确可执行本地代码或文档问题。最终 diff 与验证证据已一并复核;36/36 测试以及 build、typecheck、lint、lockfile、打包和 Fake Provider 检查全部通过。

这不是 #7449 的完整受管设计,也不是 #7585 全部路线图的实现。身份、逐用户或逐文档授权、DLP、写入、自动召回、不可绕过审批、合规审计和多 workspace serving 仍不在本 PR 范围内。

Pin the managed MCP source through an administrator-owned command-line configuration, document the Direct Profile trust boundary, and remove unused logging/runtime abstractions.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
@doudouOUC

Copy link
Copy Markdown
Collaborator Author

Final multi-route audit completed on cf84a9a44cfbd8df663ef61984d6c61b124ead99.

Changes made from the audit:

  • Managed deployments now pin the reviewed MCP entry through an administrator-owned --mcp-config; the launcher constructs the complete argument vector, uses a launcher-specific system-settings path, disables /cd, and does not install the automatic allow rule globally.
  • The trust model now explicitly requires the repository, .env/.qwen/.env, and same-UID code to be trusted. Hostile inputs, credential isolation, DLP, ACLs, and compliance audit remain Gateway Profile concerns.
  • Per-request stderr/MCP logging was removed because Qwen has no logging-notification sink in this path; Phase 1 now accurately declares no local audit.
  • The single-use runtime wrapper and unread provider-binding metadata were removed, timeout/cancellation stays inline at the only call site, and repository lint/Vitest rules now cover private integration workspaces.
  • Loopback test servers now fail immediately on listen errors instead of timing out with unhandled events.

Verification:

  • External Context tests: 34/34 passed with real loopback providers.
  • Workspace build, typecheck, lint, and compiled stdio fake-provider E2E passed; E2E stderr was empty.
  • Repository build, typecheck, lint, lockfile validation, formatting, git diff --check, and dry-run packaging passed.
  • Architecture/correctness, security/protocol, and test/failure/packaging audits all finished CLEAN; the final code received two consecutive clean architecture passes after the last fix.

已在 cf84a9a44cfbd8df663ef61984d6c61b124ead99 上完成最终多路审计。

本轮修正了受管 MCP 同名覆盖、/cd 造成的语料库错位、无消费方日志、测试监听失败、单次使用抽象及 integration lint 覆盖问题。Direct Profile 现明确要求仓库、.env/.qwen/.env 和同 UID 代码可信;恶意输入、凭证隔离、DLP、ACL 与合规审计继续路由到 Gateway Profile。

最终结果:External Context 34/34 测试、workspace 与仓库级 build/typecheck/lint、lockfile、格式、diff check、dry-run package、编译后 stdio MCP E2E 全部通过;架构/正确性、安全/协议、测试/故障/打包三路审计均为 CLEAN,最后一次修复后又取得两轮连续清洁架构复审。

@doudouOUC doudouOUC 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.

Reviewed by checking out the branch and running it, not just reading the diff. Verification I did: vitest run34/34 pass, tsc --noEmit clean, tsc --build clean, eslint integrations/external-context/src clean. So the stated test/build/lint evidence holds up.

The security envelope is the strong part of this PR and I did not find a hole in it: model input really is confined to query, redirect: 'manual' prevents credential forwarding, the response is bounded both by declared content-length and by streaming, invalid UTF-8 is rejected fatally, cancellation propagates, and no provider detail escapes into the tool result. The threat model in the README is unusually honest about what the Direct Profile does not give you.

What I did find are correctness bugs in the data path — the part that decides which retrieved results the model actually sees. I reproduced each one against the compiled dist/ with a loopback provider; the reproductions are in the inline comments. The theme is that both the parse layer and the render layer fail silently and destructively: valid content gets dropped or blanked, and the model receives items: [] or content: "" with no way to tell that from "the corpus genuinely has nothing." For a retrieval tool that is the worst failure mode, because the model will confidently answer as though no context exists.

The existing tests don't catch these because every fixture is small and well-formed — no null optional fields, no long documents, no escape-heavy content. Suggest adding cases for exactly those.

Grouping the findings by priority:

Should fix before merge (silent data loss):

  1. parseItemFields rejects a whole item when an optional field is malformed — score: null, or a content/title/uri over its cap. Reproduced: item vanishes, tool returns [].
  2. trimNewestItemToBudget mixes units and emits content: "" items. Reproduced with escape-heavy content: [999, 811, 0, 0, 0].
  3. MAX_ITEM_CONTENT_CHARS * MAX_ITEMS = 5000 > MAX_RENDERED_CHARS = 4000 is structurally unsatisfiable, so the tail item is always degraded.
  4. Provenance uri is the first field dropped under budget pressure — the field most needed for citation, while score is never dropped.

Worth fixing (operability / Simplicity First):
5. Local query-validation failures are reported as provider failures.
6. Startup errors discard already-sanitized ConfigurationError messages, leaving administrators nothing to debug with.
7. The four-class provider error taxonomy has no non-test consumer.

Repo-level, needs maintainer sign-off: this adds a new top-level integrations/ tier to workspaces and to scripts/build.js, so every contributor's npm run build / test / typecheck now pays for a private integration that no shipped artifact consumes. That's a cross-cutting change to package.json + eslint.config.js + scripts/build.js + package-lock.json and per AGENTS.md deserves an explicit maintainer decision rather than riding along with the feature.

Details inline.

Comment thread integrations/external-context/src/providers.ts Outdated
Comment thread integrations/external-context/src/context.ts Outdated
Comment thread integrations/external-context/src/context.ts
Comment thread integrations/external-context/src/context.ts Outdated
Comment thread integrations/external-context/src/mcp.ts
Comment thread integrations/external-context/src/main.ts Outdated
Comment thread integrations/external-context/src/http-client.ts Outdated
Comment thread integrations/external-context/src/providers.ts Outdated
Comment thread package.json
Comment thread integrations/external-context/qwen-extension.json
Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
@doudouOUC

Copy link
Copy Markdown
Collaborator Author

Addressed the latest review on commit 89d46604ad.

Feedback Decision Action
Optional metadata / oversized values drop valid content Partially agree Preserve valid required content, ignore malformed decorations, apply output bounds during rendering, and filter invalid records before the result limit.
Escaped-length trimming creates empty items Agree Fit content by binary search over serialized JSON length; never emit empty content and preserve ranking prefix.
5 × 1000 > 4000 Disagree as a defect Kept the three independent maxima; documented and tested their interaction.
Provenance is dropped before score Agree Drop score, updated time, and title before URI.
Whitespace query reported as provider failure Agree Return the local validation error without calling the provider.
Startup diagnostics are opaque Agree Emit only sanitized configuration errors; keep unexpected failures opaque.
Unused provider error taxonomy Agree Removed unused HTTP/transport/timeout classes.
Mem0 injected origin and repeated result cap Partially agree Validate the injected origin and reuse the provider-layer constant without coupling it to renderer policy.
Root workspace/build integration Disagree Retained the intentional maintainer-approved monorepo workspace and root verification coverage.
Trial manifest tool/env constraints Partially agree Added includeTools; documented required launch environment instead of hardcoding deployment-specific values.

Verification on the exact commit:

  • External-context tests: 42/42 passed.
  • Full repository build, typecheck, lint, and lockfile checks passed.
  • Compiled stdio Fake Provider E2E and package dry-run passed.
  • 2,000 randomized render-budget cases passed.
  • Two consecutive clean self-audit passes completed.

@wenshao

wenshao commented Jul 24, 2026

Copy link
Copy Markdown
Collaborator

Code Review — #7586 feat(integrations): add retrieval-only external context search

Reviewed the full diff (27 files, +2578/-2). Overall this is a high-quality, security-conscious PR and is essentially merge-ready. The design doc is unusually honest about its own trust boundary, the code is well-bounded, and test coverage is thorough. Comments below are minor/optional.

What it does

Adds a private monorepo workspace integrations/external-context/ that ships one on-demand, retrieval-only MCP tool, context_search({ query }). Two provider adapters (Mem0 Platform V3 search, Generic HTTP Search V1) are selected by administrator-controlled config before the MCP process starts; the model can only supply the query. Requests are bounded (timeout, no retry/cache, client-cancel abort), responses are size/UTF-8/schema validated, redirects rejected, HTTPS enforced (loopback HTTP allowed), and the untrusted result envelope is capped. Also wires the workspace into eslint scoping, scripts/build.js order, root package.json workspaces, and the lockfile. Qwen Core is untouched.

Strengths

  • Trust boundary is documented accurately, not oversold: corpus isolation is the provider credential (not app_id/filters), prompt injection in retrieved content remains, permissions.ask is bypassable by YOLO, and the config-path/one-corpus contract is operational rather than core-enforced. This honesty is the best part of the PR.
  • Solid input/output bounding: 2000-char query cap, 5-item cap, 1000-char content cap, 4000-char envelope cap with graceful degradation (drop low-value metadata → provenance → binary-search-truncate content → drop item), 64 KiB config cap, 1 MiB response cap (declared and streamed), fatal UTF-8 decode.
  • Defensive coding: Object.hasOwn guards both the config-path and credential env reads, so inherited/__proto__/constructor/toString keys can't be mistaken for a credential (explicitly tested). Errors are sanitized — no URLs, queries, bodies, or credential names leak to stderr or MCP errors; unexpected startup failures stay opaque.
  • Repo-specific claims verified against this checkout: slashCommands.disabled, QWEN_CODE_SYSTEM_SETTINGS_PATH, the mcp__external-context__context_search rule format, and includeTools are all real. eslint ignore/general/vitest scoping and the build order are correct.
  • Test coverage is genuinely thorough (config validation, budget trimming with astral/escape-heavy content, redirect/oversized/invalid-UTF-8/invalid-JSON/429/5xx/timeout, cancellation propagation, stable-error opacity, manifest single-tool assertion).

Minor suggestions (non-blocking)

  • GenericHttpSearchV1Adapter.search doesn't clamp limit the way Mem0PlatformV3Adapter does (Math.min(input.limit, MAX_PROVIDER_ITEMS)) — it forwards input.limit verbatim in the request body (providers.ts:2494). It's harmless today because mcp.ts always passes 5, but for symmetry/defense-in-depth the generic adapter should clamp too, so the "fixed result limit of five" invariant lives in the adapter, not only the single caller.
  • Redundant/unreachable length check: normalizeSearchQuery's "Search query is too long." branch (context.ts) can't fire via the tool path — the zod .refine already rejects any raw query > 2000 chars, and normalization only shrinks length. Fine as defense-in-depth, but note the zod check runs on the raw string, so a heavily-whitespaced query (e.g. 2001 spaces) is rejected even though it normalizes to something short. Minor over-rejection; acceptable if intended.
  • Version drift: package.json declares 0.20.1 while qwen-extension.json and the McpServer/Client instances use 1.0.0. Cosmetic, but worth one source of truth.
  • content-length NaN: a malformed content-length header makes Number.parseInt(...) > MAX_RESPONSE_BYTES evaluate to false, skipping the declared-size check — but the streamed cap in readBoundedBody still enforces the real limit, so this is safe. Noting only so it's a deliberate reliance, not an oversight.

Notes (no action needed)

  • Redirect rejection depends on Node/undici returning the real 3xx status for redirect: 'manual' (browsers would give an opaque status: 0). Correct and tested for this Node-only MCP server; just a runtime assumption to be aware of.
  • Omitting readOnlyHint while setting destructiveHint: false is intentional and documented (provider search may have read-side effects); good call.

Verdict: LGTM. The suggestions above are polish, not blockers.

中文说明

代码审查 — #7586(仅检索的外部上下文搜索集成)

已审阅完整 diff(27 文件,+2578/-2)。总体是一份质量高、安全意识强的 PR,基本可合并。设计文档对自身信任边界的描述非常诚实,代码边界控制到位,测试覆盖充分。以下均为次要/可选建议。

做了什么

新增私有 workspace integrations/external-context/,暴露一个按需、仅检索的 MCP 工具 context_search({ query })。两个 adapter(Mem0 V3、Generic HTTP V1)在 MCP 进程启动前由管理员配置固定,模型只能提供 query。请求有界(超时、不重试/不缓存、客户端取消可中止),响应经大小/UTF-8/schema 校验,拒绝重定向,强制 HTTPS(允许 loopback HTTP),非可信结果 envelope 受上限约束。同时正确接入 eslint、构建顺序、根 package.json 与 lockfile,且不改动 Qwen Core。

优点

  • 信任边界记录准确、不夸大:语料隔离靠 provider 凭证而非 app_id/filter;召回内容仍可能含提示注入;YOLO 会绕过 permissions.ask;一会话一语料是运维约定而非 Core 强制。
  • 输入/输出边界扎实:query 2000 字符、5 条结果、单条 1000 字符、envelope 4000 字符(优雅降级),config 64 KiB,响应 1 MiB(声明值+流式双重校验),UTF-8 fatal 解码。
  • 防御式编码:config 路径与凭证读取均用 Object.hasOwn,可防继承键/__proto__ 被当作凭证(有测试);错误信息经脱敏,不泄露 URL/query/body/凭证名。
  • 仓库相关声明均已核对slashCommands.disabledQWEN_CODE_SYSTEM_SETTINGS_PATHmcp__external-context__context_search 规则格式、includeTools 均真实存在。
  • 测试覆盖充分(配置校验、预算裁剪、重定向/超大/非法 UTF-8/非法 JSON/429/5xx/超时、取消传播、稳定错误脱敏、manifest 单工具断言)。

次要建议(非阻塞)

  • Generic HTTP adapter 未对 limitMath.min 收敛(Mem0 有),当前因 mcp.ts 恒传 5 无影响,但建议对称处理,使“固定 5 条”不变量落在 adapter 内。
  • 冗余/不可达检查normalizeSearchQuery 的“too long”分支在工具路径下不可达(zod 已按原始串长度拒绝);且 zod 按原始串校验,会过度拒绝大量空白的 query。可接受。
  • 版本不一致package.json0.20.1,而 manifest 与 McpServer1.0.0。建议统一。
  • content-length 为 NaN 会跳过声明值检查,但流式上限仍兜底,安全。

说明(无需处理)

  • 重定向拒绝依赖 Node/undici 在 redirect:'manual' 下返回真实 3xx 状态(浏览器会给不透明 status:0);对该 Node-only MCP server 正确且有测试。
  • 有意省略 readOnlyHint 并设 destructiveHint:false,已在文档解释,合理。

结论: LGTM,上述均为打磨项而非阻塞项。

@doudouOUC

Copy link
Copy Markdown
Collaborator Author

Thanks for the thorough review. I independently checked all four suggestions against 89d46604ad. Given that this PR has already gone through roughly five review rounds, I am keeping this round to correctness, security, data-loss, and regression fixes only. No item here crosses that threshold:

  • The Generic HTTP request limit is always 5 at the sole MCP call site, and response parsing independently caps accepted items at five. Adapter-side clamping would be reasonable defense-in-depth, but is optional polish and is deferred.
  • The raw 2,000-character schema bound is intentional protocol input bounding; normalizeSearchQuery retains its standalone post-normalization guard. Whitespace-heavy over-rejection is acceptable for this v1 retrieval tool.
  • The versions have different ownership: the private npm workspace tracks the monorepo version (0.20.1), while the extension manifest and MCP server identify the first integration artifact/protocol revision (1.0.0). I am retaining that separation.
  • A malformed declared content-length cannot bypass the authoritative streamed 1 MiB limit, so stricter header parsing would only improve early rejection. It is deferred.

The Node-only redirect: manual assumption and omitted readOnlyHint remain intentional as noted. No code change is needed for this review.

@doudouOUC
doudouOUC marked this pull request as ready for review July 25, 2026 00:19
@doudouOUC
doudouOUC enabled auto-merge July 25, 2026 00:19
@qwen-code-ci-bot

qwen-code-ci-bot commented Jul 25, 2026

Copy link
Copy Markdown
Collaborator

Qwen Triage finishedview run. See the stage comments above for the result.

Qwen Triage 已完成 —— 查看运行。结果见上方各阶段评论。

@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 — no blockers. 1 Suggestion-level finding(s) could not be anchored to a changed line and were dropped; nothing further to act on here.

— qwen3.7-max via Qwen Code /review

@wenshao

wenshao commented Jul 25, 2026

Copy link
Copy Markdown
Collaborator

Review: retrieval-only external context search

Reviewed at 89d46604a in an isolated worktree off main. The code is small, tight, and unusually well-reasoned — the design doc is honest about what the trust boundary is not, which is rare and valuable. Nothing I found is a correctness bug in the search path. My substantive concerns are one repo-fit question that needs a maintainer decision, one deployment gap (proxy), and three coverage/ergonomics items.


What I verified (all passing)

Check Result
vitest run in the workspace 42/42 pass
npx tsc --noEmit clean
npx eslint integrations/external-context/src --max-warnings 0 clean
npx prettier --check on every changed file clean
npm run check:lockfile passes
npm run build --workspace @qwen-code/external-context emits dist/main.js + .d.ts

I also ran a compiled stdio MCP E2E against a fake loopback provider (node dist/main.js driven by a real Client/StdioClientTransport), passing hostile extra tool arguments:

callTool({ query: '  deployment   policy \n rules ',
           app_id: 'attacker', filters: { x: 1 } })

Observed on the wire:

POST /v1/context/search
Authorization: Bearer super-secret-token
Accept: application/json
{"query":"deployment policy rules","limit":5}
  • Extra model-supplied arguments (app_id, filters) never reach the adapter. ✅
  • Whitespace normalization is applied before the outbound request. ✅
  • Result arrives under untrusted_external_context with the notice. ✅
  • Provider 500 + body UPSTREAM SECRET DETAIL → tool returns exactly External context search failed., isError: true, 1 upstream request (no retry), and no upstream detail. ✅
  • stderr was empty ("") across the whole session. ✅

Integration points against Qwen Core that I confirmed rather than assumed:

  • mcp__external-context__context_search is 37 chars and matches PROVIDER_SAFE_TOOL_NAME, so normalizeToolNameForProvider returns it unchanged — the permissions.allow entry in examples/managed-settings.json is the real rule name, not a silently-renamed no-op.
  • includeTools: ["context_search"] matches mcp-client.ts:2216, which compares against the bare declared name. Correct.
  • ${extensionPath} and ${/} are both in VARIABLE_SCHEMA (packages/core/src/extension/variableSchema.ts). Correct.
  • Locale-map displayName/description are supported (packages/core/src/extension/i18n.ts). Correct.
  • scripts/clean.js enumerates root workspaces, so the new dist/tsbuildinfo are cleaned automatically — no change needed there.
  • scripts/version.js step 7 refreshes the lock for a fixed --workspace subset; I bumped the integration to 0.20.2 and confirmed the lock entry does get updated anyway. No release-script change needed.

1. Repo-fit: new top-level integrations/ tree, wired into the default build — needs a maintainer decision

This introduces integrations/ as a sibling of packages/, adds it to root workspaces, and appends it to scripts/build.js buildOrder. Consequences for every contributor:

  • npm run build (non---cli-only) builds it
  • npm run test:ci --workspaces runs its 42 tests
  • npm run typecheck --workspaces typechecks it
  • npm run clean cleans it

The runtime cost is genuinely small (~1 s build, ~0.5 s tests), so this isn't a performance objection. It's a scope question: the PR describes this as a private integration that is explicitly not a supported standalone artifact, yet it now sits in the default build graph of the shipped repo. Two things I'd want settled before merge:

  • Is integrations/ an accepted new top-level tree, or should this live under packages/ (as packages/channels/plugin-example does for a comparable "example/private" workspace)?
  • Should a non-shipped integration be in buildOrder at all, versus an opt-in script? Nothing in packages/** depends on it, so the default build never needs its dist/.

I'm raising this rather than asserting an answer — it's the maintainers' call, but it's the one item I'd block on until someone signs off.

2. Outbound requests ignore HTTPS_PROXY / HTTP_PROXY / NO_PROXY

http-client.ts uses bare global fetch. Node's fetch does not read proxy environment variables — which is precisely why Core installs one explicitly:

// packages/core/src/config/config.ts:2252
.then(({ EnvHttpProxyAgent, setGlobalDispatcher }) => {
  setGlobalDispatcher(new EnvHttpProxyAgent({ ... }))

The external-context MCP server is a separate process that never runs that setup, so it inherits none of it. This bites exactly the audience the PR targets: an enterprise deployment behind an egress proxy will get an opaque fetch failedExternal context search failed., with no local log to diagnose it (Phase 1 deliberately writes nothing per-request to stderr). It's made worse by the managed launcher building a positive-allowlist environment — an operator who does set HTTPS_PROXY still gets nothing.

undici@7.27.2 is already hoisted in the tree, so the fix is ~3 lines in main.ts:

const { EnvHttpProxyAgent, setGlobalDispatcher } = await import('undici');
setGlobalDispatcher(new EnvHttpProxyAgent());

Use EnvHttpProxyAgent, not a bare ProxyAgent, for the NO_PROXY reason already documented at config.ts:2237. If you'd rather defer, please at least state in the README that proxy environment variables are not honored — right now the docs are silent and an operator will reasonably assume they work.

3. Test files are excluded from typecheck (mutation-confirmed)

integrations/external-context/tsconfig.json has "exclude": ["src/**/*.test.ts"], and typecheck is tsc --noEmit against that same config. Combined with the repo's ESLint not being type-aware, type errors in test files are invisible to CI. Confirmed:

// appended to src/context.test.ts
const typeErrorProbe: number = "not-a-number";
$ npx tsc --noEmit ; echo $?
0

packages/core/tsconfig.json includes src/**/*.ts (tests included), so this deviates from the house setup. The exclude is needed to keep tests out of dist/ — suggested fix is the usual split: keep tsconfig.json covering tests for typecheck, and add a tsconfig.build.json with the exclude for tsc --build.

4. The Generic HTTP request path is asserted by no test (mutation-confirmed)

/v1/context/search is the single fixed wire element of the documented "Generic HTTP Search V1" contract, and it's the one thing no test pins. The Mem0 test does assert its path (expect(requestPath).toBe('/v3/memories/search/')), so this looks like an oversight rather than a choice.

- this.searchUrl = new URL('/v1/context/search', baseUrl);
+ this.searchUrl = new URL('/v1/WRONG-PATH', baseUrl);
$ npx vitest run
Tests  42 passed (42)

The fake server answers any path, so the mutation is invisible. One line in the existing 'sends only query and limit…' test closes it:

let requestPath: string | undefined;
// inside the handler:
requestPath = request.url;
// …
expect(requestPath).toBe('/v1/context/search');

(Reviewer Test Plan step 3 explicitly calls for confirming this path — worth having the suite enforce what the plan asks a human to check.)

5. Truncation is silent, and the envelope budget is the one bound admins can't tune

MAX_RENDERED_CHARS = 4000 / MAX_ITEM_CONTENT_CHARS = 1000 are hardcoded. Two consequences:

  • No signal to the model. When content is cut mid-sentence or items 3–5 are dropped, the envelope is indistinguishable from a complete result set — it's just { notice, items }. For a retrieval tool feeding an answer, a silently half-truncated policy paragraph is a confidently-wrong-answer generator. Since the marker would be locally generated, it's trustworthy even inside the untrusted envelope. Suggest adding something bounded, e.g. "truncated": true and/or "omitted_items": n.
  • Not configurable. timeoutMs is administrator-tunable within [1, 30000]; the size budget isn't tunable at all. Core allows MCP tools up to maxOutputChars = 500_000 (mcp-tool.ts:583), so 4000 is ~0.8% of what the host permits. Five results totaling under 4 KB is tight for any real RAG corpus. Consider exposing maxContextChars in config with the same bounded-schema treatment timeoutMs already gets.

The doc does state the maxima are independent and not a five-full-items guarantee — this is about the runtime signal and tunability, not the documentation.


Minor / nits

  • MAX_CONFIG_BYTES and the isFile() guard are untested. Replacing if (!fileStat.isFile() || fileStat.size > MAX_CONFIG_BYTES) with if (false) leaves 42/42 green. Two small fixtures (a directory path, an oversized file) would cover it.
  • TOCTOU in loadConfig. stat checks the size, then readFile re-opens with no cap; a file that grows in between is read unbounded. Low severity given the admin-owned-config premise, but readFile + Buffer.byteLength check (or open/fstat) removes the window for free.
  • examples/managed-settings.json ships permissions.allow. The README argues at length that this is an outbound data channel and that permissions.ask gives interactive confirmation — but the shipped example defaults to no confirmation. Consider making ask the example and documenting allow as the deliberate opt-in; that way the copy-paste path is the safer one.
  • License headers say Copyright 2025 Google LLC. Recent new files in this repo use Copyright 2025 Qwen Team (e.g. packages/cli/src/serve/channel-settings-store.ts, packages/core/src/utils/tool-name-utils.ts). The Google header is fork-legacy on ~848 existing files; new files shouldn't add to that.
  • Dead non-null assertions in context.test.ts. renderExternalContext(...)! and JSON.parse(rendered!) — the function returns string, not string | undefined. Leftovers from an earlier signature; harmless, but not caught by lint since the config isn't type-aware.
  • No content-type check on provider responses. Any 2xx body is fed to JSON.parse. Not exploitable here (the envelope is strictly validated afterwards), just slightly looser than the rest of the file's posture.
  • No control-character stripping in normalizeSearchQuery. \s doesn't match NUL, so in a query is forwarded verbatim to the provider. Cosmetic.

Things I checked and found no issue with

  • redirect: 'manual' + the 300 ≤ status < 400 branch does fire on Node/undici (the redirect test asserts the ProviderResponseError message, which only that branch produces) — the response is not opaque-filtered here.
  • The streamed-oversize path abandons the for await, which cancels the underlying ReadableStream — no dangling body.
  • fitNewestItemToBudget's binary search is monotonic in middle and only ever mutates the freshly-compacted copy, so the prefix-of-ranking property holds and caller data isn't touched.
  • Number.parseInt on a malformed content-length yields NaN, which fails the comparison and falls through to the streamed check — safe.
  • The nested integrations/external-context/node_modules/@types/node in the lock matches what packages/cli already produces with the same ^22.0.0 range. Not new debt.

Overall: careful work, and the E2E behavior matches every claim in the description. Items 3 and 4 are quick; item 2 is the one that will bite a real enterprise deployment; item 1 needs a maintainer to weigh in on placement before this lands.

中文说明

main 的独立 worktree 中基于 89d46604a 完成审阅。代码规模小、实现严谨,设计文档对信任边界"不提供什么"的诚实描述尤其难得。检索路径上没有发现正确性缺陷;主要问题是一个需要 maintainer 拍板的仓库定位问题、一个部署缺口(代理),以及三项覆盖率/易用性问题。

已验证通过: 42/42 测试、tsc --noEmit、ESLint、Prettier、check:lockfile、workspace 构建全部干净。另外运行了编译后的 stdio MCP 端到端探针(真实 Client + fake loopback provider):出站请求确认为 POST /v1/context/search,body 恰为 {"query":"deployment policy rules","limit":5};模型传入的 app_id/filters 未进入 adapter;provider 返回 500 时工具仅返回 External context search failed.,请求次数为 1(无重试),全程 stderr 为空。同时核对了与 Qwen Core 的对接:mcp__external-context__context_search 共 37 字符且符合 PROVIDER_SAFE_TOOL_NAME,经 normalizeToolNameForProvider 后保持不变,因此示例中的 permissions.allow 是真实规则名;includeTools 按裸工具名匹配;${extensionPath}/${/} 均在变量 schema 中;clean.jsversion.js 均已自动覆盖新 workspace(后者经实测确认)。

1. 仓库定位(建议先取得 maintainer 认可): 新增顶层 integrations/ 目录并加入根 workspacesscripts/build.jsbuildOrder,意味着默认 npm run buildtest:citypecheck 都会带上它。耗时很小(约 1s/0.5s),并非性能问题,而是范围问题:一个明确"非发布产物"的私有集成是否应进入默认构建图,以及是否应放在 packages/ 下(可参考 packages/channels/plugin-example)。

2. 出站请求忽略 HTTPS_PROXY/NO_PROXY http-client.ts 使用裸 fetch。Node 的 fetch 不读代理环境变量,Core 正是为此在 config.ts:2252 显式安装 EnvHttpProxyAgent。本 MCP 是独立进程,不会继承该设置。受限出网的企业环境会得到不透明的 External context search failed.,且 Phase 1 不写每请求日志,无从排查。undici@7.27.2 已在依赖树中,在 main.ts 中约三行即可修复(须用 EnvHttpProxyAgent 而非裸 ProxyAgent)。若暂不修复,至少应在 README 中写明不支持代理环境变量。

3. 测试文件被排除在 typecheck 之外(已用变异验证): tsconfig 的 exclude: ["src/**/*.test.ts"] 同时作用于 tsc --noEmit;在测试文件中写入明显类型错误后 tsc --noEmit 仍返回 0。加之仓库 ESLint 非类型感知,测试文件的类型错误对 CI 完全不可见。建议拆出 tsconfig.build.json 承担 exclude。

4. Generic HTTP 请求路径无任何测试断言(已用变异验证):/v1/context/search 改为 /v1/WRONG-PATH 后 42/42 仍全绿;而 Mem0 的路径是有断言的。Reviewer 测试计划第 3 步恰好要求人工确认该路径,建议由测试固化:在既有用例中记录 request.url 并断言。

5. 截断无信号且预算不可配置: MAX_RENDERED_CHARS = 4000 / MAX_ITEM_CONTENT_CHARS = 1000 为硬编码。截断或丢弃条目后 envelope 与完整结果无法区分,模型无从判断(该标记由本地生成,即使置于 untrusted envelope 内也可信);建议加入 truncated / omitted_items。另外 timeoutMs 可由管理员在 [1, 30000] 内配置,而尺寸预算完全不可调,Core 对 MCP 工具允许 maxOutputChars = 500_000,4000 仅约 0.8%,对真实 RAG 语料偏紧。

次要项: MAX_CONFIG_BYTES/isFile() 分支无测试(置为 if (false) 后仍全绿);loadConfigstatreadFile 之间存在 TOCTOU;managed-settings.json 示例默认使用 permissions.allow(README 自身推荐 ask,建议示例改用更安全的一侧);License header 用的是 Copyright 2025 Google LLC,而本仓库新文件的惯例是 Copyright 2025 Qwen Teamcontext.test.tsrenderExternalContext(...)! 为无效非空断言;provider 响应未校验 content-typenormalizeSearchQuery 不剥离控制字符(NUL 会原样转发)。

整体质量很好,端到端行为与 PR 描述完全一致。第 3、4 项修改量很小;第 2 项是真实企业部署会遇到的问题;第 1 项建议合入前先由 maintainer 确认目录归属。

Install an environment-aware dispatcher before the external context MCP server starts so enterprise egress proxy and NO_PROXY settings apply to provider requests. Document the managed launcher environment and cover startup wiring.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
@doudouOUC

Copy link
Copy Markdown
Collaborator Author

Thanks for the detailed review. I independently checked every item against exact head 89d46604ad before changing the branch. The actionable enterprise compatibility gap is fixed in 388be23ac7.

Item Decision Action
Top-level integrations/ workspace and default validation Agree that this requires maintainer ownership Maintainer sign-off: this placement is intentional in the approved Direct Provider plan. It remains a private monorepo integration, and inclusion in the default build/test/typecheck graph is deliberate so it cannot silently rot. No relocation or opt-in-only build.
Proxy environment support Agree Fixed. The dedicated MCP process installs EnvHttpProxyAgent before startup, so HTTP_PROXY, HTTPS_PROXY, and NO_PROXY apply to provider requests. The runtime dependency is declared, startup wiring is tested, and the managed-launcher documentation now explains the approved proxy environment and loopback bypass entries.
Test files excluded from tsc --noEmit Agree as a coverage improvement Deferred. This does not identify a product correctness defect in the current tests, and the PR has passed roughly five review rounds. A build/typecheck tsconfig split can be handled as follow-up repo hygiene without widening this PR.
Generic HTTP path assertion Agree as a useful test Deferred for the same review-round scope rule. The fixed path is implemented and was independently verified by the compiled stdio E2E, but the missing assertion is coverage rather than a current product defect.
Truncation signal and configurable budget Partially agree A local truncation signal could improve model behavior and is suitable follow-up work. The 4,000-character bound is an intentional v1 safety/context budget, and making it configurable expands the deployment contract, so neither change is added in this late round.

The remaining notes do not justify further scope here: config-file branch tests, TOCTOU hardening under the administrator-owned-config premise, license normalization, and redundant test assertions are non-blocking follow-up polish; permissions.allow is deliberate for this retrieval-only managed profile and the README already documents ask and its bypass limits; strict JSON parsing plus schema validation is the authoritative provider-response check, so requiring Content-Type would reduce compatibility without improving the trust boundary; control characters remain bounded and JSON-escaped.

Verification on the pushed fix: external-context tests 43/43, workspace typecheck, lint, formatting, lockfile check, workspace build, full repository prepare/build, and a real dispatcher probe confirming both proxy routing and NO_PROXY loopback bypass. Two consecutive final diff audits found no additional actionable issue.

Review thread resolution: 0/0. This feedback was a top-level PR comment, and there are currently no unresolved inline review threads.

@wenshao

wenshao commented Jul 25, 2026

Copy link
Copy Markdown
Collaborator

Re-review: proxy delta (89d46604a388be23ac)

Scoped this round to the one new commit, fix(integrations): honor provider proxy settings, plus regression checks on the paths a custom global dispatcher could plausibly break. Verified in an isolated worktree at 388be23ac with the pinned undici@7.29.0 installed into the workspace.

The proxy gap I raised is genuinely closed — confirmed by live A/B, not by reading the diff. One small new failure mode is worth ~4 lines; everything else is a nit.


The fix is load-bearing (live A/B)

Compiled dist/main.js driven over real stdio MCP (Client + StdioClientTransport), against a loopback Generic HTTP provider, with a real CONNECT-capable proxy on loopback:

Scenario Proxy events Provider hit Result
A — PR head, HTTP_PROXY set CONNECT 127.0.0.1:52101 1 ✅ routed through proxy
B — PR head, NO_PROXY=localhost,127.0.0.1,[::1] none 1 ✅ bypass works as documented
Ccontrol: same build, setGlobalDispatcher(...) line stripped none 1 ✅ proxy fully ignored

C is the one that matters: without this commit the proxy is invisible, so the change is doing real work. It also confirms the cross-instance trick holds — userland undici's setGlobalDispatcher does reach Node's built-in fetch (shared Symbol.for('undici.globalDispatcher.1')), same as Core's packages/core/src/config/config.ts wiring. Valid payload returned under untrusted_external_context in all three, stderr "" throughout.

The new unit test is also load-bearing — mutating main.ts to drop the call fails it:

AssertionError: expected "spy" to be called with arguments: [ Any<EnvHttpProxyAgent> ]
Number of calls: 0    ❯ src/main.test.ts:39:33

No regression in the bounded-failure paths through a live proxy tunnel

The dispatcher swap is exactly the kind of change that quietly breaks abort/stream teardown, so I re-ran the failure matrix with traffic actually tunnelling through the proxy:

Case Provider requests Upstream aborted Tool result stderr
302 redirect 1 (no retry) External context search failed. ""
500 + body UPSTREAM SECRET DETAIL 1 External context search failed. (no leak) ""
streamed >1 MiB, no content-length 1 External context search failed. ""
client cancels in-flight 1 AbortError ""

Cancellation still tears down the upstream socket through the tunnel, and there's still no retry. Gates: 43/43 tests, tsc --noEmit clean, eslint --max-warnings 0 clean, prettier --check clean on every changed file, npm run check:lockfile passes.


1. Low — a malformed proxy env now kills the MCP server with an undiagnosable message

new EnvHttpProxyAgent() throws at construction on an invalid proxy value:

HTTP_PROXY="not a url"    -> TypeError: Invalid URL
HTTP_PROXY="http://"      -> TypeError: Invalid URL
HTTP_PROXY="  "           -> TypeError: Invalid URL
HTTP_PROXY="ftp://p:1"    -> InvalidArgumentError: Invalid URL protocol...
HTTP_PROXY=""             -> constructed OK   (so the common empty case is safe)

Because the call sits inside the top-level try, that lands in the opaque bucket rather than the sanitized-configuration bucket. Observed end-to-end on all four bad values:

exit=1   stderr="[external-context] External context startup failed."

This is a behavior change introduced by this commit: previously a malformed HTTP_PROXY was simply ignored by Node's fetch; now it's fatal, and the message never mentions the proxy. In the managed-launcher model the admin owns that environment, so the realistic failure is an admin typo in HTTPS_PROXY producing a dead context_search tool with no signal pointing at the cause — which is precisely what the PR's own two-tier error design (actionable ConfigurationError vs. opaque unexpected) exists to avoid.

Suggested fix, keeping the value out of the message since proxy URLs can embed credentials (http://user:pass@proxy):

try {
  setGlobalDispatcher(new EnvHttpProxyAgent());
} catch {
  throw new ConfigurationError(
    'Proxy environment configuration is invalid. Check HTTP_PROXY, HTTPS_PROXY, and NO_PROXY.',
  );
}

The existing catch already prints ConfigurationError.message verbatim, so this needs no other change.

2. Nit — lockfile resolves the new undici off the other two

Three workspaces declare the identical range, but the lockfile splits them:

integrations/external-context/node_modules/undici  7.29.0   (^7.28.0)
packages/cli/node_modules/undici                   7.28.0   (^7.28.0)
packages/core/node_modules/undici                  7.28.0   (^7.28.0)
node_modules/undici                                7.27.2

npm ci therefore materializes a 4th nested copy that could have deduped onto the existing 7.28.0. No functional impact — these are separate processes — but pinning to 7.28.0 (or npm dedupe) drops an avoidable duplicate.

3. Note — the README's bracketed [::1] is right, and the conventional form silently fails

Worth keeping exactly as written, because it's a real trap. Against an IPv6 loopback provider (baseUrl: "http://[::1]:PORT"):

NO_PROXY=localhost,127.0.0.1,[::1]   -> proxyEvents=[]                    ✅ bypasses
NO_PROXY=localhost,127.0.0.1,::1     -> proxyEvents=["CONNECT [::1]:..."] ❌ still proxied

An admin who reuses an existing NO_PROXY (curl and most tooling use the unbracketed ::1) silently gets their loopback traffic tunnelled. A half-sentence in step 5 noting the unbracketed form does not match would save someone an hour.

Also observed and worth knowing operationally: undici CONNECT-tunnels even plain http:// origins (CONNECT 127.0.0.1:52101 above, not an absolute-form POST). Corporate proxies commonly restrict CONNECT to :443, so an HTTPS provider on a non-standard port may be refused by the proxy even though the config is valid. Not a code issue — it's just the reason the NO_PROXY guidance in step 5 is load-bearing rather than optional.


Previously deferred — accepting the scope call, one factual update

No objection to deferring these; flagging only that the tsconfig item now covers this delta's own code. Re-confirmed on 388be23ac: exclude: ["src/**/*.test.ts"] also governs tsc --noEmit, so appending const x: number = "definitely not a number"; to the new main.test.ts still leaves tsc --noEmit at exit 0. That new test is the one file relying on non-trivial types (importOriginal<typeof import('undici')>()), so it's the least-checked new code in the PR. A tsconfig.build.json split remains the right follow-up.

The Generic HTTP /v1/context/search path assertion is likewise still absent from the unit tests, though my compiled stdio E2E above exercises the real path — so the risk is regression detection, not current correctness.


Verdict

Merge-ready. The enterprise proxy gap from last round is properly fixed and I confirmed it with a control build rather than taking the diff's word for it, and the fix doesn't regress any bounded-failure, cancellation, or redaction behavior. Item 1 is a genuine (if small) new failure mode and is the only thing I'd suggest landing before merge; items 2–3 are optional polish.

中文说明

复审:代理修复增量(89d46604a388be23ac

本轮只审阅新增的 fix(integrations): honor provider proxy settings 一个提交,外加自定义全局 dispatcher 可能破坏的路径的回归验证。在隔离 worktree 中基于 388be23ac 验证,并安装了锁定的 undici@7.29.0

我上轮提出的代理缺口确实已经修复——通过实测 A/B 对照确认,而不是只读 diff。 新引入一个约 4 行即可修复的小问题,其余都是细节建议。

修复确实生效(实测 A/B)

用真实 stdio MCP(Client + StdioClientTransport)驱动编译产物 dist/main.js,配合 loopback Generic HTTP Provider 和支持 CONNECT 的本地代理:

场景 代理事件 Provider 命中 结果
A — PR head,设置 HTTP_PROXY CONNECT 127.0.0.1:52101 1 ✅ 经过代理
B — PR head,NO_PROXY=localhost,127.0.0.1,[::1] 1 ✅ 绕过行为与文档一致
C对照组:同一产物,删除 setGlobalDispatcher(...) 1 ✅ 代理被完全忽略

关键是 C:没有本次提交,代理完全不可见,说明该改动是真正起作用的。同时也验证了跨实例机制成立——用户态 undicisetGlobalDispatcher 确实能作用于 Node 内置 fetch(共享 Symbol.for('undici.globalDispatcher.1')),与 Core 在 packages/core/src/config/config.ts 中的做法一致。三个场景都返回了合法的 untrusted_external_context 载荷,stderr 全程为 ""

新增单测也是有效的——把 main.ts 中的调用删掉后该测试失败(Number of calls: 0)。

经过真实代理隧道后,各故障路径无回归

替换 dispatcher 正是容易悄悄破坏 abort/流关闭的改动,因此我让流量真正穿过代理隧道重跑了故障矩阵:

用例 Provider 请求数 上游被中止 工具结果 stderr
302 重定向 1(无重试) External context search failed. ""
500 + body UPSTREAM SECRET DETAIL 1 External context search failed.(无泄漏) ""
流式 >1 MiB,无 content-length 1 External context search failed. ""
客户端取消进行中的请求 1 AbortError ""

取消仍能穿过隧道关闭上游连接,且仍然没有重试。各项门禁:43/43 测试、tsc --noEmiteslint --max-warnings 0、所有改动文件的 prettier --checknpm run check:lockfile 全部通过。

1. Low —— 代理环境变量格式错误会让 MCP Server 以无法诊断的信息启动失败

new EnvHttpProxyAgent() 在构造时就会对非法代理值抛异常"not a url""http://"" "TypeError: Invalid URL"ftp://p:1"InvalidArgumentError;空字符串 "" 可正常构造(因此最常见的空值情况是安全的)。

由于该调用位于顶层 try 内,它落入了不透明错误分支而非 sanitized 配置错误分支。四个非法值端到端实测结果均为:exit=1stderr="[external-context] External context startup failed."

这是本次提交引入的行为变化:此前格式错误的 HTTP_PROXY 会被 Node fetch 直接忽略,现在则是致命错误,且提示信息完全没有提到代理。在受管启动器模型下环境由管理员掌控,因此现实中的失败场景是管理员在 HTTPS_PROXY 上打错字,导致 context_search 工具直接不可用且毫无线索——而这正是本 PR 自身的双层错误设计(可操作的 ConfigurationError vs. 不透明的意外错误)想要避免的情况。

建议修复如下,注意消息中不应包含变量值,因为代理 URL 可能内嵌凭证(http://user:pass@proxy):

try {
  setGlobalDispatcher(new EnvHttpProxyAgent());
} catch {
  throw new ConfigurationError(
    'Proxy environment configuration is invalid. Check HTTP_PROXY, HTTPS_PROXY, and NO_PROXY.',
  );
}

现有 catch 已经会原样打印 ConfigurationError.message,无需其他改动。

2. Nit —— lockfile 中新增的 undici 与另外两个版本不一致

三个 workspace 声明了完全相同的范围 ^7.28.0,但 lockfile 解析结果不同:integrations/external-context 为 7.29.0,packages/clipackages/core 为 7.28.0,根目录为 7.27.2。因此 npm ci 会额外产生第 4 份嵌套副本,而它本可以复用已有的 7.28.0。由于是独立进程,没有功能影响;但固定到 7.28.0(或执行 npm dedupe)可以去掉一份多余副本。

3. Note —— README 中带方括号的 [::1] 是正确的,而常规写法会静默失效

建议原样保留,因为这是一个真实的坑。针对 IPv6 loopback Provider(baseUrl: "http://[::1]:PORT"):NO_PROXY=localhost,127.0.0.1,[::1] 可以绕过代理;而 NO_PROXY=localhost,127.0.0.1,::1(不带方括号,curl 和大多数工具使用的形式)仍然会走代理。沿用既有 NO_PROXY 的管理员会在毫无察觉的情况下让 loopback 流量被隧道转发,建议在第 5 步补一句说明不带方括号的形式不匹配。

另外一个值得了解的运维细节:undici 对http:// origin 也使用 CONNECT 隧道(上文观察到的是 CONNECT 127.0.0.1:52101,而非 absolute-form 的 POST)。企业代理通常将 CONNECT 限制在 :443,因此即使配置合法,非标准端口上的 HTTPS Provider 也可能被代理拒绝。这不是代码问题,只是说明第 5 步的 NO_PROXY 指引是必要的而非可选的。

关于此前已推迟的项目——认可范围判断,仅更新一处事实

不反对推迟这些项,只是说明 tsconfig 那一项现在也覆盖了本次增量自身的代码。在 388be23ac 上重新确认:exclude: ["src/**/*.test.ts"] 同样作用于 tsc --noEmit,因此在新增的 main.test.ts 末尾追加 const x: number = "definitely not a number"; 后,tsc --noEmit 仍然以 0 退出。而该新测试恰恰是唯一依赖非平凡类型(importOriginal<typeof import('undici')>())的文件,也就成了本 PR 中检查最薄弱的新代码。拆分 tsconfig.build.json 仍是合适的后续处理。

Generic HTTP /v1/context/search 路径断言同样仍未加入单测,不过我上面的编译产物 stdio E2E 已实际覆盖该路径——因此风险在于回归检测能力,而非当前正确性。

结论

可以合并。 上一轮的企业代理缺口已被正确修复,并且我用对照产物而非仅凭 diff 做了确认;该修复也没有破坏任何边界故障、取消传播或脱敏行为。第 1 项是本次引入的一个真实(虽小)的新故障模式,是我唯一建议在合并前处理的问题;第 2、3 项属于可选优化。

@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 — no blockers. Suggestions are inline.

— qwen3.7-max via Qwen Code /review

Comment thread integrations/external-context/src/context.ts
Comment thread integrations/external-context/src/mcp.ts
Classify proxy dispatcher construction failures as sanitized configuration errors so managed deployments can identify an invalid proxy environment without exposing proxy credentials.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
@doudouOUC

Copy link
Copy Markdown
Collaborator Author

Thanks for the focused re-review. I independently reproduced the new proxy-construction failure against exact head 388be23ac and handled this round as follows.

Item Decision Action
Invalid proxy environment becomes opaque startup failure Agree Fixed in de9d5f77d8. Dispatcher construction failures are now converted to a sanitized ConfigurationError naming only HTTP_PROXY, HTTPS_PROXY, and NO_PROXY; no proxy value or embedded credential is included. The MCP server exits before runMcp, with an actionable startup message.
undici 7.29 lockfile entry Disagree that pinning removes a physical copy Sibling workspace node_modules entries cannot reuse each other. Pinning the integration to 7.28 would align the version string but still materialize its own nested location; a broad npm dedupe would re-resolve unrelated existing lock topology. The declared ^7.28.0 range remains consistent with Core and CLI.
Explain bracketed IPv6 NO_PROXY form Agree as documentation polish The currently documented [::1] value is already correct and was independently verified. The extra warning about unbracketed ::1 is useful but non-critical, so it is deferred under the late-review scope rule.
UTF-16 serialized budget suggestion Disagree The 4,000 ceiling intentionally follows JavaScript String.length, matching Qwen Core truncation behavior. Code-point truncation is separate to avoid splitting surrogate pairs. Changing the serialized budget to code points can violate the existing payload ceiling.
Provider timeout integration test Agree as coverage Deferred because it identifies no current correctness defect and this PR has passed roughly five review rounds.

Verification for de9d5f77d8: 44/44 external-context tests, typecheck, lint, formatting, workspace build, diff check, and two consecutive clean audits. The invalid-proxy test uses the real EnvHttpProxyAgent constructor, isolates both uppercase and lowercase proxy variables, verifies the value is not exposed, verifies runMcp is not called, and restores the process environment. No unresolved product defect remains from this review.

@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.

No issues found. LGTM! ✅

中文说明

未发现问题。LGTM!✅

— qwen3.7-max via Qwen Code /review

@wenshao

wenshao commented Jul 25, 2026

Copy link
Copy Markdown
Collaborator

Local verification round 3 — de9d5f77d (real builds, no mocks)

Verified as maintainer on macOS 15 / Node 22.23.1, in an isolated worktree detached at exact head de9d5f77d, with its own npm ci from this PR's package-lock.json (which also ran the full monorepo build). Follows review round 1 (#issuecomment-5076068086) and round 2 (#issuecomment-5076440681); this round is scoped to the new commit fix(integrations): diagnose invalid proxy settings plus a from-scratch behavioural verification of the whole surface.

Verdict: merge-ready. 43 pass/fail assertions across 8 mock-free harnesses, all passing; the new commit is proven load-bearing by A/B; no new blocking finding. Two operability notes below are informational — one of them is a pre-existing Qwen Core issue, not this PR.

1. Round-2 findings at the new head

# Round-2 finding Sev Status at de9d5f77d
1 Invalid HTTP_PROXY/HTTPS_PROXY → opaque External context startup failed. Medium Fixed and verified load-bearing. 5 of 9 real-process cells flip from opaque to actionable; the new unit case fails against the pre-fix source (§3).
2 undici lockfile drift → a 4th nested copy Low Stands, as the author documented. Physically confirmed after npm ci: node_modules/undici 7.27.2, packages/core 7.28.0, packages/cli 7.28.0, integrations/external-context 7.29.0. Author's reasoning (sibling workspaces cannot share a copy) is correct; not a merge blocker.
3 NO_PROXY needs the bracketed [::1] Nit README is already correct; polish deferred. Re-confirmed that a garbage NO_PROXY (::1,%%%,[) never throws — so the new message names NO_PROXY even though it can never be the cause. Harmless as guidance.
4 UTF-16 vs code-point rendering budget Author is right; disproved my suggestion empirically. A 5 × 3000 astral-emoji provider payload renders at String.length 3999 (2470 code points) with no lone surrogate — the ceiling holds in the unit it is written in.
5 Provider-timeout integration test (deferred) Coverage Supplied here: timeoutMs: 1000 aborts the in-flight provider socket at 1006 ms, provider-side abort observed, exactly 1 request, stderr empty.
6 tsconfig exclude hides test files from tsc --noEmit Low Still open — now with concrete evidence (§6). Optional.

2. Repository gates at this head

npm ci (PR lockfile, full build) ✓ · npm run build ✓ · npm run typecheck ✓ · npm run lint ✓ · root eslint integrations/external-context/src --max-warnings 0 ✓ · prettier --check on the delta ✓ · 44/44 workspace tests ✓. PR scope re-checked: 27 files, nothing outside integrations/, docs/design/, eslint.config.js, package.json, package-lock.json, scripts/build.js.

3. The new commit is load-bearing (real OS processes)

verify7586/proxy-startup.mjs spawns the compiled integrations/external-context/dist/main.js as a real process with real proxy environment variables and observes exit code + stderr + whether the MCP server actually came up. The control arm is the same file rebuilt from 388be23ac's main.ts (inner try/catch absent) — nothing else differs.

cell env PR head de9d5f77d control 388be23ac
P1 HTTP_PROXY='not a URL' exit 1 + Proxy environment configuration is invalid. Check HTTP_PROXY, HTTPS_PROXY, and NO_PROXY. exit 1 + External context startup failed.
P2 HTTP_PROXY=' ' actionable opaque
P4 HTTPS_PROXY='ftp://proxy.internal:8080' actionable opaque
P5 lowercase http_proxy='not a URL' actionable opaque
P6 http://svc-account:<secret>@ bad host:3128 actionable, no credential/user/host in stderr or stdout opaque
P0/P3/P7/P8 none / '' / garbage NO_PROXY / valid proxy server starts, stderr empty identical

9/9 at head, 4/9 on the control. The new unit case is not vacuous either: reverting main.ts alone makes src/main.test.ts:63 fail with exactly the opaque string. Extra malformed forms that are now diagnosed rather than opaque: proxy.corp:3128 (scheme omitted — the most common admin mistake), //proxy.corp:3128, http://[::1:3128.

No regression to the round-2 proxy behaviour: with a valid HTTP_PROXY at a CONNECT-capable loopback proxy a real search still tunnels (CONNECT 127.0.0.1:<port> observed once), and NO_PROXY=127.0.0.1 still bypasses (no CONNECT, direct hit).

proxy A/B

4. Protocol matrix against the compiled server — 19/19

verify7586/mcp-matrix.mjs: a real @modelcontextprotocol/sdk client over a real stdio child process, a real loopback provider, a real CONNECT proxy. Every cell asserts both sides of the wire — what the provider received (method, path, authorization, exact body, request count, socket abort) and what the model would see — plus that stderr stays empty.

  • Tool surface is exactly context_search, one argument query, destructiveHint: false.
  • Provider receives POST /v1/context/search, Bearer <token>, body exactly {"query":"release notes captain","limit":5} from ' release notes\n\tcaptain '; the model gets a 363-char untrusted_external_context envelope.
  • Extra structured tool arguments (app_id, filters, top_k, limit, baseUrl, authorization, threshold, rerank) never reach the provider — body unchanged, decoy origin gets 0 hits.
  • Every provider failure returns only External context search failed. with exactly 1 provider request (no retry) and empty stderr: manual redirect (decoy target never contacted), declared oversize (content-length 2 MiB), streamed oversize (chunked, no content-length), invalid UTF-8, invalid JSON, valid JSON with an invalid envelope, 429, 5xx.
  • Malformed items dropped, unknown provider fields stripped from the envelope.
  • timeoutMs abort and MCP client cancellation both abort the provider socket (provider-side observed), no retry.
  • Query bounds: 2000 code points forwarded; 2001 rejected with -32602 and the provider is never contacted (also for astral queries, i.e. 4002 UTF-16 units); whitespace-only rejected locally as Search query must not be empty.

Mem0 V3 adapter, real module against a real loopback origin — 5/5: POST /v3/memories/search/, Token <key>, body exactly {"query":…,"filters":{"app_id":"repository-memory"},"top_k":5,"threshold":0.1,"rerank":false} even when the caller passes limit: 999; malformed results dropped; each adapter's prototype exposes only search; a non-loopback http:// origin is refused at construction.

protocol matrix

5. End-to-end through the real built Qwen CLI — 7/7

verify7586/cli-e2e.mjs drives packages/cli/dist/index.js non-interactively against a scripted OpenAI-compatible endpoint (the wire oracle), with the administrator-owned --mcp-config pin, QWEN_CODE_SYSTEM_SETTINGS_PATH → managed settings, and a same-name decoy server in user settings. Because Qwen defers MCP tools behind ToolSearch, turn 0 is a real discovery round-trip.

  • The tool is advertised in the deferred-tools listing under #### external-context as mcp__external-context__context_search (37 chars — matches permissions.allow), revealed by tool_search, and present in tools[] from the next turn on.
  • The pinned server answers: provider gets one POST /v1/context/search with {"query":"release cadence thursday","limit":5}; the model receives the 319-char untrusted envelope; the decoy never runs.
  • Model-supplied corpus selectors are rejected one layer earlier than expected: Qwen Core's own Ajv parameter validation (packages/core/src/utils/schemaValidator.ts:247, dataVar: 'params') refuses the call with params must NOT have additional properties, so the adapter is never entered (the provider request count stays at 1). Defence in depth on top of the adapter's fixed fields.
  • Without --mcp-config, the same-name user-settings server wins and answers (DECOY-SERVER-ANSWERED, 0 provider requests) — the README's central deployment claim, now demonstrated end-to-end rather than argued.
  • The allow rule is load-bearing: with it removed, the same call is declined (Qwen Code requires permission to use "mcp__external-context__context_search", but that permission was declined) and the provider is never contacted, so an unmanaged session does not inherit automatic execution.
  • examples/managed-mcp.json's includeTools: ["context_search"] spelling is correct and load-bearing: pinning a two-tool stand-in server under the same name shows only …__context_search in the listing and dangerous_write gone; without includeTools both appear.

CLI end-to-end

6. Informational — not blockers

(a) Where the new message actually surfaces. Three arms with HTTP_PROXY='not a URL':

arm placement result
1 in the launcher environment (as an admin would set it) Qwen Core fails first: An unexpected critical error occurred: TypeError: Invalid URL with a raw stack from Core's own dispatcher install (packages/core/src/config/config.ts:2251-2258), exit 1. The integration's message is never reached.
2 scoped to the server via the pinned config's env CLI prints Warning: MCP server(s) failed to start: external-context. … Re-run with QWEN_CODE_DEBUG=1 to see per-server reasons.; the sanitized message is not on the terminal (mcp-client.ts:2181-2185 attaches the stderr listener only in debug mode).
3 same as arm 2, with --debug the sanitized message is in the debug log — the operator following the CLI's own instruction gets Proxy environment configuration is invalid. Check HTTP_PROXY, HTTPS_PROXY, and NO_PROXY. instead of External context startup failed.

So the commit does pay off, through the documented debug path and when the MCP command is run standalone. Arm 1 is a pre-existing Core gap (this PR touches no packages/core code) and is the same bug class the author just fixed inside the integration — worth a separate follow-up applying the same sanitized-message treatment in Core. Optionally, one README line ("if the server fails to start, re-run with QWEN_CODE_DEBUG=1 to see the sanitized startup reason") would close the loop for admins.

(b) Well-formed but unreachable proxy. HTTP_PROXY=http://127.0.0.1:1 starts cleanly; searches then return only External context search failed. with empty stderr and zero provider hits. Correct per Phase 1's no-per-request-logging rule — just noting that the new diagnostic covers malformed values, not wrong-but-parseable ones.

(c) Test files are still outside tsc --noEmit (round-2 item 6, now concrete). With the workspace's own tsconfig.json and only exclude removed, the existing test files report two real errors: src/main.test.ts(33,3)process.exitCode is string | number | null | undefined, not assignable to the local string | number | undefined — and src/mcp.test.ts(69,18)result.content is unknown. Neither affects runtime (vitest transpiles only, 44/44 green) and eslint src does not flag them. A deliberately injected const probe: number = "…" in main.test.ts is likewise invisible to npm run typecheck and to eslint src. Dropping the exclude line (or adding a test-only tsconfig) would be a small hardening, and the file this round's commit touched is exactly one of the two affected.

Harnesses used

proxy-startup.mjs (9 cells × 2 builds) · mcp-matrix.mjs (19) · query-bounds.mjs (6) · mem0-wire.mjs (5) · cli-e2e.mjs (3 arms, 7) · include-tools.mjs (3) · proxy-edges.mjs (5) · operator-visibility2.mjs (3 arms). All mock-free: compiled dist/, real child processes, real loopback HTTP servers, real CONNECT proxy, real built CLI.

中文说明

本地验证第 3 轮 —— de9d5f77d(真实构建,无 mock)

以维护者身份在 macOS 15 / Node 22.23.1 上验证:独立 worktree detach 到精确 head de9d5f77d,用本 PR 的 package-lock.json 单独执行 npm ci(同时完成整个 monorepo 构建)。承接第 1 轮(#issuecomment-5076068086)与第 2 轮(#issuecomment-5076440681);本轮聚焦新提交 fix(integrations): diagnose invalid proxy settings,并对整个接口做了一次从零开始的行为验证。

结论:可以合并。 8 个无 mock harness 共 43 项通过/失败断言全部通过;通过 A/B 证明新提交确实起作用;没有新的阻塞问题。下面两条可运维性说明仅供参考,其中一条属于 Qwen Core 的既有问题,与本 PR 无关。

1. 第 2 轮问题在新 head 的状态

# 第 2 轮问题 级别 de9d5f77d 状态
1 非法 HTTP_PROXY/HTTPS_PROXY → 只输出不可诊断的 External context startup failed. Medium 已修复且证明起作用。 9 个真实进程用例中 5 个从不可诊断变为可诊断;新增单测在修复前的源码上失败(见 §3)。
2 undici lockfile 漂移 → 第 4 份物理副本 Low 如作者所述,保持现状。npm ci 后物理确认:node_modules/undici 7.27.2packages/core 7.28.0packages/cli 7.28.0integrations/external-context 7.29.0。作者的判断(同级 workspace 无法共用副本)正确,不阻塞合并。
3 NO_PROXY 需要带方括号的 [::1] Nit README 本身已正确,文档打磨延后。再次确认:非法 NO_PROXY::1,%%%,[)不会抛错——所以新消息里提到 NO_PROXY,但它永远不可能是原因。作为提示无害。
4 UTF-16 与码点计量的渲染预算 作者正确,我的建议被实测推翻。 5 × 3000 个星际平面 emoji 的 Provider 响应最终渲染为 String.length 3999(2470 码点),没有落单代理项——上限在其定义的单位上成立。
5 Provider 超时集成测试(延后) 覆盖率 本轮补上timeoutMs: 1000 在 1006 ms 中止了正在进行的 Provider 连接,Provider 侧观察到 abort,请求恰好 1 次,stderr 为空。
6 tsconfig exclude 使测试文件不被 tsc --noEmit 检查 Low 仍然存在——本轮给出具体证据(§6)。可选。

2. 本 head 上的仓库门禁

npm ci(PR lockfile,完整构建)✓ · npm run build ✓ · npm run typecheck ✓ · npm run lint ✓ · 根级 eslint integrations/external-context/src --max-warnings 0 ✓ · 对 delta 执行 prettier --check ✓ · workspace 测试 44/44 ✓。范围复核:27 个文件,除 integrations/docs/design/eslint.config.jspackage.jsonpackage-lock.jsonscripts/build.js 之外没有改动。

3. 新提交确实起作用(真实操作系统进程)

verify7586/proxy-startup.mjs 把编译后的 integrations/external-context/dist/main.js 作为真实进程启动,注入真实代理环境变量,观察退出码、stderr 以及 MCP Server 是否真的起来了。对照组是同一文件用 388be23acmain.ts 重新编译(缺少内层 try/catch),其他完全一致。

用例 环境 PR head de9d5f77d 对照组 388be23ac
P1 HTTP_PROXY='not a URL' exit 1 + Proxy environment configuration is invalid. Check HTTP_PROXY, HTTPS_PROXY, and NO_PROXY. exit 1 + External context startup failed.
P2 HTTP_PROXY=' ' 可诊断 不可诊断
P4 HTTPS_PROXY='ftp://proxy.internal:8080' 可诊断 不可诊断
P5 小写 http_proxy='not a URL' 可诊断 不可诊断
P6 http://svc-account:<secret>@ bad host:3128 可诊断,stderr/stdout 均无凭证、用户名或主机泄漏 不可诊断
P0/P3/P7/P8 无 / '' / 非法 NO_PROXY / 合法代理 Server 正常启动,stderr 为空 与 head 一致

head 9/9,对照组 4/9。 新增单测也不是空测:只回退 main.ts 就会让 src/main.test.ts:63 以那条不可诊断的字符串失败。另外这些常见错误写法现在也能被诊断:proxy.corp:3128(漏掉 scheme,最常见的管理员失误)、//proxy.corp:3128http://[::1:3128

第 2 轮验证过的代理行为没有回退:配置合法 HTTP_PROXY 指向支持 CONNECT 的 loopback 代理时,真实搜索仍然走隧道(观察到一次 CONNECT 127.0.0.1:<port>);NO_PROXY=127.0.0.1 仍然直连绕过(无 CONNECT)。

4. 针对编译产物的协议矩阵 —— 19/19

verify7586/mcp-matrix.mjs:真实 @modelcontextprotocol/sdk 客户端 → 真实 stdio 子进程 → 真实 loopback Provider → 真实 CONNECT 代理。每个用例都断言两侧:Provider 实际收到的内容(method、path、authorization、精确 body、请求次数、socket abort),以及模型实际会看到的内容,并检查 stderr 保持为空。

  • 工具面恰好只有 context_search,只有一个参数 querydestructiveHint: false
  • Provider 收到 POST /v1/context/searchBearer <token>,body 恰好{"query":"release notes captain","limit":5}(输入为 ' release notes\n\tcaptain ');模型收到 363 字符的 untrusted_external_context envelope。
  • 额外的结构化工具参数(app_idfilterstop_klimitbaseUrlauthorizationthresholdrerank)不会到达 Provider —— body 不变,诱饵 origin 0 次命中。
  • 所有 Provider 故障都只返回 External context search failed.,Provider 请求恰好 1 次(不重试),stderr 为空:手动重定向(诱饵目标从未被访问)、声明式超大响应(content-length 2 MiB)、流式超大响应(chunked 无 content-length)、非法 UTF-8、非法 JSON、合法 JSON 但 envelope 非法、429、5xx。
  • 非法条目被丢弃,Provider 的未知字段不会进入 envelope。
  • timeoutMs 超时与 MCP 客户端取消都会中止 Provider 连接(Provider 侧已观察到),且不重试。
  • Query 边界:2000 码点会转发;2001 码点被 -32602 拒绝且 Provider 从未被访问(星际平面字符同理,即 4002 个 UTF-16 单元);全空白 query 在本地被拒为 Search query must not be empty.

Mem0 V3 Adapter,真实模块 + 真实 loopback origin —— 5/5:POST /v3/memories/search/Token <key>,即使调用方传 limit: 999,body 仍恰好为 {"query":…,"filters":{"app_id":"repository-memory"},"top_k":5,"threshold":0.1,"rerank":false};非法结果被丢弃;两个 Adapter 的原型上只有 search;非 loopback 的 http:// origin 在构造时即被拒绝。

5. 通过真实构建的 Qwen CLI 做端到端 —— 7/7

verify7586/cli-e2e.mjs 以非交互方式驱动 packages/cli/dist/index.js,对接一个脚本化的 OpenAI 兼容端点(wire oracle),使用管理员拥有的 --mcp-config 固定入口、QWEN_CODE_SYSTEM_SETTINGS_PATH 指向受管 settings,并在 user settings 里放入一个同名诱饵 server。由于 Qwen 把 MCP 工具放在 ToolSearch 之后延迟加载,第 0 轮是一次真实的发现往返。

  • 该工具出现在延迟工具清单的 #### external-context 下,名称为 mcp__external-context__context_search(37 字符,与 permissions.allow 一致),由 tool_search 揭示,并从下一轮起出现在 tools[] 中。
  • 固定的 server 响应请求:Provider 收到一次 POST /v1/context/search,body 为 {"query":"release cadence thursday","limit":5};模型收到 319 字符的非可信 envelope;诱饵从未运行。
  • 模型提供的语料库 selector 比预期更早被拒绝:Qwen Core 自身的 Ajv 参数校验(packages/core/src/utils/schemaValidator.ts:247dataVar: 'params')以 params must NOT have additional properties 拒绝调用,Adapter 根本没被进入(Provider 请求数仍为 1)。这是在 Adapter 固定字段之上的额外防线。
  • 不使用 --mcp-config 时,user settings 中的同名 server 胜出并作出响应DECOY-SERVER-ANSWERED,Provider 0 次请求)—— README 最核心的部署论断,现在是端到端实测而非推理。
  • allow 规则确实起作用:移除后同样的调用被拒(Qwen Code requires permission to use "mcp__external-context__context_search", but that permission was declined),Provider 从未被访问,因此非受管会话不会继承自动执行能力。
  • examples/managed-mcp.jsonincludeTools: ["context_search"] 的写法正确且有效:把一个暴露两个工具的替身 server 以同名固定进来后,清单里只出现 …__context_searchdangerous_write 消失;不写 includeTools 时两个都出现。

6. 参考信息 —— 非阻塞

(a) 新消息实际会在哪里出现。 HTTP_PROXY='not a URL' 的三种放置方式:

放置位置 结果
1 启动器环境(管理员通常这么设) Qwen Core 先挂An unexpected critical error occurred: TypeError: Invalid URL,栈来自 Core 自己的 dispatcher 安装(packages/core/src/config/config.ts:2251-2258),exit 1。集成的消息根本走不到。
2 通过固定配置的 env 只作用于该 MCP server CLI 输出 Warning: MCP server(s) failed to start: external-context. … Re-run with QWEN_CODE_DEBUG=1 to see per-server reasons.;终端上看不到那条 sanitized 消息(mcp-client.ts:2181-2185 只在 debug 模式下挂 stderr 监听)。
3 同第 2 组,但加 --debug sanitized 消息确实出现在 debug 日志中 —— 按 CLI 自己的提示重跑的操作者会看到 Proxy environment configuration is invalid. Check HTTP_PROXY, HTTPS_PROXY, and NO_PROXY.,而不是 External context startup failed.

也就是说,这个提交通过已文档化的 debug 路径以及独立运行 MCP 命令的场景确实带来了价值。第 1 组属于 Core 既有缺口(本 PR 未改动 packages/core),而且正是作者刚刚在集成内修掉的同一类问题 —— 值得单独跟进,在 Core 里做同样的 sanitized 消息处理。另外可选地在 README 加一行("如果 server 启动失败,用 QWEN_CODE_DEBUG=1 重跑即可看到 sanitized 的启动原因"),对管理员会更完整。

(b) 格式合法但不可达的代理。 HTTP_PROXY=http://127.0.0.1:1 能正常启动;之后搜索只返回 External context search failed.,stderr 为空,Provider 0 次命中。这符合 Phase 1 不做逐请求日志的规则 —— 只是说明新诊断覆盖的是"格式非法",而不是"格式合法但配错"。

(c) 测试文件仍在 tsc --noEmit 之外(第 2 轮第 6 项,现在有具体证据)。 使用 workspace 自己的 tsconfig.json、仅去掉 exclude 后,现有测试文件报出两个真实错误:src/main.test.ts(33,3) —— process.exitCode 的类型是 string | number | null | undefined,不能赋给局部变量的 string | number | undefined;以及 src/mcp.test.ts(69,18) —— result.content 类型为 unknown。两者都不影响运行(vitest 仅做转译,44/44 通过),eslint src 也不会报。故意注入的 const probe: number = "…" 同样对 npm run typecheckeslint src 完全不可见。删掉 exclude 这一行(或加一个测试专用 tsconfig)会是一处小的加固,而本轮提交改动的正是这两个受影响文件之一。

使用的 harness

proxy-startup.mjs(9 用例 × 2 个构建)· mcp-matrix.mjs(19)· query-bounds.mjs(6)· mem0-wire.mjs(5)· cli-e2e.mjs(3 组,7)· include-tools.mjs(3)· proxy-edges.mjs(5)· operator-visibility2.mjs(3 组)。全部无 mock:编译后的 dist/、真实子进程、真实 loopback HTTP 服务、真实 CONNECT 代理、真实构建的 CLI。

@doudouOUC
doudouOUC added this pull request to the merge queue Jul 25, 2026
Merged via the queue into main with commit 8f667f5 Jul 25, 2026
97 of 98 checks passed
@doudouOUC
doudouOUC deleted the agent/direct-external-context-provider branch July 25, 2026 08:23
@qwen-code-ci-bot

Copy link
Copy Markdown
Collaborator

Released in v0.21.1.

@yiliang114

Copy link
Copy Markdown
Collaborator

⚠️ Failed to process this request. Please re-mention the bot to retry.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants