feat(computer-use): replace built-in tools with bundled skill - #9856
Conversation
CUA release workflow dry-runExact head: Run: https://github.com/QwenLM/qwen-code/actions/runs/32694558733 Inputs: Verified outcomes:
The workflow's production-only path remains protected-main-only and uses the same verified artifact with immutable registry-integrity checks and npm provenance. |
🖼️ web-shell visual previewRendered against a mock daemon (no real backend): the PR base vs this PR head Screenshots · before / afterFull-resolution recordings (.webm) are attached to the workflow run. — Qwen Code · web-shell visuals |
d4c7c08 to
e9a7733
Compare
|
Please do not rebase or force-push to an active PR as it invalidates existing review comments. Note for future reference, the bots always squash all changes into a single commit automatically as part of the integration. 中文请勿对活跃的 PR 执行 rebase 或 force-push,因为这会使已有的评审评论失效。另外,供日后参考:作为集成流程的一部分,机器人始终会自动将所有改动压缩(squash)为单个提交。 |
e9a7733 to
cf12035
Compare
Code Coverage Summary
CLI Package - Full Text ReportCore Package - Full Text ReportFor detailed HTML reports, please see the 'coverage-reports-22.x-ubuntu-latest' artifact from the main CI run. |
|
Thanks for pushing the Computer Use migration over the line! Template — complete, bilingual summary included ✓ Problem — not a bugfix; this completes the architectural consolidation that #9499 (standalone Node REPL MCP server) and #9587 (versioned CUA SDK + release pipeline) set up, both merged Aug 23. Keeping two parallel execution paths (built-in tools + skill-driven SDK) would leave model guidance, permissions, and packaging permanently ambiguous — the problem is real and structural. Direction — aligned. Third step of an already-established roadmap: one skill-based execution architecture, with the MCP server / SDK / native payload living outside Qwen Code itself. CHANGELOG: no computer-use removal entry yet, which is expected — this PR is the change that needs it. Size — core paths are touched ( Approach — scope matches the stated goal: remove the built-in tool surface and every setting/schema/bootstrap that supported it, add one bundled skill, and harden the release pipeline ( Risk — no elevated-risk path matches. Breaking changes are called out plainly ( Moving on to code review. 🔍 中文说明感谢把 Computer Use 迁移推进到最后一步! 模板 — 完整,包含双语说明 ✓ 问题 — 这不是 bug 修复,而是完成 #9499(独立 Node REPL MCP server)和 #9587(版本化 CUA SDK + 发布流水线,均已于 8 月 23 日合并)确立的架构整合。同时保留两条执行路径(内置工具 + skill 驱动的 SDK)会让模型指引、权限和打包一直处于歧义状态——问题是真实且结构性的。 方向 — 对齐。这是已确立 roadmap 的第三步:只保留一个基于 skill 的执行架构,MCP server / SDK / native payload 都不内置在 Qwen Code 中。 规模 — 触及核心路径( 方案 — 范围与目标匹配:移除内置工具面及其所有设置/schema/引导,新增一个内置 skill,并加固发布流水线( 风险 — 无高风险路径匹配。破坏性变更已清楚说明(移除 进入代码审查 🔍 — Qwen Code · qwen3.8-max Reviewed at |
Code reviewThe independent proposal for "retire the built-in CUA tools, keep one skill" is exactly what this PR does: delete Removal is complete. I grepped the tree for The release pipeline is well-guarded. Open items, none blocking:
sequenceDiagram
participant U as User
participant M as Qwen Code model
participant S as computer-use skill
participant C as qwen CLI
participant R as node-repl MCP server
participant K as cua-sdk and native driver
U->>M: desktop task
M->>S: selects skill
M->>C: qwen mcp list (first use only)
M->>C: qwen mcp add node-repl (user scope)
M->>C: npm install cua-sdk into workspace
M-->>U: asks for a restart
Note over U,K: next session
U->>M: same desktop task
M->>R: node_repl JavaScript
R->>K: ComputerUse.create()
loop observe, act, re-observe
M->>R: typed SDK calls
R->>K: accessibility actions
K-->>M: fresh window state
end
M->>R: computer.close() and node_repl_reset
M-->>U: result
Files changed (29 of 52 shown)
TestingUnattended CI run — no PR code was built or executed here; the evidence below is the PR's own CI, read through the API at the reviewed commit. The Ubuntu
Sandboxed verification would settle the remaining behavioural gap: 中文说明代码审查独立推演"退役内置 CUA 工具、只保留一个 skill"该怎么做,结论与本 PR 完全一致:删除 **删除彻底。**全库检索 发布流水线防护到位。 遗留项(均不阻塞):
测试无人值守 CI 运行——此处未构建或执行任何 PR 代码;以上证据为通过 API 读取的该 PR 自身在受审提交上的 CI 结果。 Ubuntu 沙箱验证可以补上剩余的行为缺口: — Qwen Code · qwen3.8-max Reviewed at |
|
Confidence: 4/5 — clean removal with nothing dangling, release guards are better than the feature they replace needed, and two maintainers have already signed off; the remaining points are sequencing and follow-ups, not doubts about the code. Stepping back: my independent sketch of "retire the built-in CUA tools, keep one skill" and this PR are the same shape — delete the subsystem whole, add one bundled skill, extend the release workflow that already exists. Where the PR goes past the baseline is all in the right direction: integrity-checked idempotent publication, a The deletion is the kind that usually leaves splinters, and this one doesn't: no stale references anywhere in the tree, the behavioral test coverage was renamed rather than removed, and the docs (settings table, feature page, superseded plan banner, design doc) were all walked. Net −4721 lines is a real maintenance win, and the 35 deferred tool schemas no longer ride along in sessions that never use them. Why not 5/5: the skill hardcodes Verdict: approve. ✅ 中文说明置信度:4/5 — 删除干净无残留,发布防护比旧功能所需更完备,且已有两位维护者签核;剩余问题是发布顺序与后续跟进,而非对代码本身的疑虑。 退一步看:我对"退役内置 CUA 工具、只保留一个 skill"的独立构想与本 PR 形状一致——整体删除子系统、新增一个内置 skill、扩展现有发布工作流。PR 超出基线的部分全部方向正确:完整性校验的幂等发布、 这种删除通常会留下木刺,但这次没有:全库无陈旧引用,行为测试覆盖被改名保留而非删除,文档(设置表、功能页、被取代计划的横幅、设计文档)全部跟进。净 −4721 行是实打实的维护性收益,35 个延迟工具 schema 也不再跟随从未使用它们的会话。 为什么不是 5/5:skill 硬编码了尚未发布的 结论:批准。✅ — Qwen Code · qwen3.8-max Reviewed at |
qwen-code-ci-bot
left a comment
There was a problem hiding this comment.
LGTM, looks ready to ship. ✅
|
Released in v0.22.2. |
What this PR does
This removes the previous built-in Computer Use tools, settings, downloader, permission bootstrap, schemas, and direct runtime. Qwen Code now bundles only one Computer Use skill. On first use, the skill configures the external Node REPL MCP server and installs the external CUA SDK automatically, asks for the required restart, and then follows the same observe, act, re-observe, screenshot, and cleanup workflow as the Codex Computer Use skill.
Qwen Code does not bundle the MCP server, SDK, or native driver payload and has no legacy fallback. The existing CUA release workflow independently builds, tests, packs, clean-installs, and publishes
@qwen-code/node-repl-mcp@0.1.0, with a dry-run path that performs no publication or GitHub Release mutation.Why it's needed
Keeping direct Computer Use tools alongside a skill-driven SDK path made model guidance, permissions, packaging, and debugging ambiguous. This completes the roadmap direction established by #9499 and #9587 with one execution architecture while keeping Qwen Code itself lightweight.
The skill closely follows the proven Codex workflow and adds only the Qwen-specific automatic MCP and SDK installation. It exposes the typed API surface so models do not inspect package source, guess methods, dump the complete application catalog, or continue acting after fresh state already proves the requested result.
Reviewer Test Plan
How to verify
computer_use__*tool, setting, downloader, bootstrap, schema, direct runtime, or fallback remains, and packaged Qwen Code contains the skill but not the MCP server, SDK, or native payload.Evidence (Before & After)
Before: Qwen Code registered the built-in Computer Use tool surface and owned a separate downloader, bootstrap, process, settings, and schema path.
After: Qwen Code bundles only the skill. A real
qwen3.8-maxrun with an empty isolated configuration selected the skill and automatically performed MCP configuration plus workspace SDK installation before requesting restart. A second natural-prompt run with the release-candidate MCP tarball and published SDK selected the skill in its first response, used Node REPL and the typed SDK, and changed the real AppKit text field toQWEN38MAX_SKILL_TEST; it reached postcondition verification but hit the 180-second test limit before explicit close/reset, so lifecycle completion remains pending rather than being reported as passed.Tested on
Environment (optional)
macOS 26, Node.js 22, npm 11, real
qwen3.8-max, a native AppKit accessibility harness, the published@qwen-code/cua-sdk@0.20.0, and an isolated release-candidate@qwen-code/node-repl-mcp@0.1.0tarball.Risk & Scope
tools.computerUse.*, the built-incomputer_use__*tools, and the Qwen-managed bootstrap cache are removed without a compatibility mode.Linked Issues
Builds on #9499 and #9587. Advances #9334, #9335, and #9336.
中文说明
本 PR 做了什么
本 PR 删除之前内置的 Computer Use 工具、设置、下载器、权限引导、schema 和直连运行时。Qwen Code 现在只内置一个 Computer Use skill。首次使用时,skill 会自动配置外部 Node REPL MCP server、安装外部 CUA SDK、提示完成必要的重启,然后按照与 Codex Computer Use skill 相同的观察、操作、重新观察、截图和清理流程执行任务。
Qwen Code 不会内置 MCP server、SDK 或 native driver payload,也没有旧实现 fallback。现有 CUA 发布工作流会独立构建、测试、打包、干净安装并发布
@qwen-code/node-repl-mcp@0.1.0;dry-run 路径不会执行 npm 发布或修改 GitHub Release。为什么需要
同时保留直连 Computer Use 工具和 skill 驱动的 SDK 路径,会让模型指引、权限、打包和排障产生歧义。本 PR 沿着 #9499 和 #9587 已确立的方向完成 roadmap,只保留一种执行架构,同时保持 Qwen Code 自身轻量。
skill 尽可能贴近经过验证的 Codex 工作流,只增加 Qwen 特有的 MCP 与 SDK 自动安装。它直接给出强类型 API surface,避免模型读取包源码、猜测方法、输出完整应用列表,或在最新状态已经证明目标完成后继续操作。
Reviewer 测试计划
如何验证
computer_use__*工具、设置、下载器、bootstrap、schema、直连运行时和 fallback 均不存在;Qwen Code 的发布产物只包含 skill,不包含 MCP server、SDK 或 native payload。前后证据
Before:Qwen Code 会注册内置 Computer Use 工具面,并维护独立的下载、bootstrap、进程、设置和 schema 路径。
After:Qwen Code 只内置 skill。真实
qwen3.8-max在空的隔离配置中选择 skill,自动完成 MCP 配置和 workspace SDK 安装后提示重启;第二次使用 release-candidate MCP tarball 与已发布 SDK 的自然提示测试中,模型在第一个响应选择 skill,只使用 Node REPL 和强类型 SDK,并把真实 AppKit 文本框改为QWEN38MAX_SKILL_TEST。它已经进入后置条件验证,但在显式 close/reset 前触发 180 秒测试上限,因此生命周期完整收尾仍标记为待验证,不冒充通过。已测试平台
环境
macOS 26、Node.js 22、npm 11、真实
qwen3.8-max、原生 AppKit accessibility harness、已发布的@qwen-code/cua-sdk@0.20.0,以及隔离安装的 release-candidate@qwen-code/node-repl-mcp@0.1.0tarball。风险与范围
tools.computerUse.*、内置computer_use__*工具和 Qwen 管理的 bootstrap cache,不提供兼容模式。关联问题
基于 #9499 和 #9587,推进 #9334、#9335 和 #9336。