Closed uezo closed 3 months ago
Just the chat completion is supported for now.
To use Azure OpenAI, use AzureOpenAIProxy instead of ChatGPTProxy.
AzureOpenAIProxy
ChatGPTProxy
from aiproxy.chatgpt import AzureOpenAIProxy aoai_proxy = AzureOpenAIProxy( api_key="YOUR_API_KEY", resource_name="YOUR_RESOURCE_NAME", deployment_id="YOUR_DEPLOYMENT_ID", api_version="2024-02-01", # https://learn.microsoft.com/ja-jp/azure/ai-services/openai/reference#chat-completions access_logger_queue=worker.queue_client ) aoai_proxy.add_route(app)
Clients do not need to be aware that it is Azure OpenAI; use the same code for ChatGPT API.
Just the chat completion is supported for now.
To use Azure OpenAI, use
AzureOpenAIProxy
instead ofChatGPTProxy
.Clients do not need to be aware that it is Azure OpenAI; use the same code for ChatGPT API.