Skip to content

docs(guides): run Hermes locally with Ollama — zero API cost - #5842

Closed
binhnt92 wants to merge 2 commits into
NousResearch:mainfrom
binhnt92:docs/guide-local-ollama-setup
Closed

docs(guides): run Hermes locally with Ollama — zero API cost#5842
binhnt92 wants to merge 2 commits into
NousResearch:mainfrom
binhnt92:docs/guide-local-ollama-setup

Conversation

@binhnt92

@binhnt92 binhnt92 commented Apr 7, 2026

Copy link
Copy Markdown
Contributor

Adds a step-by-step guide for running Hermes Agent entirely on local hardware using Ollama as the model backend. No cloud API keys, no subscriptions, no data leaving the machine.

Tested on a bare-metal server (AMD EPYC, 64GB RAM, CPU-only) with Gemma 4 31B, Gemma 2 9B/27B, Llama 3.2 3B, and Mistral 7B.

What the Guide Covers

  • The problem — cloud API costs and privacy concerns
  • Hardware requirements — minimum vs recommended specs table
  • Step-by-step setup — Ollama install, model pull, Hermes config
  • Model selection — comparison table with tool-call support status (important: not all models support tool calling)
  • Speed optimization — context window tuning, keep-alive, GPU offloading
  • Gateway bot — Telegram/Discord setup with local models
  • Hybrid setup — local for everyday tasks, cloud fallback for hard ones
  • Troubleshooting — connection issues, slow responses, tool-call failures, context errors
  • Cost comparison — local vs cloud per-session and monthly

Key Findings from Testing

  • gemma4:31b is the recommended model — it supports tool calling, which is essential for Hermes' agentic workflow
  • gemma2:9b/27b do NOT support tool calling via Ollama (returns HTTP 400) — they work for chat-only, noted in the guide
  • CPU-only inference with 31B models is slow (~30-120s per response) — guide includes timeout configuration advice
  • The OpenAI-compatible endpoint (/v1/chat/completions) works correctly for both chat and tool-call flows

Checklist

  • Tested all steps on real hardware
  • Verified tool-call support per model
  • No sensitive data (tokens, IPs, etc.)
  • Follows existing guide format (matches daily-briefing-bot.md structure)

binhnt92 added 2 commits April 6, 2026 18:46
When Slack's connect() acquires a scoped lock on the app token and then
fails (bad token, Socket Mode error), the lock is never released. The
next gateway start sees "Slack app token already in use" and refuses to
connect until the process dies.

Same issue in Signal: if the health check fails after acquiring the
phone lock, the lock is held permanently.

Discord got this fix in PR NousResearch#5302. Slack and Signal were missed.

Add lock release to both exception/failure paths. Extract Signal's
inline release logic into a reusable _release_phone_lock() helper.
Also close the leaked httpx client on Signal health check failure.
Step-by-step guide covering Ollama installation, model selection,
Hermes configuration, speed optimization, and optional gateway bot
setup — all running on local hardware with zero API cost.

Includes hardware requirements, model comparison table with tool-call
support status, context window tuning, GPU offloading tips, fallback
provider setup, troubleshooting, and cost comparison.
@alt-glitch alt-glitch added type/docs Documentation improvements P3 Low — cosmetic, nice to have provider/ollama Ollama / local models labels Apr 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P3 Low — cosmetic, nice to have provider/ollama Ollama / local models type/docs Documentation improvements

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants