When setting up Hermes Agent locally, you can choose between two different backends: Ollama and Unsloth Studio. Ollama is par­tic­u­lar­ly well suited to a quick and straight­for­ward setup, while Unsloth Studio gives you greater control over GGUF models, quan­ti­za­tion and memory usage.

Key Takeaways

The key points for running Hermes Agent locally:

  • Local means no cloud API: the language model and inference run on your own hardware, your inputs stay on the device and there are no usage-based API costs — only elec­tric­i­ty and hardware.
  • Ollama or Unsloth Studio: Ollama is one of the quickest ways to get started, while Unsloth Studio gives you more control over GGUF models, quan­ti­za­tion and memory.
  • Setup: install Hermes Agent and Ollama, download a model that supports tool calls and connect the two through the local endpoint http://localhost:11434/v1.
  • Context length: Hermes Agent needs at least 64,000 context tokens — set this in Ollama via OLLAMA_CONTEXT_LENGTH or a Modelfile, not in Hermes alone.
  • Hardware: what matters is quan­ti­za­tion, context length and whether the model fits into graphics memory; small 4-bit models (7B to 9B) need around 16 GB of RAM or 8 to 12 GB of VRAM, larger ones con­sid­er­ably more.
  • Trou­bleshoot­ing: the usual causes are a local server that is not running, an endpoint address without /v1 and a context length that is too small.

What does running Hermes Agent locally mean?

When running the Hermes Agent locally, the language model and inference run entirely on your own hardware. Hermes does not send requests to external cloud-APIs, but to a local backend. This keeps inputs on the device and avoids usage-based API costs; however, elec­tric­i­ty and hardware costs still apply.

Hermes Agent is not itself the language model. Instead, the open-source framework handles tasks such as con­ver­sa­tion man­age­ment, tool access, memory and the execution of multi-step workflows. Ollama or Unsloth Studio, by contrast, provide the actual LLM for Hermes Agent and process the requests sent by Hermes.

For a truly cloud-in­de­pen­dent local Hermes Agent setup, you must not configure a cloud provider such as Open­Router or Nous Portal as the model source. Ad­di­tion­al features such as web search, cloud browsing, image gen­er­a­tion or messenger in­te­gra­tions may also connect to external services. If you want all data to be processed ex­clu­sive­ly on your own computer, you should initially use Hermes through the local terminal and only with tools that can run locally.

Ollama and Unsloth Studio compared

Ollama and Unsloth Studio perform the same basic task: both load a language model into system memory or graphics memory and make it available to other programs through a local interface. In a local Hermes Agent setup, both are con­fig­ured as a “Custom Endpoint.” The main dif­fer­ence lies in how they are operated and how much control they provide over the model files being used.

Criterion Ollama Unsloth Studio
API interface OpenAI-com­pat­i­ble endpoint at http://localhost:11434/v1; for local access, an API key is normally not required OpenAI-com­pat­i­ble endpoint, by default at http://localhost:8888/v1; access is secured using a locally generated API key
Supported formats Models from the Ollama library as well as custom GGUF files imported via a Modelfile GGUF and Safeten­sors models from Hugging Face or local files
Memory op­ti­miza­tion Automatic GPU of­fload­ing and straight­for­ward use of quantized models, with few settings required Direct selection of different GGUF quan­ti­za­tions and more extensive control over the model, context and inference
Primary target group Beginners who want to get a local model running as quickly as possible Advanced users who want to use their own, cus­tomized or heavily quantized models

Ollama is generally the easier option for beginners. You can download a model with a single terminal command, and Hermes Agent detects the down­loaded models once you have con­fig­ured the local Ollama endpoint. Custom GGUF files can also be imported, although this requires an ad­di­tion­al Modelfile.

Unsloth Studio is primarily suitable if you want to select, quantize, customize or train models yourself. It can run GGUF and Safeten­sors models locally and make the loaded model available through an API. Unsloth Studio works on Windows, Linux, WSL and macOS. According to the man­u­fac­tur­er, GGUF chats can also run using only the CPU, although this is sig­nif­i­cant­ly slower than using a suitable GPU.

How to install Hermes Agent and Ollama

For beginners, Ollama is one of the easiest ways to run Hermes Agent locally on your own machine. The following steps show you how to install Hermes and Ollama, download a suitable model and connect both ap­pli­ca­tions through the local API endpoint.

Note

If Ollama is already installed, you can set up Hermes Agent locally with a single command:

ollama launch hermes
bash

Ollama checks whether the Hermes command-line ap­pli­ca­tion is available and, if necessary, offers to install it. You then select a model; Ollama au­to­mat­i­cal­ly sets up the local endpoint as a model provider and starts Hermes. To run com­plete­ly in­de­pen­dent­ly of the cloud, be sure to choose a locally available model and not a model with the suffix :cloud.

