LocalLM Lab
Your Mac already has an AI engine built in
LocalLM Lab gives you access to it — experiment with it directly in Prompt Playground, or build against it like any AI API with API Lab. Free, private, and running entirely on your Apple Silicon Mac.
Requires macOS 26+ on Apple Silicon with Apple Intelligence enabled.
Why LocalLM Lab matters
Apple's Foundation Models framework runs a real language model directly on your Mac's silicon — no network calls, no cloud costs, no data leaving your machine. Most developers don't realize it's already sitting there, ready to use. LocalLM Lab exists to make that model easy to reach, whether you're experimenting with it directly, building against it or just learning about AI, so you can find out what it can and can't do before committing to it in a real product.
Prompt Playground
Three simple panes: a system prompt, a user input, and the model's output. Write or paste in a system prompt, type or import a user input, and hit Run to see exactly how Apple's on-device model responds — with a stopwatch showing how long it took.
Every run is independent — there's no conversation memory carried between runs — so you can freely vary the system prompt or the input to see how each change shapes the response. Output renders verbatim, including raw JSON, so you can test structured-output prompts too.
The system prompt and user input aren't simply concatenated into one blob of
text — they're sent as distinct roles through Apple's FoundationModels
API. The system prompt becomes a session's instructions; the user
input is the message passed to respond(to:):
LanguageModelSession(instructions: systemPrompt)
.respond(to: userInput)
Every run is appended to a plain-text log at
~/Library/Logs/LocalLM Lab/dev.log — one timestamped chunk per run,
with the model, system prompt, user input, and output each clearly labeled. Open
it in any text editor to review or search past runs; it isn't cleared between
launches.
API Lab
API Lab turns the same on-device model into a local, OpenAI-compatible API — point existing tools and scripts built for the OpenAI API at your own Mac instead of a paid cloud endpoint.
It's a way to learn how to build AI-enabled apps against a real API without needing to hand over a credit card or pay per token just to get started. Because everything runs on your machine, it's also naturally private and free to experiment with — but the real point is giving you a zero-cost way to learn how AI app development actually works.
Turning it on is a toggle away in a simple settings screen, where you'll find the
local address and access token your code needs to connect. Turn on request
logging in that same screen and every incoming call is appended to
~/Library/Logs/LocalLM Lab/api-requests.log — method, path, status,
duration, and the full request/response bodies — handy for confirming your code
is actually reaching it.
Example code for the OpenAI-compatible API here. Examples include a Python-based chatbot UI.
SDK
Building your own native macOS app? LocalLM Lab's SDK gives it a real MCP client wired directly to Apple's on-device model — the first one built for local AI on the Mac. Your app's AI features can discover and call tools on real MCP servers (Slack, Todoist, GitHub, Notion, Linear, and others), including their OAuth flows, without a single prompt or tool result ever leaving the device to reach a cloud provider. That's real privacy, tighter security, and no per-token API bill for the reasoning step itself.
It also gives your app instant Calendar, Reminders, Contacts, and Location access — no
EventKit wrappers to write — and is proven to work inside App Sandbox, with a signed,
verified path to a Mac App Store .pkg. It's not a demo: LocalLM Lab itself
runs on this SDK.
localai-cli
Want to experiment with the local AI programmatically — trying it against different connectors
and MCP servers from a script, without building a real app? localai-cli is a small,
self-contained binary you drive from a script: write a JSON request to its stdin, read a JSON
response from stdout. No server, no HTTP, no app to build — and it's config-aware, so whatever
connectors and MCP tools you've already granted through LocalLM Lab's own settings stay the
ceiling on what a given request can use.
Connectors
Turn on connectors in Local AI Settings to give the model real information from your Mac to answer with — your calendar, reminders, contacts, current location, or the weather — instead of only what it already knows. Every connector is off by default and stays on your Mac except Weather, which is clearly flagged as the one exception that leaves the device. Most connectors are read-only; Calendar and Reminders can also add new events and reminders.
MCP Servers
The Model Context Protocol (MCP) is quickly becoming the standard way AI applications connect to real tools and data — think of it as a USB-C port for AI. Most developers have read about it; few have actually watched the protocol work end to end. LocalLM Lab is built to be that hands-on place.
Connect real, production MCP servers — Slack, Linear, GitHub, Notion, Todoist, and others — directly to your on-device model, and watch the actual exchange happen: capability negotiation, tool discovery, OAuth flows, live tool calls. No sandbox, no toy server, no cost to get started — just the real thing, running against your own Mac.
See which servers have been tested and how to connect them →