Natural and expressive voices in multiple languages. For voice agents and brand ambassadors.
Riva uses gRPC APIs. Instructions below demonstrate usage of magpie-tts-multilingual model using Python gRPC client.
You will need a system with Git and Python 3+ installed.
pip install nvidia-riva-client
Download Python client code by cloning Python Client Repository.
git clone https://github.com/nvidia-riva/python-clients.git
Open a command terminal and execute below command to synthesize audio from the example text. If you have generated the API key, it will be auto-populated in the command.
python python-clients/scripts/tts/talk.py \ --server grpc.nvcf.nvidia.com:443 --use-ssl \ --metadata function-id "877104f7-e885-42b9-8de8-f6e4c6303969" \ --metadata authorization "Bearer $API_KEY_REQUIRED_IF_EXECUTING_OUTSIDE_NGC" \ --text "this audio is generated from nvidia's text to speech model" \ --voice "Magpie-Multilingual.EN-US.Female.Female-1" \ --output audio.wav
List of available voices can be obtained using below command.
python python-clients/scripts/tts/talk.py \ --server grpc.nvcf.nvidia.com:443 --use-ssl \ --metadata function-id "877104f7-e885-42b9-8de8-f6e4c6303969" \ --metadata authorization "Bearer $API_KEY_REQUIRED_IF_EXECUTING_OUTSIDE_NGC" \ --list-voices
Riva uses gRPC APIs. Proto files can be downloaded from Riva gRPC Proto files and compiled to target language using Protoc compiler. Example Riva clients in C++ and Python languages are provided below.