Cua:Computer-Use 2.0 开源基础设施,桌面操控降格为工具调用

Cua: Computer-Use 2.0 Open Infrastructure — Desktop Control as a Tool Call

Tech-Experiment #computer-use#desktop-agent#benchmark#trajectory#local-ai#open-source
🇨🇳 中文

Cua 是 YC W25 孵化的跨平台桌面 Agent 基础设施,MIT 协议,当前 24,700+ stars。它把一个完整的从训练到评估的闭环——桌面驱动、云桌面集群、本地 VM、评测框架、专用小模型——打包进一套开源工具链。

仓库:github.com/trycua/cua | License:MIT | Stars:24.7K


Computer-Use 2.0 是什么

Cua 用这个词区分两代 Agent 的操作模式:

CU 1.0CU 2.0
工作方式截图 → 理解 → 执行 GUIGUI 仅是主 Agent 的一个工具调用
焦点霸占屏幕前台不抢焦点,后台操控
能力边界单一 GUI 循环代码/API/GUI 在同一任务自由切换
可观测性低(截图流)高(无障碍树 + 轨迹数据)

核心论点:桌面操控不应是 Agent 的整个循环,而应是它众多工具调用中的一种。 Agent 可以先读日志、改代码、调 REST API,只有在”GUI 是最佳接口”时才去操控屏幕。


五件套组件

1. Cua Driver(桌面驱动)

跨平台,macOS / Windows / Linux(X11、Sway、GNOME)。特点:

  • 不抢焦点:后台操控原生 App,用户可以同时用电脑
  • 双感知流:无障碍树(Accessibility Tree)+ 截图,Agent 选择用哪个
  • 接口:MCP / CLI / Python SDK / TypeScript SDK
  • 已接入:Claude Code、Codex、Hermes、Qwen Code、Factory Droid、Clicky
from cua import Driver

async with Driver() as driver:
    await driver.open_app("Finder")
    await driver.click("Desktop")
    screenshot = await driver.screenshot()

2. Cua Fleets(云桌面集群)

run.cua.ai,隔离 Sandbox 池,预热消除冷启动延迟。支持 Linux 容器、macOS VM、Windows VM、Android(QEMU)。注意:claim 结束后 Pool 保留计费容量,需主动清理。

3. Lume(本地 VM 管理器)

仅限 Apple Silicon,用 Apple Virtualization.Framework 跑本地虚拟机,声称 CPU 速度达宿主机 97%。

/bin/bash -c "$(curl -fsSL https://cua.ai/lume/install.sh)"
lume create --os macos --size 50gb  # macOS 镜像约 50GB

限制:macOS VM 绑死 Apple Silicon。Linux/Windows/Android 在支持 QEMU 的任何宿主机可跑。

4. Cua Bench(评测框架)

确定性三段式:setup → agent execution → evaluation。兼容 OSWorld、ScreenSpot、Windows Arena,支持导出轨迹数据供训练。

KiCad 专项评测(25 道专家级 PCB 任务)揭示了真实能力上限:

模型完成数/25
GPT-5.56(最佳)
Gemini 3.5 Flash5(全解)+ 3(部分)
其余 5 个前沿模型0(空白画布任务全部失败)

OSWorld 全行业当前仍在 30~50%——Cua 提供的是 infra,不是 intelligence。

5. CUA-S1-Forms(专用小模型)

第一个 System 1 模型,面向表单填写决策场景。

参数量体积架构
706,048(约 70 万)2.8 MB字节级嵌入 + 2 层 Transformer Encoder(宽 128,4 头)

工作方式:不生成文本,单次前向传播对候选动作(FILL / CHECK / CLICK / SKIP)打分并返回概率分布。每个选项作为 query 对 context token 做 attention(AttentionHead 机制)。

实测性能

测试集CUA-S1-FormsJev API
合成测试集99.95%
真实表单(3 份 / 196 决策)100%83.6%

模型限制

  • 只从文档解析器已提取的实体中选取,无法生成新值
  • 合成数据训练为主,真实验证样本少(196 个决策)
  • 字节级 encoder,中文不友好
  • 仅首发表单场景,其他 GUI 交互尚无对应 S1 模型

安装

# Driver(macOS/Linux)
/bin/bash -c "$(curl -fsSL https://cua.ai/driver/install.sh)"

# Python SDK
pip install cua

# TypeScript SDK
npm install @trycua/cua

# Bench(Python 3.12+ 和 uv)
uv tool install 'cua-bench[browser]'

许可证注意:可选依赖 ultralytics 为 AGPL-3.0,商用前需确认是否引入。


怎么看这件事

Cua 的价值主要在基础设施层,不是模型层。它把”截图 + 点击”的简单循环拆解成可组合的工具链——驱动、沙盒、评测、轨迹导出——让上层 Agent 系统可以把桌面操控当普通工具调用而非核心循环。

CUA-S1-Forms 的 70 万参数 / 2.8 MB 是它在模型侧的一次表态:对于特定场景的快速决策,不需要大模型。但 196 个真实决策的验证规模很小,距离足够的置信度还有距离。

KiCad 测试数字更能说明现状:最强模型 25 题只过 6 道,OSWorld 全行业卡在 30~50%。这不是在否定 Cua,而是在说整个 Computer-Use 领域的 intelligence 仍然是短板——Cua 让这个短板变得可测量、可观测,这是它真实的贡献。

开源代码与模型仅供学习研究,商用前注意 AGPL-3.0 依赖污染风险。


🇬🇧 English

Cua: Computer-Use 2.0 Open Infrastructure

