Validate Deepgram Self-Hosted TTS
tts-tui is an open-source terminal application written in Rust for testing and validating Deepgram text-to-speech on self-hosted deployments. It supports Deepgram-compatible HTTP endpoints and Amazon SageMaker, with interactive voice selection, multi-format audio output, and local audio caching.
Features
Section titled “Features”- Validate self-hosted TTS — confirm that Aura-2 models produce correct audio on your own infrastructure before going to production.
- Test output formats — switch between MP3, Linear16 (WAV), FLAC, and other encodings with configurable sample rates.
- Multi-language support — synthesize speech in any Deepgram-supported language and save utterances for comparison.
- Audio caching — repeated playback is served from disk instantly, so you can iterate without redundant API calls.
- Dual provider support — test both Deepgram-compatible HTTP endpoints and Amazon SageMaker
InvokeEndpointdeployments from the same tool.
Prerequisites
Section titled “Prerequisites”- Rust Toolchain (only required when building from source)
- Deepgram self-hosted TTS deployment
Installation
Section titled “Installation”Run Pre-compiled Binary
Section titled “Run Pre-compiled Binary”- Download the latest release from GitHub Releases.
- Extract the ZIP file.
- Run the
tts-tuibinary.
Build from Source
Section titled “Build from Source”git clone https://github.com/deepgram-devs/deepgram-demos-rust.git
cd deepgram-demos-rust/tts-tui
cargo install --path .Once installed, the tts-tui binary is available from anywhere on your system.
Configure for self-hosted
Section titled “Configure for self-hosted”Use the --endpoint flag to point tts-tui at your Deepgram-compatible HTTP endpoint:
tts-tui --provider deepgram --endpoint https://your-selfhosted-deepgram.example.com/v1/speakIf the endpoint requires an API key, supply it through the DEEPGRAM_API_KEY environment variable or press k inside the running application.
Configure for Amazon SageMaker
Section titled “Configure for Amazon SageMaker”Use self-hosted Deepgram TTS on Amazon SageMaker through the AWS SageMaker Runtime InvokeEndpoint API:
tts-tui \
--provider sagemaker \
--sagemaker-endpoint-name your-sagemaker-endpoint \
--aws-region us-east-2The same settings can be supplied with environment variables:
export TTS_TUI_PROVIDER=sagemaker
export SAGEMAKER_ENDPOINT_NAME=your-sagemaker-endpoint
export AWS_REGION=us-east-2
tts-tui