Overview
Theqwen-tts-demo command launches an interactive Gradio web interface for testing and using Qwen3-TTS models. It supports all three model types: CustomVoice, VoiceDesign, and Base (voice cloning).
Installation
The command is automatically available after installing theqwen-tts package:
Basic Usage
Quick Start Examples
http://<your-ip>:8000 in your browser, or access via port forwarding in tools like VS Code.
Command Options
Model Checkpoint
Model checkpoint path or HuggingFace repo ID (positional argument)Can also be specified with
-c or --checkpoint flag.Examples:Qwen/Qwen3-TTS-12Hz-1.7B-CustomVoice./local/path/to/model
Model Loading Options
Device for model inferenceOptions:
cpu, cuda, cuda:0, cuda:1, etc.Torch dtype for loading the modelChoices:
bfloat16, bf16, float16, fp16, float32, fp32Enable or disable FlashAttention-2 for efficient memory usageFlashAttention-2 is recommended for better performance. Requires compatible hardware.
Server Configuration
Server bind IP address for GradioUse
0.0.0.0 to allow external connections, or 127.0.0.1 for local only.Server port for Gradio
Create a public Gradio link for sharingWhen enabled, generates a temporary public URL.
Gradio queue concurrency limit
HTTPS/SSL Options
Path to SSL certificate file for HTTPS (optional)Required for secure connections and browser microphone access in Base model.
Path to SSL private key file for HTTPS (optional)
Whether to verify SSL certificateUse
--no-ssl-verify for self-signed certificates.Generation Parameters
Maximum new tokens for generation (optional)
Sampling temperature (optional)
Top-k sampling (optional)
Top-p sampling (optional)
Repetition penalty (optional)
Subtalker top-k (optional, only for tokenizer v2)
Subtalker top-p (optional, only for tokenizer v2)
Subtalker temperature (optional, only for tokenizer v2)
HTTPS Setup for Base Model
For Base model deployments, HTTPS is recommended to avoid browser microphone permission issues:Generate Self-Signed Certificate
Launch with HTTPS
https://<your-ip>:8000 in your browser.
Your browser may show a security warning for self-signed certificates. This is expected. For production deployments, use a real certificate from a trusted Certificate Authority.
Model-Specific Features
CustomVoice Demo
Provides interface for:- Text input with language selection
- Speaker selection (9 premium voices)
- Optional instruction control (e.g., “Say it in a very angry tone”)
VoiceDesign Demo
Provides interface for:- Text input with language selection
- Natural language voice design instructions
- Dynamic voice generation based on descriptions
Base Model Demo
Provides two tabs:- Clone & Generate: Upload reference audio with transcript, then synthesize new text
- Save/Load Voice: Save voice clones as reusable prompt files for consistent character voices