GitHubContribute in GitHub: Edit online

copyright: years: 2017, 2018 lastupdated: "2023-02-12"


Voice Agent Insights

Note that Voice Agent Insights is currently in beta. For more information, see the Voice Agent Insights announcement.

Voice Agent Insights provides insights into the various reporting events published by IBM® Voice Gateway and IBM Voice Agent with Watson. Voice Agent Insights is designed to query the same IBM Cloudant databases that are used by Voice Gateway and IBM Voice Agent with Watson to publish reporting events. Through Voice Agent Insights, voice agent developers now have a tool they can use to quickly gain insights about their voice agents across a large number of calls, enabling them to more quickly identify problem areas that need attention. It can also be used to identify whether changes to the voice agents are actually resulting in better KPIs or causing regressions.

To be clear, a 'voice agent' is defined differently depending on which product you use:

  1. In the IBM Voice Agent with Watson service, each agent you create is considered a 'voice agent'.
  2. In the IBM Voice Gateway product, each tenant created in a multi-tenant configuration file (see Setting up a multi-tenant JSON configuration), is considered a 'voice agent'.

What's new

To learn about the latest updates and enhancements to Voice Agent Insights, see What's new in Voice Agent Insights.

Getting started

To get started using Voice Agents Insights:

  1. Configure reporting events to flow into an IBM Cloudant database.
  2. Set up the Voice Agent Insights microservice.
  3. Configure OpenID for authentication and authorization.
  4. Run the Docker images using Docker Compose file from samples respository.

To use the more advanced features of the Voice Agent Insights service, see the Advanced Configuration section below.

1. Configure reporting events to flow into an IBM Cloudant database

In order for Voice Agent Insights to receive and analyze all information from your voice agents, each voice agent must have Event Forwarding enabled for Call Detail Record events. Transcription events are optional.

Note: Voice Agent Insights currently only supports IBM Cloudant databases.

Important: Transcription events include text transcriptions and other information that could potentially contain Protected Health Information (PHI), Personally Identifiable Information (PII), or Payment Card Industry Data Security Standard (PCI DSS) data. It's critical that the consuming server properly stores these events to prevent exposure of personal information.

You can suppress or enable the inclusion of transcription text in event reporting while storing the data with vgwActEnableTranscriptionReport and vgwActDisableTranscriptionReport action tags.

2. Set up the Voice Agent Insights microservice

  1. Download or clone the sample repository to get the required docker-compose.yml file and configuration directory.

  2. Update the vainsights.json file located in the config folder

    a. Run the following command to edit the file:

    vi config/vainsights.json
    

    b. Enter the tenant phone number in the "tenantURI" field. This value must be a valid phone number and can contain only numerals and dashes; for example, "tenantURI": "1234567890"

    c. Enter a valid short summary in the "description" field. This summary will be displayed in the dashboard.

    d. Update the Cloudant configuration information. An example configuration file example is listed below. Follow this format which includes all the possible Cloudant configuration variables allowed. Choose what is required for your setup.

    Example Configuration File:

{ "tenants": [ { "tenantURI": "1-888-555-3333", "description": "Voice Gateway Demo US",

    "reporting": {
      "cdrCloudant": {
		  "url": "myCloudantURL",
		  "account": "myCloudantAccount",
		  "dbName": "myCloudant-cdr-db",
		  "apikey": "myCloudantApiKey",
		  "username": "myCloudantUsername",
		  "password": "myCloudantPassword",
		  "eventInd": "cdr"
      },
      "transcriptionCloudant": {
		  "url": "myCloudantURL",
		  "account": "myCloudantAccount",
		  "dbName": "vgw-transcription-db",
		  "apikey": "myCloudantApiKey",
		  "username": "myCloudantUsername",
		  "password": "myCloudantPassword",
		  "eventInd": "transcription"
      }
    }
  }
]

}

  **Note:** Call Detail Records and Transcription events can be configured to exist in one database or separate databases.

### 3. Configure OpenID for authentication and authorization {: #config-openid}

For instructions on setting up OpenID to access the Voice Agent Insights dashboard, see [Configuring OpenID](https://www.ibm.com/docs/hu/voice-gateway?topic=insights-security).

### 4. Run the Docker images using Docker Compose {: insights-docker-image}

The last required step to get started is to run the Docker images.

**Note:** On startup, the services will automatically generate a self-signed certificate in the key store shared by the OP and Insights microservices if the service is running on localhost. To insure security keys are properly created, you will need to run the service twice the first time the service is started up.

To start the service, run the following command in the same directory as the `docker-compose.yml` file.
  ```
docker pull icr.io/voice-gateway/agent-insights:latest
docker pull icr.io/voice-gateway/agent-oidc-provider:latest
docker-compose up

The service can be stopped by running docker-compose down in the same directory where you ran docker-compose up.

Once the service is running, you can access the Voice Agent Insights dashboard using the secure connection URL https://localhost:9443/va.insights/. Login using your configured security credentials.

Advanced configuration

The following environment variables can be added or modified in the docker-compose.yml file.

To change the path to the configuration JSON file, modify the following environment variable:

Table 1. Configuration environment variables
Environment Variable Default Value Description
CONFIG_FILE_PATH N/A The path to the configuration JSON file.

To enable logging, add the following environment variables:

Table 2. Logging environment variables
Environment Variable Default Value Description
LOG_LEVEL info The log level. Valid values from least information to most information are off, fatal, severe, warning, info, fine, finest, and all. Note that when set to fine, finest, or all, the logs might contain sensitive PHI, PII, and PCI DSS data.
LOG_MAX_FILE_SIZE 100 The maximum size in megabytes (MB) that a log file can reach before a new file is created.
LOG_MAX_FILES 5 The maximum number of log files, trace files, and exception summary log files. When this limit is reached, the oldest file is deleted and a new file is created. For example, when this variable is set to 5, Insights generates up to 5 message logs, 5 trace logs, and 5 exception summaries.
ENABLE_TRANSCRIPTION_MESSAGES false Set to true to enable transcription messages. For transcription messages to be logged, the LOG_LEVEL environment variable must also be set to finest. Note that when these messages are enabled, they are printed to the logs and might contain sensitive PHI, PII, and PCI DSS data.

To enable support for a Cloudant proxy, add the following environment variables:

Table 3. Reporting config environment variables
Environment Variable Default Value Description
CLOUDANT_PROXY_URL N/A The url
CLOUDANT_PROXY_USERNAME N/A The username
CLOUDANT_PROXY_PASSWORD N/A The password

REST API

For information on using the Voice Agent Insights REST API, see Voice Agent Insights REST API.

License

The license for the image can be found at Voice Agent Insights.