To use this sample client to perform a speech recognition.


1. The following files should be present:

    ├── audio
    │   └── ...
    ├── README.txt
    ├── generate-protobuf-and-grpc-python.sh
    ├── run-nr-speech-client.sh
    ├── nr-speech-client.py
    ├── fruits.grxml
    └── nuance
        └── nrc
            └── v1
                └── nrc.proto


2. Generate the grpc and protobuf python files from the proto file
    $ ./generate-protobuf-and-grpc-python.sh


3. Edit run-nr-speech-client.sh
    Add your Mix client id and secret credentials.


4. Execute the run-nr-speech-client.sh script
    As an argument pass an audio file to be recognized.
    By default the audio format requested by this client is mulaw.
    Therefore the audio file must contain mulaw encoded audio.

    Examples:

    // Recognize "zero" against the loaded grammars.
    // This audio should match the builtin/grammar/digits.
    $ ./run-nr-speech-client.sh audio/0.ulaw

    // Recognize "zero one two three four" against the loaded grammars.
    // This audio should match the builtin/grammar/digits.
    $ ./run-nr-speech-client.sh audio/01234.ulaw

    // Recognize the word "orange" against the loaded grammars.
    // This audio should match the "colors" inline grammar.
    $ ./run-nr-speech-client.sh audio/orange.ulaw


NOTE:
    The sample client loads 2 grammars:
        1. a builtin "digits" grammar - recognizes digits 0 to 9.
        2. an inline grxml grammar - recognizes various color names.

    By default the sample client performs recognitions against both grammars.
    In a real scenario however, when the expected speech utterance is known,
    a better recognition accuracy and confidence level can be obtained by
    recognizing against a specific grammar. You can comment out one or the
    other grammar in the client code to experiment.

    A third grammar, fruits.grxml, is provided as an example of a URI grammar
    (a grammar that could be loaded by the recognizer via a URI) but is not
    loaded by default.  It cannot be loaded unless the "fruits.grxml" grammar
    file is hosted by a http server accessible by the recognizer, so it is
    shown as an example but is commented out in the client source.
