Playwright MCP burned 231k tokens, so this dev built a background macOS browser MCP in Swift

lifan-builds · reddit · 2026-11-26

Indie developer lifan-builds open-sourced fmu (faster-mac-use), a background macOS + Chrome automation MCP tool built in Swift + Python + a small MV3 Chrome extension. Motivation: @playwright/mcp burned 231,125 cumulative input tokens on a 10-step benchmark (every click dumps a full ARIA tree), while screenshot-based computer use hijacked mouse focus and clobbered NSPasteboard.

Architecture: Everything runs in the background behind one 268-token cua MCP tool — unfocused Chrome tabs run in a dedicated "🤖 Agent" tab group over a loopback MV3 WebSocket bridge (avoiding Chrome 144's DevToolsActivePort remote-debugging modal); native macOS apps go through a persistent Swift AXObserver Unix-socket daemon with sub-millisecond dirty-subtree diffs and local Apple Silicon Vision.framework OCR.

Performance: Follow-up turns return compact @u1..@uN UIDs and +//- CRC-32 diffs with chained single-trip batches. The same 10-step SaaS flow uses 1,290–2,024 tokens (vs. Playwright's 231k); 3 agents can drive separate background tabs in parallel with 0.0 px cursor drift (1,510 tokens over 25 ops).

Usage: one command on macOS: uvx --from faster-mac-use fmu mcp. Limitations: the native AXObserver/OCR daemon is macOS-only (Accessibility permission required); driving an existing logged-in Chrome window needs the bundled MV3 extension, otherwise it falls back to headless Chromium. Repo ships a reproducible benchmark harness.

Original post →

More from coding & agent

coding & agent channel →