1. In­stalling Hermes Agent

For Windows and macOS, the native Hermes desktop app is the simplest in­stal­la­tion method and is rec­om­mend­ed by Nous Research. Linux users, as well as those who want to use Hermes Agent local ex­clu­sive­ly in the terminal, can continue to install the command-line version.

In­stal­la­tion via the desktop app on Windows and macOS

Download the Hermes desktop installer from the official Nous Research website. The MSIX desktop package requires Windows 11 22H2 or later. On Windows 10, use the Pow­er­Shell installer described below. In­stal­la­tion packages are also available for supported macOS systems with Apple Silicon. Intel-based Macs are not supported by Hermes Desktop. Then run the down­loaded file and follow the in­struc­tions in the installer.

The desktop packages include the graphical interface, the Hermes en­vi­ron­ment and the required de­pen­den­cies. The desktop app and the command-line version use the same settings, sessions, models, skills and stored content. You can therefore switch between the graphical interface and the terminal at any time later on.

Models, providers and cre­den­tials can be con­fig­ured in the app through its settings. To run Hermes entirely locally with Ollama, you still have to install Ollama sep­a­rate­ly and then select its local endpoint as the model provider.

The Hermes desktop app also includes a built-in Local Models feature under Settings → Providers → Local Models. It installs and manages a local llama.cpp runtime, downloads suitable models and au­to­mat­i­cal­ly handles memory and context settings. This is the simplest option for desktop users who want to run Hermes locally without con­fig­ur­ing Ollama or another external backend. The Ollama setup below is par­tic­u­lar­ly useful for manual, CLI-based or in­di­vid­u­al­ly con­fig­ured in­stal­la­tions.

In­stal­la­tion via the terminal

On Linux, macOS or WSL, first open a terminal and run the official in­stal­la­tion command:

curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash
bash

On Windows, open Pow­er­Shell and use the following command instead:

