Contents
To use SolCard Inference in Hermes Agent, add a named provider under providers: in ~/.hermes/config.yaml with api: https://api.solcardinference.ai/v1, transport: chat_completions and your sk-si- key, then point model: at it. Hermes Agent, from Nous Research, works with “any OpenAI-compatible API endpoint”, so nothing needs a plugin. Every Hermes setting below comes from its own docs, linked inline. We haven’t run Hermes ourselves.
What you need
- A SolCard Inference API key. Make one on the dashboard’s API keys page. Keys start with
sk-si-and are shown once. - Some balance or a plan. One prepaid USD balance covers every key and model; see how billing works.
- Hermes Agent. The README installs it on Linux, macOS and WSL2 with
curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash, and gives a PowerShell line for Windows.
The quick way: the wizard
Run hermes model and pick “Custom endpoint (self-hosted / VLLM / etc.)”. The providers page says it asks for the API base URL, the key and the model name, then for the API mode and the context length. Answer:
| Prompt | Value |
|---|---|
| API base URL | https://api.solcardinference.ai/v1 |
| API key | your sk-si-... key |
| Model name | solcard-inference-fast |
| API mode | chat completions |
| Context length | 1048576 |
That’s enough for one model. If you plan to switch between all three, write the file below instead, so each model keeps its own context size.
The config.yaml way: a named provider
A named provider lets each model carry its own context size. Hermes’s configuration page says settings go in ~/.hermes/config.yaml and secrets in ~/.hermes/.env. Put the key in .env:
SOLCARD_INFERENCE_API_KEY=sk-si-...
Then add this to config.yaml:
model:
default: solcard-inference-fast
provider: custom:solcard
providers:
solcard:
api: https://api.solcardinference.ai/v1
key_env: SOLCARD_INFERENCE_API_KEY
transport: chat_completions
models:
solcard-inference-fast:
context_length: 1048576
solcard-inference-large:
context_length: 1000000
solcard-inference-base:
context_length: 262144
What each part does, per the providers page:
| Field | What it’s for |
|---|---|
provider: custom:solcard | Selects the named provider; custom:<name> is the documented reference. |
api | The base URL. base_url and url are accepted aliases. |
key_env | The variable holding the key, so the key stays out of the file. |
transport | The wire format: chat_completions, anthropic_messages or codex_responses. |
models.<id>.context_length | The context window for that one model. |
The context sizes are the ones on our models page. Don’t also set model.context_length. The providers page puts it first in Hermes’s resolution chain and treats it as a pin, so it would override the per-model sizes. If nothing in the chain answers, Hermes falls back to a 128K default, which is why we set them here. All three clear the 64,000-token minimum Hermes requires for agent use with tools.
Our API also speaks Anthropic Messages, but the providers page’s example for a remote OpenAI-compatible server uses chat_completions, so we’d stay on it.
Cap compression to keep turns cheap
Hermes compresses the conversation at half the context window by default, which on Fast is about 524,000 tokens. The configuration page sets compression.threshold to 0.50, “Compress at this % of context limit”. Every turn resends the conversation, so a long session gets expensive well before that.
Its threshold_tokens field adds an absolute cap, and Hermes “takes lower of ratio vs absolute”:
compression:
threshold_tokens: 200000
Here’s the difference on Fast, for a turn that writes 1,500 tokens with 90% of its input billed as cached:
| Turn size | Cost |
|---|---|
| ~524,000 tokens in (default trigger) | about $0.13 |
| ~200,000 tokens in (capped) | about $0.05 |
Large’s input costs three times as much and it always reasons, so its turns cost more again. Our API caps every response at 32,768 tokens, whatever Hermes asks for.
Switching models
Type /model custom:solcard:solcard-inference-large in a session to move to Large. The providers page gives that custom:<name>:<model> form. Per the configuring models page, adding --once switches for one turn, then restores the previous model, which suits a single planning step. --global also saves the choice to config.yaml. Because of prompt-cache cost, the same page advises switching early in a conversation or right after starting a fresh session. Fast, Large or Base compares the three.
Side tasks and fallback
By default, Hermes’s side tasks run on your main model, so they reach our API and bill your balance. The configuring models page lists auxiliary tasks such as title generation, vision and compression, and says each “defaults to auto”, meaning Hermes “tries your main model for that job too.”
Vision won’t work on our models. They take text only, and the API rejects an image with unsupported_content. The same page says that when the main model fails a side task and no fallback is declared, the task is skipped with a warning.
A fallback provider sends the turn somewhere else. The fallback page says Hermes switches immediately on a 401, 403 or 404, and on a 429, 500, 502 or 503 once retries run out. On our API, a used-up weekly plan with no credits to cover the request is a 429, plan_limit_reached, per our errors page. With a fallback set, that turn’s prompt goes to the fallback provider, under its own retention rules. The page says the primary comes back with the next user message. Leave fallback_providers empty if every prompt should stay where keeps nothing describes.
Check it works
Check the key and URL from a terminal first:
curl https://api.solcardinference.ai/v1/models \
-H "Authorization: Bearer sk-si-..."
You should see solcard-inference-fast, -large and -base. Then run hermes doctor, which the README describes as “Diagnose any issues”, start hermes and give it a small task.
Troubleshooting
These are the API’s codes from our errors page; Hermes may word them differently.
- 401
invalid_api_key: the key is missing, revoked or unknown. Check.envholds the variablekey_envnames. - 400
model_not_found: a model id doesn’t match one of the three. - 400
unsupported_content: an image or file reached the model. - 402
insufficient_balance: top up, then retry. - 429
rate_limited: too many requests a minute for your plan.
FAQ
Can I keep OpenRouter or Nous Portal set up too?
Yes. Named providers sit next to the built-in ones, and /model switches between them per session.
Can I use OPENAI_BASE_URL instead?
The providers page says it’s honored only for the openai-api provider. For a custom endpoint it points you to hermes model or config.yaml.
Should I put the key in config.yaml?
The docs allow an inline api_key, but the configuration page says secrets go in .env. key_env keeps the file safe to share.
Are my prompts or code stored? No. Prompts and responses are never logged or stored, on any model. Side tasks that run on our API are covered the same way; a fallback provider isn’t.