feat(core): add ai web-search and web-crawl tools ui components (#12854)

This commit is contained in:
Wu Yue
2025-06-19 19:15:46 +08:00
committed by GitHub
parent 2edc8e43e2
commit 3886babcf4
20 changed files with 747 additions and 54 deletions

View File

@@ -539,6 +539,20 @@ export class StreamObjectParser {
}
break;
}
case 'tool-result': {
const index = acc.findIndex(
item =>
item.type === 'tool-call' &&
item.toolCallId === curr.toolCallId &&
item.toolName === curr.toolName
);
if (index !== -1) {
acc[index] = curr;
} else {
acc.push(curr);
}
break;
}
default: {
acc.push(curr);
break;