← All work

Indic Speaker-Attributed ASR

Who said what, across 9 Indic scripts: a diarization and ASR benchmark, and the two decode defects that dominated it

Role
Solo Developer
Timeline
Sep 2026
Context
Personal project · open source

The outcome

  1. Benchmarked 3 diarizers × 3 ASR systems on 99 recordings (12.26 h, 9 scripts, 2–8 speakers, 7.61% overlapped speech) at collar 0 with overlap scored; pyannote 3.1 was best at DER 27.34 / JER 38.14, which a 0.25 s collar with overlap excluded would report as 20.58.
  2. Language-locked decoding of IndicConformer's multi-softmax CTC head took WER 93.66 → 78.82 and cpWER 94.15 → 79.67 on the same weights and audio.
  3. The language-ID fallback to Whisper cut WER to 71.71, cpWER 79.67 → 72.96 and WDER 20.12 → 9.32, with 12 recordings better, 87 unchanged and 0 worse under pyannote 3.1, and gains on all three diarizers.
  4. Devanagari WER fell 79.16 → 57.20, better than either system alone (Whisper 69.39), while routing in-set languages to Whisper made corpus WER worse (82.56).
  5. A deterministic Whisper decode (temperature 0) replaced 87/84/100 words across identical runs with 211 every time, moved corpus WER 86.62 → 85.70 and cut runtime from 396 to 153 minutes.
  6. LLM speaker relabelling was built, guarded and rejected on its own numbers (cpWER 79.67 → 80.00), with an oracle audit putting 37.87% of words beyond the reach of any relabel.
  7. cpWER sits under 1 point above WER, so recognition, not attribution, is the bottleneck; only 24% of pyannote's error seconds fall in overlapped speech.
  8. The end-to-end Colab notebook re-runs each model on a 3-recording subset and recomputes every CPU stage over all 99, reproducing 0.00% DER for all three diarizers and identical word sequences for all three ASR systems on different hardware.

The challenge

A staged pipeline that diarizes multi-speaker Indic recordings, transcribes them, and assigns every word to a speaker, benchmarked on 12.26 hours of labelled YouTube audio across 9 scripts and 2–8 speakers. Three diarizers and three ASR systems are crossed on identical words, so a difference between two rows is a difference in one component, not in what each system happened to hear. The headline finding is that two decoding defects, not the models, set most of the error, and that one language-ID rule removed a further 6.71 cpWER points without making any recording worse.

Speaker-attributed ASR is usually reported as one number for one configuration, which hides whether the error is in recognition, in attribution, or in how the output was decoded. Indic audio makes this worse: the languages share acoustics but not scripts, so a system can hear the speech correctly and still score 100% WER by writing it in the wrong alphabet. Separating those causes needs a harness where exactly one thing changes between any two numbers.

The system

Each stage is a separate script, and the filesystem is the only interface between them: every system writes to its own directory (data/hyp/<diarizer>, data/asr/<asr>, data/attrib/<asr>__<diarizer>), so adding a system never touches the code downstream of it. ASR sees audio only and runs once per recording. IndicConformer is decoded in two passes over 30 s chunks with 2 s overlap: the first pass votes the language over every speech frame of the whole clip, the second decodes inside that language's block, and a word is kept only by the chunk whose core holds its midpoint. The language-ID fallback is emitted as a fourth ASR system rather than a special case, and a CPU-only attribution stage then labels each word with the diarizer turn it overlaps most, once per (ASR, diarizer) pair. Relabelling may only move whole units between existing speakers, and the projection back to RTTM keeps the diarizer's own turn boundaries and changes only labels, so missed speech and false alarm cannot move. Reference labels are read by the scorers and by diagnostics marked oracle, never by a model. The GPU stages checkpoint to append-only, fsync'd manifests that tolerate a truncated last line and retry anything not marked ok, so a dead Kaggle session costs the clip in flight; the scoring and report stages hold no state and rebuild from per-clip counts in seconds, so a metric bug never costs a GPU run. Each GPU stack has its own environment, because NeMo, pyannote, faster-whisper and onnxruntime-gpu pin conflicting numpy and cuDNN versions.

