source: kdnuggets: running openclaw with ollama

level: technical

openclaw bridges local ollama models to messaging apps like telegram, whatsapp, and slack. it runs as a background daemon called the gateway, which routes messages from your chat app to your model and back. you can use cloud models with no gpu or local models for full privacy. the setup requires ollama 0.17 or later and node.js 18+. for local models, you need at least 25 gb vram and must set context length to 64k tokens or more to handle multi-step agent tasks.

install with a single command: ollama launch openclaw. this handles npm installation, model selection, and gateway startup. to connect telegram, create a bot via botfather, get the token, and add it in the openclaw channel configurator. cloud models automatically include web search; for local models, sign in to ollama and enable web search in settings. the agent can then perform multi-step research, like finding and summarizing papers, directly from your phone.

for production use, deploy openclaw headlessly in docker. the agent runs continuously, handling tasks in the background. you can also call ollama's web search api from python for custom automation. always review the security notice: the agent can read files and execute actions on your machine, so run it in an isolated environment if needed.

why it matters: this lets data scientists and developers run a private, always-on ai assistant that can do multi-step research and web searches without sending data to external apis.


source: kdnuggets: running openclaw with ollama