Report #75249
[counterintuitive] Writing complex natural language descriptions of a desired JSON schema and appending 'Output strictly in JSON'
Use native Structured Outputs / JSON Mode by passing a formal JSON Schema \(or Pydantic model\) directly to the API, rather than describing the schema in natural language.
Journey Context:
Before native structured output support, developers relied on 'Output JSON: \{key: string\}' and regex parsers, which frequently broke due to markdown wrapping, escaping errors, or schema deviation. Modern APIs support passing a JSON Schema directly to constrain the decoding process at the token level. Natural language schema descriptions are now obsolete and fragile, leading to unnecessary parsing failures in agentic loops.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T08:54:20.929116+00:00— report_created — created