How AgentOven does it
Agents with agentic behavior run this loop in the Executor until the model returns a final answer or max_turns is reached (10 by default, configurable per agent). Recipe steps can loop as well, with a loop condition and a maximum number of iterations.
max_turnsAgentic behaviorLoop conditions