Coding agents
OpenCode
Add Abliterator as an OpenAI-compatible custom provider in OpenCode's config, select Kimi K3.1 Pro or DeepSeek V4.1 Flash Abliterated, and fix common setup errors.
Add an Abliterator entry under providers in opencode.jsonc with the openai-compatible package, baseURL https://abliterator.ai/v1, env ABL_API_KEY and both model IDs. Then pick abliterator/kimi-k3.1-pro-abliterated with /models.
Add Abliterator as a provider
OpenCode's provider docs describe custom OpenAI-compatible providers under a top-level providers object. Add this to your OpenCode config file, opencode.jsonc (OpenCode accepts comments and trailing commas in it):
{
"$schema": "https://opencode.ai/config.json",
"model": "abliterator/kimi-k3.1-pro-abliterated",
"providers": {
"abliterator": {
"name": "abliterator",
"env": ["ABL_API_KEY"],
"package": "@opencode/ai/providers/openai-compatible",
"settings": {
"baseURL": "https://abliterator.ai/v1",
},
"models": {
"kimi-k3.1-pro-abliterated": {
"name": "Kimi K3.1 Pro Abliterated",
"capabilities": { "tools": true, "input": ["text", "image"], "output": ["text"] },
"limit": { "context": 1048576, "output": 262144 },
"compatibility": { "reasoningField": "reasoning_content" },
},
"deepseek-v4.1-flash-abliterated": {
"name": "DeepSeek V4.1 Flash Abliterated",
"capabilities": { "tools": true, "input": ["text", "image"], "output": ["text"] },
"limit": { "context": 1048576, "output": 393216 },
"compatibility": { "reasoningField": "reasoning_content" },
},
},
},
},
}
What the fields do, per OpenCode's providers and models pages:
| Field | Purpose |
|---|---|
providers.abliterator |
The provider ID. Models are referenced as abliterator/<model> |
env |
Environment variables OpenCode reads the credential from |
package |
The runtime for APIs that use the OpenAI Chat Completions format |
settings.baseURL |
Abliterator's base URL, with /v1 and without /chat/completions |
models |
Map keys are the model IDs sent to Abliterator |
capabilities |
Tool support and input types. Without it, OpenCode assumes tools and text plus image input |
limit |
Without it, OpenCode assumes a 200,000-token context and 32,000-token output |
compatibility.reasoningField |
Abliterator returns reasoning in reasoning_content; this tells OpenCode where to read it and how to send it back |
model |
The default model at startup |
Use the plain openai-compatible package, not openai-compatible/responses: Abliterator does not serve the Responses API.
Set the key and select a model
export ABL_API_KEY="sk-abl-v1-..."
opencode
Inside OpenCode, run /models and choose abliterator/kimi-k3.1-pro-abliterated or abliterator/deepseek-v4.1-flash-abliterated. You can also run /connect, pick the Abliterator provider and paste the key instead of exporting it.
Verify
Ask a question about your repository, such as "What does the main entry point of this project do?" OpenCode should read files and answer. Check that the requests reached Abliterator:
curl -s https://abliterator.ai/api/v1/activity -H "Authorization: Bearer $ABL_API_KEY" | head -c 600
Choosing the model
Use abliterator/kimi-k3.1-pro-abliterated as the main coding model and abliterator/deepseek-v4.1-flash-abliterated for quick questions or for agents you define for small tasks. Before you make kimi-k3.1-pro-abliterated your main coding model, test it on your own tasks: its Terminal-Bench 4.0 score fell from 68.8 to 56.3 after abliteration, a drop that is plausible but not statistically shown (benchmarks). Long sessions resend most of their context each turn; Abliterator caches that prefix automatically and bills it at the cached price. See prompt caching.
Troubleshooting
| Symptom | Cause | Fix |
|---|---|---|
Model unavailable: abliterator/... |
The model reference does not match a models key |
Use the exact keys, kimi-k3.1-pro-abliterated and deepseek-v4.1-flash-abliterated |
No model is available for session |
No default model and none picked | Set "model" in the config, or pick one with /models |
401 from Abliterator |
ABL_API_KEY is not set in the environment OpenCode runs in |
Export it before starting OpenCode, or use /connect. If OpenCode runs as a background service, set the variable for that service |
404 Not found. |
baseURL is missing /v1 or includes /chat/completions |
Set baseURL to https://abliterator.ai/v1 |
| Answers stop early with long reasoning | limit.output is low, or a per-request limit is |
Keep the limit values above |
429 Too many requests in flight |
Parallel subagents exceed your plan's concurrency | Fewer parallel agents, or more concurrency |
OpenCode's config format has changed between major versions. If your installed version rejects the providers key, check the providers page of the OpenCode docs for your version.