Use openai compatible as vendor

This commit is contained in:
Xin Wang
2026-02-12 18:44:55 +08:00
parent 260ff621bf
commit ff3a03b1ad
23 changed files with 822 additions and 905 deletions

View File

@@ -20,7 +20,7 @@ interface LLMModel {
id: string; // 模型唯一标识
user_id: number; // 所属用户ID
name: string; // 模型显示名称
vendor: string; // 供应商: "OpenAI Compatible" | "SiliconFlow" | "Dify" | "FastGPT"
vendor: string; // 供应商: "OpenAI Compatible" | "Dify" | "FastGPT"
type: string; // 类型: "text" | "embedding" | "rerank"
base_url: string; // API Base URL
api_key: string; // API Key
@@ -57,7 +57,7 @@ interface TTSModel {
id: string;
user_id: number;
name: string;
vendor: string; // "Ali" | "Volcano" | "Minimax" | "硅基流动"
vendor: string; // "OpenAI Compatible" | "Ali" | "Volcano" | "Minimax"
language: string; // "zh" | "en"
voice_list?: string[]; // 支持的声音列表
enabled: boolean;
@@ -316,7 +316,6 @@ class LLMModelType(str, Enum):
class LLMModelVendor(str, Enum):
OPENAI_COMPATIBLE = "OpenAI Compatible"
SILICONFLOW = "SiliconFlow"
DIFY = "Dify"
FASTGPT = "FastGPT"
@@ -389,11 +388,11 @@ class ASRModelOut(ASRModelBase):
}
```
### SiliconFlow
### OpenAI Compatible
```json
{
"vendor": "SiliconFlow",
"vendor": "OpenAI Compatible",
"base_url": "https://api.siliconflow.com/v1",
"api_key": "sf-xxx",
"model_name": "deepseek-v3"