AD SPACE AVAILABLE · BRAND PARTNERS WELCOME

How to Configure Raycast AI with Ollama for Offline Local Models on macOS

365Finds Editorial
Indexed 11,430 Wiki articles

Put 365 Wiki to work with your AI

Copy the prompt below, paste it into the AI you already use, then ask your question.

Download full Skill

Try it with the prompt first. If you use 365 Wiki often, install the full 365Wiki Skill so you do not have to paste it again. No regular AI? Gemini or Microsoft Copilot on the web will work.

365Wiki Skill

For software engineers working under strict data governance, corporate intellectual property mandates, or non-disclosure agreements, uploading proprietary source code to cloud-hosted language models (such as OpenAI GPT-4o or Anthropic Claude 3.5 Sonnet) is often strictly prohibited. Yet losing keyboard-driven desktop AI shortcuts can significantly reduce development velocity.

Running open-weight models locally on macOS through Ollama and linking them directly into Raycast AI provides a zero-leakage workflow. Raycast acts as the system-wide keyboard interface across Quick AI, AI Chat, and Custom AI Commands, while Ollama executes inference entirely on your Mac's Apple Silicon unified memory without sending any prompt text or code diffs over the internet.


Architecture: Zero Cloud Data Transmission

Understanding the data boundary is critical for corporate compliance:


Hardware Sizing & Recommended Coding Models

Because local inference relies on your Mac's Unified Memory Architecture (UMA), selecting models appropriate for your hardware profile ensures smooth multitasking alongside IDEs like Xcode, VS Code, and local Docker containers.

Unified RAMRecommended ModelsQuantizationUse Cases & Strengths
16 GBqwen2.5-coder:7b; llama3.1:8b; mistral:7bQ4_K_M (~4.7 GB - 5.2 GB footprint)Fast inline code explanation, regex generation, docstrings, commit messages; minimal memory contention.
32 GB - 36 GBqwen2.5-coder:14b; deepseek-coder-v2:16b; gemma2:9bQ4_K_M / Q5_K_M (~9 GB - 11 GB footprint)High-accuracy syntax refactoring, multi-file unit tests, architectural reasoning, complex bash scripting.
64 GB - 128 GB+qwen2.5-coder:32b; llama3.3:70b (on 64GB+ Q4); codellama:34bQ4_K_M / Q8_0 (~20 GB - 42 GB footprint)Deep code auditing, vulnerability checks, near-frontier logic synthesis, complex algorithm design.

Context Window Note: Raycast caps local model context at 64k tokens to protect system memory and ensure stable streaming performance on macOS.


Step-by-Step Setup Guide

Step 1: Install Ollama and Pull Local Models

You can install Ollama on macOS through Homebrew or the official standalone app:

# Option A: Install via Homebrew
brew install --cask ollama

# Option B: Or download the DMG from ollama.com and drag to /Applications

Launch the Ollama application once to ensure the menu bar agent and system binary links are established.

Next, open your macOS Terminal and pull your chosen programming models:

# Pull premier coding models
ollama pull qwen2.5-coder:7b
ollama pull llama3.1:8b

# Verify installed models
ollama list

You can test that the model responds locally:

ollama run qwen2.5-coder:7b "Write a Python function to compute moving averages."

Step 2: Configure Local Models in Raycast

Raycast provides first-party integration for Ollama models within its native AI engine (available on Raycast Pro):

  1. Press ⌥ Space (or your Raycast hotkey) to open Raycast.
  2. Press ⌘ , to open Raycast Settings.
  3. Select the AI tab from the top navigation bar.
  4. Go to Models & Providers and scroll down to the Local Models section.
  5. Raycast will automatically detect your local Ollama installation. If your pulled models do not immediately appear, click Sync Models.
  6. You can also download new models directly inside Raycast: enter the model tag (for example, qwen2.5-coder:7b) in the Install Ollama Model field and click Install.

Note: Raycast launches the local Ollama background server on demand when you trigger a local query, so you do not need to manually keep terminal windows open.

Step 3: Remote Ollama Host (Optional for Team Servers)

If your team runs an on-premise Mac Studio or Linux GPU server located inside your corporate LAN or private VPN:

  1. Leave the server running Ollama configured to bind its IP address (OLLAMA_HOST=0.0.0.0:11434).
  2. In Raycast Settings → AI → Models & Providers → Local Models, find the Ollama Host field.
  3. Enter your private internal endpoint, such as http://192.168.1.50:11434.
  4. Click Sync Models. Requests will route to your private internal server without traversing the public internet.

Privacy Hardening: Compliance Settings Checklist

To guarantee that confidential company data cannot leave your Mac under any circumstances, audit these specific Raycast settings:

  1. Disable AI Cloud Sync:
    • Navigate to Raycast Settings → Cloud Sync.
    • If enabled, Raycast encrypts and syncs AI Chat transcripts across devices. If your enterprise security compliance strictly bans cloud storage of raw chat history, disable AI Cloud Sync or regularly clear your chat logs.
  2. Review AI Personalization & Memory:
    • In Settings → AI → Personalization, review the Memory feature.
    • When global AI Memory is active, background summaries of conversational history may occasionally use Raycast-hosted models for background extraction. For strict air-gapped security, turn off Memory.
  3. Avoid Cloud-Only Tools:
    • Server-hosted utilities such as AI image generation require a cloud model round-trip and use AI credits. Keep your local workflows focused on text and code generation.
  4. Decline Diagnostic Feedback Submissions:
    • Never use "Send Feedback" on chat threads that contain confidential code, as feedback submissions transmit the active prompt context to Raycast support for debugging.

Essential Developer Shortcuts and Custom AI Commands

Once configured, local models can be embedded directly into macOS development workflows.

1. Dedicated Coding Assistant in AI Chat

Open AI Chat in Raycast (⌘ ⌥ Space or your configured hotkey). In the bottom model picker or by typing /model, select your local model (e.g., Local: qwen2.5-coder:7b).

You can now paste proprietary code, database schemas, and stack traces with full confidence that inference occurs entirely within your Mac's RAM.

2. Custom AI Commands for Codebases

Go to Raycast Settings → Extensions → AI → AI Commands and click Create AI Command. You can bind each command directly to your local model:


Alternative for Raycast Free Users: Community Extensions

Native integration under Raycast's Local Models tab is a Raycast Pro feature. If you use the free version of Raycast, you can still access local Ollama models via community extensions from the Raycast Store:

  1. Search for Ollama AI in the Raycast Store.
  2. Install the extension and configure the host URL to http://localhost:11434.
  3. Use commands like Ollama Chat, Ask Ollama, or text transformation actions. While this operates through an extension view rather than the native system-wide Quick AI popup, it retains identical zero-leakage local offline privacy.

Troubleshooting Local Models in Raycast


References