The Lexicon
stop_reason
The machine-readable label on every API reply saying why the model stopped. Your loop should be driven by this label, never by reading the model's prose or counting turns.
Agents & Orchestration
The Lexicon
The machine-readable label on every API reply saying why the model stopped. Your loop should be driven by this label, never by reading the model's prose or counting turns.