MemotivaPrompt Engineering Patterns: Structured Outputs, JSON Mode, Function Calling, Schema Validation

What is JSON mode and how is it different from structured outputs?

Nortren·

What is JSON mode and how is it different from structured outputs?

0:20

JSON mode is an older feature that guarantees the output is valid JSON, but does not enforce a specific schema. Structured outputs are newer and stricter: they enforce both valid JSON and conformance to a specific schema you define. Always prefer structured outputs over plain JSON mode when supported, because they eliminate parsing errors and schema mismatches.
platform.openai.com