Use stock English Whisper for the English→Chin direction - #16
Merged
Conversation
The cnh-fine-tuned model specialized on Hakha Chin and degraded at English ASR,
re-spelling English words into Chin phonetics ('street' → 'strih'). For the
en→cnh direction, transcribe English with a stock English Whisper (EN_ASR_MODEL,
default small.en) and then translate en→cnh (already wired via DIRECTIONS).
- english_asr_model(): lazily loads the stock English model on first en→cnh use
(zero cost otherwise); falls back to the fine-tuned model if it can't load.
- on_utterance: en→cnh uses the English model; cnh→en keeps the fine-tuned one.
- APP_VERSION → v5.2.0-enasr; README documents EN_ASR_MODEL.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes the "street → strih" garbling in English→Chin mode.
Cause
The cnh-fine-tuned model specialized on Hakha Chin and lost English ASR fidelity (catastrophic-forgetting-lite). In en→cnh mode it was used to transcribe English, so it re-spelled English words into Chin phonetics — "street" → "strih" — and the bad token then passed through translation into both transcript lines.
Fix
english_asr_model()lazily loads a stock English Whisper (EN_ASR_MODEL, defaultsmall.en) on first en→cnh use — zero cost if that direction is never used. Falls back to the fine-tuned model if it can't load.on_utteranceroutes en→cnh through the English model; cnh→en keeps the fine-tuned model (its strength, unaffected).DIRECTIONS["en2cnh"]=sl=en, tl=cnh, line ~341) — no change needed there, confirmed.APP_VERSION→v5.2.0-enasr; README documentsEN_ASR_MODEL.Notes
small.en, ~244M) on the GPU, only when en→cnh is first used.Deploy test:
CT_BRANCH=feature/english-asr-en2cnh python hf_space/deploy_colab.py, switch to English → Hakha Chin, say "live on a street" — the source line should read real English now, and the Chin translation should follow.🤖 Generated with Claude Code