> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tokios.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Tokios exposes private local models through https://api.tokios.com using an outbound-only connector tunnel.
> Use 'connector' for the local tokios-connector process.
> Use 'deployment' for the public model name in the API model field.
> Use 'upstream model id' for the model served by Ollama, llama.cpp, vLLM, LM Studio, or another local backend.
> API keys use the prefix sk-tok-. Connector tokens use the prefix ct-tok-.

# Point Hermes Agent at your Tokios endpoint

> Point Hermes Agent's LLM backend at a local model served by Ollama, LM Studio, or vLLM — add Tokios as a custom OpenAI-compatible provider for its agent loop.

Hermes Agent is an open-source autonomous agent runtime from Nous Research. Unlike a typical chat client, Hermes both exposes its own OpenAI-compatible endpoint for frontends to connect to, and consumes an OpenAI-compatible backend to do its own reasoning. This page covers the second part: pointing Hermes's backend LLM provider at Tokios so its agent loop runs on your private local model.

> [!NOTE]
>
> Hermes Agent is a runtime, not a typical BYOK chat UI. Treat this integration as connecting one system to another (Hermes → Tokios), not as configuring a chat app.

## Prerequisites

* A running Tokios connector paired with your local model — see [Connector install](https://docs.tokios.com/setup/connector-install.md)
* A registered model deployment name — see [Register a model](https://docs.tokios.com/setup/register-model.md)
* A Tokios API key (`sk-tok-…`) — see [API keys](https://docs.tokios.com/setup/api-keys.md)
* Hermes Agent installed

## Configure Hermes Agent's backend provider

Hermes reads its backend provider settings from `~/.hermes/config.yaml`. The provider keys live **under a top-level `model:` mapping** — they are not top-level keys themselves:

```yaml ~/.hermes/config.yaml theme={"theme":{"light":"github-light","dark":"css-variables"}}
model:
  default: gemma-tunnel
  provider: custom
  base_url: https://api.tokios.com/v1
  api_key: sk-tok-YOUR_KEY
```

> [!WARNING]
>
> The nesting matters. If `provider`, `base_url`, and `api_key` sit at the top level, Hermes ignores them and silently falls back to its default provider — you get a working agent that never touches your local model.

> [!NOTE]
>
> Replace `gemma-tunnel` with the **public deployment name** you registered on the [Models](https://tokios.com/console/models) tab — not the local model id your backend (Ollama, llama.cpp, vLLM, or LM Studio) uses. Replace `sk-tok-YOUR_KEY` with your own key, and avoid committing it into a shared or version-controlled config file.

> [!WARNING]
>
> `base_url` must include `/v1`. Hermes's custom-provider path sends requests to any server that implements `/v1/chat/completions`, so a base URL without `/v1` fails to reach the Tokios API surface.

You can also set this interactively without editing YAML by hand:

```bash theme={"theme":{"light":"github-light","dark":"css-variables"}}
hermes model
```

Select **Custom endpoint** from the provider list, then supply the same base URL, API key, and deployment name. The exact wording and prompts of the `hermes model` interactive flow can vary by Hermes Agent release, so check yours.

## Troubleshooting

> [accordion] 401 error
>
> The API key Hermes sent is missing, malformed, or has been revoked. Confirm `api_key` in `config.yaml` holds the full `sk-tok-…` key with no extra whitespace, and check its status on the [Keys](https://tokios.com/console/keys) tab.

> [accordion] 404 error
>
> The `model` value doesn't match a registered deployment. Confirm it exactly matches the public name on the [Models](https://tokios.com/console/models) tab — not your Ollama, llama.cpp, vLLM, or LM Studio local model id.

> [accordion] 503 error
>
> The connector for that deployment is offline or at its concurrency cap. Check the [Connectors](https://tokios.com/console/connectors) tab — the connector needs to show as **Online**, and the machine running it needs to still be up and reachable.

## Next steps

> [card] [Quickstart](https://docs.tokios.com/quickstart.md)
>
> Set up the connector and register your first model deployment.

> [card] [Compatible clients](https://docs.tokios.com/guides/compatible-clients.md)
>
> See base URL and key setup for other OpenAI- and Anthropic-compatible clients.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.