# Agent

> Mac Agent for macOS 26: the agentic AI harness for your Mac Desktop. Computer use, automation, scripting, coding, and more. Powered by 18+ providers across local and cloud LLMs.

- **Type:** MCP server
- **Install:** `agentstack add mcp-agentiloop-agent`
- **Verified:** Pending review
- **Seller:** [AgentiLoop](https://agentstack.voostack.com/s/agentiloop)
- **Installs:** 0
- **Category:** [AI & ML](https://agentstack.voostack.com/c/ai-and-ml)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [AgentiLoop](https://github.com/AgentiLoop)
- **Source:** https://github.com/AgentiLoop/Agent
- **Website:** https://agentiloop.ai

## Install

```sh
agentstack add mcp-agentiloop-agent
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# 🦾 AgentiLoop Agent! designed for macOS 26.4.1 or later

## **Agentic AI for your  Mac Desktop**

[](https://github.com/AgentiLoop/Agent/releases/latest)
[](https://github.com/AgentiLoop/Agent/stargazers)
[](https://github.com/AgentiLoop/Agent/fork)
[](https://github.com/apple)
[](https://www.swift.org)

## README Translations

- [English](README.md)
- [Español](README_es.md)
- [Français](README_fr.md)
- [Deutsch](README_de.md)
- [中文 (简体)](README_zh.md)

## Chess within Agent

## Backstory and the Tech behind Agent!
Agent! didn't come together overnight. It's the result of three years of building agentic AI apps, drawing on roughly a dozen projects developed along the way. Some of those were published under ANIE, Game Changer, BattleScript, XCF MCP Server and Client, D1F, and about eight original Swift Packages. The missing piece was achieving an intelligent autonomous time loop. Once achieved, I brought in the best of the best from the previous three years. The result is Agent! for macOS 26.4.1 or later.

The original goal was to build a Cursor killer. What emerged is something more interesting: an agentic AI with real legs. Agent! is only limited by your imagination. It can write code including video games like Boss-Man, https://github.com/AgentiLoop/bossman, create apps, write poetry via AppleScript within Pages, generate disk images, and attach them to GitHub releases. It can automate most tasks on your Mac. Ask it what you want in plain English or your native language and, after some initial configuration and user approvals, it will do everything it can to carry out your wish. Agent! is relentless, and aims to please.

All of Agent!'s IP is original and open source. Every Swift package dependency and the app itself were originally authored by the same person. This is a genuinely different ecosystem. Most agentic AI apps like Claude Code rely on 65 NPM packages from third parties. Agent! is 100% native, requires very little RAM, and weighs in at 35.5 uncompressed. That footprint includes Xcode automation, a Swift Syntax 6.2 package for troubleshooting native apps, Accessibility, AppleScript, AgentScript/ScriptingBridge, Safari automation, MCP Server support, and more. Out of the box.

## What's New 🚀

**v1.0.92 (186) — The Self-Verifying Autonomy Release** · [Full release notes →](https://github.com/AgentiLoop/Agent/releases/tag/v1.0.92.186)

Agent! now proves its work. A task can't declare itself done until its success criteria are verified with evidence (`goal_state`), an opt-in critic reviews the diff before completion, and every file touched can be rolled back in one shot (`rewind_task`). Extended thinking for Claude, `reasoning_effort` for OpenAI-compatible providers, and a prompt-cache-stable context that compacts to each model's real window — recoverably, with full tool results spilled to disk. Typed tool errors carry recovery hints, sub-agents run their own models (up to 6 read-only researchers), event hooks are fully wired, and 57 passing tests keep it honest.

**One app. Any AI. Total command over your Mac.**

Agent! wires **18 LLM providers** — Claude, GPT, Gemini, Grok, Mistral, DeepSeek, Qwen, Z.ai, BigModel, Hugging Face, **OpenRouter**, Ollama (cloud and local), vLLM, LM Studio, Codestral, Mistral Vibe, and on-device **Apple Intelligence** — into a native macOS app that doesn't just talk about doing things. It does them.

Watch it read your codebase, fix the bug, build the Xcode project, and commit the diff while you make coffee. Tell it to open Safari and text you the price of flights to Tokyo. Say *"Agent!"* from across the room and have it run your test suite by voice. Text your Mac from iMessage and get a polished answer before you reach your car.

It edits files with surgical string-replace diffs — every change one-click undoable from a Time-Machine-style rollback. It drives any Mac app through the Accessibility API — no AppleScript required. It remembers your preferences across sessions. It spawns parallel sub-agents for work that fans out. It indexes entire codebases into a portable JSONL repo-map that any LLM can consume. It runs shell commands as you, or as root via a Launch Daemon you approve exactly once.

Bring your own API key. Run it fully local on Ollama, vLLM, or LM Studio. Or run it free, forever, on Apple Intelligence. No subscription. No telemetry. No vendor lock-in. Your keys, your machine, your data.

Download it. Say what you need. Watch it happen.

## Quick Start (Download)

1. **Download** [Agent!](https://github.com/AgentiLoop/Agent/releases/latest) and drag to Applications
2. **Open Agent!** -- it sets up everything automatically
3. **Pick your AI** -- Settings → choose a provider → enter API key

## Quick Start (Build from Source)

1. **Clone the repository:**
   ```bash
   git clone https://github.com/AgentiLoop/agent.git
   cd Agent
   ```

#### Option A: Build with Xcode (Apple Developer account)
2. **Open `Agent.xcodeproj` in Xcode.**
3. **Build and Run the `Agent` target.**
4. **Approve the Helper Tool:** When prompted, authorize the privileged daemon to allow root-level command execution.

#### Option B: Build without an Apple Developer account
2. **Run the build script** (requires only Xcode Command Line Tools):
   ```bash
   ./build.sh              # Debug build
   ./build.sh Release      # Release build
   ```
3. The app lands in `build/DerivedData/Build/Products/Debug/Agent!.app`
4. **Run it:** `open "build/DerivedData/Build/Products/Debug/Agent!.app"`

> ⚠️ Without a developer account the app is ad-hoc signed. The Launch Agent/Daemon helpers won't register (SMAppService needs a team ID), but the LLM loop, all tools, accessibility, AppleScript, shell, and MCP all work.

#### Then:
5. **Configure your AI Provider:** Go to Settings and enter your API key or select a local provider like Ollama.

> 💡 **Cheap GLM setup:** **GLM-5.1** runs on all four cheap providers — **Ollama**, **Hugging Face**, **Z.ai**, **BigModel** — at pennies per million tokens. New here? Start with **Z.ai** (fastest signup, GLM-5.1 is the default, nothing to provision). Running locally? Only **GLM-4.7-Turbo** (32B) fits on consumer hardware (M2/M3/M4 Mac, 64-128GB, via Ollama) — GLM-5 and GLM-5.1 are too large (~1.6TB), use them via the cloud providers above.

### Troubleshooting (Build from Source)

First-time builders of Option B hit a few predictable snags:

- **`xcode-select` points at the Command Line Tools, not full Xcode.** `./build.sh` calls `xcodebuild`; if `xcode-select -p` prints `/Library/Developer/CommandLineTools`, `xcodebuild` can fail to resolve the project. Point it at a full Xcode: `sudo xcode-select -s /Applications/Xcode.app/Contents/Developer` (then `xcodebuild -version` to confirm).

- **`BUILD FAILED` after pulling new changes (stale DerivedData).** The build caches under `build/DerivedData`. When a stale cache causes odd, unrelated errors, wipe it and rebuild: `./build.sh clean && ./build.sh`.

- **The Launch Agent / Daemon helpers never register.** Expected on Option B — the script builds ad-hoc signed (`CODE_SIGN_IDENTITY="-"`, empty `DEVELOPMENT_TEAM`), and `SMAppService` needs a valid Team ID to register the helpers. The LLM loop, all tools, Accessibility, AppleScript, shell, and MCP still work. To get the helpers, use **Option A** (open `Agent.xcodeproj` in Xcode, set your own Development Team, Build & Run, and approve the helper when prompted).

- **macOS / Swift version mismatch.** Agent! targets macOS 26. If `xcodebuild` reports an unsupported deployment target or missing SDK, update to the required macOS and the matching Xcode before rebuilding.

- **Wrong build configuration.** The config argument is case-sensitive as the script uses it — `./build.sh` (Debug) or `./build.sh Release`. The app lands in `build/DerivedData/Build/Products//Agent!.app`.

## What Can It Do?

> *"Play my Workout playlist in Music"*
> *"Build the Xcode project and fix any errors"*
> *"Take a photo with Photo Booth"*
> *"Send an iMessage to Mom saying I'll be home at 6"*
> *"Open Safari and search for flights to Tokyo"*
> *"Refactor this class into smaller files"*
> *"What calendar events do I have today?"*

Just type what you want. Agent! figures out how and makes it happen.

---

## Key Features

### 🧠 Agentic AI Framework
Built-in autonomous task loop that reasons, executes, and self-corrects. Agent! doesn't just run code; it observes the results, debugs errors, and iterates until the task is complete. Goal state with evidence-verified success criteria means a task can't declare itself done until it proves it.

### 🛠 Agentic Coding
Full coding environment built in. Reads codebases, edits files with precision, runs shell commands, builds Xcode projects, manages git, and auto-enables coding mode to focus the AI on development tools. Replaces Claude Code, Cursor, and Cline -- no terminal, no IDE plugins, no monthly fee. Features **Time Machine-style backups** for every file change, letting you revert any edit instantly.

### 🔍 Dynamic Tool Discovery
Automatically detects and uses available tools (Xcode, Playwright, Shell, etc.) based on your prompt. No manual configuration required for core tools.

### 🛡 Privileged Execution
Securely runs root-level commands via a dedicated macOS Launch Daemon. The user approves the daemon once, then the agent can execute commands autonomously via XPC.

#### Why there's no manual `setCodeSigningRequirement` on the XPC listener

Users sometimes ask why `AgentHelper`'s XPC listener accepts connections without a manual `connection.setCodeSigningRequirement(...)` check. The short answer: **SMAppService already enforces signing identity one layer below your code**, so the check would be redundant.

That recommendation is a holdover from the pre-SMAppService **SMJobBless era**, where launchd did not validate identity for you and the XPC server had to set a designated-requirement string itself. SMAppService changed that contract:

- The app-bundle-embedded plist plus signature-gated registration **is** the code-signing requirement.
- The Mach service names (`Agent.app.redacted.helper`, `Agent.app.redacted.user`) are namespaced to the signed bundle that registered them — no other bundle can claim them.
- Any signature mismatch (tampering, re-signing, different Team ID, bundle swap) **breaks the XPC channel at the launchd layer** — `listener(_:shouldAcceptNewConnection:)` is never even invoked.

**Empirical proof:** Agent! itself attempted to re-sign its own daemons during an experiment and immediately lost the ability to connect. `NSXPCConnection` to both Mach services failed at the launchd layer before a single byte reached the listener delegate — exactly the behavior a manual `setCodeSigningRequirement` call would enforce, except SMAppService is doing it in the kernel's XPC lookup path where it cannot be bypassed from userland.

| Enforcement | Mechanism | Bypassable from userland? |
|---|---|---|
| Helper must be in signed app bundle | Gatekeeper + SMAppService registration | No |
| Helper must match app's Team ID (469UCUB275) | Code signing + SMAppService | No |
| Mach service name bound to signed bundle | launchd / XPC namespace | No |
| Helper binary hash matches registered identity | SMAppService + kernel XPC lookup | No (re-signing breaks the channel) |
| User approved the helper | System Settings → Login Items & Extensions | No (user gesture required) |

Adding `setCodeSigningRequirement` explicitly would be reasonable belt-and-braces defense-in-depth (useful only if the app were ever ported off SMAppService, or if SIP were disabled), but it is **not a gap** in the current architecture. See [docs/SECURITY.md](docs/SECURITY.md) for the full trust-anchor write-up.

### 🖥 Desktop Automation (AXorcist)
Control any Mac app through the Accessibility API. Click buttons, type into fields, navigate menus, scroll, drag -- all programmatically. Powered by [AXorcist](https://github.com/steipete/AXorcist) for reliable, fuzzy-matched element finding.

### 🤖 18 AI Providers

The provider picker (LLM Settings, toolbar button #7) shows 17 providers; Apple Intelligence is reached via the separate brain icon (#8). Source of truth: `AgentTools.APIProvider`.

| Provider | API key | Best for |
|---|---|---|
| **Claude** (Anthropic) | Paid | Long autonomous tasks, complex reasoning, prompt caching |
| **OpenAI** | Paid | General purpose, tool calling, vision |
| **Google Gemini** | Paid (free tier) | Long context, vision, fast |
| **Grok** (xAI) | Paid | Real-time info |
| **Mistral** | Paid | Open-weight cloud, fast tool calling |
| **Codestral** (Mistral) | Paid | Code-specialized Mistral |
| **Mistral Vibe** | Paid | Mistral's chat/agent product |
| **DeepSeek** | Cheap | Budget cloud, strong coding, prompt cache hit reporting |
| **Hugging Face** | Varies | Open-source models hosted serverless or on dedicated endpoints |
| **OpenRouter** | Paid | 200+ models through one API key — Claude, GPT, Gemini, Llama, Mistral, and more. Smart protocol toggle routes Claude models via Anthropic protocol, everything else via OpenAI |
| **Z.ai** | Cheap | GLM-5.1 via API — recommended starting point |
| **BigModel** (Zhipu) | Cheap | GLM family via Zhipu's API |
| **Qwen** (Alibaba) | Cheap | Qwen 2.5 / 3 via Dashscope |
| **Ollama** (cloud) | Free tier | Run open models via Ollama's hosted endpoint |
| **Local Ollama** | Free + hardware | Self-hosted Ollama daemon — fully offline, no account |
| **vLLM** | Free + hardware | Self-hosted vLLM server with prefix caching |
| **LM Studio** | Free + hardware | Self-hosted, easiest GUI for local models |
| **Apple Intelligence** | Free, on-device | Triage, summary, token compression (via brain icon, not the provider picker) |

> 💡 **Self-hosted "free" providers (Local Ollama, vLLM, LM Studio) are only free in the API-fee sense.** Running a 30B+ model with usable speed needs an M2/M3/M4 Ultra Mac Studio (64-128GB unified memory) or a Linux box with 24GB+ VRAM. If you don't already have that hardware, the cloud paths above (Ollama Cloud, Hugging Face, Z.ai, BigModel, DeepSeek) are dramatically cheaper than buying it.

## Toolbar Buttons

The Agent! header contains **15 buttons** for quick access to settings, monitors, and tools. Each button opens a popover when clicked. Source of truth: `Agent/Views/HeaderSectionView.swift`.

| # | Icon | Name | What it does |
|---|------|------|--------------|
| 1 | ⚙️ | **Services** | Toggle the Launch Agent / Launch Daemon, manage project folder, scan command output |
| 2 | 💬 | **Messages Monitor** | Toggle iMessage monitoring on/off — green when active. Opens the recipients list and approval UI |
| 3 | ✋ | **Accessibility** | Open the Accessibility settings sheet (permission status, axorcist diagnostics) |
| 4 | 🖥️ | **MCP Servers** | Add/remove/configure MCP (Model Context Protocol) servers — extends Agent! with `mcp_*` tools |
| 5 |  | **Coding Preferences** | Toggle auto-verify, visual tests, auto-PR, auto-scaffold. Green when any are on |
| 6 | 🔧 | **Tools** | Per-provider tool toggles. Enable/disable individual built-in and MCP tools |
| 7 | 🧠 | **LLM Settings** | Pick AI provider, model, API key, base URL. Pulses when a task is running |
| 8 | 🧬 | **Apple Intelligence** | Configure FoundationModels (on-device Apple AI). Filled when available |
| 9 | 🎛️ | **Agent Options** | Temperature, max iterations, vision auto-screenshot, plan-mode encouragement, etc. |
| 10 | 🔄 | **Fallback Chain** | Configure provider fallback order — Agent! retries with the next provider when one fails |
| 11 | 🔲 | **HUD** | Toggle the green-CRT scanline overlay on the LLM Output view |
| 12 | 📊 | **LLM Usage** | Per-model token usage and cost tracking. Green when there's recorded usage |
| 13 | ↩️ | **Rollback** | Time-Machine-style file backup browser. Restore any previous version of any file Agent! edited |
| 14 | 🕐 | **History** | Past prompts, errors, and task summaries for

…

## Source & license

This open-source MCP server is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [AgentiLoop](https://github.com/AgentiLoop)
- **Source:** [AgentiLoop/Agent](https://github.com/AgentiLoop/Agent)
- **License:** MIT
- **Homepage:** https://agentiloop.ai

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: flagged — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/mcp-agentiloop-agent
- Seller: https://agentstack.voostack.com/s/agentiloop
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
