Skip to content
This repository has been archived by the owner on Jul 11, 2023. It is now read-only.

Azure OpenAI Support? #51

Open
Elvincth opened this issue Mar 19, 2023 · 1 comment
Open

Azure OpenAI Support? #51

Elvincth opened this issue Mar 19, 2023 · 1 comment

Comments

@Elvincth
Copy link

I tried to override openai config the base url like this:

const configuration = new Configuration({ basePath: "https:/xxx.openai.azure.com/openai/deployments/demo", apiKey: process.env.AZURE_OPENAI_API_KEY, });

But no luck. Any suggestions would be appreciated.

@mlnj
Copy link

mlnj commented May 13, 2023

This works for me:

{
  basePath: "https://xxx.openai.azure.com/openai/deployments/xxx",
  baseOptions: {
    headers: { "api-key": env. AZURE_OPENAI_API_KEY },
    params: {
      "api-version": "2023-03-15-preview",     // https://oai.azure.com/portal/chat
    },
  },
}

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants