diff --git a/src/endpoints/backends/chat-completions.js b/src/endpoints/backends/chat-completions.js index e61dd16bf..8ff3f569c 100644 --- a/src/endpoints/backends/chat-completions.js +++ b/src/endpoints/backends/chat-completions.js @@ -1,6 +1,7 @@ import process from 'node:process'; import express from 'express'; import fetch from 'node-fetch'; +import util from 'node:util'; import { CHAT_COMPLETION_SOURCES, @@ -498,7 +499,7 @@ async function sendMakerSuiteRequest(request, response) { const responseContent = candidates[0].content ?? candidates[0].output; const functionCall = (candidates?.[0]?.content?.parts ?? []).some(part => part.functionCall); const inlineData = (candidates?.[0]?.content?.parts ?? []).some(part => part.inlineData); - console.warn('Google AI Studio response:', responseContent); + console.warn('Google AI Studio response:', util.inspect(generateResponseJson, {depth: 6, colors: true})); const responseText = typeof responseContent === 'string' ? responseContent : responseContent?.parts?.filter(part => !part.thought)?.map(part => part.text)?.join('\n\n'); if (!responseText && !functionCall && !inlineData) {