A CLIProxyAPI native plugin (C ABI v1) that adds
AbliteratedLLM as an API-key provider with the id abliteratedllm.
AbliteratedLLM is a pay-per-token, OpenAI- and Anthropic-compatible API for abliterated
(refusal-removed) and stock open-weight models. This plugin is maintained by the people who run
AbliteratedLLM.
-
API-key credentials. Add a key through the interactive login page, or upload a credential file:
{"type": "abliteratedllm", "api_key": "sk-..."}Keys are created at https://abliteratedllm.dev/dashboard/keys.
-
Live model catalog.
model.for_authreads the publicGET /v1/modelslist, including context length, output limit and input modalities. There is no built-in fallback list. -
Chat Completions execution. Requests go to
POST /v1/chat/completions, streaming and non-streaming. The executor accepts theopenaiformat; CLIProxyAPI translates Claude, Gemini and Responses clients into it.
From the CLIProxyAPI plugin store, or download abliteratedllm_<version>_<os>_<arch>.zip from
Releases and verify it against
checksums.txt. Releases cover darwin, linux and windows on amd64 and arm64.
plugins:
enabled: true
configs:
abliteratedllm:
enabled: true
priority: 10
# Optional settings, shown with their defaults:
base_url: "https://api.abliteratedllm.dev/v1"
public_url: ""
default_reasoning_effort: "low"| Setting | Meaning |
|---|---|
base_url |
OpenAI-compatible base URL. The plugin appends /chat/completions, /models and /balance. It must be https; plain http is accepted only for a loopback host. |
public_url |
Origin used in the login page link, for example https://cpa.example.com. When empty, the link uses the local listener address that CLIProxyAPI passes to the plugin (http://127.0.0.1:<port>). Set it when you open the management panel from another machine. |
default_reasoning_effort |
reasoning_effort sent when a request sets none: low, medium, high, xhigh or max. |
- Start the AbliteratedLLM login from the CLIProxyAPI management panel. CLIProxyAPI opens
/v0/resource/plugins/abliteratedllm/login?state=.... - Paste the API key and submit. The page posts the key to the authenticated route
POST /v0/management/plugins/abliteratedllm/login. It uses the management key saved by the CLIProxyAPI panel on the same origin when it can read it, and otherwise asks for it. - The plugin checks the key format and calls
GET /v1/balancewith it. That call runs no model and costs nothing. A rejected key is reported on the page and is not stored. - The panel's login poll receives the new credential, and CLIProxyAPI saves it in its auth store.
- The key is kept only in the credential's storage JSON, which CLIProxyAPI persists in its own auth store. The plugin writes no files.
- The auth label, file name and metadata carry only a 12-character SHA-256 fingerprint of the key,
never the key or a masked form of it. The attributes carry only the credential kind (
apikey). - The plugin never logs. Error messages never include the key.
- The key is sent only to
base_url, in theAuthorization: Bearerheader, never in a URL.executor.http_requestrefuses any URL outsidebase_url. The model catalog request carries no key. auth.parseclaims only files whosetypeisabliteratedllm. It refuses a file that also names a differentprovider, and it does not read other providers' credentials.- A key submitted on the login page is held in memory until the next login poll, at most 15 minutes. The login state is 256 random bits.
- The page under
/v0/resource/plugins/abliteratedllm/loginis static and identical for every request. The CLIProxyAPI management key is used only for this plugin's/v0/management/...route.
Every AbliteratedLLM model is a reasoning model. The plugin publishes low, medium, high,
xhigh and max as each model's reasoning levels, so CLIProxyAPI validates and maps client settings
(model suffixes such as glm-5.3(high), Claude thinking budgets, Responses reasoning.effort) before
a request reaches the plugin. A request that turns reasoning off is sent with the lowest level,
because GLM models reject none. minimal is not advertised because glm-5.3-flash-abliterated
rejects it. When a request sets no level, the plugin sends default_reasoning_effort (low).
The executor sends the client's Chat Completions body with these changes:
modelandstreamare set from the routed request.- Streaming requests get
stream_options.include_usage: true;stream_optionsis removed otherwise. - When both
max_tokensandmax_completion_tokensare present, onlymax_completion_tokensis kept. The API accepts either one but not both. storeis removed, anddevelopermessages are sent with thesystemrole.
Upstream errors keep their HTTP status. 400, 413 and 422 are marked request-scoped (no credential
cooldown), 404 cools only the requested model, and 429 carries Retry-After as a short per-model
cooldown.
Not implemented: token counting (executor.count_tokens returns 501), quota reporting, and the
native /v1/responses and /v1/messages endpoints.
Requires Go 1.26.10 or later and a C toolchain, because the plugin is a -buildmode=c-shared
library.
go vet ./...
go test -race ./...
CGO_ENABLED=1 go build -trimpath -buildvcs=false -buildmode=c-shared -o build/abliteratedllm.so .
cc -o build/abi_test tests/abi_test.c -ldl && ./build/abi_test build/abliteratedllm.soThe unit tests need no C compiler: CGO_ENABLED=0 go test ./... leaves out the C ABI glue in
abi.go. tests/abi_test.c loads a built library (with dlopen or LoadLibrary) and calls it
through the C ABI.
.github/workflows/build.yml builds all six libraries on native
runners: zig (ziglang from PyPI) for Linux, with a glibc 2.28 baseline, and for Windows; Apple clang
for macOS. On a v* tag it packages abliteratedllm_<version>_<os>_<arch>.zip (the library at the
zip root) with a sha256 checksums.txt and publishes a GitHub release. The tag must match
pluginVersion in plugin.go.
MIT