Ollama

Pure local mode

In this mode Glider uses no cloud API key. It sends each request that it fulfils to a model on your machine. The profile is configs/glider.local.yaml.

Read this first. "Pure local" describes what Glider fulfils. It does not put your machine offline. Two paths still reach the network, and each one is under your control. The section below names them.

Start

ollama serve
ollama pull qwen2.5-coder:14b
ollama pull llama3:8b-instruct
.\glider.exe --config configs\glider.local.yaml

Then point your CLI at the gateway:

# Claude Code
set ANTHROPIC_BASE_URL=http://127.0.0.1:8080

# any CLI with a base-URL setting
http://127.0.0.1:8080/v1

This profile does not turn transparent interception on. The default profile does, and this one does not. Therefore a CLI does not reach Glider by itself here. You must point it at the gateway, or add mitm.transparent: true yourself. Refer to what this profile intercepts.

The models that the profile gives

ModelVRAMContextLabelsIn memory
qwen2.5-coder:14b9000 MB32768code, refactor, debugAlways. keep_warm: true.
llama3:8b-instruct5000 MB8192general, docs, explainOn demand.

The strategy for the VRAM keeps headroom_mb: 512 free, and it holds a maximum of 3 models. The coder model stays in memory. Therefore the first request after a pause is not slow.

Three aliases let a CLI ask for a cloud model and receive a local one:

The CLI asks forThe model that answers
gpt-4oqwen2.5-coder:14b
claude-3.5-sonnetqwen2.5-coder:14b
gpt-4o-minillama3:8b-instruct

To use a different model, pull it with Ollama, add it to models, and change routing.default_local_model. The configuration reference gives each field.

What the profile changes

SettingValueWhy
routing.defaultlocalThe rule at priority 0 sends the work to the local model, and not to the cloud.
routing.allow_cloud_fallbackfalseAfter a local model fails, Glider does not try a cloud model.
routing.task_classifier.tools_force_cloudfalseA request with tools can stay local. In the default profile that request goes to the cloud. Your model must support tools.
cloud.providers[]No cloud backend exists. Therefore no rule can reach one.
cloud.budget_cap_usd0A second stop on the same path.
mitm.origin_on_local_errorfalseYou see the error of Ollama. Glider does not send the request to the origin of the CLI, which would spend a subscription with no message.
mitm.require_local_healthytrueGlider selects the local model only after a health check succeeds.
mitm.agent_rpc_canned_on_errorfalseNo fixed test reply. A failure stays visible.

What this profile intercepts

mitm.hosts in this profile lists the hosts of Cursor only. It does not list api.anthropic.com. With passthrough_default: true, each host that is not in the list goes to its origin with no decryption.

How your CLI reaches GliderDoes it operate here?
The gateway, with a base URL that you setYes. This is the method for this profile.
MITM with CONNECT, for CursorYes.
Transparent, with no help from the CLINo. Add mitm.transparent: true to turn it on, and start Glider as Administrator or root.

The two paths that still reach the network

Glider fulfils no request from the cloud in this mode. These two mechanisms are different, and each one is a choice that you can change.

1. A delegate CLI uses its own backend

<task> /claude starts the real Claude Code as a subprocess. That process talks to the backend of its vendor, with its own credentials. Glider fulfils nothing there, and this profile does not change it. To keep a delegate local also, you must intercept the traffic of that subprocess: turn transparent mode on, and add the hosts of that vendor to mitm.hosts.

2. The summary of a compaction

This profile gives no context.summary block. Therefore the default order applies: [origin, cloud, local]. Glider skips cloud, because no provider exists. But origin comes first, and it runs an installed CLI, which spends that subscription. To keep compaction on your machine, name the source:

context:
  summary:
    chain: [local]

Refer to Context · compaction for what the summary does, and for when it runs.

How to confirm that a request stayed local

WhereWhat you see
The Overview page of the dashboardA row for each request, with the rule that claimed it and the cause.
GET /api/metricsThe counts, and the percentage that went local against cloud.
The Rules Engine pageA test that shows which rule a message obeys, before you send it.
POST /api/router/explainThe same test, as an endpoint.

You can also force one turn, at any position in the message: /local or /fast. Refer to Routing.

What you accept

ItemThe effect
Quality on a difficult taskA 14b model is not a frontier model. Keep the cloud for the difficult work, or use the default profile and /cloud for one turn.
The context window32768 tokens for the coder model, against the much larger window of a cloud model.
ToolsThe classifier permits them, and your model must truly support them. A model with no support for tools gives text where a tool call must be.
SpeedIt is the speed of your GPU. keep_warm removes the load time, and it does not remove the time to generate.

When something is wrong

What you seeThe cause
Each request goes to the originYour CLI does not reach Glider. This profile does not turn transparent mode on, therefore set the base URL.
An error from Ollama, and no answerThis is correct here. origin_on_local_error: false shows the failure. Start ollama serve, and pull the model.
Glider does not select the local modelrequire_local_healthy: true, and the health check fails. Test http://127.0.0.1:11434.
The answer stops in the middle of a sentenceIncrease thresholds.default_max_tokens. Ollama receives it as num_predict.
A tool call arrives as plain textThe model does not support tools. Use a model that does, or set tools_force_cloud: true and give a cloud provider.

Next: the configuration reference gives each setting, Routing gives the rules, and MITM gives the interception.