![]() See: TopicĪ walk-through of the major components of a synthesis client using a simple client.Ī full-fledged synthesis client, written in Python. Once you have the proto files and optionally the client stubs, you are ready to start writing client applications with the help of the API and several sample applications. The resulting files contain the information in the proto files in your programming language. If your programming language requires client stub files, generate the stubs from the proto files using gRPC protoc, following the Python example as guidance. Unzip the file in a location that your applications can access, for example in the directory that contains or will contain your client apps. Synthesizer and storage gRPC protos: nuance_tts_and_storage_protos.zip See gRPC Documentation for a complete list and instructions on using gRPC with each one.ĭownload the NVC gRPC proto files, which contain a generic version of the functions or classes that perform speech synthesis and upload operations: Install gRPC for the programming language of your choice, including C++, Java, Python, Go, Ruby, C#, Node.js, and others. The basic steps in using the NVC gRPC protocol are: Python -m grpc_tools.protoc -proto_path=./ -python_out=./ nuance/rpc/status.protoįinal structure of protos and stubs for TTS and storage ├── Your client apps here Python -m grpc_tools.protoc -proto_path=./ -python_out=./ nuance/rpc/status_code.proto Python -m grpc_tools.protoc -proto_path=./ -python_out=./ nuance/rpc/error_details.proto # Generate Python stubs from RPC proto files Python -m grpc_tools.protoc -proto_path=./ -python_out=./ -grpc_python_out=./ nuance/tts/storage/v1beta1/storage.proto Python -m grpc_tools.protoc -proto_path=./ -python_out=./ -grpc_python_out=./ nuance/tts/v1/synthesizer.proto Generate client stubs # Generate Python stubs from TTS proto files Inflating: nuance/tts/v1/synthesizer.proto Inflating: nuance/tts/storage/v1beta1/storage.proto ![]() Inflating: nuance/rpc/error_details.proto Install gRPC for programming language $ python -m pip install -upgrade pipĭownload and unzip proto files $ unzip nuance_tts_and_storage_protos.zipĪrchive: nuance_tts_and_storage_protos.zip The URLs for NVC in the hosted Mix environment are: ![]() Learn the URL to call the TTS service: see Accessing a runtime service. Later you will use these credentials to request an access token to run your application. Generate a client ID and "secret" in your Mix project: see Authorize your client application.
0 Comments
Leave a Reply. |