Mac Computer Use
To3akaRin/mac-computer-use
操作 macOS 桌面应用,探测窗口和自动化接口、截图、读取或修改辅助功能元素、执行鼠标键盘动作,以及通过 CDP 操作内嵌 Chromium 页面。适用于桌面应用自动化与界面验收;普通网页任务优先使用已有浏览器工具。
Guides an agent to operate native macOS apps by surveying an app first, acting through intents, menus or keystrokes, and verifying each step, in OpenLoaf Desktop only.
$ npx skills add OpenLoaf/OpenLoaf --skill macos-control-skill -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install OpenLoaf/OpenLoaf macos-control-skill --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/OpenLoaf/OpenLoaf.git skills-src && mkdir -p .claude/skills && cp -r skills-src/apps/server/src/ai/builtin-skills/macos-control/en .claude/skills/macos-control-skill && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "macos-control-skill" agent skill from https://github.com/OpenLoaf/OpenLoaf/tree/main/apps/server/src/ai/builtin-skills/macos-control/en into .claude/skills/macos-control-skill/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "macos-control-skill", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/OpenLoaf/OpenLoaf/tree/main/apps/server/src/ai/builtin-skills/macos-control/enType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add OpenLoaf/OpenLoaf --skill macos-control-skill -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install OpenLoaf/OpenLoaf macos-control-skill --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/OpenLoaf/OpenLoaf.git skills-src && mkdir -p .agents/skills && cp -r skills-src/apps/server/src/ai/builtin-skills/macos-control/en .agents/skills/macos-control-skill && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "macos-control-skill" agent skill from https://github.com/OpenLoaf/OpenLoaf/tree/main/apps/server/src/ai/builtin-skills/macos-control/en into .agents/skills/macos-control-skill/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "macos-control-skill", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add OpenLoaf/OpenLoaf --skill macos-control-skill -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install OpenLoaf/OpenLoaf macos-control-skill --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/OpenLoaf/OpenLoaf.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/apps/server/src/ai/builtin-skills/macos-control/en .cursor/skills/macos-control-skill && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "macos-control-skill" agent skill from https://github.com/OpenLoaf/OpenLoaf/tree/main/apps/server/src/ai/builtin-skills/macos-control/en into .cursor/skills/macos-control-skill/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "macos-control-skill", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/OpenLoaf/OpenLoaf.git --path apps/server/src/ai/builtin-skills/macos-control/en--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add OpenLoaf/OpenLoaf --skill macos-control-skill -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install OpenLoaf/OpenLoaf macos-control-skill --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/OpenLoaf/OpenLoaf.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/apps/server/src/ai/builtin-skills/macos-control/en .gemini/skills/macos-control-skill && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "macos-control-skill" agent skill from https://github.com/OpenLoaf/OpenLoaf/tree/main/apps/server/src/ai/builtin-skills/macos-control/en into .gemini/skills/macos-control-skill/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "macos-control-skill", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install OpenLoaf/OpenLoaf macos-control-skillInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add OpenLoaf/OpenLoaf --skill macos-control-skill -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/OpenLoaf/OpenLoaf.git skills-src && mkdir -p .github/skills && cp -r skills-src/apps/server/src/ai/builtin-skills/macos-control/en .github/skills/macos-control-skill && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "macos-control-skill" agent skill from https://github.com/OpenLoaf/OpenLoaf/tree/main/apps/server/src/ai/builtin-skills/macos-control/en into .github/skills/macos-control-skill/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "macos-control-skill", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add OpenLoaf/OpenLoaf --skill macos-control-skill -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install OpenLoaf/OpenLoaf macos-control-skill --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/OpenLoaf/OpenLoaf.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/apps/server/src/ai/builtin-skills/macos-control/en .opencode/skills/macos-control-skill && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "macos-control-skill" agent skill from https://github.com/OpenLoaf/OpenLoaf/tree/main/apps/server/src/ai/builtin-skills/macos-control/en into .opencode/skills/macos-control-skill/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "macos-control-skill", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
macos-control-skillGuides an agent to operate native macOS apps by surveying an app first, acting through intents, menus or keystrokes, and verifying each step, in OpenLoaf Desktop only.
The core rule is to understand an app before acting on it. The agent calls MacosSurvey for each new app to get a model of its known intents, accessibility tree richness, menu bar and windows, picks a path from the recommended order, then acts with MacosAct and confirms the result with MacosObserve. Skipping the survey is named as the most common failure, especially for self-drawn apps such as WeChat, QQ, Feishu, DingTalk and Teams, where a guessed click can land on the close button.
MacosListWindows and MacosCaptureWindow handle lighter window listing and per-window screenshots, and MacosAct supports intents, launching apps, menu clicks, AppleScript, keys, clicks, typing, scrolling, dragging, waiting and accessibility actions. Recommended paths run from known intents to menu navigation and keyboard shortcuts. The tools exist only in OpenLoaf Desktop on macOS; elsewhere the skill says to fall back to BrowserAct or hand the task back.
4 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit f7eccf6. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md.
From the folder's file list and the shell code blocks in SKILL.md.
Hosts in commands or code, which the agent is likely to contact:
github.comFrom URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
macOS Desktop Control loads about 2.4k tokens when it runs. Until then it costs about 144 tokens; SKILL.md has 868 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from OpenLoaf/OpenLoaf at commit f7eccf6, republished under its AGPL-3.0 licence (© OpenLoaf). 868 words, ~2,430 tokens.
.claude/skills/macos-control-skill/SKILL.md (or your agent's skills folder).Do not see an app and immediately click. When a human opens an unfamiliar app they look around first — they notice which region is business UI, where the close button is, what entry points exist. You have to do the same.
Three-phase framework:
1. Survey → MacosSurvey(app) — get a mental model of the app
2. Plan → pick a path from the "Recommended path order" the survey gives you
3. Act+Verify → MacosAct executes; MacosObserve confirms the resultSkipping Survey and going straight to Act is the single most common failure mode. WeChat / QQ / Feishu / DingTalk / Teams are self-drawn — their AX tree exposes only 3 window chrome buttons (close / min / zoom). A model that guesses path=["0","0"] lands on the red close button and kills the window. Survey will tell you in advance when you're in that trap.
| Tool | When |
|---|---|
MacosSurvey(app) | First call for every new app in a session. Returns the mental model: known intents, AX richness, menu bar map, window list, recommended path order. Cached per session × app for 5 minutes. |
MacosObserve(appFilter?) | Look at the current UI state — screenshot + AX tree + window list. Use after Survey and after every MacosAct to verify the result. |
MacosAct | Execute an action. Supports intent / launch_app / menu_click / applescript / key / click / type / scroll / drag / wait / ax_action. |
MacosListWindows(appFilter?) | Lighter than Observe — just enumerate windows. Useful when you need a specific window in a multi-window app. |
MacosCaptureWindow(windowID) | Screenshot a specific window by id; covered / off-screen / minimized windows still capture (Window Server keeps the composition buffer). |
All tools are desktop-only. They aren't registered off-macOS; don't try to call them.
MacosSurvey's response contains a Recommended path order section, highest confidence first:
1. Known intents MacosAct type="intent" 100% confidence
2. Menu navigation MacosAct type="menu_click" works on self-drawn apps too
3. Keyboard shortcut MacosAct type="key" read the shortcut from the menu tree
4. AX path click MacosAct type="click" ref=... only when Survey verdict is ax-rich
5. Coord click MacosAct type="click" point=... last resort, read pixels off a screenshotGo down the list in order. Never skip ahead. On apps classified self-drawn, step 4 is off-limits — AX path clicks on window chrome buttons are refused (you'll get WINDOW_CHROME_BLOCKED).
App: 微信 (WeChat.app) (com.tencent.xinWeChat, pid=86795)
AX profile: self-drawn — AXWindow children are only chrome buttons
richness: 0.995 (203 nodes)
windowChildRoles: [AXCloseButton, AXFullScreenButton, AXMinimizeButton]
Known intents (from registry):
- id: open_moments — Open Moments feed
- id: open_chats — Switch to chats tab
- id: open_discover — Open Discover tab
...
Menu bar (34 entries with shortcuts, sample):
- File > Lock WeChat (⌘L)
- View > Chats (⌘1)
- View > Moments (⌘⇧4)
...
Windows (2):
- windowID=227474 visible 1060×859 "Weixin" (main)
- windowID=260481 hidden 710×831
Recommended path order:
1. Known intents (highest confidence): MacosAct type="intent" — 5 registered
2. Menu navigation: MacosAct type="menu_click" — 34 reachable entries
3. Keyboard shortcut: MacosAct type="key"
4. AX path click: **DO NOT USE** on this app.
5. Coordinate click: last resort."Known intents" are paths that have been vetted for you. Use them first.
1. MacosAct { type: "launch_app", app: "WeChat" }
2. MacosSurvey { app: "WeChat" }
→ sees Known intents contains open_moments
3. MacosAct { type: "intent", app: "WeChat", intent: "open_moments" }
4. MacosObserve { appFilter: "WeChat" } — verify Moments is showingDo NOT observe + click AX tree right after launch_app. That's the old path, and it lands on the close button.
1. MacosSurvey { app: "Safari" }
→ Known intents has open_url (requires url arg)
2. MacosAct { type: "intent", app: "Safari", intent: "open_url", args: { url: "https://github.com" } }
3. MacosObserve { appFilter: "Safari" } — verify the page loadsUser asks "what's on my screen / what's in this app": one MacosObserve call — use the screenshot + AX tree to answer. No Survey, no Act needed.
Survey returns ax-rich but no matching intent. Prefer menu_click or key, then AX path click:
1. MacosSurvey { app: "Finder" } → ax-rich; recommends menu_click / AX path click
2. Want a new Finder window → menu bar shows "File > New Finder Window (⌘N)"
3. MacosAct { type: "key", keys: ["cmd", "n"] } — shortcut beats click
4. MacosObserve to verify1. MacosSurvey { app: "WeChat" } → Windows: 2 entries, windowIDs 227474/260481
2. MacosCaptureWindow { windowID: 227474 } — capture the main window directly (even if preview covers it)
3. Subsequent MacosAct click coords are now based on that window's image1. MacosObserve { appFilter: "..." } to get the text field ref
2. MacosAct { type: "click", ref: { app, path: [...] } } to focus
3. MacosAct { type: "type", text: "..." }
4. MacosAct { type: "ax_action", ref: { app, path: [submit button] }, action: "AXPress" }
5. MacosObserve to verifyMenu bar section — almost every app's menu bar is menu_click-able(⌘⇧X), MacosAct type="key" is more reliable than clickintent / menu_click, if no further action is needed you can skip the verify.ax-rich apps. mixed = cautious; self-drawn = forbidden — chrome buttons are hard-blocked (WINDOW_CHROME_BLOCKED).BrowserAct or hand back.First call prompts for missing permissions; the server auto-opens the matching System Settings pane. Required:
screen — Screen Recording (Survey / Observe / CaptureWindow all need it)accessibility — Accessibility (AX tree + synthetic input)Some system-level apps need an OpenLoaf Desktop restart after granting.
point.{x,y} refers to pixels on the most recent MacosObserve or MacosCaptureWindow screenshot — read them straight off the image. The tool converts to screen coords automatically; you don't handle retina scale, window offset, or multi-display yourself.
Screenshot: window 2120×1718 px line in observe/capture_window output is the coordinate rangepermissionsMissing → settings pane already opened, prompt user, waitdesktop-only → not running under OpenLoaf Desktop; switch platformsWINDOW_CHROME_BLOCKED → you clicked a chrome button. Pick one of the 4 suggested fallbacks (menu_click / key / coord / URL). Do NOT add confirm_window_chrome:true unless you really do mean to close the window.MacosSurvey to list available intents; otherwise degrade to menu_click.key cmd+tab back first.© OpenLoaf, AGPL-3.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in apps/server/src/ai/builtin-skills/macos-control/en of OpenLoaf/OpenLoaf.
Open the folder on GitHubat commit f7eccf6
macOS Desktop Control next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| macOS Desktop Control this skillOpenLoaf/OpenLoaf | 108 | — | ~2.4k | Automated safety check: Pass | AGPL-3.0 | |
| Mac Computer UseTo3akaRin/mac-computer-use | 1.1k | 1 repos | ~495 | Automated safety check: Pass | MIT | |
| TreeSheets Agent Socketaardappel/treesheets | 3.2k | — | ~5.7k | Automated safety check: Notes | Zlib | |
| Open Computer UseiFurySt/open-codex-computer-use | 2.4k | — | ~1.5k | Automated safety check: Pass | MIT | |
| Interceptor BrowserHacker-Valley-Media/Interceptor | 517 | 1 repos | ~4.8k | Automated safety check: Pass | Custom licence | |
| TuriX macOS Desktop AgentTurixAI/TuriX-CUA | 3.2k | — | ~3.2k | Automated safety check: Warn | MIT |
To3akaRin/mac-computer-use
操作 macOS 桌面应用,探测窗口和自动化接口、截图、读取或修改辅助功能元素、执行鼠标键盘动作,以及通过 CDP 操作内嵌 Chromium 页面。适用于桌面应用自动化与界面验收;普通网页任务优先使用已有浏览器工具。
aardappel/treesheets
Runs Lobster scripts against the document open in a running TreeSheets instance through its local agent socket, and returns the results or errors.
iFurySt/open-codex-computer-use
Platform-neutral guidance for using Open Computer Use, the open-source Computer Use MCP server and CLI for macOS, Linux, and Windows.
Hacker-Valley-Media/Interceptor
Drive a signed-in Chrome / Brave / Safari session via the interceptor CLI: open/read pages, click, type, inspect DOM/text/network, automate rich browser editors and scene graphs, capture…
TurixAI/TuriX-CUA
Controls the macOS desktop visually through the TuriX computer-use agent, for opening apps, clicking buttons and navigating interfaces that have no CLI or API.
drewocarr/generate-shortcuts-skill
Generate macOS/iOS Shortcuts by creating plist files. An agent skill from drewocarr/generate-shortcuts-skill.
OpenLoaf/OpenLoaf
Triggers when the master Agent faces a multi-step complex task and is deciding whether / how to outsource sub-tasks to built-in subagents (browser / doc-editor / data-analyst / extractor /…
OpenLoaf/OpenLoaf
Triggered when the user asks for page-level interaction with a specific webpage: login, form filling, button clicks, pagination scraping, screenshots, downloading page images, handling CAPTCHAs or…
OpenLoaf/OpenLoaf
Triggered when the user wants lifecycle management of OpenLoaf canvases / whiteboards: create, open, filter, duplicate, delete, rename, or change ownership.
OpenLoaf/OpenLoaf
Reads, edits, converts and reviews Word documents through three dedicated tools, covering tracked changes, comments, tables, images and format conversion.
OpenLoaf/OpenLoaf
Handles a real email account through query and mutate tools: check the inbox, read, search, reply, forward, compose and organize, with sending always confirmed first.
OpenLoaf/OpenLoaf
All-in-one PDF read / write / convert / OCR. An agent skill from OpenLoaf/OpenLoaf.
Works with
Categories
Guides an agent to operate native macOS apps by surveying an app first, acting through intents, menus or keystrokes, and verifying each step, in OpenLoaf Desktop only. The core rule is to understand an app before acting on it. The agent calls MacosSurvey for each new app to get a model of its known intents, accessibility tree richness, menu bar and windows, picks a path from the recommended order, then acts with MacosAct and confirms the result with MacosObserve.
macOS Desktop Control fits situations like: opening a native Mac app and clicking through its interface; reading what is currently on the screen; filling in a form inside a native window; automating a repeatable local GUI flow.
Run `npx skills add OpenLoaf/OpenLoaf --skill macos-control-skill -a claude-code`. Or copy the skill folder (apps/server/src/ai/builtin-skills/macos-control/en in OpenLoaf/OpenLoaf) into .claude/skills/macos-control-skill in your project. Claude Code loads it when a task matches its description.
Run `npx skills add OpenLoaf/OpenLoaf --skill macos-control-skill -a codex`. Or copy the skill folder (apps/server/src/ai/builtin-skills/macos-control/en in OpenLoaf/OpenLoaf) into .agents/skills/macos-control-skill in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add OpenLoaf/OpenLoaf --skill macos-control-skill -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/macos-control-skill, .gemini/skills/macos-control-skill, .github/skills/macos-control-skill and .opencode/skills/macos-control-skill in your project.
SKILL.md names no scripts, command-line tools or credentials: macOS Desktop Control is instructions for the agent only. Our summary lists: OpenLoaf Desktop running on macOS.
SKILL.md names 1 domain. In commands or code: github.com; the agent is likely to contact it when it follows the instructions. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
macOS Desktop Control is published under the AGPL-3.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.4k tokens (SKILL.md is roughly 9.7k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with macOS Desktop Control: Mac Computer Use (To3akaRin/mac-computer-use, 1.1k stars), TreeSheets Agent Socket (aardappel/treesheets, 3.2k stars), Open Computer Use (iFurySt/open-codex-computer-use, 2.4k stars) and Interceptor Browser (Hacker-Valley-Media/Interceptor, 517 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
OpenLoaf (a GitHub organization) maintains it in OpenLoaf/OpenLoaf, which has 108 GitHub stars. The repository holds 33 skills in this directory. The repository was last updated on May 14, 2026.
Source: OpenLoaf/OpenLoaf on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.