How to run mini-me on Ollama
This guide shows how to point mm at Ollama through its OpenAI-compatible endpoint. It assumes Ollama is installed and you know how to build mm.
Steps
-
Pull the model. Ollama's OpenAI API does not pull a missing model: a question to it fails with
model '…' not found:ollama pull qwen3.5:2b -
Make sure the server runs on
localhost:11434(the desktop app starts it; otherwiseollama serve). -
Run the demo configuration from its directory (its
skillsDiris../skills):cd demos/ollama ../../mm agent.ollama.yaml -
Check the banner.
provider: ollamaconfirms the provider.ctx: 32768 (/api/ps)means the model was already loaded andmmread the window it is served with;ctx: unknownmeans it was not loaded yet —mmasks again before the next question.
Variants
- Another model. Set
model:to the name exactly asollama listspells it (qwen3.5:9b, …). - From a Docker sandbox. Nothing to change: when
localhost:11434does not answer,mmfalls back tohttp://host.docker.internal:11434/v1, the Ollama on the host. - A larger window. The OpenAI API cannot set
num_ctxper request: start Ollama withOLLAMA_CONTEXT_LENGTH, and put the same value incontextWindowif you want compression to know it from the first question. - ollama.com's API. Set
baseUrlto its OpenAI endpoint and export the key inOLLAMA_API_KEY(or name another variable underapiKeyEnv). - Keep your own
agent.yaml.AGENT_PROVIDER=ollama ./mmworks as long as the file leavesbaseUrlempty.
What differs from the llama.cpp servers
- No
Reading the prompt …line: Ollama sends no progress while it reads, sofirstTokenTimeouthas to cover the whole prompt and the model's loading. - The summary of a compaction turns reasoning off with
reasoning_effort: "none"— Ollama ignoreschat_template_kwargs.
See also
- Providers: one implementation per protocol — what was measured on Ollama, and why each server keeps its own entry.
- Configuration reference — provider defaults.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 |
|