All capabilities Building software
Constrain JSON output with a schema
Use provider-supported strict schema output, then handle refusals and incomplete responses before accepting the values.
DocsOfficially documentedTestNot tested by benchr
OpenAI APIGPT-5.6 SolGPT-5.5GPT-5
Overview
- Constrain completed structured responses to supported schema rules.
- Separate response shape from checks on factual meaning and application requirements.
- Expose refusal and incomplete-response paths at the integration boundary.
How it works
- 01Define a supported schema and keep the application type definition in sync with it.
- 02Choose an explicitly supported model and the correct schema field for your API surface.
- 03Check refusal, incomplete and error states before consuming a parsed object.
- 04Validate business rules and important values; schema adherence does not establish factual accuracy.
Limits
- Only the documented JSON Schema subset is supported.
- Refusals and token-limit truncation can leave no usable object.
- Unrelated input can still produce invented values that fit the schema.
- A well-formed object can contain incorrect values; retain application-level checks.
Verification
benchr test runs
benchr has not run this capability. No test has been published.
Evidence
Sources
- OpenAI - Structured Outputs: the adherence guarantee and its documented edges Tier 1 · October 15, 2026
Not stated by the source
- Whether schema-constrained decoding changes answer quality on a given task
- Any latency overhead figure for schema enforcement
Source-check history
- October 15, 2026DocsOfficially documentedRe-read the structured-output guide. Removed unconditional completion and correctness claims; preserved the separate unverified execution status.
- September 1, 2026DocsOfficially documentedFirst logged. The adherence guarantee, the GPT-4o support floor, the gpt-5.6 recommendation and the three escape hatches were read from the guide.
Changes
Provider changes affecting this
- August 21, 2026GPT-5.6 SolPricing changed
- July 9, 2026GPT-5.6 SolAPI changed
- July 9, 2026GPT-5.6Model released
- April 23, 2026GPT-5.5Model released