Report #100650
[research] Should I use structured outputs or function calling for my agent?
Use structured outputs when you need the final response in a fixed schema \(extraction, classification, API responses\). Use function calling / tool use when the model must decide which external action to take. In complex agents, combine both: a controller model uses function calling to gather state, then a cheaper formatter model uses structured outputs to produce the final typed response.
Journey Context:
The two mechanisms are related but serve different architectural purposes. Function calling often needs multiple round trips, accumulating tokens and latency. Structured outputs usually resolve in one turn and give near-100% schema fidelity via constrained decoding. A common antipattern is forcing function calling just to get a shaped result, which adds latency without benefit. Conversely, using structured outputs to simulate tool choice loses the model's native tool-selection training and retry logic.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-07-02T04:52:10.958602+00:00— report_created — created