Speaker diarization for Python — who spoke when. Rust + ONNX, no Python runtime overhead. K-means/AHC clustering, overlap detection.
Project description
polyvoice
Speaker diarization for Python — who spoke when.
Rust-powered, ONNX-based speaker diarization that runs on CPU, fits in 30 MB, and requires zero Python runtime overhead. Pipeline v2 with K-means auto-k clustering and overlap detection.
Install
pip install polyvoice
Requires Python 3.9+.
Quick start
import polyvoice
# Models auto-download on first run (~30 MB)
pipeline = polyvoice.Pipeline.balanced()
result = pipeline.run(samples, sample_rate=16000)
print(f"Speakers: {result['num_speakers']}")
for turn in result["turns"]:
print(f"Speaker {turn['speaker']}: {turn['start']:.1f}s - {turn['end']:.1f}s")
API
polyvoice.Pipeline.balanced(models_cache=None)— balanced accuracy / speed.polyvoice.Pipeline.mobile(models_cache=None)— smaller, faster model.pipeline.run(samples, sample_rate)→dictwithnum_speakersandturns.
Performance
| Pipeline | VoxConverse DER | Model size |
|---|---|---|
| Hybrid + K-means | 14.12% | ~30 MB |
See the full repository for Rust / C / CLI APIs, benchmarks, and development docs.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file polyvoice-0.7.0-cp312-cp312-win_amd64.whl.
File metadata
- Download URL: polyvoice-0.7.0-cp312-cp312-win_amd64.whl
- Upload date:
- Size: 8.3 MB
- Tags: CPython 3.12, Windows x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
63c8105826f9191b9746ac6b5ccb9fc2aec53c88a813aa425bb14d3a6aca6f29
|
|
| MD5 |
1eb46bf942407e46c261eff097b0c720
|
|
| BLAKE2b-256 |
1d10c54de1fd0eb1255ee08a9ce8009d9e5ef83b01cbed189c546a3af9f9ebc6
|
Provenance
The following attestation bundles were made for polyvoice-0.7.0-cp312-cp312-win_amd64.whl:
Publisher:
release.yml on ekhodzitsky/polyvoice
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
polyvoice-0.7.0-cp312-cp312-win_amd64.whl -
Subject digest:
63c8105826f9191b9746ac6b5ccb9fc2aec53c88a813aa425bb14d3a6aca6f29 - Sigstore transparency entry: 1813481681
- Sigstore integration time:
-
Permalink:
ekhodzitsky/polyvoice@e256c4ba4fb72522d0ed59334d436699293788b7 -
Branch / Tag:
refs/tags/v0.7.0 - Owner: https://github.com/ekhodzitsky
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@e256c4ba4fb72522d0ed59334d436699293788b7 -
Trigger Event:
push
-
Statement type:
File details
Details for the file polyvoice-0.7.0-cp312-cp312-manylinux_2_38_x86_64.whl.
File metadata
- Download URL: polyvoice-0.7.0-cp312-cp312-manylinux_2_38_x86_64.whl
- Upload date:
- Size: 10.1 MB
- Tags: CPython 3.12, manylinux: glibc 2.38+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
81ea6fd4469a2132084762e1614f8e9c4dcbfac7f55436ba175e6953a5ba6ba7
|
|
| MD5 |
43897b8619d5f17e252aee1d185fe109
|
|
| BLAKE2b-256 |
77254f05677d7647c8782e1229ffc5b3e41c21531a29758d5cb4cb7f2a7cbfca
|
Provenance
The following attestation bundles were made for polyvoice-0.7.0-cp312-cp312-manylinux_2_38_x86_64.whl:
Publisher:
release.yml on ekhodzitsky/polyvoice
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
polyvoice-0.7.0-cp312-cp312-manylinux_2_38_x86_64.whl -
Subject digest:
81ea6fd4469a2132084762e1614f8e9c4dcbfac7f55436ba175e6953a5ba6ba7 - Sigstore transparency entry: 1813481406
- Sigstore integration time:
-
Permalink:
ekhodzitsky/polyvoice@e256c4ba4fb72522d0ed59334d436699293788b7 -
Branch / Tag:
refs/tags/v0.7.0 - Owner: https://github.com/ekhodzitsky
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@e256c4ba4fb72522d0ed59334d436699293788b7 -
Trigger Event:
push
-
Statement type:
File details
Details for the file polyvoice-0.7.0-cp312-cp312-macosx_11_0_arm64.whl.
File metadata
- Download URL: polyvoice-0.7.0-cp312-cp312-macosx_11_0_arm64.whl
- Upload date:
- Size: 9.1 MB
- Tags: CPython 3.12, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c94356c1242075265de573e67b5d09d5b70bb1a2c0b329ec64d46fe16c7416b5
|
|
| MD5 |
1ac809a0ecabcf34fd87ad29dee65fca
|
|
| BLAKE2b-256 |
eac6381d35a1b1221c5eb8b3472eb5e263fb01b18b79a8e55744681d02260cb3
|
Provenance
The following attestation bundles were made for polyvoice-0.7.0-cp312-cp312-macosx_11_0_arm64.whl:
Publisher:
release.yml on ekhodzitsky/polyvoice
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
polyvoice-0.7.0-cp312-cp312-macosx_11_0_arm64.whl -
Subject digest:
c94356c1242075265de573e67b5d09d5b70bb1a2c0b329ec64d46fe16c7416b5 - Sigstore transparency entry: 1813481557
- Sigstore integration time:
-
Permalink:
ekhodzitsky/polyvoice@e256c4ba4fb72522d0ed59334d436699293788b7 -
Branch / Tag:
refs/tags/v0.7.0 - Owner: https://github.com/ekhodzitsky
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@e256c4ba4fb72522d0ed59334d436699293788b7 -
Trigger Event:
push
-
Statement type: