Qwen3 Streaming TTS
Low-latency WebSocket serving and reproducible zero-shot evaluation for Qwen3-TTS ONNX exports. QST preserves QTSO's Talker, codec-cache, and generated-reference continuity while scheduling causal text and decoded audio for live streaming.
The current release uses the exact QTSO ten-session boundary family. The fresh
1.7B package is exported from Qwen/Qwen3-TTS-12Hz-1.7B-Base; the controlled
0.6B comparison uses the source-bound QTSO-compatible package derived from
Qwen/Qwen3-TTS-12Hz-0.6B-Base.
Model Support
| Model/runtime | Package or source | Ten QTSO boundaries | Release role |
|---|---|---|---|
| Qwen3-TTS 0.6B QTSO-compatible FP32 | models/Qwen3-TTS-12Hz-0.6B-Base-qtso-fp32 |
exact graph bodies and contracts | controlled baseline |
| Qwen3-TTS 1.7B QTSO-compatible FP32 | models/Qwen3-TTS-12Hz-1.7B-Base-qtso-fp32 |
fresh boundaries with model-dependent widths | release candidate |
| External QTSO fixed-four runtime | $QTSO_REPO/qwen3-tts_onnx |
reference implementation | behavioral baseline |
| Seven-logical-graph exporter family | models/Qwen3-TTS-12Hz-*-Base-fp32 |
different runtime | diagnostic only |
Graph compatibility means the same filenames, tensor names, cache roles,
dtypes, ranks, and call boundaries. Cross-size graph-body identity is not
claimed. The 1.7B codec embedding graph contains the complete
[33792, 2048] Talker plus Local Talker table required by QTSO IDs
0..33791.
Architecture
causal text deltas
-> tokenizer-stable phrase segmentation
-> Talker + Local Talker speech-token generation
-> one-frame onset + four-frame steady CUDA-graph decode
-> dynamic final codec remainder
-> sustained-speech onset gate
-> binary PCM16LE WebSocket frames
SynthesisBackend separates streaming policy from model execution.
QTSOOnnxAdapter owns QTSO cache transitions and ONNX Runtime construction.
The service accepts one mutable synthesis session at a time.
See ARCHITECTURE.md, continuous streaming, and the WebSocket protocol.
Installation
conda create -n qwen3-streaming-tts python=3.12
conda activate qwen3-streaming-tts
pip install -e '.[dev,onnx,evaluation]'
pip install --no-deps faster-whisper==1.2.1
Install Faster-Whisper with --no-deps so it does not replace the pinned
onnxruntime-gpu==1.23.2 with generic CPU onnxruntime.
Serve
qst-server \
--config configs/qst-qtso10-17b-top50-seed1242-fast-onset.json \
--model-profile qwen3-tts-12hz-1.7b-base \
--host 127.0.0.1 \
--port 8765
Use configs/qst-qtso10-06-top50-seed1242-fast-onset.json for the controlled
0.6B package and configs/qtso-fixed4.json for the external QTSO baseline.
Full setup and runtime compatibility details are in
docs/deployment.md.
Stream
qst-client \
--uri ws://127.0.0.1:8765 \
--speaker-id female_shadowheart \
--reference-audio "$QTSO_REPO/audio_ref/female_shadowheart.flac" \
--language english \
--text "Low latency streaming speech keeps live conversation natural." \
--out-wav artifacts/waveforms/smoke/request-000.wav
Remote clients may send base64 reference audio instead of a host-local path.
One connection may contain multiple begin/text/end requests for continuous
Talker, codec, and generated-reference state.
Evaluate
The release matrix covers 36 English and 36 Russian utterances, all six canonical reference speakers, and five repetitions per speaker/utterance: each model/language report contains 216 groups and 1,080 retained syntheses; each model across both languages contains 432 groups and 2,160 syntheses.
QST_CONFIG=configs/qst-qtso10-17b-top50-seed1242-fast-onset.json \
QST_TEXT_CHUNK_CHARS=4 \
QST_EVALUATION_REPETITIONS=5 \
./scripts/run_single_service_matrix.sh \
qwen3-tts-12hz-1.7b-base \
release-rseed-17b-en \
en_transcript english small.en en
Every request derives its random seed as
configured_sampling_seed + repetition_index % max_repetition.
sampling_index is request-order provenance only. Five raw syntheses are
retained and averaged per speaker/utterance; latency acceptance uses the
maximum of those means under the 0.70 s gate.
Every metric reports count/mean/std/min/max/p50/p90/p95/p99 at:
- per utterance-speaker;
- per utterance;
- per corpus-speaker;
- per corpus.
WER and CER outliers are selected independently by language and metric with
the strict upper Tukey fence Q3 + 1.5 * IQR. All five waveforms for a
selected speaker/utterance are copied and hash-verified. See
docs/evaluation.md.
Release Results
Quality values are unweighted means over the 216 speaker/utterance five-run means per language. The combined gate gives English and Russian equal weight.
| System | English WER | English CER | Russian WER | Russian CER | Combined WER | Combined CER |
|---|---|---|---|---|---|---|
| External QTSO fixed-four baseline | 0.051380 | 0.023540 | 0.129301 | 0.036903 | 0.090341 | 0.030221 |
| Fresh source-bound 0.6B | 0.047410 | 0.022410 | 0.140276 | 0.039337 | 0.093843 | 0.030874 |
| Fresh 1.7B candidate | 0.046982 | 0.023222 | 0.101595 | 0.027033 | 0.074288 | 0.025127 |
The 1.7B candidate improves combined WER by 0.019555, combined CER by
0.005747, and combined speaker similarity by 0.000346. Russian improves
both WER and CER. English improves WER but regresses CER slightly; that
per-language tradeoff remains explicit. Maximum per-utterance five-run mean
onset is 0.5300 s for 1.7B English, 0.5286 s for 1.7B Russian,
0.4132 s for 0.6B English, and 0.4476 s for 0.6B Russian, all below the
0.70 s release gate. The external QTSO baseline's maximum group mean is
0.4096 s.
Full distributions, pooled edit counts, raw latency tails, outlier counts, and the external QTSO fixed-four baseline are in docs/results.md.
Configurations
| Configuration family | Text send | First/steady codec frames | Sampling | Status |
|---|---|---|---|---|
qst-qtso10-*-top50-seed1242-fast-onset |
4 chars | 1 / 4 | temperature 0.9, top-p 1.0, top-k 50, penalty 1.05 | controlled release |
qtso-fixed4 |
1 char | 4 / 4 | QTSO native | external baseline |
qst-qtso10-*-greedy-fast-onset |
4 chars | 1 / 4 | top-k 1 | superseded diagnostic |
qst-qtso10-*-top{2,3,5}-fast-onset |
4 chars | 1 / 4 | bounded top-k | diagnostic |
qst-micro-audio, qst-no-cuda-graph |
4 chars | 1 / 4 | policy ablations | diagnostic |
qwen3-tts-12hz-*-fresh-export |
exporter policy | exporter-owned | exporter sampling | separate runtime |
All QTSO-family policies retain the 50-frame Talker reset, 125-frame codec reset, and eight-second generated-reference limit.
Development
pytest
./scripts/check_python_coverage_90.sh
ruff check src tests
python -m compileall -q src tests
bash -n scripts/*.sh
git diff --check
Ordinary tests use fake backends and synthetic PCM. ONNX, CUDA, WebSocket, and full-data paths are integration tests. Every project-owned Python file must maintain at least 90% line coverage individually and repository-wide.
Limitations
- One active mutable synthesis session per model instance.
- Prosody measurements are objective proxies, not MOS or human listening.
- CUDA graph support depends on ONNX Runtime and the host CUDA stack.
- The exporter family has different graph and continuity semantics and is not a QTSO ten-graph match.
References
- Qwen3-TTS-12Hz-0.6B-Base
- Qwen3-TTS-12Hz-1.7B-Base
- Qwen3-TTS technical report
- Qwen3-TTS-Streaming-ONNX
- ONNX Runtime CUDA Execution Provider
License
Apache-2.0 for QST code and packaging metadata. Qwen model weights and derived ONNX artifacts retain upstream licensing and attribution requirements.
Created by Patrick Lumbantobing, VertoX AI, Inc. Copyright (c) 2026 VertoX AI, Inc.
- Downloads last month
- 63
Model tree for vertox-ai/qwen3-streaming-tts
Base model
Qwen/Qwen3-TTS-12Hz-0.6B-Base