Gajae-Code
Gajae-Codev0.9.1

Computer use

Experimental Apple Silicon macOS screenshot and input control through Gajae-Code's native, supervisor-gated computer tool.

computer is an experimental desktop-control tool surface for Apple Silicon macOS. It controls the real desktop, so use it only when the task genuinely needs screenshots or input control.

Gajae-Code operator mascot representing desktop-control computer use

Availability

The tool is callable and discoverable by default on supported hosts:

  1. Apple Silicon macOS (process.platform === "darwin" and process.arch === "arm64").
  2. computer.alwaysOn is not explicitly false, unless computer.enabled is set to true.

When disabled or unsupported, every action returns COMPUTER_DISABLED and captures nothing. Native execution remains supervisor-gated: stale supervisor state, missing permissions, stale displays, cancellation, or suspension fail closed with a COMPUTER_* code.

Actions

The action object uses an exact snake_case discriminated schema. CamelCase fields are rejected.

ActionRequired fieldsOptional fields
screenshotnonetimeout, include_screenshot
clickx, ybutton, timeout, include_screenshot
double_clickx, ybutton, timeout, include_screenshot
movex, ybutton, timeout, include_screenshot
dragx, y, to_x, to_ybutton, timeout, include_screenshot
scrollx, y, scroll_x, scroll_ytimeout, include_screenshot
typetexttimeout, include_screenshot
keypresskeystimeout, include_screenshot
waitmstimeout, include_screenshot
batchactionstimeout, include_screenshot

button is one of left, right, or middle.

Coordinate contract

x, y, to_x, and to_y are screenshot pixels in the latest screenshot coordinate frame. They are not CSS pixels and not normalized fractions. Native code validates display freshness and coordinates before input; invalid coordinates return COMPUTER_COORD_INVALID or COMPUTER_DISPLAY_STALE.

Errors

Stable error codes include:

  • COMPUTER_DISABLED
  • COMPUTER_SUSPENDED
  • COMPUTER_SUPERVISOR_NOT_LIVE
  • COMPUTER_PERMISSION_REQUIRED
  • COMPUTER_DISPLAY_STALE
  • COMPUTER_COORD_INVALID
  • COMPUTER_CANCELLED

The TUI renderer shows bounded action metadata, coordinates, screenshot dimensions, supervisor status, and error code. It never renders raw screenshot base64.

On this page