An AI coding agent sends far more model requests than a regular chat window. One task can trigger half a dozen tool calls to read files, run checks, and summarize output. Paying per token during exploration adds up fast, so I put together a supported setup to run Hermes Agent in the terminal without a paid API bill.
Because Hermes separates provider credentials (~/.hermes/.env and ~/.hermes/auth.json) from model routing (~/.hermes/config.yaml), you can mix free hosted tiers, browser OAuth portals, and local models, then switch between them without touching code.
1. Install the Hermes CLI
On Linux, macOS, or WSL2, run the installer to set up the hermes command and its Python environment:
curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash
source ~/.bashrc
After installation, hermes opens an interactive terminal session, hermes --tui opens the full terminal UI, and hermes chat -q "..." runs a single non-interactive prompt.
2. Five Ways to Get Free Model Access
Hermes includes several zero-cost providers inside its wizard (hermes model):
| Option | How you get access | Best fit |
|---|---|---|
| Nous Portal (Free plan) | Run hermes setup, open Nous Portal, and pick the Free plan (plus :free promotional variants when offered) |
Fastest guided onboarding |
OpenRouter (:free models) |
Sign in with hermes auth add openrouter --type oauth or set OPENROUTER_API_KEY, then pick a :free model or openrouter/free |
Trying multiple open-weight models |
| NVIDIA NIM | Create a free developer key at build.nvidia.com and save NVIDIA_API_KEY |
Large hosted open models like Nemotron |
| Qwen / MiniMax OAuth | Run hermes model, pick Qwen OAuth or MiniMax (OAuth), and finish the browser login |
Zero API-key setup |
| Hugging Face Inference | Create an HF_TOKEN with Inference Providers enabled (includes a $0.10/month free tier) |
Lightweight open model routing |
| Local server (Ollama / LM Studio) | Run Ollama (http://localhost:11434/v1) or LM Studio on your own hardware |
Unlimited offline runs, zero rate limits |
Keep two limits in mind when picking a free cloud model for Hermes:
- Tool calling and context size: Hermes loads its system prompt and tool schemas on each turn, so pick a model with native tool-calling support and at least a
64000-token context window. - Turn multipliers on strict quotas: Providers like Google AI Studio offer a free-tier
GOOGLE_API_KEY, yet one agent prompt can fire multiple tool calls and hit strict per-minute or daily request caps after a few turns.
3. Wire Up a Free Provider in the CLI
Save an API key without editing files by hand:
# Example: OpenRouter or NVIDIA NIM
hermes config set OPENROUTER_API_KEY sk-or-...
# or
hermes config set NVIDIA_API_KEY nvapi-...
For browser OAuth providers (qwen-oauth, minimax-oauth, or OpenRouter PKCE):
hermes model
Pick your provider from the interactive list and finish the browser login. Hermes saves the refreshable credentials in ~/.hermes/auth.json and writes the active provider to ~/.hermes/config.yaml.
Test a specific provider or model from the terminal:
hermes chat --provider nvidia --model nvidia/nemotron-3.5-super-vl-120b-a12b
If you run a local model with Ollama, pull a tool-capable coding model and set its context window to at least 64K tokens in ~/.hermes/config.yaml:
model:
provider: custom
default: qwen2.5-coder:32b
base_url: http://localhost:11434/v1
context_length: 64000
4. Stretch Free Limits with Fallbacks and Daily Commands
Free tiers often throttle requests per minute before they throttle tokens. Two habits keep a session moving when a primary free endpoint hits a rate limit:
- Configure a fallback chain (
hermes fallback): Add secondary free providers (or a local Ollama server) underfallback_providersin~/.hermes/config.yamlso Hermes switches mid-session if the primary hits a limit:
model:
provider: openrouter
default: openrouter/free
fallback_providers:
- provider: nvidia
model: nvidia/nemotron-3.5-super-vl-120b-a12b
- provider: custom
model: qwen2.5-coder:32b
base_url: http://localhost:11434/v1
- Keep sessions lean inside the CLI:
- Run
/modelmid-session to switch between configured providers. - Run
/usageto inspect token counts and session activity. - Run
/compresswhen a thread grows long so you stop resending old history. - Restrict active tools with
hermes chat --toolsets "file,terminal"on smaller free or local models so schemas use less context.
- Run
Start with one free provider and add a second free endpoint or local server as a fallback to keep terminal sessions running without usage-based billing.