Ecosystem & Emerging Terms

Structured Outputs

Also called: JSON mode · schema-constrained output · constrained decoding

Structured outputs are a model feature that forces a response to follow a declared schema, such as a JSON object with specific fields, so software can read it without fragile parsing.

Language models produce free text, but programs need data they can rely on. Early on, developers asked the model to "respond in JSON" and hoped for the best, then wrote code to catch malformed replies. Structured outputs move that guarantee into the model provider's stack: you supply a schema, and the response is constrained to match it.

Many major providers offer some form of this, under names such as structured outputs or JSON mode, and the same idea underlies function-tool-calling, where a tool call's arguments must fit a declared shape. The exact features and coverage of schemas vary by provider and change, so check current documentation.

The important limit is what it guarantees. A schema-valid response has the right fields and types; it does not mean the values are true or the choice is right.

How it works

The common mechanism is constrained decoding: while the model generates tokens, the system masks out any token that would make the output invalid under the schema, so the finished output always parses. Other approaches validate afterwards and retry on failure. Either way the model still generates the values token by token, so the content can be wrong even when the format is perfect.

How it differs

Structured outputs vs. decision models like jev: with structured outputs an LLM still generates the answer as text that happens to fit a schema, one token after another. A decision model returns a value chosen from options you declare, in one parallel pass, with a probability, and cannot produce anything else. Structured outputs are general and can carry free text inside fields; a decision model is narrower, faster and calibrated but cannot write.

Common misconceptions

Often assumed: Valid JSON means a correct answer.
Actually: A schema guarantees the shape only. The model can still fill a valid field with a wrong or made-up value (see hallucination).

FAQ

What are structured outputs in an LLM?
A feature that constrains the model's response to a schema you declare, such as JSON with given fields, so code can consume it reliably.
Does structured output stop hallucinations?
No. It guarantees the format is valid, not that the contents are true.
What is the difference between structured outputs and function calling?
They rest on the same idea. Function calling applies a schema to a tool call's arguments so software can run a tool; structured outputs apply a schema to the model's reply itself.

Last checked: 2026-09-21

Related terms