WAVturnsRTTMwords + LID4 word setsattributed wordsunitsword labelsRTTMscorers onlyStage 1 · audioyt-dlp → 16 kHz mono WAVDiarizationpyannote 3.1 · SortformerWhole-clip ASRIndicConformer · WhisperLID fallbackout-of-set → Whisper wordsWord → turnmax overlap · orphans keptRelabellingrule · Qwen2.5-7B 4-bitTurn projectiondiarizer bounds · 0-edit ctlStage 2 · referencesRTTM + attributed textScorers + reportDER/JER · cpWER/WDER
Indic Speaker-Attributed ASR — stages joined only through per-system directories on disk

The hard parts

  1. A multi-softmax CTC head decoded as if it were one softmax

    IndicConformer scores each language in its own 256-token block with its own softmax, so logits from different blocks are not on one scale, and a global argmax spelled single words across six scripts at once. The fix was to vote for the recording's language over its speech frames and decode inside that block only. WER went from 93.66 to 78.82 with the same weights and the same audio. The naive decode is kept as a scored ablation, because the size of the gap is the evidence that the defect was real.

  2. A benchmark that returned a different answer every run

    faster-whisper's default temperature fallback samples without a seed, so one recording returned 87, 84 and 100 words on three identical runs. Pinning temperature to 0 returns 211 words every time. It also improved corpus WER from 86.62 to 85.70 and cut runtime from 396 to 153 minutes, so determinism cost nothing.

  3. A language-ID fallback, and the check that it wasn't fitted

    On 13 recordings IndicConformer's own vote chose Urdu or Nepali, and every word came out in the wrong script at 100% WER; spoken Hindi and Urdu differ mainly in script, so this is real acoustic ambiguity. The rule takes Whisper's words when the detected language is outside the ten served codes, and reads no reference. cpWER goes 79.67 → 72.96 with 12 recordings better, 87 unchanged and 0 worse, on all three diarizers. The counterfactual, routing clips detected as Hindi or Marathi to Whisper instead, makes corpus WER worse (82.56), so the gain is the rule and not a general preference for Whisper.

  4. Building the LLM relabeller, and reporting that it failed

    Relabelling from the transcript, after DiarizationLM, ran Qwen2.5-7B-Instruct in 4-bit over windows of 25 units, dropped edits below 0.7 confidence, discarded any recording where it tried to edit over 30% of units, and asserted per clip that the text never changed. It made cpWER worse (79.67 → 80.00) and WDER worse (20.12 → 20.96), with 6 recordings better against 19 worse. An oracle audit gives the mechanism: even after splitting at pauses over 0.5 s, 37.87% of words sit in units that span two true speakers, where no relabel can help.

  5. Scoring a word-level fix on a turn-level metric

    Relabelling edits words, but DER is measured over time, and turns rebuilt from word spans are shorter than the diarizer's, so DER would move for a reason unrelated to the edits. The projection keeps the diarizer's boundaries exactly and gives each turn the duration-weighted majority label of its words. Even with zero edits that already moves DER from 27.34 to 29.03, so the zero-edit projection is the control: against it the rule costs +1.52 DER and the LLM +0.87, and the results table prints the control beside every DER.

What I took from it

  • Read a model's output contract before trusting its decode. A per-language softmax argmaxed globally produces confident nonsense, and 14.84 WER points sat behind that one assumption.
  • Hold everything constant but one thing. Transcribing once and attributing per (ASR, diarizer) pair is what lets a cpWER difference be read as a labelling difference.
  • A negative result needs a mechanism. The relabeller's failure is only useful because the oracle audit says why: 37.87% of words are in units no relabel could fix.
  • Quote the strict number and print the lenient one beside it, and give every method its fair control. Both are what keep a benchmark figure comparable to someone else's.

Stack

Diarization
pyannote 3.1, Sortformer 4spk-v1, NeMo
ASR
IndicConformer-600M, ONNX Runtime, Whisper large-v3, faster-whisper
Relabelling
Qwen2.5-7B-Instruct, bitsandbytes 4-bit, transformers
Metrics
pyannote.metrics, MeetEval, WDER, rapidfuzz
Pipeline
Python, yt-dlp, ffmpeg, Colab / Kaggle T4, Append-only manifests

Timeline

  1. Sep 2026

    Six-stage diarization and ASR benchmark pipeline; reference cleaning and the metric policy.

  2. Sep 2026

    Stage 5 relabelling (rule and LLM) plus the zero-edit DER projection control.

  3. Sep 2026

    Language-ID fallback: IndicConformer, or Whisper when its own LID lands out of set.

  4. Sep 2026

    End-to-end Colab notebook reproducing every committed table, and the write-up.

Download resume