A personal assistant that lives on your desktop, remembers what matters, and can use your Mac for you.
TypeScript
docs(odd): specify computer control speed (S24.8, T24)
Alan Buscaglia13a8252daf1c
diff --git a/odd/tasks/gentle-dot.md b/odd/tasks/gentle-dot.mdindex 8520d17..1de35d0 100644--- a/odd/tasks/gentle-dot.md+++ b/odd/tasks/gentle-dot.md@@ -83,6 +83,7 @@ Branch: `feat/gentle-dot` · Delivery strategy: `single-pr` (user choice, L7; fo- **S24.4 Guards enforced by the helper.** A fixed blocklist: no action targets Gentle Dot's own windows, System Settings, SecurityAgent, loginwindow, Keychain Access, or known password managers (1Password, Bitwarden, Dashlane, LastPass, Apple Passwords); a target is the frontmost app for keyboard actions and the app owning the window under the point for pointer actions. A rate limit of 10 actions per second. Risky actions need a native per-action confirmation showing the action and target: a click on an Accessibility element whose role is a button or menu item and whose title or description matches send, pay, buy, purchase, delete, remove, submit, confirm, transfer, place order, checkout, or their Spanish equivalents (enviar, pagar, comprar, eliminar, borrar, confirmar, transferir); `return` or `cmd+return` while the focused element is a default button or a send-like field; or any declared `intent` matching those words. The intent only adds checks, never removes them.- **S24.5 Permissions guide.** The app reports Accessibility (`AXIsProcessTrusted`) and Screen Recording (`CGPreflightScreenCaptureAccess`) status, can prompt for them, and deep-links to the System Settings panes. The connectors screen shows a built-in "Computer" entry with both statuses, grant buttons, a note that ad-hoc signed debug builds lose the grant on every rebuild (macOS ties it to the code signature), and a note when the current model does not accept images.- **S24.6 Visible state.** While a session is active, the rose shows an "in control" state, and the panel shows a banner with the remaining time and a Stop button.+ - **S24.8 Speed (L66, user: "anda muy bien pero lento, bastante lento"; "hagamos todas si").** (a) A `batch {steps: [{tool, ...args}], intent?}` tool runs up to 20 steps of the action tools (click, move, drag, scroll, type, key, open_app, wait) in one call and returns one screenshot at the end; every step goes through the same checks as a single call (session, epoch/panic, rate limit, blocklist, risky confirmation, coordinate mapping against the screenshot taken before the batch); the batch stops at the first refused, declined, or failed step and reports which steps ran. The tool descriptions steer the model to batch predictable sequences. (b) The helper gets faster: dependencies that encode and resize images are optimized in debug builds, and the settle wait after an action drops from 300 ms to about 150 ms (open_app keeps its longer wait). (c) Screenshots get lighter (lower JPEG quality) without losing legibility of UI text. (d) Explain and fix the 18 s `type` seen in L66 if it is the helper's doing.- **S24.7 Wiring.** The desktop webview asks the app for the endpoint and registers it with the daemon (`computer_register {url, token}`); the daemon renders a built-in `computer` MCP server into the engine's `mcp.json` (direct exposure, no in-engine approval cards, since the helper enforces) and removes it on `computer_unregister` or when that client disconnects. The web UI (VPS) never offers computer control.- **S25 — Connector enforcement outside the agent's reach (stage 2, before publishing to other users).** Decided in L48. The daemon proxies MCP traffic: connector tokens live in the OS secure store (macOS Keychain, with an equivalent on Linux and the VPS), the engine sees only local proxy URLs, and enabled state, mode, and approvals are enforced by the daemon, not by files or an in-engine hook. Subagent child processes are covered too. Approvals must reach the user through a channel the agent cannot reach (L49: with the daemon access key, the agent could connect to the WebSocket and answer its own approval cards), for example a native OS dialog shown by the desktop app, or a per-window key never stored in a file the agent can read.@@ -114,6 +115,7 @@ Branch: `feat/gentle-dot` · Delivery strategy: `single-pr` (user choice, L7; fo| T21 | S24 (macOS only) | explore (delegated, read-only) → spec → implement | in progress | map done (L60) | Computer control with permissions guide, panic stop, and approvals || T21a | S24.1–S24.5 (app side), S24.6 events | delegated writer (parallel with T21b, disjoint surface `apps/desktop/src-tauri/**`) | done (verified, real Mac pending) | `176f547`, fixes `3e29886`, `3ebfe5c`, N1/N2 below; RED 82 failing → GREEN; parent re-ran cargo test 145/145 | Rust helper: MCP server, session grant, guards, permissions, panic || T21b | S24.5 UI, S24.6, S24.7 | delegated writer (parallel with T21a, surface `packages/**`, `docs/**`) | done | `5b59c0e`; RED 20 failing → GREEN; parent re-ran 400 passed / 5 skipped | Protocol, daemon registration, connectors entry, rose state, banner |+| T24 | S24.8 | delegated writer (context backstop), then independent verifier (high: touches the S24.4 checks) | in progress | — | Computer control speed: batch, faster helper, lighter screenshots || T22 | S18 (hardening, L47 B1/B2) | delegated writer | done (accepted with documented gaps, L52) | `8651bba`; parent re-ran 328 tests + typecheck | Option A: authoritative in-memory connector state with revert, credential reads blocked, path-independent bash checks, full approval preview, redirect manual, private Engram stop, onboarding overlap fix || T23 | S25 | explore → spec → implement (stage 2) | pending | — | Daemon-side MCP proxy with Keychain tokens || T9 | S1–S6, S9–S12 | delegated verifier (high risk: process supervision, auth) | done | L24 + L31 | Full verification: unit, integration, Playwright, `@real-agent`, `tauri build` + launch, manual macOS checklist with observed results |@@ -187,4 +189,5 @@ Environment notes: Node v24.14.1 and pnpm are present. `cargo` is on PATH but `r- **L63 (2026-10-08):** independent verifier on 85bd25d..3ebfe5c: all checks green (400 TS, 145 Rust, clippy, typecheck, lint); S24.2, S24.3, S24.5–S24.7 PASS; S24.4 FAIL with B1 (pointer owner resolved to the WindowServer cursor window, blocklist bypass) and B2 (same-point drag skips risky confirmation); critical R1 (daemon spawned without TCC responsibility disclaim, so the agent's bash likely inherits the app's grants, contradicting S24.1). One correction batch launched: B1, B2, R1 (posix_spawn with `responsibility_spawnattrs_setdisclaim`), and advisories A1 (space on send-like button), A2 (control characters), A4 (system dialog blocklist + focused-element pid), A5 (fresh screenshot per session), A6 (rename a saved `computer` connector instead of dropping it). Recheck limited to those items.- **L64 (2026-10-08):** correction batch `3e29886` (B1, B2, R1 disclaim via posix_spawn, A1, A2, A4, A5, A6). Recheck: B1, B2, A1, A2, A4, A5, A6 FIXED; R1 correct in code (the child is its own responsible process), real-Mac confirmation pending. New advisories closed inline by the parent: N1 (`type` refuses a space or newline after a tab, since the focus may have moved onto a send button) and N2 (Unicode line/paragraph separators and C1 controls refused); RED 2 failing → GREEN, cargo test 169/169, clippy clean.- **L65 (2026-10-08, user, real-Mac run):** screenshot of the panel toast "A change to your connectors was blocked." right after the app started. Reproduced: daemon.log showed "the desktop app registered computer control" then, 34 ms later, "put back …/connectors.json". Root cause: `enforce()` treated a missing file as untouched only with no saved connector and no computer helper, for both files, so on an install with no saved connector the registration made the missing record count as tampering. Fix `d099a89`: each file is judged by what it would hold (RED reproduced the exact log line; GREEN 402 passed; the key-leak test no longer assumes the record exists). App restarted: registration logs no revert. Note: the registration restarts the engine during startup and logs one "agent failed to start: Agent is not ready; retrying", which recovers to idle.-- **Next step:** real-Mac run: grant both permissions, take a screenshot (the Dot must be absent), click and type in a harmless app, a risky "Send" confirmation, ⌥⇧Esc panic, a blocked app (System Settings), and `screencapture -x /tmp/t.png` from the agent's bash must fail (R1); the community tester runs docs/linux-testing.md when the user shares it; T23/S25 before any public release.+- **L66 (2026-10-08, user):** real-Mac run: "anda muy bien pero lento, bastante lento". Measured from the engine session: the model takes 5–9 s per step and the helper 0.8–1 s per action (300 ms settle + capture + JPEG in an unoptimized debug build); mentioning five people took ten round trips (~70 s); one `type` with an emoji took 18 s. Proposed batch, faster helper, lighter screenshots; user: "hagamos todas si". Recorded as S24.8/T24.+- **Next step:** T24, then the remaining real-Mac checks; grant both permissions, take a screenshot (the Dot must be absent), click and type in a harmless app, a risky "Send" confirmation, ⌥⇧Esc panic, a blocked app (System Settings), and `screencapture -x /tmp/t.png` from the agent's bash must fail (R1); the community tester runs docs/linux-testing.md when the user shares it; T23/S25 before any public release.