Installing the Vocalizer client

To install the client, you must install the full Nuance Vocalizer for Enterprise package.

The include, lib, and SO files

After completing the installation you can find the SO, include, and library files under the Common path for your voice platform. These files are required for integrating the Vocalizer client in a custom application.

Configuring an application for the Vocalizer client

To use the Vocalizer client, your application must invoke it via one of two API commands:

  • NVSClientInit()—Initiates a Vocalizer client session.
  • NVSClientInitFromFile()—Initiates a Vocalizer client session while loading configuration parameters from a prepared configuration file.

These two commands are mutually exclusive: you must use one or the other, but not both. They are used only at application startup, and must be invoked before TtsSystemInit().

To close the Vocalizer client gracefully at the end of the application, your application must use the NVSClientTerminate() API function. This function must be invoked after the TtsSystemTerminate() function.

Configuration parameters

The Vocalizer client requires certain configuration parameters. These are passed to the Vocalizer client as arguments for the NVSClientInit() function, or stored in the file whose location is specified in the NVSClientInitFromFile() function.

  • When using NVSClientInit(), these parameters are expressed as key/value pairs.
  • For the NVSClientInitFromFile() function, you must create a configuration file for the Vocalizer host that lists values for all the required configuration parameters. This file is a simple text file that begins with an [nvs-client] heading, and lists each parameter on a separate line, as shown below:
    [nvs-client]
    server.nvs.Address = localhost:9200
    server.nvs-client.Port = 9300
    server.nvs.ConnectionTimeout = 5000

    To disable a parameter, put the # sign at the beginning of the row to comment it out. For example:

    #server.nvs-client.LogPath = /tmp/nvsclient.log

The configuration parameters the Vocalizer client uses are listed below.

Parameter

Default value

Description

server.nvs.Address

127.0.0.1:9200

Specifies the locations of the Vocalizer host with which the Vocalizer plugin communicates.

server.nvs-client.Port

9300

Specifies the port where Vocalizer client connects for implementing the backward B channel.

server.nvs.ConnectionTimeout

5000

Specifies the timeout value (in milliseconds) for connecting (or re-connecting) Vocalizer plugin to Vocalizer host. After this timeout expires, resource allocation will fail and Vocalizer returns negative value into MRCP resource negotiation.

server.nvs-client.LogPath
(optional)

[no default]

This is the base log path where diagnostic log file(s) are to be written. If this parameter is not present, no log file is written.

When a log file reaches the server.nvs-client.LogMaxSize size, the file is stored in the same folder with a suffix –BCKXX (before file extension, to preserve readability) where XX is a number from 00 to 09. This means that up to 10 backup files may be present on the disk at a given time.

The software cycles sequentially through the 10 available log files, overwriting the oldest backup if necessary. For example, if the log file is named log.txt and files log-BCK00.txt to log-BCK09.txt have already been created, then when the current log.txt reaches the size limit, it overwrites the backup log-BCK00.txt. When the next log.txt reaches the maximum size, it overwrites log-BCK01.txt, and so on until it cycles through to log-BCK00.txt again.

Note: If you have multiple instances of the client, you need to specify different values for this path when specifying it as a parameter of the NVSClientInit() or NVSClientInitFromFile() API function calls.

server.nvs-client.LogMaxSize
(optional)

500

This is the maximum size (in MB) allowed for each log file. When this size is reached, the file is rolled over into the next available file.

server.nvs-client.LogLevel
(optional)

0

This is the log level desired for diagnostic log file(s). Permitted values are 0, 1, or 2:

  • 0 is for BASIC logs
  • 1 is for INFO logs
  • 2 is for DEBUG logs