Lebrel provider for Hermes Agent
Adds Lebrel to Hermes Agent as the lebrel model provider
(alias lebrel-ai) over Lebrel's OpenAI-compatible Chat Completions endpoint,
https://attested.lebrel.ai/v1: Lebrel's own uncensored edition of DeepSeek
V4.1 Flash, and the DeepSeek, Qwen, Kimi and GLM models Lebrel's router relays.
Install
hermes plugins install lebrel
hermes model # choose Lebrel, paste your key, pick a model
Or set the key yourself and start a session:
echo 'LEBREL_API_KEY=<your-api-key>' >> ~/.hermes/.env
hermes --provider lebrel --model lebrel/deepseek-v4.1-flash-uncensored
Create a key at https://lebrel.ai/dashboard#keys. Requests are billed to your
Lebrel account at the rates on lebrel.ai/pricing;
Lebrel's docs cover the API itself.
What it does
- Registers one provider profile,
lebrel, inchat_completionsmode against
https://attested.lebrel.ai/v1.LEBREL_BASE_URLoverrides the endpoint. - Fills the
/modelpicker from Lebrel's public catalog,
GET https://attested.lebrel.ai/v1/models, Lebrel's editions first. The list
is cached in memory until/model --refresh; when the catalog cannot be
reached, the picker offers the ten models below. - Declares each model's context window, image input and tool calling, so Hermes
compacts long sessions at the right point. - Caps each step's output at 32,768 tokens when you set no
max_tokens. Lebrel
holds the cost of the longest answer a request allows while it runs, and the
models' full limits (131,072 to 393,216 tokens) would hold far more than a
step needs. Setmodel.max_tokensto choose another cap. - Sends reasoning controls in each lab's own fields, and only when you set
agent.reasoning_effort(or/reasoning); otherwise every model keeps its
lab's default. - Leaves auxiliary tasks (context compression, titles, vision) on the model you
chose, so a conversation with Lebrel's edition is never summarised by a
relayed model.
| Model | Context | Images | Reasoning levels (/reasoning) |
|---|---|---|---|
lebrel/deepseek-v4.1-flash-uncensored | 1,048,544 | yes | none, max (Lebrel's thinking switch) |
deepseek/deepseek-v4-pro | 1,048,576 | no | none, low, high, max |
deepseek/deepseek-v4.1-flash | 1,048,576 | yes | none, low, high, max |
moonshotai/kimi-k3 | 1,048,576 | yes | low, high, max (always reasons) |
moonshotai/kimi-k3.1-pro | 1,048,576 | yes | low, high, max (always reasons) |
qwen/qwen3.8-flash | 1,000,000 | yes | none, high (on/off switch) |
qwen/qwen3.8-max | 1,000,000 | yes | low, medium, xhigh (always reasons) |
qwen/qwen4-max | 1,000,000 | yes | none, low, high, xhigh |
z-ai/glm-5.3 | 1,048,576 | no | low, high, max (always reasons) |
z-ai/glm-5.3-flash | 1,048,576 | no | low, high, max (always reasons) |
A level a model lacks is lowered to the nearest one below it (never raised).
none on a model that always reasons asks for its lowest level.
Disclosure
- Network calls:
GET https://attested.lebrel.ai/v1/models, made by this plugin without
the API key or any other credential, to fill the/modelpicker.POST https://attested.lebrel.ai/v1/chat/completions(or under the URL in
LEBREL_BASE_URL), made by Hermes's own client: it sends your prompts, tool
schemas and tool results for inference. Lebrel's edition runs on Lebrel's
own GPUs. The other models are relayed by Lebrel's router to their lab or
cloud, which sees the request; each model'sdata_notein the public
catalog names where it goes.
- Credentials:
LEBREL_API_KEYis resolved by Hermes through the active
profile's secret scope, from the provider's declaredenv_vars. The plugin
never reads it, nor.envfiles,auth.jsonor any other credential store,
and never sends it on the catalog request. Hermes sends it only as an
Authorization: Bearerheader to the inference endpoint. - Scope: registers one model provider at import and nothing else: no tools,
hooks, middleware, commands, background threads, subprocesses, file access,
telemetry or self-updating code. No third-party Python dependencies.
Development
Offline unit tests (standard library only):
python3 -m unittest discover -s tests -v
The same suite plus the integration tests, inside the Hermes you have
installed (they install the plugin into a throwaway HERMES_HOME):
HERMES_PY=$(hermes --print-runtime-command | python3 -c 'import json, sys; print(json.load(sys.stdin)[0])')
HERMES_SRC=$(hermes --version | sed -n 's/^Install directory: //p')
HERMES_HOME=$(mktemp -d) "$HERMES_PY" -I -c "import sys; sys.path[:0] = ['$HERMES_SRC', '.']; import hermes_bootstrap, unittest; unittest.main(module=None, argv=['unittest', 'discover', '-s', 'tests', '-v'])"
Check the plugin as the catalog does: hermes plugins validate --install-deps .
License: MIT
README from the reviewed commit 177c8e6; it updates when the author re-pins.

LEBREL-AI