You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add a constrained-decoding API so applications can request structured extraction/classification results with machine-checkable output. The reviewed sampling and request APIs do not expose a JSON/schema constraint.
Scope and acceptance criteria
Start with a documented JSON grammar and a deliberately bounded JSON Schema subset; explicitly reject unsupported schema features.
Apply an incremental token constraint before sampling; handle tokens containing partial UTF-8 sequences and multiple grammar characters.
Expose the feature in core generation, browser bindings/SDK, and the server request API with consistent semantics.
Permit EOS only at valid completion points and surface unsatisfiable constraints as a clear error.
Distinguish complete valid output from cancellation or token-budget exhaustion; never label truncated JSON as schema-valid.
Ensure greedy, sampled, streaming, and batch paths use the same constraints; define or disable incompatible speculative paths.
Test escaping, Unicode, nesting, enums, required fields, arrays, invalid schemas, and impossible constraints.
Add an extraction/classification example and benchmark constraint overhead.
Initial delivery should document its supported subset instead of claiming full JSON Schema compatibility. Valid JSON/schema conformance does not guarantee factual extraction accuracy.
Suggested priority: P2 — application-facing capability.
Add a constrained-decoding API so applications can request structured extraction/classification results with machine-checkable output. The reviewed sampling and request APIs do not expose a JSON/schema constraint.
Scope and acceptance criteria
Initial delivery should document its supported subset instead of claiming full JSON Schema compatibility. Valid JSON/schema conformance does not guarantee factual extraction accuracy.
Implementation starting points: sampling, generation, server requests, browser bindings.