ML Intern: don't end a turn before its plan's steps have started (#2753)
* ML Intern: don't end a turn before its plan's steps have started
A round with no tool calls is final, so when GLM-class models reason
about Qwen's <think></think> switch, the literal tags end their reasoning
at the provider and the leftover half-thought finalizes the turn after
step one. Retry once when an answer ends the turn while a step of this
turn's plan was never started, naming the open steps.
Also stop telling a think-only round in a tool loop to give its final
answer; tell it to continue with its next tool call instead.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* Skip the plan retry without the plan tool or after an output-limit recovery
Let the nudge leave a step pending while it waits on the user.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>