openai.version=‘0.27.5’
openai.api_key = ‘sk…’ [not showing here but downloaded from website]
openai.api_base = ‘https://api.openai.com/v1/chat/completions’
Trying to run
response = openai.ChatCompletion.create(
engine=“gpt-3.5-turbo”,
messages=[{“role”: “user”, “content”: “Does Azure OpenAI support customer managed keys?”}],
temperature=0,
)
response.choices[0].message[“content”]
With the above code, I am getting an error.
InvalidRequestError: Invalid URL (POST /v1/chat/completions/openai/deployments/gpt-3.5-turbo/chat/completions)
Not sure what’s wrong. I tried changing api_base to ‘https://api.openai.com/v1’ but still same issue