AI & ML interests

Speaker diarization

Recent Activity

wq2012Β  updated a Space about 13 hours ago
diarizers-community/diarizers
wq2012Β  published a Space about 14 hours ago
diarizers-community/diarizers
wq2012Β  updated a Space about 19 hours ago
diarizers-community/DiarizationLM-GGUF
View all activity

Organization Card

πŸ€— Diarizers Community β€” Open-Source ASR, Speaker Diarization, and DiarizationLM Post-Processing

diarizers-community builds open-source models and software for speaker-attributed automatic speech recognition (ASR + Speaker Diarization + DiarizationLM Post-Processing):


Architecture of diarizers (v1.0.0)

diarizers (v1.0.0) provides a 100% Apache-2.0 / MIT 4-stage pipeline for speaker-attributed transcription and LLM post-processing:

  1. Stage 1 β€” Timestamped ASR (diarizers.asr): openai/whisper-large-v3-turbo (WhisperWordASR, MIT License) with native Whisper <|t.tt|> segment-level timestamps and character-length-proportional word timestamp interpolation (plus support for Qwen/Qwen3-ASR GGUF via audio.cpp, Apache-2.0 License).
  2. Stage 2 β€” Neural Speaker Turn Segmentation + Speaker Embeddings + Spectral Clustering (diarizers.diarization & diarizers.spectral):
    • Standalone PyTorch pyannote/segmentation-3.0 (PyanNetSegmentation: SincNet + 4-layer BiLSTM + 7-class powerset classifier, MIT License) for local speaker-change flux boundary snapping.
    • Standalone PyTorch speechbrain/spkrec-ecapa-voxceleb (SpeechBrainECAPATDNN, Apache-2.0 License) with exact HTK decibel-scaled (10 * log10) 80-bin log-mel filterbanks, global embedding mean subtraction, and recording-level channel centering.
    • Clean-room Symmetric Normalized Laplacian Spectral Clusterer (L_sym = I - D^{-1/2} W D^{-1/2}, Apache-2.0 License) with Gaussian temporal smoothing and calibrated eigengap speaker count estimation (eigen_threshold=0.45).
  3. Stage 3 β€” Word-to-Turn Alignment & Chunked Prompting (diarizers.alignment): Sub-millisecond assign_speakers overlap orchestration, nearest-turn midpoint fallback, and 4,000-character chunked prompt generation (ChunkedPromptBuilder).
  4. Stage 4 β€” DiarizationLM-Gemma-4-E4B-v1 Post-Processing & LG-TPST (diarizers.llm & diarizers.alignment): Post-processing via diarizers-community/DiarizationLM-Gemma-4-E4B-v1 (CPU llama.cpp Q4_K_M GGUF or GPU/CPU Hugging Face transformers), Hungarian inter-chunk permutation reconciliation, Myers' (1999) bit-parallel exact word-level Levenshtein alignment (tpst_align), and Locality-Gated Transcript-Preserving Speaker Transfer (LG-TPST).

Benchmark Evaluation Results

All metrics are micro-averaged across the full evaluation splits (172 Fisher conversations, 20 CALLHOME-English calls, 3 ICSI meetings, and 16 AMI Mix-Headset meetings = 211 test recordings).

1. Open-Source Frontend (diarizers v1.0.0) + DiarizationLM-Gemma-4-E4B-v1

