#2239

[BUG] Traditional Chinese conversion skipped when mixed Chinese-English speech is detected as English

Openfafalala75-opsopened 22d ago

Before You Submit

  • Searched existing issues and discussions. Related: #2143 (History/Live display vs pasted OpenCC-converted text), #605 (older post-processing behavior). Neither appears to cover language-gated conversion for mixed-language output.

Bug Description

With Advanced > Chinese script conversion = Traditional, a mixed Mandarin/English dictation can still produce Simplified Chinese in the pasted text. The repro occurs when the speech model detects the overall language as English, even though the output also contains Mandarin.

This is particularly disruptive to users in Taiwan who dictate naturally in both languages and expect the Traditional Chinese setting to apply to any Chinese portions of their transcript.

Actual result (short excerpt from my test):

欸我跟你说,我今天早上本来想要去咖啡厅工作,结果一打开电脑就发现,Oh my god, I forgot to charge my laptop last night.

Expected script (without changing the language of the English words):

欸我跟你說,我今天早上本來想要去咖啡廳工作,結果一打開電腦就發現,Oh my god, I forgot to charge my laptop last night.

This report is about script conversion, not a request to translate or rewrite spoken words.

Steps to Reproduce

  1. On Handy v0.9.8, set Advanced > Chinese script conversion = Traditional.
  2. Select Whisper Large v3 Turbo (Q8_0), with recognition language Auto Detect.
  3. Leave Translate to English = off and AI post-processing disabled.
  4. Record a ~53-second passage that switches between English and Mandarin, including an English introduction.
  5. Observe that Simplified Chinese can appear in the output despite the Traditional setting.

I also re-transcribed the exact same 53.31-second recording with Qwen3-ASR 0.6B and Breeze-ASR-25. Those runs were detected as zh and resulted in Traditional Chinese. The Whisper Turbo run was detected as en and produced Simplified Chinese.

Relevant debug evidence (transcript content omitted)

[2026-10-08][09:45:22] transcribe-cpp run: task=Transcribe, language=None, initial_prompt=false
[2026-10-08][09:45:37] Output language evidence: ModelDetected("en")
[2026-10-08][09:45:37] Transcription completed in 15.80s for 53.31s of audio

The current settings file confirms chinese_script=traditional, selected_language=auto, translate_to_english=false. I am not uploading full logs because they may contain dictated text.

System Information

  • App version: Handy v0.9.8 (installed from the official website)
  • Operating system: Windows 11 Home
  • CPU: Intel Core i5-12500H
  • GPU: Intel Iris Xe, Vulkan backend
  • Model: Whisper Large v3 Turbo Q8_0
  • Chinese script: Traditional
  • Recognition language: Auto Detect
  • English translation: Disabled
  • AI post-processing: Disabled

Suspected Cause / Maintainer Question

In src-tauri/src/managers/transcription.rs (v0.9.8), post_process_transcription_text() appears to derive a single ChineseVariety from OutputLanguageEvidence. When a mixed-language transcript reports ModelDetected("en"), ChineseVariety::from_language("en") returns None, so the existing OpenCC conversion is skipped even when the transcript contains Chinese characters.

Would maintainers consider a small bug fix to apply the existing Taiwan Traditional conversion to Chinese content in mixed-language output, while preserving English text and avoiding accidental changes to Japanese kanji?

Ideally it would reuse the existing OpenCC converter, require no new AI model, and add negligible latency. If this direction is acceptable, I would be happy to investigate a minimal PR after receiving maintainer guidance.

Related but distinct from #2143: that issue addresses what the History/Live UI displays versus the pasted text. Here the pasted transcript itself can remain Simplified because the overall language was detected as English.

Thank you for maintaining Handy!

Activity

4
cjpais22d ago

Yeah, I definitely would love to try a fix. And if you have a fix, I would really appreciate it. I certainly contest with traditional Chinese as well as I can speak a little bit of Mandarin. 我住在台灣!I'm primarily an English speaker, so I didn't catch this myself

fafalala75-ops22d ago

Oh wow, I had no idea you live in Taiwan! What a lovely surprise! 😄

Thank you so much for the quick response and for being open to a fix. I'd be happy to give it a try!

I'll first take a closer look at the existing code and the related PR (#1929) to avoid duplicating work. My goal is to make a small, focused fix so Traditional Chinese conversion works correctly in mixed Mandarin/English transcriptions, even when the model detects English as the overall language, without affecting other languages.

I'll include regression tests and submit a PR referencing this issue once the fix is ready.

Thanks again! Really appreciate your openness to contributions!

cjpais22d ago

Thank you. Yeah, if it can be small and focused and make sure it works, that's the best thing possible. And since you're a user of this specific use case, it's perfect. So I really appreciate you wanting to make the fix and testing it. And I will definitely give it a try myself as well. For now, don't worry too much about the related PR. I think this fix is priority

fafalala75-ops22d ago

Got it! I'll keep the fix small and focused, and make sure to test it thoroughly before submitting a PR. Thanks again! 😊