Downloads · 30 days
16
10% of all-time downloads
joshuavinith/whisper-small-hindi
whisper-small-hindi is a automatic speech recognition model from joshuavinith. Use it when you need speech turned into text. The card lists the license as mit.
Fine-tuned openai/whisper-small on approximately 10 hours of conversational Hindi speech, achieving a WER reduction from 48.26% → 31.51% on the in-domain evaluation set.
Downloads · 30 days
16
10% of all-time downloads
All-time downloads
156
Public
Parameters
242M
967 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors967 MB · 100%
From the Hugging Face model README
Fine-tuned openai/whisper-small on approximately 10 hours of conversational Hindi speech, achieving a WER reduction from 48.26% → 31.51% on the in-domain evaluation set.
This model is a domain-adapted version of Whisper-small, fine-tuned for conversational Hindi ASR. The base model was adapted using a carefully engineered utterance-level dataset derived from 104 long-form Hindi recordings. Key contributions include a custom data pipeline, disfluency-aware dataset construction, and a novel lattice-based multi-system consensus evaluation framework.
The training corpus was constructed from scratch from 104 long-form conversational Hindi recordings (~10 hours total). The pipeline involved:
pydublibrosaA unique-word spelling analysis across 7,457 transcript tokens found 65.5% were orthographically noisy, directly informing text normalization strategy.
| Parameter | Value |
|---|---|
| Base model | whisper-small |
| Epochs | 4 (best at epoch 3) |
| Batch size | 8 |
| Learning rate | 1e-5 |
| Optimizer | AdamW |
| Weight decay | 0.01 |
| Warmup steps | 500 |
| Mixed precision | FP16 |
| Gradient checkpointing | Enabled |
| Framework | HuggingFace Seq2SeqTrainer |
| Epoch | Validation Loss | WER (%) |
|---|---|---|
| 1 | 0.3356 | 39.24 |
| 2 | 0.3030 | 33.01 |
| 3 | 0.3120 | 31.51 |
| 4 | 0.3606 | 32.48 |
Baseline (pretrained Whisper-small): 48.26% WER
Best fine-tuned (epoch 3): 31.51% WER
Improvement: 16.75 percentage points (~35% relative reduction)
The fine-tuned model was also evaluated on an external clean read-speech Hindi benchmark. It consistently outperformed the pretrained Whisper-small baseline on this out-of-domain set, demonstrating that fine-tuning improved general Hindi ASR capability beyond the conversational domain.
A novel lattice-style multi-system consensus framework was designed to evaluate 6 ASR hypotheses jointly via Levenshtein dynamic programming with gap modeling. Most models showed reduced WER under the lattice reference vs a single human transcript, indicating that some apparent errors were reference disagreements rather than true recognition mistakes.
from transformers import WhisperForConditionalGeneration, WhisperProcessor
import librosa
import torch
processor = WhisperProcessor.from_pretrained("joshuavinith/whisper-small-hindi")
model = WhisperForConditionalGeneration.from_pretrained("joshuavinith/whisper-small-hindi")
model.eval()
# Load audio (must be 16kHz mono)
audio, sr = librosa.load("your_hindi_audio.wav", sr=16000, mono=True)
inputs = processor(audio, sampling_rate=16000, return_tensors="pt")
with torch.no_grad():
predicted_ids = model.generate(
inputs["input_features"],
language="hi",
task="transcribe"
)
transcript = processor.batch_decode(predicted_ids, skip_special_tokens=True)[0]
print(transcript)
Try the model directly in your browser — no code needed:
🔗 huggingface.co/spaces/joshuavinith/hindi-asr-demo
A production-ready FastAPI wrapper is available:
git clone https://github.com/joshuvavinith/hindi-asr-whisper
cd hindi-asr-whisper
docker build -t hindi-asr-api .
docker run -p 8000:8000 hindi-asr-api
Then POST audio to http://localhost:8000/transcribe — interactive docs at /docs.
If you use this model or the associated pipeline in your work, please cite:
@misc{joshuvavinith2024hindiasr,
author = {Joshuva Vinith},
title = {Hindi ASR: Dataset Construction, Whisper Fine-Tuning, Disfluency Detection, and Lattice Evaluation},
year = {2024},
note = {ArXiv preprint in preparation}
}
Joshuva Vinith
B.Tech — Artificial Intelligence & Data Science
📧 [email protected] | 🔗 GitHub