Replies: 4 comments 3 replies
-
The code in this comment seems to be from https://github.com/openai/openai-python/blob/75c90a71e88e4194ce22c71edeb3d2dee7f6ac93/openai/util.py#L21 that translates to variability in the header passed to the endpoint. Specifically, azure does not use Is this configurable in the npm package |
Beta Was this translation helpful? Give feedback.
-
Thank you for bringing this up. That's correct, there are some differences between the two endpoints, and I am aware of them. This isn't supported at the moment. I'm curious what models you are more interested in using from your Azure OpenAI Service deployments? i.e. text-davinci, code-davinci or chatgpt? I may consider updating my chatgpt api fork to support Azure OpenAI endpoints. |
Beta Was this translation helpful? Give feedback.
-
wait for azure support 👍 |
Beta Was this translation helpful? Give feedback.
-
This is now supported in Genie Test it out and let us know if you face any issues via our repo's Issues. @gencay could you transfer this as an issue over to us? |
Beta Was this translation helpful? Give feedback.
-
Using the python module for ChatGPT, it is possible to use a "local" instance that is hosted on a Azure subscription, but we have not figured out how to connect that VS Code extension to a Azure hosted instance... these are the paramaters that are used in the python module:
Microsoft Azure Endpoints
In order to use the library with Microsoft Azure endpoints, you need to set the api_type, api_base and api_version in addition to the api_key. The api_type must be set to 'azure' and the others correspond to the properties of your endpoint. In addition, the deployment name must be passed as the engine parameter.
`import openai
openai.api_type = "azure"
openai.api_key = "..."
openai.api_base = "https://example-endpoint.openai.azure.com"
openai.api_version = "2022-12-01"
create a completion
completion = openai.Completion.create(engine="deployment-name", prompt="Hello world")
print the completion
print(completion.choices[0].text)`
How can we contribute to enable this feature ?
Beta Was this translation helpful? Give feedback.
All reactions