March 7, 2025 in guidance by Emanuel-Todor Hascau-Dumitrelea and Dimitri Tombroff2 minutes
Running Fred with a local Ollama server
This short post explains how to run Fred and its agents on a local Ollama server. Ollama makes it easy to run large language models like llama2, mistral, or gemma locally — without needing any API key.
It’s straightforward and great for testing or offline setups.
On macOS, simply run:
brew install ollamaStart the Ollama server:
ollama serveOr install it as a background service:
brew services start ollamaThen run a model (e.g., llama2):
ollama run llama2You can verify that the Ollama server is listening:
lsof -i :11434You should see output like:
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
ollama 56805 dimi 3u IPv4 0xa591e9eac9b75a54 0t0 TCP localhost:11434 (LISTEN)The steps are very similar on Linux desktops.
Fred supports multiple backends per agent. To make an agent (like the GeneralistExpert) use your local Ollama model, simply update the config:
ai:
timeout:
connect: 5 # Time to wait for a connection in seconds
read: 15 # Time to wait for a response in seconds
agents:
GeneralistExpert:
enabled: true
model:
model_type: "ollama"
model: "llama2"
temperature: 0No credentials are needed when using Ollama locally — it’s fast and self-contained.
Once configured, just restart Fred. Your agent is now using a local LLM to process prompts!
You can now experiment with prompts, test offline setups, or even try different local models — all without relying on external APIs.