event: history_message
data: {"id":"msg-1","role":"user","content":"Analyze this CSV file","createdAt":"2026-01-26T15:50:54.870Z","attachedFiles":[{"name":"data.csv","path":"uploads/data.csv"}]}
event: history_message
data: {"id":"msg-2","role":"assistant","content":"I analyzed the CSV file...","createdAt":"2026-01-26T15:50:59.998Z","thoughts":[{"subject":"Analyzing","description":"Reading CSV structure"}],"toolCalls":[{"callId":"tc-1","toolName":"read_file","status":"success"}]}
event: history_done
data: {"messageCount":2,"isStreaming":true}
event: content
data: {"text":"Now let me provide additional analysis...","isPartial":true}
event: tool_call
data: {"callId":"call_456","toolName":"write_file","status":"executing","args":{"path":"output.csv"}}
event: tool_result
data: {"callId":"call_456","status":"success","output":"File written successfully"}
event: subagent_start
data: {"agentName":"code-writer","displayName":"Code Writer","description":"Writes and edits code files","objective":"Create summary chart"}
event: subagent_thought
data: {"agentName":"code-writer","text":"I'll generate a chart from the analyzed data"}
event: subagent_tool
data: {"agentName":"code-writer","status":"end","toolName":"write_file","output":"Chart saved"}
event: subagent_end
data: {"agentName":"code-writer","terminateReason":"GOAL","result":"Created summary chart"}
event: content
data: {"text":"I've created the output file.","isPartial":false}
event: done
data: {"finalResponse":"I've created the output file with the analysis results."}