Agent guide · current Cline CLI and VS Code · ← All agents

Cline local LLM setup on Mac

Use Cline CLI or VS Code with a local MLX model on your Apple Silicon Mac.

Local setup in 3 steps

# 1. Install
brew install rapid-mlx
npm install -g cline
# 2. Terminal 1: start the model; leave running
rapid-mlx serve qwen3.5-4b-4bit
# 3. Terminal 2: configure and send a request
rapid-mlx agents cline --setup
cline --yolo "say hello"

Wait for the server to be ready before step 3. Setup previews changes to your regular agent settings and asks before writing. A text reply confirms the connection; it does not prove a coding task will succeed. Choose a model that fits your Mac.

In VS Code, select OpenAI Compatible in Cline’s API Configuration, enter http://localhost:8000/v1, model qwen3.5-4b-4bit and key not-needed for an unprotected server.

Where setup writes

The CLI reads ~/.cline/data/settings/providers.json. The openai-compatible provider entry holds baseUrl, apiKey, and model. Setup preserves other providers and backs up an existing file. For a server on another port, add --base-url http://127.0.0.1:18730/v1. For a protected server, export RAPID_MLX_API_KEY first.

CLINE_DATA_DIR changes Cline's data root; CLINE_DIR changes its parent; CLINE_PROVIDER_SETTINGS_PATH overrides the provider file. rapid-mlx launch cline --server-url http://127.0.0.1:18730 is an alternative setup path.

VS Code

If a Cline session already selected another provider, open Cline → Settings → API Configuration. Select OpenAI Compatible, set the Rapid-MLX /v1 URL and served model ID, and use the same API key. The CLI provider file does not force an open editor session to switch models.

Check the connection

rapid-mlx agents cline --test runs wire and CLI checks when the binary is installed. For a tool check, ask Cline to read a local file and verify that its reply contains the file's actual text.

Upstream references

Cline CLI commands · provider settings file

Build on the same local server

Write a script with the OpenAI SDK, compare Claude Code, or inspect the measured Mac inference-server comparison. For tool-use results and model-specific limits, use the integration matrix.