From 6412a698a8bcda8f38e61d44d0c36439f17862ed Mon Sep 17 00:00:00 2001 From: Eric Allam Date: Mon, 15 Jun 2026 17:49:03 +0100 Subject: [PATCH] docs(ai-chat): correct the extractNewToolResults return type --- docs/ai-chat/patterns/tool-result-auditing.mdx | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/docs/ai-chat/patterns/tool-result-auditing.mdx b/docs/ai-chat/patterns/tool-result-auditing.mdx index 493c8037486..cab6b421a70 100644 --- a/docs/ai-chat/patterns/tool-result-auditing.mdx +++ b/docs/ai-chat/patterns/tool-result-auditing.mdx @@ -112,12 +112,11 @@ await auditLog.upsert({ ## What `extractNewToolResults` returns ```ts -type ExtractedToolResult = { +type ChatNewToolResult = { toolCallId: string; toolName: string; - input: unknown; // The arguments the model passed when calling the tool - output?: unknown; // The tool's return value (output-available state) - errorText?: string; // Error message (output-error state) + output: unknown; // The tool's return value (carries the resolved value; in output-error state see errorText) + errorText?: string; // Set iff the part is in output-error state }; ```