Repository navigation
Local Transcribe 1.5.0-beta.4 — macOS + Windows
Local Transcribe 1.5.0-beta.4
中文
这次修复了三个真实问题,其中一个是会导致应用闪退的严重 bug。
修复:部分音视频导入后应用直接闪退
根因:媒体时长不是 30 秒整数倍时,最后会剩一个很短的尾巴分块(例如 120.065 秒 → 4 个整块 + 65 毫秒)。这么短的输入会让语音模型内部的 onnxruntime 在卷积层抛出 C++ 异常(Invalid input shape: {1,39}),Rust 无法捕获外部异常,进程随即 abort,表现为无提示闪退。这解释了"有的视频闪退、有的不闪退"——取决于时长除以 30 秒的余数。
- 现在 0.5 秒以下的尾巴不再送进模型;0.5–1 秒的输入补静音到 1 秒,时间轴仍按真实长度记录。
- 用导致崩溃的原文件在 zipformer / paraformer / fire-red 三种模型上验证通过,不再闪退。
修复:Windows 上首页删除记录没反应
删除命令原来用 $HOME 拼废纸篓路径,而 Windows 没有这个环境变量,命令在碰任何文件之前就失败了。现在 Windows 走真正的回收站(SHFileOperationW + FOF_ALLOWUNDO),macOS 仍进 ~/.Trash。同一修复也覆盖了局域网节点与服务端的历史清理。
修复:静音音频被"转写"成幻觉文字、控制标记泄漏
- 接近静音的分块不再送进模型(Paraformer 面对静音会编出"怎么了什么"这类不存在的句子)。
- 模型输出的
<sil>、<unk>等控制标记会被剔除,不再混进正文。
改进:长视频不再整段解码进内存
改为一解码、二重采样、三分块识别,内存只保留当前一个分块(此前两小时 48 kHz 视频需要约 1.9 GB 解码音频驻留内存)。
界面:窗口变窄时工具栏只保留图标
阅读器工具栏改为按自身可用宽度响应(容器查询):窄于 560 px 时隐藏文字与快捷键提示,只显示图标(查找、询问 AI 补齐了图标),避免文字被挤成竖排。
English
Three real fixes, one of them a crash.
Fixed: some media closed the app while importing
When the media duration is not a multiple of 30 s, decoding leaves a very short tail chunk (e.g. 120.065 s → four 30 s chunks plus 65 ms). Such input made onnxruntime throw a C++ exception in a Conv node (Invalid input shape: {1,39}); Rust cannot catch foreign exceptions, so the process aborted with no message. That is why "some videos crash and some do not" — it depends on duration modulo 30 s.
- Tails shorter than 0.5 s are no longer sent to the model; inputs between 0.5 s and 1 s are zero-padded to 1 s while timestamps keep the real length.
- Verified with the original crashing file on zipformer, paraformer and fire-red.
Fixed: deleting a record on Windows did nothing
The delete command built the Trash path from $HOME, which Windows does not define, so it failed before touching any file. Windows now moves records to the real Recycle Bin (SHFileOperationW + FOF_ALLOWUNDO); macOS keeps ~/.Trash. The same fix covers LAN node and service retention cleanup.
Fixed: silence hallucinated text, control tokens leaked
- Near-silent chunks are skipped instead of being "transcribed" (paraformer invented "怎么了什么" from silence).
- Control tokens such as
<sil>are stripped from model output.
Changed: long media streams instead of decoding into memory
Decoding, resampling and recognition now run chunk by chunk; only the current chunk stays in memory (a two-hour 48 kHz video previously needed ~1.9 GB of decoded audio).
UI: the toolbar collapses to icons in a narrow window
The reader toolbar now responds to its own width (container query): below 560 px it hides labels and shortcut hints and keeps icons only (find and Ask AI gained icons), so labels never stack vertically.
校验 / Verification
cargo fmt --check,cargo test --workspace(248 passed),cargo clippy -D warnings,npm run check(0/0),npm test(119 passed).- macOS DMG: built locally from the release commit, strict
codesign --verify --deep --strictpasses (ad-hoc signature, not notarized). - Windows MSI: built by the Windows CI workflow from the same commit (Rust tests, Clippy, frontend check and MSI packaging all green).
- Windows builds are unsigned; macOS is ad-hoc signed and not notarized.