diff --git a/frontend/src/interfaces/llm-provider.ts b/frontend/src/interfaces/llm-provider.ts index 877c6be0..c0b1c2d1 100644 --- a/frontend/src/interfaces/llm-provider.ts +++ b/frontend/src/interfaces/llm-provider.ts @@ -3,15 +3,10 @@ export interface LlmProvider { name: string; type: string; protocol?: string; - modelMapping: ModelMapping; tokens: string[]; tokenFailoverConfig?: TokeFailoverConfig; } -export interface ModelMapping { - [propName: string]: string; -} - export interface TokeFailoverConfig { enabled?: boolean; failureThreshold?: number; @@ -21,11 +16,6 @@ export interface TokeFailoverConfig { healthCheckModel?: string; } -export enum LlmProviderType { - OPENAI = 'openai', - QWEN = 'qwen', -} - export enum LlmProviderProtocol { OPENAI_V1 = 'openai/v1', } diff --git a/frontend/src/pages/ai/components/RouteForm/index.tsx b/frontend/src/pages/ai/components/RouteForm/index.tsx index d764b1b0..fe84aee6 100644 --- a/frontend/src/pages/ai/components/RouteForm/index.tsx +++ b/frontend/src/pages/ai/components/RouteForm/index.tsx @@ -199,7 +199,7 @@ const AiRouteForm: React.FC = forwardRef((props: { value: any }, ref) => { provider: fallbackConfig_upstreams, modelMapping: {}, }; - _upstreams["modelMapping"][fallbackConfig_modelNames] = fallbackConfig_upstreams; + _upstreams["modelMapping"]["*"] = fallbackConfig_modelNames; payload['fallbackConfig']['upstreams'] = [_upstreams]; payload['fallbackConfig']['strategy'] = "SEQ"; }