CARD NEWS · Prompts & AI use

Structured Output · 4 cards

Four cards for social posts, teaching materials and presentations. Capture the screen or print to a PDF.

1/4
Prompts & AI use

Structured Output

Structured output is a way of making a large language model (LLM) answer in a format defined in advance by a schema, usually JSON Schema, so that downstream code can parse and check the answer safely. Major model APIs implement it with constrained decoding: while the model generates, tokens that would break the schema are blocked.[1][2] Developers can often write the schema as a code type, such as a Pydantic or Zod model, and let the SDK convert it.[1][9]

2/4
In simple terms

An easy way to understand

Normally an LLM answers in free-form text. With structured output, you hand the API a form, a schema that lists the fields, their types and the allowed values, and the model must fill in that form instead of writing prose.

3/4
Where it is used

Who uses it, and when?

Case 1: OpenAI launch — Action items from meeting notes On August 6, 2024, OpenAI launched Structured Outputs in its API.

4/4
Learn more

ai.rookienote.com
/en/term/structured-output

RookieNote
← Read the full entry

Capture these cards or print them to a PDF.