gRPC setup
Before developing and running client applications, you need to set up the gRPC environment for your programming language on Linux or Windows.
The basic steps for using the Nuance Recognizer gRPC protocol are:
-
Install gRPC for the programming language of your choice, including C++, Java, Python, Go, Ruby, C#, Node.js, and others. See gRPC Documentation for a complete list and instructions on using gRPC with each one. For example, for Python:
python3 -m pip install --upgrade pip python3 -m pip install grpcio python3 -m pip install grpcio-tools
python -m pip install --upgrade pip python -m pip install grpcio python -m pip install grpcio-tools
-
Download the proto files: nuance_recognizer_proto_file_v1.zip. This file defines the Nuance Recognizer engine’s API to perform speech recognition.
-
Unzip the file in a location that your applications can access, for example in the directory that contains or will contain your client apps. On Linux, use the `unzip`` command
unzip nuance_nrc_v1_nrc.zip tree ├── Your client apps here └── nuance └── nrc └── v1 └── nrc.proto
-
If your programming language requires client stub files, generate the stubs from the proto files using gRPC protoc, following this Python example as guidance:
python3 -m grpc_tools.protoc -I./nuance/nrc/v1/ --python_out=. --grpc_python_out=. nuance/nrc/v1/nrc.proto
python -m grpc_tools.protoc -I./nuance/nrc/v1/ --python_out=. --grpc_python_out=. nuance/nrc/v1/nrc.proto
The resulting files contain the information in the proto files in your programming language.
tree ├── Your client apps here ├── nrc_pb2_grpc.py ├── nrc_pb2.py └── nuance └── nrc └── v1 └── nrc.proto
Once you have the proto files and optionally the client stubs, you are ready to develop and run client applications with the help of sample clients:
Feedback
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.