feat: Support files and batches APIs provided by Azure OpenAI (#1904)

This commit is contained in:
Kent Dong
2025-03-17 11:21:05 +08:00
committed by GitHub
parent 9a89665b22
commit 5de7c2a5ea
3 changed files with 54 additions and 21 deletions

View File

@@ -28,10 +28,14 @@ const (
ApiNameEmbeddings ApiName = "openai/v1/embeddings"
ApiNameImageGeneration ApiName = "openai/v1/imagegeneration"
ApiNameAudioSpeech ApiName = "openai/v1/audiospeech"
ApiNameFiles ApiName = "openai/v1/files"
ApiNameBatches ApiName = "openai/v1/batches"
PathOpenAICompletions = "/v1/completions"
PathOpenAIChatCompletions = "/v1/chat/completions"
PathOpenAIEmbeddings = "/v1/embeddings"
PathOpenAIFiles = "/v1/files"
PathOpenAIBatches = "/v1/batches"
// TODO: 以下是一些非标准的API名称需要进一步确认是否支持
ApiNameCohereV1Rerank ApiName = "cohere/v1/rerank"