Skip to content
Docs

Coding agents

Use Libremodel in Hermes Agent

Hermes Agent reads its providers from config.yaml. Add us as a custom provider and every model is one /model away.

1. Install Hermes Agent

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

2. Set your API key

Create a key in API keys and save it as LIBREMODEL_API_KEY. On macOS and Linux, add the line to ~/.zshrc or ~/.bashrc so every new terminal has it.

export LIBREMODEL_API_KEY="sk-libremodel-..."

3. Add Libremodel

Add this to ~/.hermes/config.yaml, replacing its model section. If the file already lists providers, add ours to the list.

~/.hermes/config.yaml
model:
  provider: custom:libremodel
  default: deepseek-v4.1-flash-1017

providers:
  libremodel:
    name: Libremodel
    api: https://api.libremodel.ai/v1
    key_env: LIBREMODEL_API_KEY
    transport: chat_completions
    default_model: deepseek-v4.1-flash-1017
    models:
      kimi-k3.1-pro-uncensored: {context_length: 1048576}
      deepseek-v4.1-flash-1017-uncensored: {context_length: 1048576}
      glm-5.3-flash-uncensored: {context_length: 1048576}
      kimi-k3.1-pro: {context_length: 1048576}
      deepseek-v4.1-flash-1017: {context_length: 1048576}
      minimax-m3.1-flash: {context_length: 1048576}

4. Start it

Shell
hermes

Switch models with /model custom:libremodel:<model id> and reasoning effort with /reasoning.

Troubleshooting

Run this in the same terminal you start the tool from. It costs nothing. A list of models means the key is fine. A 401 means LIBREMODEL_API_KEY is empty or wrong in that terminal; open a new one after saving it.

curl -s https://api.libremodel.ai/v1/models -H "Authorization: Bearer $LIBREMODEL_API_KEY"

If the key is fine and the tool gets a 402, your balance does not cover the request. See Billing and credits.

Notes

Agents that run subagents send several requests at once. When capacity is busy, the extra ones wait in a short queue instead of failing. See Limits and errors.