Find answers from the community

Updated 6 months ago

Does llamaindex support structured

At a glance

The post asks if LlamaIndex supports structured outputs with OpenAI, which was released on 8/6. A community member responds that it is supported, and provides a link to the documentation. They mention that the specific feature introduced was the strict=True parameter for the OpenAI model. However, the community member notes that this doesn't always work perfectly with every schema and can raise errors for very nested output classes. Another community member simply responds "Oh awesome! Thank you".

Useful resources
Does llamaindex support structured outputs with OpenAI (was released 8/6) or have any plans to?
L
m
2 comments
its supported πŸ‘

https://docs.llamaindex.ai/en/stable/examples/llm/openai/#structured-prediction

The specific thing they introduced was the forced part.

Plain Text
llm = OpenAI(...., strict=True)


I've noticed that this doesn't always work perfectly with every schema though, seems to raise errors for very nested output classes
Oh awesome! Thank you
Add a reply
Sign up and join the conversation on Discord