agents.ts: return all msg types in sync mode

This commit is contained in:
Ramnique Singh 2025-07-16 00:01:52 +05:30
parent 27ad5d675a
commit 62dc05e36a

View file

@ -1209,7 +1209,7 @@ export async function getResponse(
}, },
}; };
for await (const event of streamResponse(workflow, projectTools, messages)) { for await (const event of streamResponse(workflow, projectTools, messages)) {
if ('role' in event && event.role === 'assistant') { if ('role' in event) {
out.push(event); out.push(event);
} }
if ('tokens' in event) { if ('tokens' in event) {