iex (irm https://hermes-agent.nousresearch.com/install.ps1)
pow­er­shell

The installer au­to­mat­i­cal­ly sets up the required Python en­vi­ron­ment, Node.js and other de­pen­den­cies. On macOS and Linux, Git should already be installed. On Linux, curl and xz-utils are also required. Restart the terminal after in­stal­la­tion:

source ~/.bashrc
bash

When using the Z shell, which is common on newer macOS systems for example, the command is:

source ~/.zshrc
bash

Then check the in­stal­la­tion:

hermes doctor
bash

The command checks, among other things, the in­stal­la­tion, the con­fig­u­ra­tion files and the con­fig­ured model provider. If errors are found, Hermes usually displays suitable sug­ges­tions for solutions.

2. Install Ollama

Download Ollama from the provider’s official download page and select the ap­pro­pri­ate version there. On macOS and Windows, then install the supplied in­stal­la­tion package; for Linux, the page displays a terminal command for automatic in­stal­la­tion. After in­stal­la­tion, you can check in the terminal whether the command is available:

ollama --version
bash

Ollama starts au­to­mat­i­cal­ly in the back­ground on desktop systems. The local API service is available by default on port 11434. For OpenAI-com­pat­i­ble programs such as Hermes Agent local, the full base address is:

http://localhost:11434/v1
text

localhost means that Hermes Agent local only accesses the service on the same computer. Ollama usually does not require an API key for this local access.

3. Download a local model

For Hermes Agent local, it is advisable, for example, to download Gemma 4 and Qwen3.6. For reliable tool calls, the Hermes doc­u­men­ta­tion rec­om­mends the gemma4:31b variant, which takes around 20 GB on disk and needs at least 24 GB of RAM. Qwen3.6 is around 23 GB in its default variant, so you should plan for roughly 24 GB as well.

Download Gemma 4 with the following command:

ollama pull gemma4:31b
bash

Al­ter­na­tive­ly, you can download Qwen3.6:

ollama pull qwen3.6
bash

The download may be several gigabytes in size, depending on the model. Then display the installed models:

ollama list
bash

First, test the model directly in Ollama:

ollama run gemma4:31b
bash

If you receive a response, local inference is working correctly. Use /bye to end the test.

4. Set the context length for Hermes Agent local

Hermes Agent local requires at least 64,000 context tokens for reliable tool use. Depending on the available VRAM, Ollama may use sig­nif­i­cant­ly smaller default values. With less than 24 GB of VRAM, Ollama normally starts with 4,096 tokens, with 24 to 48 GB it uses 32,768 tokens, and only from 48 GB upwards does it use a larger default context. Stop the currently running Ollama service and restart it with the correct context length.

OLLAMA_CONTEXT_LENGTH=64000 ollama serve
bash

On Windows Pow­er­Shell, use:

$env:OLLAMA_CONTEXT_LENGTH="64000"
ollama serve
pow­er­shell

Leave this terminal open, as it is now running the local Ollama server.

Al­ter­na­tive­ly, you can per­ma­nent­ly store the context length in your own Ollama model. To do this, create a file called Modelfile with the following content:

FROM gemma4:31b
PARAMETER num_ctx 64000
text

Then create a new model from it:

ollama create gemma4-64k -f Modelfile
bash

If you use this Modelfile method, select gemma4-64k as the model in Hermes in the next step.

Hermes Agent local cannot increase the context length via the OpenAI-com­pat­i­ble Ollama API. This setting therefore has to be con­fig­ured directly in the Ollama server or in the Modelfile.

5. Connect Ollama with Hermes Agent local

In the next step, you need to link Ollama and Hermes Agent local. To do this, open a new terminal and start the model assistant:

hermes model
bash

Select the following options one after the other:

  • More providers
  • Custom endpoint
  • For the API base URL: http://localhost:11434/v1
  • Leave the field for the API key empty.
  • Also select the model detected by Hermes Agent local.
  • Enter 64000 as the context length, or leave the field empty if Hermes Agent local au­to­mat­i­cal­ly detects the correct value.

Hermes Agent local queries the /v1/models endpoint and can therefore detect Ollama models that have already been down­loaded. The selection is per­ma­nent­ly stored in the ~/.hermes/config.yaml file.

Then start Hermes:

hermes
bash

First, enter a simple query. Then you can test with a task to check whether the model also calls tools correctly.

Advanced setup with Unsloth Studio

Unsloth Studio is a local web interface for running, training and exporting open AI models. For Hermes Agent local, the in­te­grat­ed OpenAI-com­pat­i­ble API endpoint is par­tic­u­lar­ly relevant.

Install Unsloth Studio with:

curl -fsSL https://unsloth.ai/install.sh | sh
bash

In Windows Pow­er­Shell, use:

irm https://unsloth.ai/install.ps1 | iex
pow­er­shell

Then start the interface ex­clu­sive­ly on the local address:

unsloth studio -H 127.0.0.1 -p 8888
bash

Then open in your browser:

http://localhost:8888
text

The first time you start it, set a password for the local Studio interface. You then connect it to Hermes Agent local in the following steps:

  1. Load model in Unsloth Studio: Open the chat or model section and search for a suitable GGUF model. You can download models from Hugging Face or select an existing GGUF file. For limited memory, 4‑bit quan­ti­za­tion such as Q4_K_M is a sensible starting point. Make sure the model supports tool calls. You usually do not need to set the available context length manually in Unsloth Studio, as llama.cpp’s smart auto context loads only the context a session actually needs. If you do want to pin a value, Unsloth Studio lets you set the context length yourself.
  2. Generate a local API key: Open the Settings > API section in Unsloth Studio and create a new key. The key usually begins with sk-unsloth-. It is used solely to secure local API access and does not mean that requests are sent to any cloud. With the con­fig­u­ra­tion used above, the OpenAI‑com­pat­i­ble base address is http://localhost:8888/v1.
  3. Configure Hermes Agent local: Open the ~/.hermes/config.yaml file in a text editor and enter the model name, endpoint and key:
model:
  default: "EXACT-MODEL-NAME-FROM-UNSLOTH"
  provider: custom
  base_url: "http://localhost:8888/v1"
  api_key: "sk-unsloth-YOUR-LOCAL-KEY"
yaml

Replace EXACT-MODEL-NAME-FROM-UNSLOTH with the model ID shown in the API section of Unsloth Studio. Be careful with in­den­ta­tion in YAML files: under model: there are two spaces each time. Hermes Agent local uses ~/.hermes/config.yaml as the central source for model, provider and base URL.

As the file contains an access key, it should only be readable by your user account. On macOS and Linux, you can restrict the per­mis­sions with the following command:

chmod 600 ~/.hermes/config.yaml
bash

Then check the setup again:

hermes doctor
bash

Then start Hermes:

hermes
bash

Unsloth Studio must remain open or running as a local server while in use. If Studio is closed, Hermes Agent local can no longer reach the API endpoint.

Hardware re­quire­ments for local models

Hardware re­quire­ments depend on more than just the number of model pa­ra­me­ters. Quan­ti­za­tion, context length, model ar­chi­tec­ture and whether the model fits entirely into graphics memory also play an important role.

The following values provide a practical guide for quantized GGUF models:

Model size Practical minimum spec Clas­si­fi­ca­tion
7B to 9B, 4-bit Approx. 16 GB RAM or unified memory; with a dedicated GPU, ideally at least 8 to 12 GB VRAM Suitable for simple local tests; a context of 64,000 tokens can sig­nif­i­cant­ly increase memory re­quire­ments
12B to 14B, 4-bit Approx. 24 GB RAM or unified memory, or 12 to 16 GB VRAM Offers better answer quality, but with no­tice­ably higher hardware re­quire­ments
27B to 35B, 4-bit At least 32 GB RAM or unified memory; for smooth GPU inference, often around 24 GB VRAM Suitable for current models such as Qwen3.6; long contexts require ad­di­tion­al memory
70B, 4-bit Generally at least 64 to 96 GB of available memory Better suited to powerful work­sta­tions or systems with multiple GPUs
Note

RAM and VRAM are not the same. RAM is the computer’s main working memory, while VRAM is the memory of a dedicated graphics card. Macs with Apple Silicon instead use unified memory that can be accessed by both the processor and GPU.

These values are not fixed limits. A 27B model with 4-bit quan­ti­za­tion may be around 17 GB as a file, but it requires ad­di­tion­al memory during operation. This is par­tic­u­lar­ly relevant for a local Hermes Agent setup, as agent tasks are designed to use a context window of at least 64,000 tokens. If a model does not fit entirely into VRAM, Ollama and Unsloth can move parts of it into regular system memory. This makes it possible to run the model on less powerful hardware, although per­for­mance may be slower.

Trou­bleshoot­ing the local in­stal­la­tion

Many problems are caused by the local server not running, an incorrect endpoint address or an in­suf­fi­cient context length. The following checks can help you identify and resolve the most common issues quickly.

Hermes command not found

If the message hermes: command not found appears, first reload the shell con­fig­u­ra­tion:

source ~/.bashrc
bash

On macOS or if you are using the Z shell, use instead:

source ~/.zshrc
bash

Also check whether ~/.local/bin is included in the PATH en­vi­ron­ment variable. Then run the following di­ag­nos­tic command:

hermes doctor
bash

Hermes Agent local checks the in­stal­la­tion and points out possible con­fig­u­ra­tion errors.

Hermes cannot reach Ollama

First check whether the local Ollama server is reachable:

curl http://localhost:11434/v1/models
bash

If a list of models appears, the con­nec­tion is working. If there is a con­nec­tion error, restart Ollama:

OLLAMA_CONTEXT_LENGTH=64000 ollama serve
bash

Also check the address entered in Hermes Agent local. It must be exactly http://localhost:11434/v1. If /v1 is missing, an HTTP 404 error may occur.

Hermes Agent local is asking for an API key

Normally, no API key is required for the local Ollama endpoint. Therefore, leave the cor­re­spond­ing field in the setup wizard empty.

Cor­rect­ing context length and context drift with Ollama

Problems can arise if Hermes Agent local and Ollama use different context lengths. For example, Hermes Agent local might plan with 64,000 tokens, while Ollama actually runs the model with only 4,096 tokens. Longer con­ver­sa­tions or tool calls may then be cut off or rejected.

Therefore, enter the desired context length in ~/.hermes/config.yaml:

model:
  default: "gemma4:31b"
  provider: custom
  base_url: "http://localhost:11434/v1"
  context_length: 64000
yaml

Then start Ollama with the same value:

OLLAMA_CONTEXT_LENGTH=64000 ollama serve
bash

Check the context that has actually been loaded with:

ollama ps
bash

In the CONTEXT column, the value should be at least 64000. Changing the Hermes Agent local con­fig­u­ra­tion alone does not increase the model’s context window. However, do not choose a higher value than the model and your hardware support. Otherwise, memory errors, slow responses, or con­nec­tion drops may occur.

Tool calls only appear as text

Hermes Agent local requires a model that supports struc­tured tool calls. If the model only describes an action in text instead of executing the cor­re­spond­ing tool, the model or its chat template is often un­suit­able. Therefore, use an Ollama model that ex­plic­it­ly supports tool calls wherever possible. For GGUF files you import yourself, the ap­pro­pri­ate chat template and tool support must also be preserved.

Which local setup is best for Hermes Agent?

For your first fully local Hermes Agent setup, Ollama is the simplest option. Models can be loaded with just a few terminal commands, the local endpoint does not require an API key, and the con­nec­tion can be con­fig­ured directly using hermes model. The key re­quire­ment is to start Ollama with a context window of at least 64,000 tokens.

Unsloth Studio offers greater control. The setup involves a few ad­di­tion­al steps, but it also provides Hermes Agent with an OpenAI-com­pat­i­ble local endpoint. In both cases, model inference can run without an external cloud API, provided you use only local models and do not enable any cloud-based Hermes Agent tools.

Reviewer

Go to Main Menu