From e871b8ecf1a34f81529097cbde529dc5c4f466da Mon Sep 17 00:00:00 2001 From: nai-degen Date: Sat, 27 Jan 2024 12:19:24 -0600 Subject: [PATCH] removes logprobs default value since it breaks gpt-4-vision --- .../request/preprocessors/transform-outbound-payload.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/proxy/middleware/request/preprocessors/transform-outbound-payload.ts b/src/proxy/middleware/request/preprocessors/transform-outbound-payload.ts index 7a6a487..1abe89b 100644 --- a/src/proxy/middleware/request/preprocessors/transform-outbound-payload.ts +++ b/src/proxy/middleware/request/preprocessors/transform-outbound-payload.ts @@ -90,7 +90,7 @@ export const OpenAIV1ChatCompletionSchema = z // Be warned that Azure OpenAI combines these two into a single field. // It's the only deviation from the OpenAI API that I'm aware of so I have // special cased it in `addAzureKey` rather than expecting clients to do it. - logprobs: z.boolean().optional().default(false), + logprobs: z.boolean().optional(), top_logprobs: z.number().int().optional(), // Quickly adding some newer tool usage params, not tested. They will be // passed through to the API as-is.