🗣️ This framework is intended to provide an easy, ready-to-use and strong SepRQ feature extractor for 🍸 cocktail-party 🍸 and multi-talker conversational scenarios 🔀 👥, while also facilitating the use of other feature extractors from the literature. You can use the ready-to-use models to process your own audio across many cocktail-party speech tasks, both with and without speaker enrollment.
For an interactive overview, examples, and audio results, use the SepRQ website.
Install
Install the SepRQ package from PyPI:
pip install seprq
Quick navigation
-
Feature extraction. Extract frozen or fine-tunable representations.
-
Run a task. Choose a ready-to-use cocktail-party task.
| ID | Task name | Dataset | Enrollment |
|---|---|---|---|
| SS | Speech separation | Libri2Mix | No |
| SD | Speaker diarization | Libri2Mix | No |
| SE | Speech enhancement | VoiceBank-DEMAND | No |
| TSE | Target-speaker extraction | Libri2Mix | Yes |
| PSE | Personalized speech extraction | SparseLibriMix | Yes |
| PVAD | Personalized VAD | SparseLibriMix | Yes |
| TS-ASR | Target-speaker ASR | Libri2Mix | Yes |
| DH3 | Speaker Diarization (DIHARD 3) | DIHARD 3 | No |
| WSJ2 | Speech Separation (WSJ0-2mix) | WSJ0-2mix | No |
| WSJ3 | Speech Separation (WSJ0-3mix) | WSJ0-3mix | No |
- Learn more. Explore the architecture.
Feature extraction
Use the encoder frozen ❄️ or fine-tuned 🔥:
from seprq import SepRQEncoder
wav = "hf.co/SepRQ/SepRQ/blob/main/ex/mix.wav"
# wav = torchaudio.load("path/to/audio.wav")
# "SepRQ"; see "Available models" for every name
encoder = SepRQEncoder("SepRQ", streams=2)
# ❄️ frozen feature extraction
encoder.requires_grad_(False).eval() # or True for 🔥 fine-tuning
features = encoder(wav)
The class accepts a file path (any format/rate; decoded, converted to mono, and resampled to 16 kHz)
or a waveform tensor [num_samples], [batch, num_samples] or
[batch, channel, num_samples].
SepRQ ships in variants trained to separate a different number of speakers;
select one with streams (default 2):
encoder = SepRQEncoder("SepRQ", streams=3)
# 3-speaker variant
Available models
| name | layers | dim |
|---|---|---|
⭐ SepRQ ⭐ | 12 | 576 |
BestRQ_50Hz | 12 | 576 |
HuBERT_BASE | 12 | 768 |
WavLM_BASE | 12 | 768 |
WavLM_BASE_PLUS | 12 | 768 |
WavLM_LARGE | 24 | 1024 |
Run a task
Run a task in three steps:
- Choose an upstream from the available models.
- Choose a downstream task from the overview above.
- Run the pipeline with the corresponding example below (or your own audio).
Downstream heads are published for SepRQ (streams=2, and streams=3 on DIHARD 3
and WSJ0-mix), HuBERT_BASE, WavLM_BASE, and WavLM_BASE_PLUS.
Note: Extraction tasks require a speaker enrollment utterance.
Speech separation
from seprq import SepRQPipeline
pipe = SepRQPipeline("separation", upstream="SepRQ", streams=2)
# Input mixture - [num_samples]
mixture = "hf.co/SepRQ/SepRQ/blob/main/ex/SS/mix1.wav"
save_to = "./output"
sources = pipe(mixture, save_to=save_to)
# [num_speakers, num_samples]
# ./output/source1.wav
# ./output/source2.wav
Speaker diarization
from seprq import SepRQPipeline
pipe = SepRQPipeline("diarization", upstream="SepRQ", streams=2)
# Input mixture - [num_samples]
mixture = "hf.co/SepRQ/SepRQ/blob/main/ex/SD/mix1.wav"
save_to = "./output"
activations = pipe(mixture, save_to=save_to)
# [time, num_speakers]
# ./output/activations.rttm
Speech enhancement
from seprq import SepRQPipeline
pipe = SepRQPipeline("enhancement", upstream="SepRQ", streams=2)
# Input mixture - [num_samples]
mixture = "hf.co/SepRQ/SepRQ/blob/main/ex/SE/mix1.wav"
save_to = "./output"
clean = pipe(mixture, save_to=save_to)
# [num_samples]
# ./output/cleaned.wav
Target-speaker extraction
from seprq import SepRQPipeline
pipe = SepRQPipeline("target-speaker-extraction",
upstream="SepRQ",
streams=2)
# Input mixture - [num_samples]
mixture = "hf.co/SepRQ/SepRQ/blob/main/ex/TSE/mix1.wav"
enrollment = "hf.co/SepRQ/SepRQ/blob/main/ex/TSE/enroll1.wav"
save_to = "./output"
target = pipe(mixture, enrollment=enrollment, save_to=save_to)
# [num_samples]
# ./output/extracted_audio.wav
Personalized speech extraction
from seprq import SepRQPipeline
pipe = SepRQPipeline("personalized-extraction",
upstream="SepRQ",
streams=2)
# Input mixture - [num_samples]
mixture = "hf.co/SepRQ/SepRQ/blob/main/ex/PSE/mix1.wav"
enrollment = "hf.co/SepRQ/SepRQ/blob/main/ex/PSE/enroll1.wav"
save_to = "./output"
target = pipe(mixture, enrollment=enrollment, save_to=save_to)
# [num_samples]
# ./output/extracted_audio.wav
Personalized VAD
from seprq import SepRQPipeline
pipe = SepRQPipeline("personalized-vad", upstream="SepRQ", streams=2)
# Input mixture - [num_samples]
mixture = "hf.co/SepRQ/SepRQ/blob/main/ex/PVAD/mix1.wav"
enrollment = "hf.co/SepRQ/SepRQ/blob/main/ex/PVAD/enroll1.wav"
save_to = "./output"
activations = pipe(mixture, enrollment=enrollment, save_to=save_to)
# [time]
# ./output/activations.rttm
Target-speaker ASR
from seprq import SepRQPipeline
pipe = SepRQPipeline("target-speaker-asr",
upstream="SepRQ",
streams=2)
# Input mixture - [num_samples]
mixture = "hf.co/SepRQ/SepRQ/blob/main/ex/TS-ASR/mix1.wav"
enrollment = "hf.co/SepRQ/SepRQ/blob/main/ex/TS-ASR/enroll1.wav"
save_to = "./output"
text = pipe(mixture, enrollment=enrollment, save_to=save_to)
# ./output/extracted_transcript.txt
Speaker Diarization (DIHARD 3)
from seprq import SepRQPipeline
pipe = SepRQPipeline("diarization-dihard3",
upstream="SepRQ",
streams=2)
# Input mixture - [num_samples]
mixture = "hf.co/SepRQ/SepRQ/blob/main/ex/DH3/mix1.wav"
save_to = "./output"
activations = pipe(mixture, save_to=save_to)
# [time, num_speakers]
# ./output/activations.rttm
# Local segmentation only (EEND).
# Not intended for long file recordings without clustering.
Speech Separation (WSJ0-2mix)
from seprq import SepRQPipeline
pipe = SepRQPipeline("separation-wsj0-2mix",
upstream="SepRQ",
streams=2)
# Input mixture - [num_samples]
mixture = "hf.co/SepRQ/SepRQ/blob/main/ex/WSJ2/mix1.wav"
save_to = "./output"
sources = pipe(mixture, save_to=save_to)
# [num_speakers, num_samples]
# ./output/source1.wav
# ./output/source2.wav
Speech Separation (WSJ0-3mix)
from seprq import SepRQPipeline
pipe = SepRQPipeline("separation-wsj0-3mix",
upstream="SepRQ",
streams=3)
# Input mixture - [num_samples]
mixture = "hf.co/SepRQ/SepRQ/blob/main/ex/WSJ3/mix1.wav"
save_to = "./output"
sources = pipe(mixture, save_to=save_to)
# [num_speakers, num_samples]
# ./output/source1.wav
# ./output/source2.wav
# ./output/source3.wav
🔀 SepRQ: separation as the pretext task
SepRQ swaps masked prediction for pseudo source separation. It predicts one stream of discrete units per speaker in the mixture, at several temporal resolutions.

