mirror of
https://github.com/hansjone/oclaw.git
synced 2026-10-19 11:40:46 +08:00
fix(chat): complete streaming for reasoning, tools, and tool calls
- Forward reasoning_content and non-stream reasoning to on_token in OpenAI chat completions; Gemini thought parts to on_token. - Stream bubble: always render session.tool panels; format tool_use_call payloads and title as call · tool_name. - Emit tool_use_call via on_tool_ui before tool execution so WS shows invoke cards before tool_use_result. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
75a3038f33
commit
398d85ba06
4 changed files with 68 additions and 17 deletions
|
|
@ -224,6 +224,8 @@ class GoogleGeminiChatModel(ChatModel):
|
|||
txt = str(p.get("text") or "")
|
||||
if txt:
|
||||
thinking_parts.append(txt)
|
||||
if on_token:
|
||||
on_token(txt)
|
||||
sig = p.get("thoughtSignature")
|
||||
if isinstance(sig, str) and sig:
|
||||
thinking_signature = sig
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue