-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Confirm this is a Node library issue and not an underlying OpenAI API issue
- This is an issue with the Node library
Describe the bug
Thanks OpenAI team for providing this great Node package. While debugging, I noticed a potential issue in the AzureOpenAI class.
In the documentation, the example endpoint URL is shown as https://example-resource.azure.openai.com/. However, when the baseURL is constructed, it results in double slashes:
baseURL = `${endpoint}/openai`;
// https://example-resource.azure.openai.com//openai
I’m not sure if I’m misunderstanding something, or if this is indeed an issue in the AzureOpenAI class. Could you please take a look?
To Reproduce
this.azureOpenAI = new AzureOpenAI({
apiKey: this.azureOpenAIKey,
endpoint: this.azureOpenAIEndpoint,
apiVersion: this.azureOpenAIVersion,
});
Code snippets
OS
macOS
Node version
Node 21
Library version
"openai": "^4.87.3"
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working