diff --git a/src/common/AutoModel/modeling_qwen3_5_omni.cpp b/src/common/AutoModel/modeling_qwen3_5_omni.cpp index 28695786..682fcaa0 100644 --- a/src/common/AutoModel/modeling_qwen3_5_omni.cpp +++ b/src/common/AutoModel/modeling_qwen3_5_omni.cpp @@ -793,7 +793,16 @@ NonStreamResult Qwen3_5_Omni::parse_nstream_content(const std::string response_t if (func_end_pos != std::string::npos) { block_end = func_end_pos + func_end_tag.length(); } else { - block_end = response_text.length(); + // Neither closing tag is present, so generation stopped inside + // the call -- almost always because it hit the output limit + // while writing a large argument. Taking the remainder here + // fabricates a complete-looking call from a partial one: the + // arguments JSON is well formed, because it is rebuilt from the + // parsed parameters, so the client cannot tell it is truncated + // and runs it. A heredoc cut mid-body becomes an unterminated + // `cat <