API reference
Reasoning
Control how much Abliterator's models think with reasoning_effort or Anthropic thinking settings, read the reasoning output, and budget max_tokens for reasoning.
Both models reason by default: deepseek-v4.1-flash-abliterated at high effort, kimi-k3.1-pro-abliterated at max. Set reasoning_effort from none to max. Reasoning comes back in reasoning_content (or thinking blocks), is billed as output, and counts toward max_tokens.
reasoning_effort values
Send reasoning_effort in a Chat Completions request. Abliterator passes it to the model unchanged, and the serving engine maps it to each model's levels:
| Value | deepseek-v4.1-flash-abliterated | kimi-k3.1-pro-abliterated |
|---|---|---|
none |
Reasoning off | Reasoning off |
minimal |
Same as low |
Same as low |
low |
Low | Low |
medium |
Medium | Medium |
high |
High (the default) | High |
xhigh |
Same as high |
Same as max |
max |
Maximum | Maximum (the default) |
| Omitted | high |
max |
Higher effort usually improves hard reasoning, math and multi-step agent work, at the cost of more output tokens and a longer wait before the answer. For classification, extraction, short chat and most data generation, none or low is faster and much cheaper.
import os
from openai import OpenAI
client = OpenAI(base_url="https://abliterator.ai/v1", api_key=os.environ["ABL_API_KEY"])
response = client.chat.completions.create(
model="deepseek-v4.1-flash-abliterated",
max_tokens=1024,
reasoning_effort="none",
messages=[{"role": "user", "content": "Label as SQLi, XSS or benign: GET /search?q=%3Cscript%3Ealert(1)%3C/script%3E"}],
)
print(response.choices[0].message.content)
Reading the reasoning
- Chat Completions:
choices[0].message.reasoning_contentholds the reasoning;contentholds the answer. In a stream, reasoning arrives indelta.reasoning_contentbefore the content. - Messages API: reasoning comes as
thinkingcontent blocks before thetextblocks, and asthinking_deltaevents in a stream.
The reasoning is the model's working, not a vetted explanation. Do not show it to end users as fact, and do not parse it for answers. With reasoning off, reasoning_content is absent or empty.
import os
from openai import OpenAI
client = OpenAI(base_url="https://abliterator.ai/v1", api_key=os.environ["ABL_API_KEY"])
response = client.chat.completions.create(
model="kimi-k3.1-pro-abliterated",
max_tokens=16384,
reasoning_effort="medium",
messages=[{"role": "user", "content": "A web app stores session IDs in localStorage. Walk through the attack surface and rank the risks."}],
)
message = response.choices[0].message
print("reasoning:", (getattr(message, "reasoning_content", None) or "")[:500], "...")
print("answer:", message.content)
print("output tokens billed:", response.usage.completion_tokens)
Anthropic Messages format
| Setting | Effect |
|---|---|
"thinking": {"type": "disabled"} |
Reasoning off (same as none) |
"thinking": {"type": "enabled"} or {"type": "adaptive"} |
Reasoning on at the model's default effort |
"output_config": {"effort": "low"} |
Sets the level, with the values in the table above |
budget_tokens in the thinking object is accepted but does not cap or set the reasoning level; use output_config.effort and max_tokens. Example:
import os
import anthropic
client = anthropic.Anthropic(base_url="https://abliterator.ai", api_key=os.environ["ABL_API_KEY"])
message = client.messages.create(
model="kimi-k3.1-pro-abliterated",
max_tokens=16384,
messages=[{"role": "user", "content": "Review this nginx config line for security issues: autoindex on;"}],
extra_body={"output_config": {"effort": "high"}},
)
for block in message.content:
if block.type == "thinking":
print("thinking:", block.thinking[:300], "...")
elif block.type == "text":
print(block.text)
Budget max_tokens for reasoning
Reasoning tokens count toward max_tokens. If reasoning uses the whole budget, the response ends with finish_reason: "length" and empty or partial content.
- Leave headroom: a few thousand tokens for
lowandmedium, 16,384 or more forhighandmaxon hard problems. - If you see
lengthwith no content, raisemax_tokensor lowerreasoning_effort. - The playground uses 2,048 output tokens with reasoning off, 4,096 at
lowand 8,192 atmediumandhigh. These are reasonable starting points for chat.
Larger max_tokens also means Abliterator reserves more credit while the request runs; see usage and billing.
Billing
Reasoning tokens are billed as output at the model's output price. Abliterator bills completion_tokens from the usage report, or total_tokens - prompt_tokens when that is larger, so reasoning reported outside completion_tokens is still counted. To cut cost, lower the effort, not just the visible answer length.
Sampling and tool_choice on kimi-k3.1-pro-abliterated
Kimi's sampling is fixed (temperature 0.6, top_p 0.95); Abliterator ignores temperature, top_p and penalty settings for it, so tool defaults are safe. A named function in tool_choice is rejected while reasoning is on, so send reasoning_effort: "none" with it; see tool calling. deepseek-v4.1-flash-abliterated accepts your sampling settings and has no tool_choice restriction. See models.
Refusals with reasoning on
Reasoning does not bring refusals back. On DeepSeek V4.1 Flash Abliterated with thinking on, refusals of harmful prompts among finished answers went from 96.7% on the original to 0%. Reasoning scores held: GPQA Diamond 92.1 to 92.3 and AIME 2025 96.3 to 96.7, both within noise. On Kimi K3.1 Pro Abliterated with thinking on, JailbreakBench harmful refusals went from 90% to 0%, and GPQA Diamond went from 93.1 to 92.8, within noise. See /benchmarks.
Frequently asked questions
Does Abliterator change my reasoning_effort value?
No. The gateway forwards reasoning_effort unchanged. The serving engine maps it to each model's native levels, as the table on this page shows.
Is reasoning text billed?
Yes. Reasoning tokens are output tokens, billed at the model's output price, whether or not you display them.