feat: update message handling to use 'finish' property for step completion logic

This commit is contained in:
Bohdan Triapitsyn
2025-12-27 15:51:28 +02:00
parent 88e0cedcd3
commit 4d7340bf49
11 changed files with 60 additions and 134 deletions
+1 -1
View File
@@ -590,7 +590,7 @@ export const debugUtils = {
const lastMessage = assistantMessages[assistantMessages.length - 1];
const stepFinishParts = lastMessage.parts.filter((p: any) => p.type === 'step-finish');
const hasStopReason = lastMessage.parts.some((p: any) => p.type === 'step-finish' && p.reason === 'stop');
const hasStopReason = (lastMessage.info as { finish?: string }).finish === 'stop';
const timeInfo = lastMessage.info.time as any;
const completedAt = timeInfo?.completed;