fix:in the dify agent llm return message can not joint (#1617)

This commit is contained in:
fdc310
2025-08-19 23:23:00 +08:00
committed by GitHub
parent 30bb26f898
commit ff7bebb782

View File

@@ -499,7 +499,7 @@ class DifyServiceAPIRunner(runner.RequestRunner):
content = re.sub(r'^\n</think>', '', chunk['answer'])
pending_agent_message += content
think_end = True
elif think_end:
elif think_end or not think_start:
pending_agent_message += chunk['answer']
if think_start:
continue