superbased 2.0.1 → 2.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +21 -9
- package/SUPERBASED_SKILL.md +45 -2
- package/dist/headless/headless/cli.js +1 -1
- package/mcp-server/package.json +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# SuperBased
|
|
2
2
|
|
|
3
3
|
**Agent eyes, ears, and hands — cross-platform, works offline.**
|
|
4
|
-
|
|
4
|
+
72 MCP tools — full GUI automation (click / type / hotkey / scroll / drag / hover / AX-invoke / form-fill / dialog-handle / find-image / tab-management / find-in-page / virtual-desktop / tray-click) plus orientation tooling (workspace_sync / project / accessibility_tree / window_bounds / undo_last / progressive-disclosure dispatcher / stt_status), on top of screen capture / OCR / gallery / recording / monitor — with built-in humanization v2 (Bezier-curved cursor approaches with sin-shaped velocity envelope, gaussian click-target jitter, gamma-distributed inter-key timing, per-key + click hold variation, optional typo+correct sequences, per-process cross-session salt). Sign in for cloud AI.
|
|
5
5
|
|
|
6
6
|
## Three-line quickstart
|
|
7
7
|
|
|
@@ -134,11 +134,11 @@ superbased --version Show version
|
|
|
134
134
|
superbased --help Show all commands
|
|
135
135
|
```
|
|
136
136
|
|
|
137
|
-
The API server runs on `http://127.0.0.1:47592` and exposes **
|
|
137
|
+
The API server runs on `http://127.0.0.1:47592` and exposes **72 MCP tools + 13 resources**. See [SUPERBASED_SKILL.md](./SUPERBASED_SKILL.md) for the full per-tool reference (parameters, return shapes, examples, error codes, decision guide, plus a CAPTCHA-solving Common Workflows section).
|
|
138
138
|
|
|
139
139
|
---
|
|
140
140
|
|
|
141
|
-
## All
|
|
141
|
+
## All 72 tools
|
|
142
142
|
|
|
143
143
|
<details>
|
|
144
144
|
<summary>Capture & View (8)</summary>
|
|
@@ -174,15 +174,16 @@ The API server runs on `http://127.0.0.1:47592` and exposes **70 MCP tools + 13
|
|
|
174
174
|
</details>
|
|
175
175
|
|
|
176
176
|
<details>
|
|
177
|
-
<summary>Dictation & Voice (
|
|
177
|
+
<summary>Dictation & Voice (4)</summary>
|
|
178
178
|
|
|
179
179
|
- `superbased_dictate` — transcribe with cleanup (file, base64, or live mic; sign-in)
|
|
180
180
|
- `superbased_transcribe` — raw Whisper transcription (sign-in)
|
|
181
181
|
- `superbased_dictation_history` — past transcriptions
|
|
182
|
+
- `superbased_stt_status` — local STT engine probe (sherpa binary/model state, cloud signed-in, native availability, auto-resolved-to)
|
|
182
183
|
</details>
|
|
183
184
|
|
|
184
185
|
<details>
|
|
185
|
-
<summary>GUI Automation — Primitives (
|
|
186
|
+
<summary>GUI Automation — Primitives (13)</summary>
|
|
186
187
|
|
|
187
188
|
The agent's hands. All write tools accept `humanize: 'off' | 'light' | 'human' | 'paranoid'` per call (default `'light'` via `humanInputDefault` setting). All gated behind `guiAutomation.enabled` (master toggle, default OFF) + per-action toggles + `confirm: true` flag.
|
|
188
189
|
|
|
@@ -197,7 +198,8 @@ The agent's hands. All write tools accept `humanize: 'off' | 'light' | 'human' |
|
|
|
197
198
|
- `superbased_wait` — sleep N ms server-side (no per-iteration approval cost)
|
|
198
199
|
- `superbased_wait_for` — server-side polling for window appearance, pixel match, AX state
|
|
199
200
|
- `superbased_locate` — resolve label/AX/template to screen coords without acting
|
|
200
|
-
- `superbased_ui_dump` — screenshot + OCR text elements + AX tree merged (every visible element with center coords)
|
|
201
|
+
- `superbased_ui_dump` — screenshot + OCR text elements + AX tree merged (every visible element with center coords) — flat element list, optimized for "find me a clickable thing"
|
|
202
|
+
- `superbased_accessibility_tree` — raw native AX/UIA tree (hierarchical) for tree traversal, parent/child queries, full attribute access. Requires optional native binding (`@superbased/macos-ax` / `@superbased/win-uia`)
|
|
201
203
|
</details>
|
|
202
204
|
|
|
203
205
|
<details>
|
|
@@ -220,9 +222,10 @@ The agent's hands. All write tools accept `humanize: 'off' | 'light' | 'human' |
|
|
|
220
222
|
</details>
|
|
221
223
|
|
|
222
224
|
<details>
|
|
223
|
-
<summary>GUI Automation — Window + Launch + Browser (
|
|
225
|
+
<summary>GUI Automation — Window + Launch + Browser (8)</summary>
|
|
224
226
|
|
|
225
227
|
- `superbased_window_state` — minimize / maximize / restore / close / always_on_top_on/off/toggle / move_to_display
|
|
228
|
+
- `superbased_window_bounds` — read window rect + minimized/maximized state (PURE QUERY — no activation, no focus change). For "is this window in the top-left yet?" reasoning without disturbing foreground.
|
|
226
229
|
- `superbased_resize_window` — device presets (iphone-se / ipad-pro-13 / desktop-hd / etc.) + custom W×H + optional X/Y reposition; `contentArea: true` for browser device-emulation
|
|
227
230
|
- `superbased_focus_window` — standalone focus (rare — never as setup before another tool; per-tool window targeting handles this in one approval)
|
|
228
231
|
- `superbased_launch_app` — spawn process with `launchAllowlist` gate (substring or sha256:hex pin)
|
|
@@ -232,17 +235,26 @@ The agent's hands. All write tools accept `humanize: 'off' | 'light' | 'human' |
|
|
|
232
235
|
</details>
|
|
233
236
|
|
|
234
237
|
<details>
|
|
235
|
-
<summary>GUI Automation — Specialized + Meta (
|
|
238
|
+
<summary>GUI Automation — Specialized + Meta (6)</summary>
|
|
236
239
|
|
|
237
240
|
- `superbased_tray_click` — click a Windows system-tray icon by tooltip match (walks Shell_TrayWnd cross-process via VirtualAllocEx + ReadProcessMemory; optional `includeOverflow`)
|
|
238
241
|
- `superbased_virtual_desktop` — switch desktops (Win+Ctrl+Left/Right on Windows; Ctrl+Left/Right on macOS Spaces)
|
|
239
242
|
- `superbased_doctor_gui_automation` — hermetic probe (launches Notepad/TextEdit and runs every primitive, reports per-tool {ok, durationMs, errorCode})
|
|
240
243
|
- `superbased_dry_run` — cross-tool preview wrapper (`{tool, args}` returns `{errorCode: 'DRYRUN'}` without dispatching)
|
|
241
244
|
- `superbased_replay` — replay a range of `~/.superbased/audit.log` entries via `superbased_sequence` (default-safe `dryRun: true`)
|
|
245
|
+
- `superbased_undo_last` — reverse the last action from this process's in-memory stack. `type` undoes via Backspace count; `click`/`hotkey`/`scroll`/`focus_window` are popped but return `not_reversible` (call again to walk back further).
|
|
242
246
|
</details>
|
|
243
247
|
|
|
244
248
|
<details>
|
|
245
|
-
<summary>
|
|
249
|
+
<summary>Orientation + Discovery (3)</summary>
|
|
250
|
+
|
|
251
|
+
- `superbased_project` — "where am I" snapshot for agents: cwd, git branch + status + ahead/behind, detected framework(s), recent captures, active recording (if any), last dictation preview. **Recommended first call** for many agent sessions — gives enough context to pick the right tool without extra round-trips.
|
|
252
|
+
- `superbased_workspace_sync` — one-call bundled snapshot: fullscreen capture (base64 PNG) + OCR text (truncated 4000 chars) + active window metadata + timestamp + project dir. Replaces the `capture → ocr → window_list` chain with a single round-trip. Read-only; does NOT persist to gallery.
|
|
253
|
+
- `superbased_tools` — progressive-disclosure dispatcher. When `progressiveDisclosure.enabled = true` in settings, only 15 core tools appear in `tools/list`; this tool reveals the hidden tools by category (capture / record / dictate / interact / window / layout / ax / ai / edit / clipboard / system). For trimming agent token cost without restricting access.
|
|
254
|
+
</details>
|
|
255
|
+
|
|
256
|
+
<details>
|
|
257
|
+
<summary>Settings, Gallery, Auth, System (11)</summary>
|
|
246
258
|
|
|
247
259
|
- `superbased_gallery` — list / get / search / stats
|
|
248
260
|
- `superbased_gallery_update` — update tags or notes
|
package/SUPERBASED_SKILL.md
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: superbased
|
|
3
|
-
description: Use this skill when you need to see, capture, OCR, record, diff, annotate, redact, dictate, compress, or DRIVE the user's actual desktop. Provides
|
|
3
|
+
description: Use this skill when you need to see, capture, OCR, record, diff, annotate, redact, dictate, compress, or DRIVE the user's actual desktop. Provides 72 MCP tools — eyes (capture / OCR / window targeting incl. minimized / gallery search / clipboard image read / display enumeration / visual template match), ears (voice dictation + cloud transcription), hands (click / type incl. JKC / IME Unicode path / hotkey / scroll / drag incl. waypoint path / hover / pixel_color / resize_window / window_state / launch_app / open_url / virtual_desktop / tray_click / context_menu_select / ax_invoke / form_fill / dialog_handle / find_in_page / tab_management / focus_window / mouse_position / wait / wait_for / OCR-based locator / sequence), and automation meta (dry_run wrapper / replay from audit log / doctor hermetic probe — S7 additions; all write-action tools OFF by default behind a master toggle, per-action + group (safe/write/destructive) toggles, protected-apps blocklist, protected-process geofence (SuperBased self-targeting refused), confirm-flag gate, and NDJSON audit log). Plus recording sessions (smart change-detect / periodic / monitor with AI alerts), visual regression diff, baseline management, frame description / narration, token compression (text → optimized images), and PII / secrets redaction. Cross-platform (Windows / macOS / Linux). Most tools work without an account; cloud AI vision, transcription, and frame narration require sign-in. Backed by a local HTTP API on port 47592 — works alongside the SuperBased desktop app or standalone via the `superbased` npm package.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# SuperBased — Screen Capture & AI Tools via MCP
|
|
7
7
|
|
|
8
8
|
SuperBased gives you eyes on the user's screen. Use it to see what's visible, capture screenshots, analyze UI, extract text, record sessions, monitor for errors, and more — all via MCP tools.
|
|
9
9
|
|
|
10
|
-
> Skill metadata: `name: superbased` ·
|
|
10
|
+
> Skill metadata: `name: superbased` · 72 MCP tools, 13 resources · install: `npm install -g superbased` · cross-platform · most tools work without an account.
|
|
11
11
|
|
|
12
12
|
## When to Use SuperBased
|
|
13
13
|
|
|
@@ -1282,6 +1282,49 @@ Bring a window to the foreground by name substring (case-insensitive). Use ONLY
|
|
|
1282
1282
|
| `processName` | string | Exact process executable name (e.g. "Notepad", "Notepad.exe") |
|
|
1283
1283
|
| `hwnd` | string | Direct window handle from `superbased_window_list` |
|
|
1284
1284
|
|
|
1285
|
+
#### superbased_window_bounds
|
|
1286
|
+
Read a window's current screen rect + minimized / maximized state. **PURE QUERY — no activation, no focus change, no side effects.** Use when the agent needs to reason about positioning ("is this window in the top-left corner yet?", "does the target fit on the primary display?") without disturbing the user's foreground. Fills the gap where agents previously had to chain `superbased_focus_window` + fullscreen screenshot or trigger `superbased_resize_window` just to learn a rect. Rect is in virtual-screen physical pixels — directly usable as input to `resize_window` / `click` / `drag` / `screenshot` region. Windows: `GetWindowRect` + `IsIconic` + `IsZoomed` via one PowerShell call. macOS: `osascript` position + size + `AXMinimized` + `AXFullScreen` via System Events AX. Not gated by `confirm` (same policy as `window_list` / `mouse_position` — reads don't need approval).
|
|
1287
|
+
|
|
1288
|
+
| Parameter | Type | Description |
|
|
1289
|
+
|-----------|------|-------------|
|
|
1290
|
+
| `window` | string | Window-title needle (scored matcher). Use `superbased_window_list` to enumerate. |
|
|
1291
|
+
| `processName` | string | Exact process executable name. Highest-precision non-hwnd target. |
|
|
1292
|
+
| `hwnd` | string | Direct window handle (from a prior tool's `details.matchedWindow.hwnd` or `superbased_window_list`). Bypasses scoring — preferred for chained operations where the title may drift. |
|
|
1293
|
+
|
|
1294
|
+
**Returns**: `{ ok, details: { hwnd, rect:{x,y,width,height}, minimized, maximized, matchedWindow } }` on success. Returns `WINDOW_NOT_FOUND` errorCode when no matching window resolves.
|
|
1295
|
+
|
|
1296
|
+
#### superbased_accessibility_tree (Phase 8.1)
|
|
1297
|
+
Return the **native** accessibility tree for a running application — macOS `AXUIElement` via `@superbased/macos-ax`, Windows UIA via `@superbased/win-uia`. More reliable than OCR for structured UI dumps: roles, labels, values, bounding rects, and full hierarchy come straight from the OS. **Different from `superbased_ui_dump`** — `ui_dump` merges OCR text + AX into a flat element list optimized for "find me a clickable thing"; `accessibility_tree` returns the raw hierarchical structure for agents that need to walk the tree (e.g. "find the second row inside the third group inside the data table"). Requires the optional native binding installed (`npm install -g superbased --include=optional`) AND Accessibility permission granted on macOS (System Settings > Privacy & Security > Accessibility).
|
|
1298
|
+
|
|
1299
|
+
| Parameter | Type | Description |
|
|
1300
|
+
|-----------|------|-------------|
|
|
1301
|
+
| `pid` | number | Target process id. Required on darwin; optional on win32 (defaults to foreground). |
|
|
1302
|
+
| `hwnd` | number | Windows window handle (win32 only). Mutually exclusive with `pid`. |
|
|
1303
|
+
| `maxDepth` | number | Tree walker depth limit (default 24, max 64). Lower values reduce latency + JSON size on rich GUIs (e.g. complex Electron apps with thousands of nodes). |
|
|
1304
|
+
| `includeAttributes` | boolean | Include the full per-node attribute list (default false). Noisy but useful for debugging which UIA / AX attribute holds the value you want. |
|
|
1305
|
+
|
|
1306
|
+
**Returns**: `{ ok, tree?: { role, title, value, frame:{x,y,width,height}, children: [...], attributes? }, error?, message? }`. On macOS without the binding installed: `{ ok:false, error: 'binding_not_installed', hint: 'npm install -g superbased --include=optional' }`. On macOS without Accessibility permission: `{ ok:false, error: 'ACCESSIBILITY_NOT_GRANTED', hint: 'System Settings > Privacy & Security > Accessibility — add SuperBased' }`.
|
|
1307
|
+
|
|
1308
|
+
**When to use vs `superbased_ui_dump`:** prefer `ui_dump` for the common "I want to click something" path (returns flat elements with screen-space `center.{x,y}` ready to feed into `click`). Use `accessibility_tree` when you need parent/child relationships, AX-pattern availability, or the full attribute set per node — e.g. tree traversal in a treeview, finding the Nth row of a grid, querying a control's `IsEnabled` / `IsKeyboardFocusable` state.
|
|
1309
|
+
|
|
1310
|
+
#### superbased_undo_last (Phase 5.4)
|
|
1311
|
+
Reverse the last GUI automation action from this server process's in-memory stack. **`type` actions undo via Backspace keystrokes** matching the typed length (so `type "hello"` → undo presses Backspace 5×). **`click`, `hotkey`, `scroll`, `focus_window` actions are recorded but NOT reversible** — they pop from the stack and return `ok:false, error:"not_reversible"` so calling `undo_last` again reverses the NEXT-most-recent action (lets the agent walk back through a chain skipping non-reversible entries). Returns `ok:false, error:"stack_empty"` when nothing to undo. **Stack is per-process and does not persist** — clears on process restart. Useful as a safety net in agent loops where the agent realizes it just typed into the wrong field.
|
|
1312
|
+
|
|
1313
|
+
No parameters. No safety gate (action-is-reversal of an already-approved action).
|
|
1314
|
+
|
|
1315
|
+
**Returns**: `{ ok, action?, count?, ... }` on success (e.g. `{ ok:true, action:"type", count:5 }` after undoing a `type "hello"`). `{ ok:false, error:"not_reversible"|"stack_empty", ... }` otherwise.
|
|
1316
|
+
|
|
1317
|
+
**Limitations**: doesn't reverse cross-process state. If `type "hello"` triggered an autocomplete that filled additional characters, the Backspace count will under-delete. If the field was cleared by an unrelated event between the type and the undo, the Backspaces will eat the wrong characters. Treat as best-effort, especially across user-driven foreground changes.
|
|
1318
|
+
|
|
1319
|
+
#### superbased_tools (Phase 5.5)
|
|
1320
|
+
Progressive-disclosure dispatcher. **When `progressiveDisclosure.enabled = true` in settings, only the 15 core tools appear in the standard `tools/list` MCP response; the other ~57 tools are hidden but still callable.** Call this with a category to get the names + descriptions of the hidden tools in that group. Useful for token-cost reduction in agents that load every tool definition into context — the hidden tools stay discoverable but don't bloat the initial schema dump.
|
|
1321
|
+
|
|
1322
|
+
| Parameter | Type | Description |
|
|
1323
|
+
|-----------|------|-------------|
|
|
1324
|
+
| `category` | enum | One of: `capture` / `record` / `dictate` / `interact` / `window` / `layout` / `ax` / `ai` / `edit` / `clipboard` / `system`. Omit for the full index across all categories. |
|
|
1325
|
+
|
|
1326
|
+
**Returns**: `{ ok, categories: [{ name, count, tools: [{ name, description }] }], coreTools: [...] }`. The returned schemas are **names + descriptions only**; once an agent knows a hidden tool name, it can call it directly and the MCP server accepts the call. The progressive-disclosure feature is about trimming `tools/list` token cost, **not access restriction**.
|
|
1327
|
+
|
|
1285
1328
|
#### superbased_mouse_position
|
|
1286
1329
|
Read the current cursor position. Read-only; no safety gate.
|
|
1287
1330
|
|
|
@@ -256,7 +256,7 @@ Without auth (free):
|
|
|
256
256
|
find-in-page, virtual-desktop, tray-click, sequence)
|
|
257
257
|
- Humanization v2 (Bezier cursor approaches, gamma keystroke timing,
|
|
258
258
|
click-target jitter, click + key hold variation)
|
|
259
|
-
-
|
|
259
|
+
- 72 MCP tools + 13 resources for AI coding assistants
|
|
260
260
|
|
|
261
261
|
With auth (sign in for):
|
|
262
262
|
- AI analysis (vision, code review, etc.)
|
package/mcp-server/package.json
CHANGED