Skip to main content

2 docs tagged with "structured-output"

View all tags

Structured Extraction

Turn a pile of unstructured documents into validated records — structured output run in a batch loop, with a place to put the ones that don't validate.

Structured Output

withstructuredoutput wraps a chat model so it returns a validated Pydantic object instead of prose you then have to parse. The provider enforces the schema at generation time (constrained decoding or native tool-calling), which is far more reliable than parsing free-form output after the fact.