From 4a0d8efead6076019ed347e710731db0e0c3c340 Mon Sep 17 00:00:00 2001 From: baiqing Date: Thu, 30 Apr 2026 10:52:41 +0800 Subject: [PATCH] =?UTF-8?q?feat(settings):=20=E7=A1=85=E5=9F=BA=E6=B5=81?= =?UTF-8?q?=E5=8A=A8=20ASR/LLM=20=E9=85=8D=E7=BD=AE=20+=20=E5=85=B3?= =?UTF-8?q?=E4=BA=8E=E9=A1=B5=E5=AE=8C=E5=96=84=20+=20onAsrProviderChange?= =?UTF-8?q?=20bug=20=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - LLM 供应商新增「硅基流动」(https://api.siliconflow.cn/v1,默认模型 Qwen2.5-7B) - ASR 供应商新增「硅基流动 SenseVoice」(Whisper 兼容,默认模型 FunAudioLLM/SenseVoiceSmall) - 修复 onAsrProviderChange 调用未定义 setPrefsState/setSettings 的 bug,改用 updatePrefs - 关于页:新增源码入口(GitHub 链接)、QQ 群号 1078960553(可一键复制) --- openless-all/app/src/pages/Settings.tsx | 48 +++++++++++++++++++++---- 1 file changed, 41 insertions(+), 7 deletions(-) diff --git a/openless-all/app/src/pages/Settings.tsx b/openless-all/app/src/pages/Settings.tsx index 50bedbff..899fa63a 100644 --- a/openless-all/app/src/pages/Settings.tsx +++ b/openless-all/app/src/pages/Settings.tsx @@ -200,10 +200,11 @@ function Toggle({ on, onToggle }: { on: boolean; onToggle?: (next: boolean) => v } const LLM_PRESETS = [ - { id: 'ark', name: 'ARK(火山方舟)', baseUrl: 'https://ark.cn-beijing.volces.com/api/v3', modelPlaceholder: 'deepseek-v3-2' }, - { id: 'deepseek', name: 'DeepSeek', baseUrl: 'https://api.deepseek.com/v1', modelPlaceholder: 'deepseek-chat' }, - { id: 'openai', name: 'OpenAI', baseUrl: 'https://api.openai.com/v1', modelPlaceholder: 'gpt-4o' }, - { id: 'custom', name: '自定义', baseUrl: '', modelPlaceholder: '' }, + { id: 'ark', name: 'ARK(火山方舟)', baseUrl: 'https://ark.cn-beijing.volces.com/api/v3', modelPlaceholder: 'deepseek-v3-2' }, + { id: 'deepseek', name: 'DeepSeek', baseUrl: 'https://api.deepseek.com/v1', modelPlaceholder: 'deepseek-chat' }, + { id: 'siliconflow', name: '硅基流动', baseUrl: 'https://api.siliconflow.cn/v1', modelPlaceholder: 'Qwen/Qwen2.5-7B-Instruct' }, + { id: 'openai', name: 'OpenAI', baseUrl: 'https://api.openai.com/v1', modelPlaceholder: 'gpt-4o' }, + { id: 'custom', name: '自定义', baseUrl: '', modelPlaceholder: '' }, ] as const; type LlmPresetId = typeof LLM_PRESETS[number]['id']; @@ -211,8 +212,9 @@ type LlmPresetId = typeof LLM_PRESETS[number]['id']; const ASR_DEFAULT_RESOURCE_ID = 'volc.bigasr.sauc.duration'; const ASR_PRESETS = [ - { id: 'volcengine', name: '火山引擎 bigasr' }, - { id: 'whisper', name: 'OpenAI Whisper(兼容)' }, + { id: 'volcengine', name: '火山引擎 bigasr' }, + { id: 'siliconflow', name: '硅基流动 SenseVoice' }, + { id: 'whisper', name: 'OpenAI Whisper(兼容)' }, ] as const; type AsrPresetId = typeof ASR_PRESETS[number]['id']; @@ -304,6 +306,14 @@ function ProvidersSection() { + ) : asrProvider === 'siliconflow' ? ( + <> + + + + ) : ( <> @@ -586,6 +596,14 @@ function PermissionPill({ status }: { status: PermissionStatus | 'loading' }) { } function AboutSection() { + const [qqCopied, setQqCopied] = useState(false); + + const copyQq = () => { + navigator.clipboard?.writeText('1078960553'); + setQqCopied(true); + setTimeout(() => setQqCopied(false), 1500); + }; + return (
@@ -603,8 +621,24 @@ function AboutSection() {
openExternal('https://github.com/appergb/openless/releases')}>打开 Releases + openExternal('https://github.com/appergb/openless')}>GitHub openExternal('https://github.com/appergb/openless#readme')}>README - openExternal('https://github.com/appergb/openless/issues')}>GitHub Issues + openExternal('https://github.com/appergb/openless/issues')}>GitHub Issues + +
+ 1078960553 + + {qqCopied && 已复制} +
+
本地优先