# mac-pilot: Zero-Dependency macOS Automation for AI Agents [![GitHub stars](https://img.shields.io/github/stars/shxmi03/mac-pilot?style=social)](https://github.com/shxmi03/mac-pilot) > **Tired of Anthropic's Docker container melting your MacBook?** This is the solution. ## The Problem - Anthropic's Computer Use requires full Docker container + VNC server - **Constant 100% CPU** on Intel MacBooks - Heavy dependencies (pip installs, Xcode, etc.) - Battery drain in < 1 hour ## The Solution - **Zero dependencies** - uses only Python stdlib + native macOS APIs - **One-shot commands** - no background polling, 0% idle CPU - **Native speed** - Quartz CoreGraphics + AppleScript ## Quick Start ```bash # Zero-dependency install (no pip, no Docker, no Xcode) bash install.sh # AI agents can now call: mac-pilot click 100 200 # Click at coordinates mac-pilot move 500 300 # Move mouse mac-pilot type "Hello World" # Type anywhere mac-pilot screenshot /tmp/s.png # Silent screenshot ``` Ili preko pip-a (za developere): `pip install .` Prvi put daj Accessibility dozvolu (System Settings → Privacy & Security → Accessibility → dodaj Terminal) — inače `click`/`type` šutke ne rade. ## Architecture ``` AI Agent → mac-pilot.py → Quartz CoreGraphics / screencapture / osascript ↓ One-shot execution, exits cleanly ``` ## MCP Integration Faza 2 gotova: `mac_pilot_mcp.py` je zero-dependency MCP server (stdlib JSON-RPC preko stdio-a). Dodaj ga u Claude Desktop / Cursor / Windsurf: **Claude Desktop** (`~/Library/Application Support/Claude/claude_desktop_config.json`): ```json { "mcpServers": { "mac-pilot": { "command": "python3", "args": ["/Users/shxmi/Projects/mac_pilot/mac_pilot_mcp.py"] } } } ``` Nakon `pip install` (Faza 3) može i kraće: `"command": "mac-pilot-mcp"`. Dostupni alati: `pos`, `move`, `click`, `rclick`, `type`, `screenshot` (vraća sliku). ## Roadmap - [x] Core engine (click, move, type, screenshot) - [x] MCP server wrapper - [x] pip install package + install.sh - [x] Linux/Windows cross-platform (implemented; macOS tested, L/W untested) > Linux koristi X11+XTest, Windows koristi user32 — oba preko čistog ctypes, > bez ovisnosti. Implementirano, ali netestirano na ovom stroju (razvijeno na macOS). ## License MIT