Skip to content

Commit eda03d0

Browse files
committed
fix azure openai api version.
This api version is not supported any more and azure allows not set api version when call chat completion api.
1 parent 1e41add commit eda03d0

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/app/bots/chatgpt-azure/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ export class ChatGPTAzureApiBot extends AbstractChatGPTApiBot {
1313
}
1414

1515
async fetchCompletionApi(messages: ChatMessage[], signal?: AbortSignal) {
16-
const endpoint = `https://${this.config.azureOpenAIApiInstanceName}.openai.azure.com/openai/deployments/${this.config.azureOpenAIApiDeploymentName}/chat/completions?api-version=2025-01-01-preview`
16+
const endpoint = `https://${this.config.azureOpenAIApiInstanceName}.openai.azure.com/openai/deployments/${this.config.azureOpenAIApiDeploymentName}/chat/completions`
1717
return fetch(endpoint, {
1818
method: 'POST',
1919
signal,

0 commit comments

Comments
 (0)