Specialized variant of
coriollon/whisper-large-v3-turbo-russian
optimized for
Russian speech with embedded English tech terms ("Открой Python и сделай git push").
¹ Term accuracy = fraction of utterances where the English tech term (e.g. "Python",
"GitHub", "Docker") appears verbatim in latin script in the transcript.
1from transformers import WhisperProcessor, WhisperForConditionalGeneration
2import torch
3
4repo = "coriollon/whisper-large-v3-turbo-russian-codeswitch"
5processor = WhisperProcessor.from_pretrained(repo)
6model = WhisperForConditionalGeneration.from_pretrained(repo, torch_dtype=torch.float16).to("cuda")
7
8inputs = processor(audio_array, sampling_rate=16000, return_tensors="pt")
9feats = inputs.input_features.to("cuda", dtype=torch.float16)
10ids = model.generate(feats, language="ru", task="transcribe", num_beams=5)
11print(processor.batch_decode(ids, skip_special_tokens=True)[0])
1from huggingface_hub import snapshot_download
2from faster_whisper import WhisperModel
3
4ct2_path = snapshot_download(
5 repo_id="coriollon/whisper-large-v3-turbo-russian-codeswitch",
6 allow_patterns="ct2_int8_float16/*",
7)
8model = WhisperModel(f"{ct2_path}/ct2_int8_float16", device="cuda", compute_type="int8_float16")
9segments, _ = model.transcribe("audio.wav", language="ru", beam_size=5)
Reference labels in mixed script ("Открой Python") teach the model to natively output
latin tokens for English terms instead of cyrillic transliteration ("питон").
Apache 2.0 (inherited from base Whisper model).