Commit Graph
308 Commits
Author SHA1 Message Date
baiqing 3416919da6 fix(asr): OpenAI 兼容 preset 也前置校验 endpoint 与 model
PR-Agent #213 reviewer guide: 切到新 preset 后用户若手动清空
asr.endpoint,read_whisper_credentials 会返回空字符串,
WhisperBatchASR 拼出相对路径 `/audio/transcriptions`,要等用户录完
才以 reqwest 错误失败。model 同理(兜底成 "whisper-1" 对 SiliconFlow
等是无效模型名,runtime 才 400)。

在 ensure_asr_credentials 的兼容分支里加前置校验,把错误时机提前到
按下热键的瞬间,复用与 api_key 同款 hard-error 语义。
2026-05-03 22:18:45 +08:00
baiqing 0a4d33c755 fix(asr): QA 凭据校验改用专用 Volcengine 检查,避免被 active_asr 误导
Codex P1 (PR #213): 主听写路径分支化 `ensure_asr_credentials` 后,QA 路径
仍然复用同一函数,导致两类用户可见 bug:

1. 用户选了 qwen/siliconflow/zhipu/groq 但没填 `asr.api_key` → QA 报
   "请先填写 ASR 服务商 API Key",可火山凭据明明是齐的。
2. 反之 `asr.api_key` 已填、火山凭据为空 → QA 通过 ensure,进 open_session
   再以 Volcengine 凭据错误失败,更难诊断。

修法是给 QA 加专用 `ensure_qa_volcengine_credentials()`,只看 Volcengine 字段;
dictation 路径继续走 `ensure_asr_credentials` 不变。
2026-05-03 22:01:34 +08:00
baiqing 94d6a7199c feat(asr): 接入 Qwen3-ASR / SiliconFlow / GLM-ASR / Groq 作为可选服务商
复用现有 OpenAI 兼容 `/audio/transcriptions` 通道(WhisperBatchASR),无需
新增 Rust 客户端。把 `coordinator.rs` 中的 whisper 分支条件改为
`is_whisper_compatible_provider(id)`,新增厂商时一处即可扩展。

设置页 ASR 下拉新增 4 项预设,切换时自动预填 baseUrl 与 model,避免用户
忘填模型 ID 必然踩坑。

Closes #212
2026-05-03 21:54:34 +08:00
Chris233 6062516dba Merge pull request #209 from H-Chris233/main
docs(readme): add Chris233 to Developers section
2026-05-03 18:00:23 +08:00
Chris233 d08f649f15 docs(readme): add Chris233 to Developers section 2026-05-03 17:55:00 +08:00
Chris233 532ec65832 Merge pull request #208 from H-Chris233/main
fix(app): 修正浏览器 timeout ref 类型
2026-05-03 17:53:52 +08:00
Chris233 6027bb7d6f fix(app): correct browser timeout ref types for build 2026-05-03 17:36:21 +08:00
TRIP 6696c2e1fd Merge pull request #202 from appergb/docs/official-website
docs(readme): 增加官方网站 openless.top 链接
2026-05-03 16:38:12 +08:00
baiqing bba13b1b42 docs(readme): 增加官方网站 openless.top 链接
在中英 README 顶部加官方网站链接,并在描述段落中补一句官网地址,方便读者直达。
2026-05-03 16:37:51 +08:00
TRIP 3bcc367eaa Merge pull request #201 from appergb/fix/jiangmuran-is-sponsor
docs(readme): jiangmuran 移到赞助商栏
2026-05-03 15:53:55 +08:00
baiqing cd41267483 docs(readme): jiangmuran 移到赞助商栏
上一个 PR 把 jiangmuran 错放到了开发者栏。修正:

- 赞助商栏(Sponsors):悠雾云数据 + jiangmuran,圆形头像 48×48
  与悠雾云 logo 高度(48)对齐
- 开发者栏(Developers):仅 TRIP

英文 sponsor → Sponsors(多于一个)。
2026-05-03 15:53:24 +08:00
TRIP ed3088f0dd Merge pull request #200 from appergb/chore/readme-personal-sponsors
docs(readme): 加开发者栏目(圆形头像)+ 资源整理
2026-05-03 15:50:35 +08:00
baiqing 64b9132553 docs(readme): 加开发者栏目(圆形头像)+ 资源整理
- 新增"开发者 / Developers"栏(QQ 群、赞助商之下):
  - TRIP — https://tripmc.top/
  - jiangmuran — https://jiangmuran.com/
- 头像本地化到 assets/people/,每张 200×200 圆形透明 PNG
  (ffmpeg geq alpha mask 抗锯齿;GitHub markdown sanitizer 不支持
  border-radius 内联样式,预处理图片是唯一稳定路径)
- 赞助商栏(悠雾云数据)保留不动
2026-05-03 15:48:50 +08:00
baiqing 96502b8331 chore: release 1.2.13 2026-05-03 15:20:40 +08:00
TRIP a40561911b Merge pull request #199 from appergb/chore/readme-sponsor
docs(readme): 加赞助商悠雾云数据栏目
2026-05-03 15:19:52 +08:00
baiqing 36afec52ba docs(readme): 加赞助商悠雾云数据栏目
QQ 群下方新增「赞助商 / Sponsor」一栏,内容:
- 名称:悠雾云数据
- 站点:https://www.knin.net (logo + 文字均可点击跳转)
- Logo:https://www.knin.net/upload/logo.png(按文件名语义择 logo.png;
  另一张 login.png 看起来是后台登录配图,暂不用,必要时一行替换)

中英文 README 同步。
2026-05-03 15:17:30 +08:00
TRIP 3cfa46231b Merge pull request #198 from appergb/codex/fix-macos-window-ui
fix(macos): 1.2.11 窗口/胶囊 UI 对齐 + tab cross-fade + polish 纠错
2026-05-03 15:05:50 +08:00
baiqing 0bf4f7e253 fix(capsule): Windows 翻译模式 host 高度跟随 translation flag
PR Reviewer (PR Agent) 指出:getCapsuleHostMetrics(os, false) 把
translation 参数硬编码成 false,Windows 端 host 在翻译模式下应该从
84 长到 118,硬编码后徽章 bottom 用更短 host 量出来 → 跟 118pt 实际
窗口尺寸错位、徽章可能溢出或被裁。

修:把 useState<translation> 提到 hostMetrics 之前,调用改回
getCapsuleHostMetrics(os, translation)。macOS / Linux 不受影响 —
capsuleLayout 在那两个分支已经忽略 translationActive 返回固定 42。
2026-05-03 15:04:36 +08:00
baiqing d39072a21f Merge remote-tracking branch 'origin/main' into codex/fix-macos-window-ui
# Conflicts:
#	openless-all/app/src-tauri/src/polish.rs
2026-05-03 13:55:44 +08:00
baiqing 65f84305cc feat(polish): 自动纠错 + 按整体意图组织自然书面表达
补 COMMON_RULES 两条:
- 规则 3 扩展:在保留原意和语气的前提下,按用户的整体意图把零碎口语
  组织成协调、自然的书面表达。
- 规则 5(新增)自动纠错:明显的 ASR 同音 / 形近错字按上下文纠回正确字面,
  覆盖"跟目录/根木鹿→根目录"、"代码厂→代码仓"、"编一编→编译"、
  "的/得/地"、"做/作"等常见错别字。专有名词、人名、品牌名、不在常见
  中文词典里的词原样保留,不强行改字;改动会引起含义变化的不改。

不动 ROLE_BLOCK / OUTPUT_BLOCK / 各 mode 任务段,保持"不要激进改写"
的边界(feedback memory)。translate / qa prompt 与本次诉求无关,未改。

加一个测试 common_rules_include_auto_correction_and_natural_organization
覆盖四个 mode,防止规则被回退或遗漏。
2026-05-03 13:36:31 +08:00
baiqing f06f305774 fix(macos): align with 1.2.11 window/capsule UI + tab cross-fade
红绿灯
- trafficLightPosition x=14 y=20(Apple Notes / Safari 视觉),
  MAC_TITLEBAR_HEIGHT 30→28,paddingTop 30→28,让红绿灯在 titlebar
  内对称居中。

胶囊几何回退到 1.2.11
- macOS / Linux 上 capsule_window_bounds 固定 220×110,capsule_visual_height
  改回 96,emit_capsule 不再随 translation_active 改 size + 位置。修两个
  回归:(a) 录音胶囊 pill 左右被裁;(b) 按 Shift 后窗口高度从 42→110
  导致整体下移。
- 单元测试断言同步更新。

emit_capsule macOS show 路径回退到 1.2.11
- show_capsule_window_no_activate macOS 实现删除(合进 cfg(not(windows))
  stub 返回 false),fallback 走 window.show() + restore_main_window_key_if_active。
  orderFrontRegardless 路径在 webview 未完整初始化时偶发不可见。

Translation 设置页 + i18n 回退到 1.2.12
- 撤回 d7d274f 整页重排,回到 1.2.11/1.2.12 的简洁布局。

tab 切换 cross-fade with blur
- FloatingShell.tsx 加 displayTab + tabPhase;点新 tab 触发旧页
  ol-page-fadeout(opacity 1→0、blur 0→8px、180ms),结束后挂载
  新页走现有 ol-page-slide。修 Windows 徽章 bottom 公式:保留
  hostMetrics 路径(pill 不在 win host 中线,calc(50%) 不对)。

Capsule.tsx 动画化简
- 徽章/capsule-in 撤回 motion-soft / motion-spring 别名 + filter blur,
  回到 1.2.11 的 ease-out / cubic-bezier。
2026-05-03 13:29:53 +08:00
Chris233 90497a6147 Merge pull request #197 from H-Chris233/main
fix(window): 恢复 macOS 原生交通灯
2026-05-03 12:54:06 +08:00
H-Chris233 6545231d83 Restore mac traffic lights without enabling native chrome on Linux/Windows
Keep custom chrome on non-mac platforms while restoring native traffic lights on macOS. Also remove the extra outer mac shell radius/border to avoid double-rounded corners.

Constraint: macOS must show native traffic lights for issue #183
Constraint: Windows/Linux should keep custom titlebar behavior
Rejected: set decorations=true in tauri.conf globally | enables native chrome on Linux
Confidence: high
Scope-risk: narrow
Directive: Platform-specific window decoration behavior should be controlled at runtime, not by global config
Tested: npm run build (openless-all/app)
Not-tested: manual visual verification on real macOS/Linux/Windows runtimes
2026-05-03 12:22:14 +08:00
Chris233 a2a5605239 Merge pull request #193 from H-Chris233/main
fix(llm): 允许无密钥 LLM 配置
2026-05-03 12:13:50 +08:00
H-Chris233 b85006c9a9 Allow keyless custom LLM endpoints while blocking default Ark fallback leakage
Content flows now allow empty Ark API keys only when a custom Ark endpoint is configured. If both key and endpoint are empty, we fail locally instead of falling back to the public Ark endpoint, preserving the privacy guard while restoring ticket #192 keyless self-hosted behavior.

Constraint: Keep no-key self-hosted OpenAI-compatible LLM support from issue #192
Constraint: Prevent transcript content from being sent to default public Ark endpoint when key is empty
Rejected: unconditional API-key requirement in coordinator | breaks keyless self-hosted usage
Rejected: unconditional default-endpoint fallback | risks accidental data egress on fresh installs
Confidence: high
Scope-risk: narrow
Directive: Any future endpoint fallback change must preserve the blank-key + blank-endpoint local guard for content-sending flows
Tested: rustfmt --edition 2021 --check src/coordinator.rs; cargo test --lib resolve_ark_endpoint_
Not-tested: end-to-end UI interaction for keyless custom endpoint polish/translate/chat
2026-05-03 11:40:52 +08:00
baiqing d7d274fa87 fix(ui): clean sidebar and translation settings 2026-05-03 10:03:40 +08:00
H-Chris233 7e36d0756c Block keyless Ark content flows before default endpoint fallback
Polish, translate, and QA chat now fail locally when ArkApiKey is blank, so fresh installs and keyless LLM setups do not leak transcript content to the default public Ark endpoint. Model discovery remains keyless because it is a separate non-content path.

Constraint: LLM model discovery must stay keyless
Rejected: rely on downstream provider auth failures | leaks user content over the network
Confidence: high
Scope-risk: narrow
Directive: Keep the blank-key guard ahead of any Ark endpoint fallback in content-sending flows
Tested: cargo test --lib require_ark_api_key_rejects_blank_key; rustfmt --edition 2021 --check src/coordinator.rs
Not-tested: full UI settings flow
2026-05-03 10:03:39 +08:00
baiqing 91f1c5fae8 fix(macos): keep native traffic lights visible 2026-05-03 09:56:47 +08:00
TRIP 7f64a1b464 fix(ci): allow PR-Agent review on external PRs 2026-05-03 09:55:17 +08:00
H-Chris233 1d0dcef18c Skip auth header for blank-key LLM model discovery
Model discovery now matches the keyless LLM path by omitting Authorization when the stored API key is blank. This keeps Fetch models usable for endpoints that reject empty Bearer credentials while preserving authenticated discovery for configured providers.

Constraint: ASR still requires an API key
Rejected: send a fake or empty Bearer header | breaks keyless endpoints
Confidence: high
Scope-risk: narrow
Directive: Do not reintroduce auth headers for blank LLM keys without a provider-specific requirement
Tested: cargo test --lib fetch_provider_models_omits_authorization_when_api_key_is_empty; rustfmt --edition 2021 --check src/commands.rs
Not-tested: full frontend integration flow
2026-05-03 09:51:39 +08:00
baiqing 420c5425e6 fix(macos): tune window chrome motion 2026-05-03 09:43:19 +08:00
baiqing f89a285877 fix(macos): restore native window chrome and capsule focus 2026-05-03 09:29:59 +08:00
H-Chris233 0fe00ced9a Allow LLM validation without a saved API key
Some OpenAI-compatible LLM endpoints do not require an API key, so the LLM validation and runtime polish paths should not invent one or fail early when the key field is blank. The client now omits the Authorization header when the key is empty, the coordinator stops treating a blank LLM key as a hard error, and the settings validation continues to distinguish a missing model from a genuinely failed connection.

Constraint: Keep the change minimal and preserve the existing HTTP-status error mapping.
Rejected: Keep key-required behavior for all LLM endpoints | it mislabels keyless endpoints such as local 11443-style servers as invalid.
Confidence: high
Scope-risk: moderate
Directive: Empty LLM API keys are allowed only for the OpenAI-compatible path; ASR remains key-required.
Tested: npm run build; cargo test --lib
Not-tested: Live behavior against a real keyless endpoint outside the test harness
2026-05-02 23:32:27 +08:00
Chris233 280b50ea17 更新 pr-agent.yml 2026-05-02 21:16:12 +08:00
Chris233 dbd0503c55 Merge pull request #187 from H-Chris233/main
fix(settings): 用当前模型验证连接
2026-05-02 20:23:05 +08:00
Chris233 69d7f62161 更新 pr-agent.yml 2026-05-02 20:07:26 +08:00
H-Chris233 e99619948e Treat missing LLM model as unconfigured
The LLM connection check no longer falls back to an Ark-specific default model when the user has not configured one. Instead, it returns a dedicated marker and the settings UI surfaces the empty-state copy, which keeps the validation result aligned with the actual configuration state.

Constraint: Preserve the existing provider-status parsing and keep the change minimal.
Rejected: Keep the deepseek-v3-2 fallback | it creates a false positive for unconfigured non-Ark providers.
Confidence: high
Scope-risk: narrow
Directive: Validation should never invent a model when the user has not saved one.
Tested: npm run build; cargo test --lib
Not-tested: Live provider behavior with a truly empty model field on a real endpoint
2026-05-02 19:59:09 +08:00
Chris233 4027909a8c 更新 pr-agent.yml 2026-05-02 19:23:44 +08:00
Chris233 14149207a4 更新 pr-agent.yml 2026-05-02 19:15:19 +08:00
Chris233 dbb95abab7 更新 pr-agent.yml 2026-05-02 18:55:56 +08:00
Chris233 f7c0c59408 创建 pr-agent.yml 2026-05-02 17:40:27 +08:00
H-Chris233 5725e4433a Preserve provider HTTP markers in LLM validation failures
LLM validation now maps non-2xx completion responses back to the same providerHttpStatus:<code> marker used by the model-listing path. That keeps the settings page on its existing error-copy branch so real API-key, endpoint, and model failures stay diagnosable instead of collapsing into a generic message.

Constraint: Keep the change minimal and preserve the existing settings error-message parser.
Rejected: Teach the frontend to parse LLMError::InvalidResponse text | this would duplicate provider-status semantics and broaden the UI change.
Confidence: high
Scope-risk: narrow
Directive: Validation error strings for provider status should stay normalized at the command boundary.
Tested: cargo test --lib
Not-tested: Live provider error text against a real non-2xx endpoint
2026-05-02 17:03:55 +08:00
Chris233 a259b57d5e Merge branch 'appergb:main' into main 2026-05-02 16:11:42 +08:00
baiqing 89dd4e49bb chore: release 1.2.12 2026-05-02 12:19:28 +08:00
TRIP 7aefb8199e Merge pull request #181 from Cooper-X-Oak/codex/windows-native-titlebar-off
fix(windows): 收紧主窗口 shell 外观契约
2026-05-02 12:18:12 +08:00
Cooper-X-Oak 802ee653c9 fix(windows): 收紧主窗口 shell 外观契约 2026-05-02 12:12:46 +08:00
Cooper-X-Oak 946d842023 fix(windows): restore custom chrome interactions 2026-05-02 12:12:02 +08:00
Cooper-X-Oak 4ea8389ceb fix(windows): align custom shell rounded frame 2026-05-02 12:12:02 +08:00
Cooper-X-Oak f83a5339c7 fix(windows): remove native titlebar before first show 2026-05-02 12:12:02 +08:00
TRIP a2d243f333 Merge pull request #182 from Cooper-X-Oak/codex/windows-capsule-geometry-pr
fix(windows): 收紧 Capsule 几何契约
2026-05-02 12:11:51 +08:00