Cua (YC W25) is a cross-platform desktop agent infrastructure stack — MIT licensed, 24,700+ stars. It ships five pieces as a single open-source toolkit: a desktop driver, cloud desktop pools, a local VM manager, a deterministic benchmark framework, and a series of tiny specialized decision models (CUA-S1).

Repo: github.com/trycua/cua | License: MIT | Stars: 24.7K


Computer-Use 2.0: The Concept

CU 1.0CU 2.0
Execution modelScreenshot → understand → execute GUIGUI is one tool call among many
FocusFront-stage, cursor-grabbingBackground, non-disruptive
CapabilitySingle GUI loopCode / API / GUI within the same task
ObservabilityLow (screenshot stream)High (accessibility tree + trajectory data)

The core claim: desktop control should be a tool the primary agent reaches for — not the entire loop. An agent should be free to read logs, edit code, or call an API, and only drop down to GUI interaction when the screen is the best interface.


Five Components

Cua Driver — cross-platform (macOS / Windows / Linux X11/Sway/GNOME). Runs in background without grabbing focus. Exposes both an accessibility tree and screenshots. Integrates via MCP / CLI / Python SDK / TypeScript SDK. Already wired into Claude Code, Codex, Hermes, Qwen Code.

Cua Fleets — cloud desktop sandbox pool (run.cua.ai). Pre-warmed to eliminate cold starts. Supports Linux containers, macOS VMs, Windows VMs, Android (QEMU). Note: pool capacity keeps billing after a claim ends — requires manual cleanup.

Lume — local VM manager for Apple Silicon only, using Apple Virtualization.Framework. Claims 97% native CPU speed. macOS images are ~50 GB.

Cua Bench — deterministic three-stage framework (setup → execution → evaluation). Compatible with OSWorld, ScreenSpot, Windows Arena. Exports trajectory data for training.

CUA-S1-Forms — first System 1 model (706K params, 2.8 MB). Single forward pass scores candidate actions (FILL / CHECK / CLICK / SKIP) against extracted entities. No text generation.


Honest Benchmark Numbers

KiCad benchmark (25 expert-level PCB tasks, Cua Bench-driven):

ModelCompleted / 25
GPT-5.56 (best)
Gemini 3.5 Flash5 full + 3 partial
5 other frontier models0 (all failed on blank-canvas tasks)

OSWorld: industry-wide still 30–50%. Cua provides infrastructure, not intelligence.

CUA-S1-Forms accuracy:

  • Synthetic test set: 99.95%
  • Real forms (3 forms / 196 decisions): 100% vs Jev API’s 83.6%
  • Validation sample size is small — 196 decisions is not a large production dataset.

Limitations

  1. macOS VM locked to Apple Silicon. Linux/Windows/Android run on any QEMU host.
  2. macOS images ~50 GB — not a quick install.
  3. Linux Driver still pre-release.
  4. CUA-S1-Forms can only pick from already-extracted entities — cannot generate new values.
  5. Byte-level encoder is not Chinese-friendly.
  6. Optional ultralytics dependency is AGPL-3.0 — commercial use requires careful review.
  7. Fast-moving codebase (1,300+ stars/week) — pin versions.

Bottom Line

Cua’s value is primarily in infrastructure: it decomposes the “screenshot-and-click” loop into composable, observable primitives. The trajectory export and deterministic benchmarking are the most immediately useful pieces for anyone building or evaluating desktop agents. CUA-S1-Forms at 2.8 MB is a credible proof-of-concept that specialized models can handle narrow GUI decisions efficiently — but 196 real-world validation decisions is a thin sample. The KiCad numbers are the most honest signal in the whole package: the intelligence problem in computer-use is wide open, and Cua is making it measurable.

Open-source code and models for research and learning only. Check AGPL-3.0 transitive dependency exposure before commercial use.

💬 评论与讨论

使用 GitHub 账号登录后发表评论

关于本站 · 免责声明

🍄 Mushroom Research Blog 是非营利、免费公开的个人科技观察博客与公众号 XStack18,不接受商业合作、不代表任何企业或机构立场,也不谋求商业利益。我们以个人视角客观中立地记录和分析 AI、Web3 等领域的最新模型发布与技术动态——不止转述新闻标题或二手信息,而是给出有独立思考的深入分析,希望帮更多人获得有价值的一手科技认知。

⚠️ 文中介绍的开源代码与模型,仅供学习交流与技术借鉴。它们大多仍处于早期阶段,有待进一步研究和验证,请勿直接用于工作或生产环境;如需采用,请先自行充分测试,并核实其许可证与安全性。
Open-source code and models featured here are shared for learning and reference only. Most are early-stage and still need further study and verification — please don't use them directly in your work or in production. Test them thoroughly and check their licenses and security first.

  1. 本站文章均为作者基于公开信息的个人研究与观点整理,不代表文中提及的任何公司、产品、模型的官方立场,未与其构成商业关联或合作关系。
  2. 科技行业信息更新极快,我们尽力保证内容准确、及时,但不对完整性、实时性做绝对保证,具体请以相关企业/项目官方公告为准。
  3. 文中引用的第三方商标、产品名称、图片、数据等版权归原权利人所有,我们会尽量注明来源;如你认为存在版权疑问或侵权,请通过下方邮箱联系我们,收到通知后会尽快核实处理(更正、加注来源或删除)。
  4. 文章内容仅为技术科普与个人观点,不构成投资、法律或其他专业建议,据此进行任何决策的后果需自行判断和承担。

📮 侵权 / 勘误 / 合作咨询:[email protected]