Comment by guntars
With function calls the model may or may not output something that matches the schema, with structured output the schema is enforced at the logit level.
With function calls the model may or may not output something that matches the schema, with structured output the schema is enforced at the logit level.
At least in the case of openai, you can set "strict" to "true" and function calling / tool use must / is enforced to follow the schema too.