Benchmark (Full Test Split) Utterances Pipeline / System WER (%) WDER (%) cpWER (%) SpkCntMAE
Fisher English 172 diarizers v1.0.0 Open Frontend (Whisper-large-v3-turbo + pyannote/seg-3.0 + ECAPA-TDNN + SpectralClusterer, Fixed K=2) 20.80 4.35 24.78 0.000
Fisher English 172 diarizers v1.0.0 + DiarizationLM-Gemma-4-E4B-v1 (LG-TPST) 20.80 2.59 (Raw: 2.65) 21.91 (Raw: 21.99) 0.000
CALLHOME English 20 diarizers v1.0.0 Open Frontend (Auto Speaker Count [2..6], eigen_threshold=0.45) 21.25 9.42 32.42 0.050
CALLHOME English 20 diarizers v1.0.0 + DiarizationLM-Gemma-4-E4B-v1 21.25 4.89 (LG-TPST: 5.98) 25.91 (LG-TPST: 27.69) 0.050
ICSI Meeting Corpus 3 diarizers v1.0.0 Open Frontend (Auto Speaker Count [2..10], eigen_threshold=0.45) 35.29 23.48 48.97 3.333
ICSI Meeting Corpus 3 diarizers v1.0.0 + DiarizationLM-Gemma-4-E4B-v1 (LG-TPST) 35.29 23.10 (Raw: 23.11) 48.62 (Raw: 48.63) 3.333
AMI (Mix-Headset) 16 diarizers v1.0.0 Open Frontend (AMI_MEETING_PRESET, Auto Speaker Count [3..5], eigen_threshold=0.45) 29.14 20.68 46.07 0.688
AMI (Mix-Headset) 16 diarizers v1.0.0 + DiarizationLM-Gemma-4-E4B-v1 29.14 20.13 (LG-TPST: 20.14) 45.53 (LG-TPST: 45.56) 0.688

Note: Post-LLM evaluation numbers above were computed with the full-precision (bfloat16) DiarizationLM-Gemma-4-E4B-v1 checkpoint using 6,000-character prompt chunks. For CPU deployment, the repository also provides the 4-bit quantized DiarizationLM-Gemma-4-E4B-v1-q4_k_m.gguf model (4,000-character default chunks).

2. USM + Turn-to-Diarize Frontend + DiarizationLM-Gemma-4-E4B-v1

Benchmark Test Split WER (%) System WDER (%) [95% CI] cpWER (%) [95% CI] SpkCntMAE [95% CI] Paired Ξ”WDER vs. Baseline
Fisher TEST FULL (172 sessions) 15.37 Baseline (USM + Turn-to-Diarize)
DiarizationLM-Gemma-4-E4B-v1 (4B)
5.32 [4.93, 5.74]
2.99 [2.65, 3.37]
20.88 [19.97, 21.88]
17.62 [16.76, 18.56]
0.215 [0.151, 0.291]
0.093 [0.047, 0.145]
-2.33% (p < 0.0001)
CALLHOME TEST FULL (20 calls) 15.22 Baseline (USM + Turn-to-Diarize)
DiarizationLM-Gemma-4-E4B-v1 (4B)
7.74 [6.07, 9.65]
4.92 [3.46, 6.75]
24.31 [21.27, 27.43]
20.69 [17.98, 23.66]
0.050 [0.000, 0.150]
0.000 [0.000, 0.000]
-2.82% (p < 0.0001)
ICSI TEST FULL (3 meetings) 29.42 Baseline (USM + Turn-to-Diarize)
DiarizationLM-Gemma-4-E4B-v1 (4B)
14.70 [11.65, 20.29]
14.10 [10.77, 19.94]
43.90 [39.10, 51.67]
43.32 [38.38, 51.20]
0.333 [0.000, 1.000]
0.333 [0.000, 1.000]
-0.60% (p < 0.0001)
AMI TEST WORD FULL (16 meetings) 24.33 Baseline (USM + Turn-to-Diarize)
DiarizationLM-Gemma-4-E4B-v1 (4B)
15.68 [10.64, 21.11]
14.89 [9.80, 20.38]
40.32 [32.43, 48.00]
39.57 [31.57, 47.29]
0.500 [0.188, 0.812]
0.438 [0.188, 0.750]
-0.79% (p < 0.0001)

Quickstart

pip install "diarizers[audio,llm]"
import diarizers

pipe = diarizers.DiarizersPipeline.from_pretrained(
    asr_model="openai/whisper-large-v3-turbo",
    diarizer_preset=diarizers.FISHER_TELEPHONY_PRESET,
    llm_model_or_path="diarizers-community/DiarizationLM-Gemma-4-E4B-v1",
    llm_gguf_filename="DiarizationLM-Gemma-4-E4B-v1-q4_k_m.gguf",
    llm_backend="gguf",
    device="cpu",
)

transcript = pipe("conversation.wav", num_speakers=2)
print(transcript.to_diarized_text())
print(transcript.to_rttm(recording_id="conversation"))
print(transcript.to_srt())

For full documentation, CLI usage, SFT training recipes, and evaluation tools, visit https://github.com/diarizers-community/diarizers.