26 Commits
Author SHA1 Message Date
Waleed 11cd2cb867 fix(computer-use): tighten app-command update confirmations (#10236)
* fix(computer-use): check both event boundaries, show offset times locally, refuse mismatched date forms before asking

* fix(computer-use): keep a new time's offset beside its local time, filter all bidi controls, bound create titles
2026-11-19 23:04:35 -08:00
Waleed 017ac49d89 feat(computer-use): edit calendar events and add to contacts through app commands (#10228)
* feat(computer-use): find and update calendar events through app commands

* fix(computer-use): refuse unverifiable long fields, keep long events editable, one line per confirmed value

* feat(computer-use): find contacts and add details to them through app commands

* fix(computer-use): keep dialing controls when de-duplicating phones, and de-duplicate within a request

* fix(computer-use): read phone digits from any script, and report Contacts failures as failures

* fix(computer-use): find a unified contact's record in the group's account
2026-11-19 21:51:43 -08:00
Waleed 1ace34f28d feat(computer-use): find and update reminders through app commands (#10222)
* feat(computer-use): find and update reminders through app commands

* fix(computer-use): refuse stale reminder updates and bound replies in UTF-16 units
2026-11-19 20:17:50 -08:00
Waleed e97cb17d17 fix(computer-use): reject impossible app-command dates and name the destination in confirmations (#10210)
* fix(computer-use): reject impossible app-command dates and name the destination in confirmations

- The helper's zoned date-time parser rolled Feb 30, Feb 29 in a common year and hour 24 into
  other days and accepted offsets like +25:00; zoned values are now checked part by part, while
  local times keep the strict formatter
- Reminders trim their title and notes with the same helpers events use, so the confirmation
  shows exactly what is saved
- The confirmation names the chosen list, calendar or group, read from the helper when it is
  shown; an id missing from a complete list is refused before the user is asked
- Synced the computer-use contract, which now refuses impossible dates at tool validation

* fix(computer-use): read only ASCII digits and cap zoned offsets at ±14:00; accept minute-precision zoned times
2026-11-19 11:30:24 -08:00
Waleed e0b5ec1631 feat(computer-use): add typed reminder, event and contact app commands behind a desktop capability (#10196) 2026-11-18 22:38:57 -08:00
Waleed 06db09b0a0 improvement(computer-use): name the activation step when an element refuses an advertised action (#10189) 2026-11-18 15:45:10 -08:00
Waleed 99a6c76083 fix(computer-use): observe an app's floating and panel-level windows (#10188) 2026-11-18 14:47:08 -08:00
Waleed 4a304942d5 fix(computer-use): find a save panel control's window through its ancestors when it reports none (#10116) 2026-11-16 19:48:56 -08:00
Waleed f836354903 improvement(computer-use): wait for an app's first observable window after launching it (#10112)
* improvement(computer-use): wait for an app's first observable window after launching it

* count a minimized window as ready and time out each window read
2026-11-16 18:58:01 -08:00
Waleed cbb3d5e89b fix(computer-use): treat an attribute-unsupported refusal of an advertised action as unsupported (#10109)
* fix(computer-use): treat an attribute-unsupported refusal of an advertised action as unsupported

* scope the refusal mapping to performed actions; value and selection writes keep the generic error
2026-11-16 18:13:52 -08:00
Waleed ac5c50a78a improvement(computer-use): report an advertised action the element refuses as unsupported, with the snapshot still valid (#10106) 2026-11-16 17:42:53 -08:00
Waleed eb9c30fedc improvement(computer-use): keep an element's id stable across observations (#10046)
* improvement(computer-use): keep an element's id stable across observations

* fix the snapshot key and make the stable-id fixture insert ahead of the field

* assert stable ids on an element after the inserted row

* keep element ids across actions, which consume the actionable snapshot

* keep each app's id counter apart from the evictable history and carry the index only when a full read fits the cap
2026-11-14 11:53:35 -08:00
Waleed 0156813a4c fix(computer-use): stop reporting closed menu items past the cap as a truncated state (#10043) 2026-11-14 05:53:04 -08:00
Waleed abd2e8df24 fix(computer-use): read elements reported at infinity without a frame instead of crashing the helper (#10034) 2026-11-13 18:43:16 -08:00
Waleed 377e81bf09 fix(computer-use): type after a focus click only once the caret is confirmed at the end (#10019)
* fix(computer-use): type after a focus click only once the caret is confirmed at the end

The click-to-focus fallback typed at the click point when the editor exposed no
settable selection range or no string value, or when focus settled only after its
poll. It now reads the editor's length (value or AXNumberOfCharacters), accepts an
empty editor or a caret already at the end, verifies a caret move by reading the
range back, and otherwise refuses with caret_unconfirmed before any keystroke. An
input_sequence that starts with Cmd+A skips the check, since it replaces the value.

* test(computer-use): cover the caret_unconfirmed refusal with an editor that ignores caret moves
2026-11-13 16:16:05 -08:00
Waleed 06f077d8d9 fix(computer-use): tighten batch and click-to-focus edge cases from the staging audit (#10012)
* fix(computer-use): tighten batch and click-to-focus edge cases from the staging audit

Validate every batch step before the first runs and name a refused first step;
observe the window a batch targets; wait 250 ms for Accessibility focus before
clicking, treat a refused click as no click and put the caret at the end; never
report nothing-dispatched after a click; skip per-attribute fallback reads on a
hung app; guard a self-parent in the projection; fix legend and README wording.
Syncs the contract's activateFirst wording.

* fix(computer-use): check Stop before every batch step, validate click and scroll targets up front, and keep the escaped-newline row cost

* fix(computer-use): send no text when the caret cannot be moved to the end after a focus click
2026-11-13 13:53:41 -08:00
Waleed 6cb5bfcf11 fix(computer-use): click an editor into focus when Accessibility cannot focus it (#10004)
* fix(computer-use): click an editor into focus when Accessibility cannot focus it

SwiftUI sheets such as Clock's city search ignore an Accessibility focus request, so
type_text refused with 'the exact editor is no longer focused'. In a foreground app
the helper now clicks the editor's center, only when that point hit-tests to the
editor inside its observed window, then applies the usual focus checks.

* docs(computer-use): describe the click-to-focus fallback

* fix(computer-use): click only onto the editor or a text control inside it, and cover click-to-focus in the live fixture

* test(computer-use): move focus away before checking the background click-to-focus refusal

* fix(computer-use): check for Stop before the click-to-focus mouse-down

* fix(computer-use): never click a secure field into focus
2026-11-13 12:33:02 -08:00
Waleed cd82e4faed feat(computer-use): batch 2-8 actions per call and read app state in one round trip per element (#9995)
* improvement(computer-use): read each node's attributes in one Accessibility round trip

Index observed elements by CFHash so membership and parent lookups stay linear,
and query value settability only for text roles.

* feat(computer-use): batch 2-8 actions planned from one snapshot

Each step runs through its single action's checks; the batch stops at the first
failure and after any step that changes the app's window structure, and returns
one fresh observation.

* test(computer-use): check the sheet batch's skipped step after dismissing the sheet

* fix(computer-use): stop a batch on menu or sheet switches and before any step after Stop

The structure guard compares on-screen window and focused-window child identities
instead of counts, and every step checks cancellation first. Synced the contract,
which now bounds batch progress to 2-8 steps.
2026-11-13 04:58:30 -08:00
Waleed 2c6d89c051 fix(computer-use): refuse Script Editor, Automator and Shortcuts, which run shell commands outside the Terminal control (#9990) 2026-11-12 22:06:31 -08:00
Waleed e09144ac7a improvement(computer-use): allow every app by default, protect sensitive apps, and make per-app approval optional (#9980)
* improvement(computer-use): allow every app by default, block password managers, make per-app approval optional, and trim the settings

Turning Computer Use on and granting Accessibility and Screen Recording now covers
every app except Sim, System Settings and password managers. Approving each app's
first use becomes an opt-in setting, and the settings section keeps only the switch,
the two macOS permissions and the optional approvals.

* fix(computer-use): protect terminals, match protected bundle IDs case-insensitively, and remember unlisted app names

* fix(computer-use): protect more terminals, test the protected-app guard, and keep the approval copy for older shells

* fix(computer-use): describe ask mode in the settings line and list the protected apps in the helper README
2026-11-12 20:48:54 -08:00
Waleed 200b219663 fix(desktop): let computer use type into date and time pickers (#9128) 2026-10-16 01:59:03 -07:00
Waleed 28eaf54ae6 fix(desktop): tighten computer use input guards for text, tabs, menus and AX failures (#9112)
* fix(desktop): tighten computer use input guards for text, tabs, menus and AX failures

* fix(desktop): keep hidden tabs out of the window list and pin typed text to its first editor
2026-10-15 23:17:41 -07:00
Waleed ce1f2f5ed9 fix(desktop): count only UI-opening AX actions as delivered on timeout, drop unused contract target (#9100) 2026-10-15 19:33:16 -07:00
Waleed debdd0e7ce fix(desktop): accept common computer calls and let input reach attached sheets (#9093)
* fix(desktop): accept coordinate input without a window, one-axis scrolls and targeted keys

Mirrors the worker contract. Coordinate clicks, scrolls and drags without a windowId
target the window the snapshot selected; scroll deltas default to 0; press_key with an
elementId focuses that element first. Each shape was rejected before reaching the app
in benchmark runs (about one call per task).

* fix(desktop): let input reach sheets attached to the observed window

Go to Folder and out-of-process open and save panels are sheets: the app reports
them as its focused window, and a panel's contents report no window at all. Input
checks now treat a sheet as the window it is attached to, and a click on windowless
panel content is allowed only inside the app's focused sheet.

* fix(desktop): keep coordinate input on the selected window and confirm targeted focus

- Coordinate clicks and scrolls without a windowId use the snapshot's selected
  window through every input check; element targets keep their own window
- press_key with an elementId sends the key only once that element holds focus
- The service observes the selected window after a call without one
- A scroll needs at least one delta, matching the worker contract

* fix(desktop): observe the focused window after an untargeted key
2026-10-15 17:05:36 -07:00
Waleed fda495d258 fix(desktop): make computer use act on the app the user sees (#9084)
* fix(desktop): make computer use act on the app the user sees

- Hit-test coordinate input with Accessibility: Notification Center and the Dock keep
  full-screen click-through windows, so the window-list check rejected every click
- Count an AX press that times out while a sheet or modal opens as dispatched
- Keep the snapshot when nothing reached the app, in the helper and the service
- Type into any focusable element (terminals, combo boxes), send keys to sheets
  and popovers, accept common key aliases
- Complete menu presses that only highlight their item, observe open menus and
  submenus first, and show menu shortcuts in labels
- Fit the model projection under Mothership's computer result budget

* test(desktop): computer-use snapshots survive actions that sent nothing

* fix(desktop): refuse unverifiable clicks, stop menu completion on cancel, scope press_key

- Refuse coordinate input when Accessibility cannot say which app owns the point
- Check cancellation before the menu-completion Return
- press_key goes to the observed window or a dialog, panel or popover above it,
  never another document window
- Only presses treat an Accessibility timeout as delivered; a value or selection
  change that times out fails as uncertain

* fix(desktop): accept press_key without a window and screenshot shorthand on actions

Mirrors the worker contract: press_key may omit windowId (the key goes to the
focused observed window, or a dialog above it), and mutations accept
includeScreenshot as shorthand for observeAfter.includeScreenshot.

* fix(desktop): type the computer-use params omit over the whole input union

* fix(desktop): confirm the click window and the highlighted menu item before input

- A coordinate click must land in the observed window, or in a sheet, popover,
  panel or menu above it; another document window of the same app is refused
- The menu-completion Return is sent only when the pressed item reports itself
  highlighted

* fix(desktop): refuse input when the receiving window cannot be confirmed

Clicks and keys go only to the observed window, or to one of the app's dialogs or
floating panels above it. A missing window attribute is allowed only for menus, and
an unreadable subrole is refused rather than treated as auxiliary.

* fix(desktop): revalidate the editor's window before every keystroke

type_text and input_sequence check, before each key, that the editor still sits in
an observed window (or a dialog above it) at its observed frame.

* fix(desktop): compare the observed window's identity, not only its bounds

Each observed windowId keeps its Accessibility window, and click, key and editor
checks require that exact window at its observed frame (or a dialog or floating
panel), so a second document window with identical bounds is refused.

* fix(desktop): refuse input to windows whose identity is ambiguous

Window-list entries match their Accessibility windows only by bounds; when two
windows share bounds neither gets an identity, so input aimed at either is refused
instead of possibly reaching the other.

* fix(desktop): read editor focus after activateFirst brings the app forward
2026-10-15 15:13:26 -07:00
Siddharth GanesanandVikhyath Mondreti f525ff2feb feat(mothership): add super-user Plan and knowledge graph settings with benchmark tooling (#8637)
* feat(mothership): authorize private cross-workspace memory scopes

* feat(desktop): add gated macOS computer use

* fix(desktop): preserve generated computer-use contracts

* fix(desktop): cancel computer use when its renderer exits

* fix(desktop): complete native computer tool lifecycle

* fix(desktop): support rich editors and verified Mac input batches

* fix: preserve desktop observations through recovery and report app focus

* Gate Search Assistant integration lookups with AppConfig (#8301)

* Enable read-only integration lookups for Search Assistant

* Preserve inherited tool versions in generated integration docs

* Align provider tests with Search read-only operations

* Gate Search integration tools with AppConfig

* Preserve dev test runner isolation during promotion

* Default Plan chats to independently saved Opus 5.5 Medium preferences

* Remove default Mship execution cutoff and expose Slack agent prerequisites

* fix(catalog): preserve credential gates for automation discovery

* Add workspace specification benchmarks with isolated Plan evaluation

* Add private knowledge graph selection in settings

* Retain benchmark run history with comparisons and human review

* chore: redeploy Sim after benchmark configuration update

* Add superuser benchmark console with selected-user execution

* Inspect benchmark workspaces incrementally and search generated specs

* Remove benchmark cutoffs and renew active stage leases

* Generate benchmark redactions from exact passages

* Create owned conversations for every benchmark execution

* Preserve partial benchmark answers for human review

* Grade benchmark mechanics with verified reference resolution

* Reconcile Plan feature with staging contracts and validation gates

* Expose the Graphiti rollout gate through authorized memory scope

* Share benchmark super-user eligibility with Plan and knowledge graphs

* fix(plan): address eligibility, benchmark state and desktop review findings

* feat: compare benchmark planner models with saved scores

* test: align Plan composer and desktop fixtures with staging

* fix(desktop): keep disabled computer use dormant

* fix(plan): enforce benchmark and native action admission

* fix(plan): preserve secret metadata during benchmark reads

* fix(plan): isolate embedded CLI and checkpoint benchmark stages

* fix(desktop): bound native requests and completion images

* fix(plan): revalidate access and retain benchmark state

* fix(plan): qualify persisted effort integration fixtures

* fix(db): reconcile benchmark migrations with staging retirement

* fix(db): preserve table change log in benchmark migration chain

* fix(benchmarks): delete artifacts with their execution target

* fix(mothership): isolate benchmark state and preserve tool completions

* fix(desktop): preserve action evidence in unload completions

* fix(desktop): keep projected parent references valid

* fix(computer): preserve uncertainty and label permission controls

* test(mothership): await actual tool cancellation completion

* fix(plan): resolve review findings and trigger initialization

* docs(triggers): point Linq guidance at the builder module

* fix(plan): preserve fork scope and benchmark redaction boundaries

* fix(plan): retry retained completions and guard benchmark drafts

* fix(computer): stop completion delivery at identity reset

---------

Co-authored-by: Vikhyath Mondreti <vikhyath@simstudio.ai>
2026-10-13 16:24:27 -07:00