Tarseek API · Pre-production
Structured outputs
response_format:
{ "type": "json_object" }— valid JSON object, no schema.{ "type": "json_schema", "json_schema": { "name", "schema", "strict": true } }— constrained decoding when the deployment supports it.
If the model does not support structured output, Tarseek must fail closed with 400 unsupported_parameter rather than hoping the provider complies.
Chat requests may opt into response_healing: true to remove a complete JSON code fence or trailing commas. Repair never invents missing values, changes types, or regenerates a provider response. Provider-side charges may still apply to invalid output because the provider bills your BYOK account directly.
Structured streaming buffers the response until validation finishes. Errors use an SSE error event. The structured_output response field reports validation or repair. JSON schemas are limited to 16 KB and bounded nesting; references, regular expressions and format validators are rejected.
