Update common.ts

This commit is contained in:
Richard C Lim 2025-01-31 22:33:24 -05:00 committed by GitHub
parent 32d788d808
commit 37ff8924d1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -52,7 +52,7 @@ export async function requestOpenai(req: NextRequest) {
if (isAzure) { if (isAzure) {
const isAIFoundation = serverConfig.azureUrl?.includes(".models.ai.azure.com"); const isAIFoundation = serverConfig.azureUrl?.includes(".models.ai.azure.com");
if (isAIFoundation) { if (isAIFoundation && serverConfig.azureUrl) {
// For AI Foundation, use the path directly without api-version // For AI Foundation, use the path directly without api-version
baseUrl = serverConfig.azureUrl; baseUrl = serverConfig.azureUrl;
path = "chat/completions"; path = "chat/completions";