Merge pull request #1992 from arc53/fix-api-answer-tool-call

fix: api answer tool call event
This commit is contained in:
Alex authored and GitHub committed 2025-09-30 14:49:57 +01:00
commit 2cd4c41316
1 file changed
+2
+2
View File
@@ -110,6 +110,8 @@ class BaseAnswerResource:
yield f"data: {data}\n\n"
elif "tool_calls" in line:
tool_calls = line["tool_calls"]
data = json.dumps({"type": "tool_calls", "tool_calls": tool_calls})
yield f"data: {data}\n\n"
elif "thought" in line:
thought += line["thought"]
data = json.dumps({"type": "thought", "thought": line["thought"]})