From 590204a1e058dddf4a67e4f4981c666de2565c86 Mon Sep 17 00:00:00 2001 From: Richard C Lim <61879224+richardclim@users.noreply.github.com> Date: Sat, 1 Feb 2025 20:23:37 -0500 Subject: [PATCH] Update constant.ts --- app/constant.ts | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/app/constant.ts b/app/constant.ts index 7c66a932b..4d943d2ca 100644 --- a/app/constant.ts +++ b/app/constant.ts @@ -173,6 +173,16 @@ export const OpenaiPath = { ListModelPath: "v1/models", }; +export const Azure = { + ChatPath: (deployName: string, apiVersion: string) => { + return "chat/completions"; + }, + // https://.openai.azure.com/openai/deployments//images/generations?api-version= + ImagePath: (deployName: string, apiVersion: string) => + `deployments/${deployName}/images/generations?api-version=${apiVersion}`, + ExampleEndpoint: "https://{resource-url}", +}; +/* export const Azure = { ChatPath: (deployName: string, apiVersion: string) => { // Check if it's an AI Foundation endpoint @@ -186,7 +196,6 @@ export const Azure = { `deployments/${deployName}/images/generations?api-version=${apiVersion}`, ExampleEndpoint: "https://{resource-url}", }; -/* export const Azure = { ChatPath: (deployName: string, apiVersion: string) => `deployments/${deployName}/chat/completions?api-version=${apiVersion}`,