Desktop Agent 适配器

wesgine 的 Desktop Agent 适配器提供桌面自动化能力,是三层浏览器/桌面架构的第三层。


定位

Desktop Agent 运行在客户端物理设备上(AX-5 物理边界公理),提供截屏、剪贴板、应用启动等原生桌面操作能力。


CellSpec 声明

CellSpec{
    Desktop: &DesktopConfig{
        Command: "/path/to/device-agent",
        Transport: "stdio",  // stdio 或 sse
    },
}

传输协议

传输场景
stdio本地桌面(wesclaw / wescode)
sse远程桌面(teleclaw:员工 PC 装 device-agent 监听,Cell 拨号)

API 端点

GET /cells/{id}/desktop/status    Desktop Agent 连接状态

Cell Handle

cell.Desktop() → DesktopHandle

代码共享

wesgine 提供 adapter/desktop/ 的 adapter 代码(共享维护),但 Desktop 二进制运行在客户端——运行时隔离。

各产品负责编译和分发 device-agent 二进制:


能力范围

典型 MCP tools:


超出范围

摄像头、USB、SystemTray 等硬件外设不在 wesgine Desktop Agent 范围内。


反模式

禁止正确做法
在服务端运行 Desktop Agent客户端运行(AX-5)
手写 MCP Upsert 注册 device-agentCellSpec.Desktop 声明式
跨 Cell 共享 Desktop AgentPer-Cell 连接
Desktop Agent 绕过治理链通过 MCP 协议走 Cell 治理