Fig. 1. SepRQ performs pseudo source separation in the discrete space. Random vector quantizers (RVQs) give speaker-specific discrete labels at several resolutions.
- Pseudo source separation: each separation head predicts the frozen BEST-RQ codewords of one clean speaker from the mixture. Utterance-level PIT resolves speaker order.
- Mask-free: masking can hide exactly the content needed to disentangle a mixture. SepRQ predicts units over the full utterance, which uses every frame for training.
- Multi-resolution: a separation objective follows every two Conformer layers, with frame folding going from 20 ms to 320 ms and one codebook per scale.
👥 Results
Frozen upstreams with SUPERB / TS-SUPERB downstream heads.
Multi-speaker SUPERB
Speaker diarization (SD), speech separation (SS) and speech enhancement (SE). LS = LibriSpeech, LL = Libri-Light, Mix = LL-60k + GigaSpeech-10k + VoxPopuli-24k.
TS-SUPERB
Target speaker extraction (TSE), personalized speech extraction (PSE), personalized VAD (PVAD), target-speaker ASR (TS-ASR).
Out-of-domain
EEND diarization on DIHARD 3 and ConvTasNet separation on WSJ0-2/3mix.
Citation
If SepRQ helps your research, please cite the paper: arXiv:2610.04690.
@misc{baroudi2026seprqselfsupervisedspeech,
title = {SepRQ : Self-Supervised Speech Mixture Representation Learning
via Mask-Free, Multi-Scale Source Separation},
author = {Séverin Baroudi and Hervé Bredin and Ricard Marxer},
year = {2026},
eprint = {2610.04690},
archivePrefix = {arXiv},
primaryClass = {eess.AS},
url = {https://arxiv.org/abs/2610.04690}
}