When an LLM response stops with reason “length”, streamed tool-call arguments are finalized by a best-effort JSON salvage parser: they may parse and validate yet be silently incomplete. Pi’s loop refuses to execute any tool call from such a message, failing the whole batch with an error that asks the model to re-issue complete calls. Executing truncated arguments risks running malformed operations; failing them costs one extra turn.
Related: