Skip to content

One-Key Input v0.2.0

Choose a tag to compare

@github-actions github-actions released this 21 May 09:40
e340bdf

中文 / English


🇨🇳 中文

本次发布带来 翻译模式(Translation Mode),与原有的润色(口述)流程并列。

✨ 新功能

  • F8 翻译模式:按住 F8(可在 Settings 里改)口述一种语言,自动翻译后注入到光标位置。复用 F9 润色相同的 Azure Speech → OpenAI 管道。
  • TranslationPrompt 模块:结构化的翻译提示词,规避 Azure 内容过滤的越狱检测。
  • Settings UI 翻译区:在 Tauri 设置面板新增翻译相关配置——启用开关、热键、源/目标语言、提示词覆盖。
  • 润色提示词 显式要求英文技术词保持原样,告别 APIJSON 等被乱译的情况。

🐛 修复

  • 修复 kPromptTidy 中的乱码字符(U+FFFD 替换字符)。
  • 修复翻译提示词触发 Azure 内容过滤越狱检测的问题。
  • 翻译配置回填复用 defaultConfig()(来自 PR #5 review)。

🛠 工程

  • 新增 scripts/stage-portable.ps1,本地复现 CI 的 portable zip 打包流程,方便 dogfood 不用推 tag。
  • 测试栈已就位(#1):GoogleTest(core) + Vitest(settings UI) + cargo test(Tauri 后端)。

📦 使用

下方下载 OneKeyInput-0.2.0-portable.zip,解压到任意目录:

  1. 先跑 onekey-settings.exe 配 Azure key、热键、目标语言
  2. 再跑 onekey-core.exe 常驻
  3. 首次启动 SmartScreen 会拦截(未签名),点「仍要运行」即可

🇬🇧 English

This release introduces Translation Mode alongside the existing polish (dictation) pipeline.

✨ New features

  • F8 Translation Mode — press-and-hold F8 (configurable) to dictate in one language and have the result translated and injected at the cursor. Reuses the same Azure Speech → OpenAI pipeline as F9 polish.
  • TranslationPrompt module with a structured translator prompt designed to survive Azure content-filter jailbreak detection.
  • Settings UI — new Translation section in the Tauri settings app: enable/disable, hotkey, source & target language, prompt overrides.
  • Polish prompt now explicitly keeps English technical terms verbatim (no more mangled API, JSON, etc.).

🐛 Fixes

  • Fixed mojibake (U+FFFD replacement char) in kPromptTidy.
  • Translate prompt no longer trips Azure content-filter jailbreak heuristics.
  • Polish reuses defaultConfig() for translate backfill (review feedback from #5).

🛠 Tooling

  • scripts/stage-portable.ps1 — local equivalent of the CI portable-zip staging step, useful for dogfooding without pushing a tag.
  • Test stacks landed in #1: GoogleTest (core), Vitest (settings UI), cargo test (Tauri backend).

📦 Download

Grab OneKeyInput-0.2.0-portable.zip below, unzip anywhere:

  1. Run onekey-settings.exe first to configure Azure keys, hotkeys, target language
  2. Then run onekey-core.exe to keep it resident
  3. SmartScreen will block on first launch (binary is unsigned) — click "Run anyway"

Full Changelog: https://github.com/zwcih/one-key-input/commits/v0.2.0