diff --git a/src/renderer/src/config/models.ts b/src/renderer/src/config/models.ts index 55d3b1a811..f96808a2f3 100644 --- a/src/renderer/src/config/models.ts +++ b/src/renderer/src/config/models.ts @@ -78,75 +78,12 @@ export const SYSTEM_MODELS: Record = { name: 'Qwen2-7B-Instruct', group: 'Qwen2' }, - { - id: 'Qwen/Qwen2-1.5B-Instruct', - provider: 'silicon', - name: 'Qwen2-1.5B-Instruct', - group: 'Qwen2', - enabled: false - }, - { - id: 'Qwen/Qwen1.5-7B-Chat', - provider: 'silicon', - name: 'Qwen1.5-7B-Chat', - group: 'Qwen1.5', - enabled: false - }, { id: 'Qwen/Qwen2-72B-Instruct', provider: 'silicon', name: 'Qwen2-72B-Instruct', group: 'Qwen2' }, - { - id: 'Qwen/Qwen2-57B-A14B-Instruct', - provider: 'silicon', - name: 'Qwen2-57B-A14B-Instruct', - group: 'Qwen2', - enabled: false - }, - { - id: 'Qwen/Qwen1.5-110B-Chat', - provider: 'silicon', - name: 'Qwen1.5-110B-Chat', - group: 'Qwen1.5', - enabled: false - }, - { - id: 'Qwen/Qwen1.5-32B-Chat', - provider: 'silicon', - name: 'Qwen1.5-32B-Chat', - group: 'Qwen1.5', - enabled: false - }, - { - id: 'Qwen/Qwen1.5-14B-Chat', - provider: 'silicon', - name: 'Qwen1.5-14B-Chat', - group: 'Qwen1.5', - enabled: false - }, - { - id: 'deepseek-ai/DeepSeek-V2-Chat', - provider: 'silicon', - name: 'DeepSeek-V2-Chat', - group: 'DeepSeek', - enabled: false - }, - { - id: 'deepseek-ai/DeepSeek-Coder-V2-Instruct', - provider: 'silicon', - name: 'DeepSeek-Coder-V2-Instruct', - group: 'DeepSeek', - enabled: false - }, - { - id: 'deepseek-ai/deepseek-llm-67b-chat', - provider: 'silicon', - name: 'Deepseek-LLM-67B-Chat', - group: 'DeepSeek', - enabled: false - }, { id: 'THUDM/glm-4-9b-chat', provider: 'silicon', @@ -154,32 +91,16 @@ export const SYSTEM_MODELS: Record = { group: 'GLM' }, { - id: 'THUDM/chatglm3-6b', + id: 'deepseek-ai/DeepSeek-V2-Chat', provider: 'silicon', - name: 'GhatGLM3-6B', - group: 'GLM', - enabled: false + name: 'DeepSeek-V2-Chat', + group: 'DeepSeek' }, { - id: '01-ai/Yi-1.5-9B-Chat-16K', + id: 'deepseek-ai/DeepSeek-Coder-V2-Instruct', provider: 'silicon', - name: 'Yi-1.5-9B-Chat-16K', - group: 'Yi', - enabled: false - }, - { - id: '01-ai/Yi-1.5-6B-Chat', - provider: 'silicon', - name: 'Yi-1.5-6B-Chat', - group: 'Yi', - enabled: false - }, - { - id: '01-ai/Yi-1.5-34B-Chat-16K', - provider: 'silicon', - name: 'Yi-1.5-34B-Chat-16K', - group: 'Yi', - enabled: false + name: 'DeepSeek-Coder-V2-Instruct', + group: 'DeepSeek' } ], deepseek: [ @@ -201,8 +122,7 @@ export const SYSTEM_MODELS: Record = { id: 'yi-large', provider: 'yi', name: 'Yi-Large', - group: 'Yi', - enabled: false + group: 'Yi' }, { id: 'yi-large-turbo', @@ -214,8 +134,7 @@ export const SYSTEM_MODELS: Record = { id: 'yi-large-rag', provider: 'yi', name: 'Yi-Large-Rag', - group: 'Yi', - enabled: false + group: 'Yi' }, { id: 'yi-medium', @@ -227,15 +146,13 @@ export const SYSTEM_MODELS: Record = { id: 'yi-medium-200k', provider: 'yi', name: 'Yi-Medium-200k', - group: 'Yi', - enabled: false + group: 'Yi' }, { id: 'yi-spark', provider: 'yi', name: 'Yi-Spark', - group: 'Yi', - enabled: false + group: 'Yi' } ], zhipu: [ @@ -243,15 +160,13 @@ export const SYSTEM_MODELS: Record = { id: 'glm-4', provider: 'zhipu', name: 'GLM-4', - group: 'GLM-4', - enabled: false + group: 'GLM-4' }, { id: 'glm-4-plus', provider: 'zhipu', name: 'GLM-4-Plus', - group: 'GLM-4', - enabled: false + group: 'GLM-4' }, { id: 'glm-4-air', @@ -263,36 +178,31 @@ export const SYSTEM_MODELS: Record = { id: 'glm-4-airx', provider: 'zhipu', name: 'GLM-4-AirX', - group: 'GLM-4', - enabled: false + group: 'GLM-4' }, { id: 'glm-4-flash', provider: 'zhipu', name: 'GLM-4-Flash', - group: 'GLM-4', - enabled: false + group: 'GLM-4' }, { id: 'glm-4v', provider: 'zhipu', name: 'GLM 4V', - group: 'GLM-4v', - enabled: false + group: 'GLM-4v' }, { id: 'glm-4v-plus', provider: 'zhipu', name: 'GLM-4V-Plus', - group: 'GLM-4v', - enabled: false + group: 'GLM-4v' }, { id: 'glm-4-alltools', provider: 'zhipu', name: 'GLM-4-AllTools', - group: 'GLM-4-AllTools', - enabled: false + group: 'GLM-4-AllTools' } ], moonshot: [ @@ -447,8 +357,7 @@ export const SYSTEM_MODELS: Record = { id: 'llama3-8b-8192', provider: 'groq', name: 'LLaMA3 8B', - group: 'Llama3', - enabled: false + group: 'Llama3' }, { id: 'llama3-70b-8192', @@ -460,15 +369,13 @@ export const SYSTEM_MODELS: Record = { id: 'mixtral-8x7b-32768', provider: 'groq', name: 'Mixtral 8x7B', - group: 'Mixtral', - enabled: false + group: 'Mixtral' }, { id: 'gemma-7b-it', provider: 'groq', name: 'Gemma 7B', - group: 'Gemma', - enabled: false + group: 'Gemma' } ] } diff --git a/src/renderer/src/store/migrate.ts b/src/renderer/src/store/migrate.ts index f6ec64c94c..805c03b650 100644 --- a/src/renderer/src/store/migrate.ts +++ b/src/renderer/src/store/migrate.ts @@ -20,7 +20,7 @@ const migrateConfig = { apiKey: '', apiHost: 'https://api.lingyiwanwu.com', isSystem: true, - models: SYSTEM_MODELS.yi.filter((m) => m.enabled) + models: SYSTEM_MODELS.yi } ] } @@ -39,7 +39,7 @@ const migrateConfig = { apiKey: '', apiHost: 'https://open.bigmodel.cn/api/paas/v4/', isSystem: true, - models: SYSTEM_MODELS.zhipu.filter((m) => m.enabled) + models: SYSTEM_MODELS.zhipu } ] } @@ -77,7 +77,7 @@ const migrateConfig = { apiKey: '', apiHost: 'https://api.moonshot.cn', isSystem: true, - models: SYSTEM_MODELS.moonshot.filter((m) => m.enabled) + models: SYSTEM_MODELS.moonshot } ] } @@ -95,7 +95,7 @@ const migrateConfig = { name: 'OpenRouter', apiKey: '', apiHost: 'https://openrouter.ai/api/v1/', - models: SYSTEM_MODELS.openrouter.filter((m) => m.enabled), + models: SYSTEM_MODELS.openrouter, isSystem: true } ] @@ -143,7 +143,7 @@ const migrateConfig = { ...state.llm, providers: state.llm.providers.map((provider) => { if (provider.id === 'zhipu' && provider.models[0] && provider.models[0].id === 'llama3-70b-8192') { - provider.models = SYSTEM_MODELS.zhipu.filter((m) => m.enabled) + provider.models = SYSTEM_MODELS.zhipu } return provider }) @@ -162,7 +162,7 @@ const migrateConfig = { name: 'BAICHUAN AI', apiKey: '', apiHost: 'https://api.baichuan-ai.com', - models: SYSTEM_MODELS.baichuan.filter((m) => m.enabled), + models: SYSTEM_MODELS.baichuan, isSystem: true, enabled: false } @@ -182,7 +182,7 @@ const migrateConfig = { name: 'DashScope', apiKey: '', apiHost: 'https://dashscope.aliyuncs.com/compatible-mode/v1/', - models: SYSTEM_MODELS.dashscope.filter((m) => m.enabled), + models: SYSTEM_MODELS.dashscope, isSystem: true, enabled: false }, @@ -191,7 +191,7 @@ const migrateConfig = { name: 'Anthropic', apiKey: '', apiHost: 'https://api.anthropic.com/', - models: SYSTEM_MODELS.anthropic.filter((m) => m.enabled), + models: SYSTEM_MODELS.anthropic, isSystem: true, enabled: false } @@ -211,7 +211,7 @@ const migrateConfig = { name: 'AiHubMix', apiKey: '', apiHost: 'https://aihubmix.com', - models: SYSTEM_MODELS.aihubmix.filter((m) => m.enabled), + models: SYSTEM_MODELS.aihubmix, isSystem: true, enabled: false } @@ -309,7 +309,7 @@ const migrateConfig = { name: 'Gemini', apiKey: '', apiHost: 'https://generativelanguage.googleapis.com', - models: SYSTEM_MODELS.gemini.filter((m) => m.enabled), + models: SYSTEM_MODELS.gemini, isSystem: true, enabled: false }, @@ -318,7 +318,7 @@ const migrateConfig = { name: 'StepFun', apiKey: '', apiHost: 'https://api.stepfun.com', - models: SYSTEM_MODELS.stepfun.filter((m) => m.enabled), + models: SYSTEM_MODELS.stepfun, isSystem: true, enabled: false }, @@ -327,7 +327,7 @@ const migrateConfig = { name: 'doubao', apiKey: '', apiHost: 'https://ark.cn-beijing.volces.com/api/v3/', - models: SYSTEM_MODELS.doubao.filter((m) => m.enabled), + models: SYSTEM_MODELS.doubao, isSystem: true, enabled: false }, @@ -356,7 +356,7 @@ const migrateConfig = { name: 'MiniMax', apiKey: '', apiHost: 'https://api.minimax.chat/v1/', - models: SYSTEM_MODELS.minimax.filter((m) => m.enabled), + models: SYSTEM_MODELS.minimax, isSystem: true, enabled: false }