From the archive
OpenAI adds Structure Outputs, a feature to ensure model-generated outputs match JSON Schemas, to its API and offers lower pricing for new GPT-4o model versions
We are introducing Structured Outputs in the API—model outputs now reliably adhere to developer-supplied JSON Schemas.
Context & ripple effects
OpenAI had already moved its developer platform toward more programmatic model use through function calling and the broader general availability of the GPT-4 API. Schema-constrained responses extend that path by making model output easier for software, rather than a human, to consume.
The change also precedes GPT-4o fine-tuning for domain-specific customization, pairing control over a model’s output format with later control over its behavior. Lower-priced GPT-4o versions make that more operationally viable for API builders.
First-order effects
- Developers can request JSON Schema-conformant responses, reducing the parsing, validation, and retry work required to place model results into structured application workflows.
- Lower pricing for new GPT-4o versions directly improves the economics for customers running those API models, especially where structured responses are generated repeatedly.
Second-order effects
- Application teams can shift more workflows from free-form text handling to schema-defined integrations, raising the value of reliable extraction, tool orchestration, and downstream automation.
- Competing model APIs face pressure to combine output reliability with lower inference costs; price comparisons increasingly hinge on the cost of a usable, machine-actionable result rather than raw generation alone.
Third-order effects
- If schema adherence becomes standard across leading APIs, the differentiator shifts from merely producing fluent text to providing a dependable runtime for software operations, with evaluation centered on failure rates and integration overhead.
- This points toward AI procurement organized around cost per completed task: cheaper tokens matter, but durable adoption depends on whether outputs can safely enter existing systems with minimal human cleanup.
The trend: Generative-AI APIs are evolving from text-generation endpoints into governed, cost-optimized components for production software workflows.
Related: Operational AI assurance · AI cost per useful task · JSON Schemas · OpenAI GPT-4 API general availability · OpenAI GPT-4o fine-tuning
Related coverage
- OpenAI cuts GPT-4o prices, launches Structured Outputs amidst price war with Google
- View article
- OpenAI cures structured data headache for developers
- OpenAI Enhances API with Structured Outputs for Developers
- OpenAI launches Structured Outputs and announces DevDay events
More related coverage
- OpenAI: Introducing Structured Outputs in the API. OpenAI have offered structured outputs …
- OpenAI responds to ‘very popular demand’ with launch of key LLM safety feature for developers
- OpenAI Launches Structured Outputs, Slashes Prices for GPT-4o
- OpenAI has finally released the No. 1 feature developers have been desperate for
- Been waiting for this one for a while. Coercing models to give you structured outputs via function calls / reflection always felt a bit hacky …
- We are introducing Structured Outputs in the API—model outputs now reliably adhere to developer-supplied JSON Schemas. …
- @OpenAI releases structured outputs for their API, giving developers tight control over JSON responses during function calling and regular calls. …
- Structured Outputs in the API
- Introducing Structured Outputs in the API
Discussion
Am I the only one not excited about structured outputs? I was super bullish on them 6 months to a year ago, but have since found 1) it tends to degrade overall token quality in non-obvious ways, and 2) these days you can achieve perfect JSON output following with prompting alone…
Our newest GPT-4o model is 50% cheaper for input tokens and 33% cheaper for output tokens. It also supports Structured Outputs, which ensures model outputs exactly match your JSON Schemas. [image]
Introducing Structured Outputs! A huge leap beyond JSON mode, solving a major challenge for developers. If your app relies on a specific JSON format to drive the UI, our models now match your schema—every time. No more missing keys or hallucinated enums! https://openai.com/...
More discussion
New GPT4o pricing is now 50% cheaper on inputs and 33% cheaper on outputs!
This is especially notable because GPT-4o-mini is priced the SAME for image inputs as regular GPT-4o - so I think this released-today “gpt-4o-2024-08-06” model is now OpenAI's cheapest model for image inputs by quite a wide margin
excited to announce Structured Outputs — our newest feature in the api. model outputs will now reliably follow your exact json schemas, matching the parameters and types accurately. schema reliability is now 100% with this feature enabled, up from 86% on our past gpt-4o model
On one hand, OpenAI just made it so that its models can be forced to output in JSON, which makes it much easier for developers to use LLMs in their programs. On the other hand, forcing LLMs to answer in JSON lowers their reasoning ability (but helps classification)
holy shit @minimaxir chain of thought as structured output is an officially recommended pattern i need to rewrite -everything- to use this [image]
Structured output from OpenAI is a super underrated technical launch. It's finally going to enable consistent dynamic UIs. To demo it, I used JSON Forms to build a little app where you describe a form that renders in ~3s — sign in, airline booking, hospital and legal intake! [vid…
big deal, that. We've used structured outputs in our llm usage very successfully over the last year
I've been collecting all sorts of extra information about the new OpenAI structured outputs feature throughout the day I think my post here may now be the definitive guide to details you may have missed https://simonwillison.net/...
Hidden at the bottom of this announcement: “By switching to the new gpt-4o-2024-08-06, developers save 50% on inputs ($2.50/1M input tokens) and 33% on outputs ($10.00/1M output tokens) compared to gpt-4o-2024-05-13.” That's a pretty substantial price decrease!
They solved instructor. We need a new mode again.
Confirmation from OpenAI's Jeff Harris that image input is indeed half price now, and the calculator needs to be updated https://news.ycombinator.com/ ...
by very popular demand, structured outputs in the API: https://openai.com/...
OpenAI: Introducing Structured Outputs in the API
Did OpenAI just kill llama.cpp's GBNF grammars (used for guaranteed structured outputs) without acknowledging that their idea came from open-source? …