Chat Completions
The OpenAI-style chat completion endpoint, request parameters, and response shape
POST /v1/chat/completions is the OpenAI-style chat endpoint. It accepts the official openai SDK unchanged.
Request
Authenticate with Authorization: Bearer sk-ablatic-....
cURL
curl https://api.ablatic.ai/v1/chat/completions \
-H "Authorization: Bearer $ABLATIC_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "talos",
"messages": [{ "role": "user", "content": "Hello" }]
}'Parameters
| Name | Type | Required | Description |
|---|---|---|---|
model | string | no | Model id. Default talos. See Models |
messages | array | yes | Conversation messages, 1 to 2000 |
stream | boolean | no | Stream tokens over SSE, ending with data: [DONE] |
temperature | number | no | Sampling temperature, 0 to 2 |
max_tokens | integer | no | Max output tokens, 1 to 200000 |
top_p | number | no | Nucleus sampling cutoff |
tools | array | no | Tool definitions. Uses function.parameters |
tool_choice | string or object | no | Tool selection policy |
response_format | object | no | One of text, json_object, json_schema |
reasoning_effort | string | no | Reasoning depth. none/minimal to fast, low to brief thinking, medium (default) to thinking, high/xhigh/max to thinking with a larger reasoning-token budget |
max_reasoning_tokens | integer | no | Cap on reasoning tokens, 0 to 200000 |
session_id | string | no | Group requests into a session |
glassbox | object | no | Opt in to Glassbox trace and confidence |
refusal_mode | string | no | One of soft, strict |
The mode and depth are set by reasoning_effort. When you omit it, it defaults to medium (thinking). For the lowest latency send reasoning_effort of none; for the shortest reasoning while still thinking, send low. See Reasoning modes. When streaming, the reasoning trace arrives in delta.reasoning_content, separate from delta.content.
Response
The response is a chat.completion object.
{
"id": "chatcmpl-...",
"object": "chat.completion",
"created": 1744761600,
"model": "talos-thinking",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "Hello. How can I help?"
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 9,
"completion_tokens": 7,
"total_tokens": 16,
"reasoning_tokens": 0
}
}The response model field echoes the resolved mode as talos-<mode>. usage carries prompt_tokens, completion_tokens, total_tokens, and reasoning_tokens when reasoning ran. reasoning_tokens counts tokens that are already part of completion_tokens, so never add the two together.
finish_reason
| Value | Meaning |
|---|---|
stop | The model completed its answer |
length | Output hit max_tokens, or the model spent its whole budget reasoning without answering |
tool_calls | The model called one or more tools. See Function calling |
low_confidence | Glassbox only. Confidence fell below the threshold you set |
abstained | Glassbox only. Confidence fell below the hard cutoff |
Extension fields
These non-standard fields appear alongside the standard object.
| Field | Description |
|---|---|
talos_trace | Glassbox trace object. Present only when you opt into Glassbox, omitted otherwise |
talos_complexity | Complexity signal object. Always present |
session_id | Echoes the session_id you sent. Present only when you sent one |
Glassbox and confidence are opt-in and off by default. When off, talos_trace.confidence is null. Do not rely on live confidence scores.
The response carries an X-Request-Id header. Quote it in support tickets.