z-vision
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
z-vision — Token-Diet Windows Desktop Vision & Safe Agent Arm
Give AI coding agents crisp Windows desktop eyes, zero-hijack virtual pointers, and multi-arrow parallel execution without burning vision tokens.
z-visionpairs a token-diet Node.js 22+ MCP server with an on-the-fly C# 5 native Windows host compiled by stock.NET Framework 4.xcsc.exe— zero npm packages, zero .NET SDK required, and built-in Esc / Ctrl+Alt+F12 emergency stop.
Visual Demos
Virtual Mouse (mode: "virtual") — Zero Hardware Cursor Hijack
Resolves leaf child windows (ChildWindowFromPointEx + ScreenToClient) and dispatches WM_MOUSEMOVE / WM_LBUTTON* / WM_MOUSEWHEEL / WM_CHAR directly to target HWNDs while leaving the user's real cursor and focused editor undisturbed.
Multi-Arrow Parallel Execution (zvision_parallel + ArrowOverlay.cs)
Runs up to 8 concurrent stroke/input lanes (virtual per-lane PostMessage or Win8+ multi-contact InjectTouchInput), rendered in real time through a topmost click-through layered arrow HUD (#1..#N) that clears immediately on completion or Esc.
Related MCP server: ScreenMind
Key Capabilities
Desktop Vision ("Eyes")
Window Enumeration & Launch (
zvision_windows): Lists visible windows with bothDWMWA_EXTENDED_FRAME_BOUNDS(bounds, eliminating invisible Windows 10/11 drop-shadow drift) andclient_bounds(GetClientRect). Optionally launches target apps first vialaunch_exe/launch_args.Compact UI Automation Tree (
zvision_observe): WalksUIAutomationClientcontrols with COM/disposal guards and returns 1-line summaries ([0] Button "Save" aid=btnSave (420,310 80x28) [Invoke]) — ~10–15 tokens/control.64-Bit Perceptual dHash Gating (
with_image: "auto"): Computes a 9x8 BT.709 grayscale difference hash on every frame. When the Hamming distance vs. the prior frame is<= 2and UIA nodes are present, redundant screenshots are suppressed automatically andimage_sizeresets toboundsto eliminate phantom coordinate scaling.Explicit Coordinate Spaces (
coord_space): Supportsimage(default downscaled screenshot pixels),window(offset from DWMbounds),client(offset fromclient_boundsinside titlebar/borders), andscreen(exact virtual-desktop pixels).Native Windows WinRT OCR (
zvision_ocr): UsesWindows.Media.Ocrdirectly from Windows 10/11 WinMetadata returning lines, words, and absolute screen bounding boxes (gracefully degrades if WinMetadata is absent).Template Matching: Coarse-to-fine Normalized Cross Correlation (NCC) over grayscale buffers for owner-drawn icons or custom surfaces.
Precision Physical, Virtual & Parallel Arm ("Hands")
Physical Pixel-Center Actuation (
mode: "physical"):SendInputacross multi-monitor virtual desktops (MOUSEEVENTF_VIRTUALDESK) with pixel-center65536rounding,GetCursorPosverification, optionalrestore_cursor, full UTF-16 / Vietnamese typing (KEYEVENTF_UNICODE), STA clipboard-preservingpaste, hotkey chords (key), and semantic UIA (mode: "uia"/physical: false).Virtual Background Mouse (
mode: "virtual"): Sends targetedPostMessagemouse, wheel, and character events directly to resolved leaf childHWNDs without moving the hardware cursor or stealing active window focus.Sequential Batch Plans (
zvision_plan): Pre-validates and runs 1..50 sequential steps in a single turn (click,drag,type,paste,key,wait_settle,wait_text,sleep), stopping immediately on first failure or emergency stop.Concurrent Multi-Arrow Lanes (
zvision_parallel): Runs 1..8 concurrent lanes invirtualmode or Win8+touchmulti-pointerInjectTouchInputmode with numbered click-through overlay arrows (show_arrows: true).
Example: Virtual Client-Space Action & Parallel Multi-Arrow Batch
// Single action targeting Paint / WinForms canvas without moving hardware cursor
{
"observation_id": "obs_42",
"action": "drag",
"mode": "virtual",
"coord_space": "client",
"points": [[80, 120], [220, 95], [380, 140]],
"restore_cursor": true,
"reason": "Draw ridge stroke inside client canvas"
}// 4-lane concurrent parallel drawing with numbered ArrowOverlay HUD
{
"observation_id": "obs_43",
"mode": "virtual",
"coord_space": "client",
"show_arrows": true,
"lanes": [
{ "id": "sky", "steps": [{ "action": "drag", "points": [[40, 80], [520, 80]], "steps": 14 }] },
{ "id": "ridge", "steps": [{ "action": "drag", "points": [[40, 150], [280, 130], [520, 145]], "steps": 16 }] },
{ "id": "terrace", "steps": [{ "action": "drag", "points": [[40, 220], [520, 220]], "steps": 14 }] },
{ "id": "arch", "steps": [{ "action": "drag", "points": [[240, 260], [240, 195], [320, 195], [320, 260]], "steps": 16 }] }
],
"reason": "Render 4 landscape layers concurrently"
}Safety & Control Fences
One-Use
observation_id+ Window Drift Guard: Everyzvision_act,zvision_plan, andzvision_parallelconsumes itsobservation_idonce and aborts (stale_observation) if the window moved/resized beyond4pxor if Stop occurred.Process Tier Isolation:
blocked: UAC / credential dialogs (consent.exe,CredentialUIBroker.exe,LogonUI.exe,LockApp.exe) block all input.click-only: Terminals and IDEs (WindowsTerminal,pwsh,cmd,Code,devenv,rider64,regedit, etc.) reject typing/keystrokes unlessallow_restricted: trueis explicitly passed.
Sensitive Action Confirmation: Blocks English/Vietnamese destructive labels (
delete,pay,submit,password,xóa,thanh toán,chuyển khoản,đăng nhập, ...) and dangerous hotkeys (Alt+F4,Win+R,Ctrl+Alt+Del) unlessconfirm_sensitive: true+reasonare supplied.Hardware Emergency Stop (
zvision_stop): Dedicated low-level hook (WH_KEYBOARD_LL) intercepts physicalEscorCtrl+Alt+F12, latchesemergency_stopped, releases all held inputs tracked inInputLedger, and immediately clearsArrowOverlay.
MCP Tools (8 Focused Tools)
Tool | Purpose |
| Inspect monitors/DPI, virtual mouse & touch injection support, cursor position, WinRT OCR, and Stop state |
| List visible desktop windows ( |
| Read compact UIA tree, 64-bit |
| Execute one guarded action via |
| Pre-validate and run 1..50 sequential steps ( |
| Run 1..8 concurrent lanes ( |
| Run WinRT OCR on a window or screen ROI |
| Latch emergency stop, reset stop state, release all held inputs, and clear overlay arrows |
Zero-SDK Native Architecture
On first run on Windows,
scripts/lib/native-builder.mjslocates stockC:\Windows\Microsoft.NET\Framework64\v4.0.30319\csc.exe, GACUIAutomation*/WindowsBaseassemblies, andC:\Windows\System32\WinMetadata\Windows.*.winmd.It compiles
scripts/native/*.cs(ZVisionHost.cs,UiaTree.cs,InputArm.cs,VirtualPointer.cs,ArrowOverlay.cs, etc.) into~/.z-plugin/z-vision/bin/ZVisionHost-<sha256>.exe(override withZVISION_DATA_DIR).If
WinMetadatais unavailable on a machine, it automatically falls back to compiling core UIA + Capture + dHash + InputArm + VirtualPointer + ArrowOverlay without WinRT OCR.scripts/lib/host-client.mjsspawnsZVisionHost.exelazily over UTF-8 newline-delimited JSON stdio and shuts it down after idle timeout.
Installation
Google Antigravity & ZCode
git clone https://github.com/kzxl/z-vision.git
cd z-vision
powershell -ExecutionPolicy Bypass -File install.ps1Cursor / Claude Code / Any MCP Client
Add to your .cursor/mcp.json or .claude_mcp.json:
{
"mcpServers": {
"z-vision": {
"command": "node",
"args": ["C:/path/to/z-vision/scripts/mcp-server.mjs"]
}
}
}Standalone CLI
npm run build
node scripts/cli.mjs status
node scripts/cli.mjs windows
node scripts/cli.mjs observe 0 --image
node scripts/cli.mjs ocr 0
node scripts/cli.mjs stopTesting
npm run check
npm testRuns safety-policy unit tests (coord_space, validateParallelLanes), mock-transport vision-engine tests, MCP JSON-RPC stdio smoke tests, and on Windows compiles ZVisionHost.exe via csc.exe and executes real desktop probe status, windows (client_bounds), observe, virtual click (CLICKED_VIRTUAL without cursor hijack), 2-lane parallel, ocr, and stop/reset checks (65 assertions).
License
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Let AI see and use your own Windows PC with your permission: screen, apps, mouse and keyboard.
Connect ChatGPT, Claude, Cursor or VS Code to your Windows PC: files, terminal, browser, apps.
Remote desktop MCP: let AI see, click, type and run terminal commands on your own Windows or Mac.
Real desktops for AI agents, on machines you choose: screenshot, type, click, hire more agents.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables AI agents to control Windows GUI applications like a human using screen capture, OCR, mouse and keyboard input, and window management, with safety levels and memory.-
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to inspect and operate Windows applications through structured UI Automation maps, humanized mouse and keyboard input, and on-demand screenshots or OCR via MCP. It supports locating elements by role, name, or query; clicking, typing, scrolling, window management, event watching, and chained multi-step actions without relying on image analysis.MIT
- AlicenseNot gradedqualityCmaintenanceEnables MCP-capable AI agents to control Windows desktops through UI Automation element trees, native screenshots, app launching, batched action sequences, smart waits, and safety gates using normalized coordinates.MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI agents to capture and inspect high-resolution Windows desktops, snip and zoom regions, use UIA/OCR perception, and control mouse and keyboard input with closed-loop safety.MIT