An open automatic speech recognition (ASR) model for Kalenjin — a Highland Nilotic
language of Kenya's Rift Valley (~2M speakers). This is an
honest fine-tune of NVIDIA's
parakeet-tdt-0.6b-v3 (a 0.6B-parameter
FastConformer encoder with a Token-and-Duration Transducer decoder).
It is not trained from
scratch, and it does
not beat the strongest closed baseline overall — see
Results for the
honest comparison.
Adaptation rebuilds the SentencePiece tokenizer to Kalenjin orthography (vocab 2048, BPE,
preserving the velar-nasal apostrophe in ng' — a real Kalenjin letter, not punctuation),
reinitializes the decoder embedding + joint head to the new vocabulary, and keeps the acoustic
encoder warm. Covered dialects: Kipsigis and Nandi.
Character Error Rate (CER) is the primary metric — Kalenjin has no single agreed orthography,
which inflates WER. 95% confidence intervals are paired bootstrap (B=2000, seed=1234).
1import torch, soundfile as sf
2from transformers import (ParakeetForTDT, ParakeetProcessor, ParakeetTokenizer,
3 LogitsProcessorList)
4
5repo = "Tonykip/parakeet-tdt-0.6b-kalenjin"
6model = ParakeetForTDT.from_pretrained(repo, dtype=torch.bfloat16).to("cuda").eval()
7processor = ParakeetProcessor.from_pretrained(repo)
8processor.tokenizer = ParakeetTokenizer.from_pretrained(repo) # the rebuilt Kalenjin tokenizer
9
10V = model.config.vocab_size
11class MaskDurations: # keep argmax inside the real vocab
12 def __call__(self, input_ids, scores):
13 if scores.shape[-1] > V:
14 scores[..., V:] = float("-inf")
15 return scores
16
17wav, sr = sf.read("clip.wav") # mono; resample to 16 kHz if needed
18feats = processor.feature_extractor(wav, sampling_rate=16000, return_tensors="pt")
19feats = {k: (v.to("cuda", dtype=model.dtype) if torch.is_floating_point(v) else v.to("cuda"))
20 for k, v in feats.items()}
21with torch.no_grad():
22 out = model.generate(**feats, logits_processor=LogitsProcessorList([MaskDurations()]))
23seq = out.sequences if hasattr(out, "sequences") else out
24print(processor.tokenizer.decode(seq[0], skip_special_tokens=True))
1@misc{kipkemboi2026parakeetkalenjin,
2 title = {Open Kalenjin Automatic Speech Recognition: Fine-tuned Parakeet Models and the KaleBench-ASR Benchmark},
3 author = {Kipkemboi, Tony},
4 year = {2026},
5 note = {Preprint}
6}