botium-connector-nuance
v1.0.0
Published
Botium Connector for Azure Conversational Language Understanding
Downloads
14
Readme
Botium Connector for Nuance
This is a Botium connector for testing your Nuance chatbot.
Did you read the Botium in a Nutshell articles ? Be warned, without prior knowledge of Botium you won't be able to properly use this library!
How it works?
Botium uses the Nuance API to connect to your chatbot.
It can be used as any other Botium connector with all Botium Stack components:
Requirements
- Node.js and NPM
- a deployed Nuance chatbot
- a project directory on your workstation to hold test cases and Botium configuration
Install Botium and Nuance Webhook Connector
When using Botium CLI:
> npm install -g botium-cli
> npm install -g botium-connector-nuance
> botium-cli init
> botium-cli run
When using Botium Bindings:
> npm install -g botium-bindings
> npm install -g botium-connector-nuance
> botium-bindings init mocha
> npm install && npm run mocha
When using Botium Box:
Already integrated into Botium Box, no setup required
Connecting your Nuance chatbot to Botium
- Fill the mandatory capabilities of botium.json file:
- NUANCE_CLIENT_ID
- NUANCE_CLIENT_SECRET
- NUANCE_CONTEXT_TAG
- NUANCE_CHANNEL
- Nlp analytics (It slows down the communication, so it is not enabled as default):
- Enable it with NUANCE_NLP_ANALYTICS_ENABLE capability
- In order to use downloader/uploader:
- Generate service account
- If it is not visible to you, then please ask nuance for permissions
- Setup the following capabilities:
- NUANCE_API_URL
- NUANCE_ADMIN_CLIENT_ID
- NUANCE_ADMIN_CLIENT_SECRET
- NUANCE_PROJECT_ID
Sample botium.json in your working directory:
{
"botium": {
"Capabilities": {
"PROJECTNAME": "<whatever>",
"CONTAINERMODE": "nuance",
"NUANCE_CLIENT_ID": "...",
"NUANCE_OAUTH_URL": "...",
"NUANCE_CLIENT_SECRET": "...",
"NUANCE_CONTEXT_TAG": "...",
"NUANCE_CHANNEL": "...",
"NUANCE_NLP_ANALYTICS_ENABLE": true,
"NUANCE_API_URL": "...",
"NUANCE_ADMIN_CLIENT_ID": "...",
"NUANCE_ADMIN_CLIENT_SECRET": "...",
"NUANCE_PROJECT_ID": "..."
}
}
}
Botium setup is ready, you can begin to write your BotiumScript files.
Supported Capabilities
Set the capability CONTAINERMODE to nuance to activate this connector.
NUANCE_CLIENT_ID, NUANCE_CLIENT_SECRET
Nuance client id, and client secret
NUANCE_CONTEXT_TAG
NUANCE_CHANNEL
NUANCE_LANGUAGE
Language of the chatbot. A chatbot can be multi lingual, but the communication is bound to one dedicated one.
Optional.
Default: en-US
NUANCE_NLP_ANALYTICS_ENABLE
Capability to enable nlp analytics.
Optional.
Default: false
NUANCE_API_URL
Optional. Only required for downloader/uploader. Default: https://mix.api.nuance.com/
NUANCE_ADMIN_CLIENT_ID, NUANCE_ADMIN_CLIENT_SECRET
Credentials for Nuance Service Account
Optional. Only required for downloader/uploader.
NUANCE_PROJECT_ID
The Nuance Project ID.
Optional. Only required for downloader/uploader.
NUANCE_OAUTH_URL
Default: https://auth.crt.nuance.com/oauth2/token
NUANCE_DLG_ENDPOINT
Default: nlu.api.nuance.com:443
NUANCE_NLU_ENDPOINT
Default: dlg.api.nuance.com:443
NUANCE_OAUTH_MAX_RETRIES
Oauth max retries. It is to deal with for Nuance Authorization rate limit: 50 requests/minute per IP address
Default: 6
NUANCE_OAUTH_RETRY_DELAY_SEC
Oauth retry delay in sec. It is to deal with for Nuance Authorization rate limit: 50 requests/minute per IP address
Default: 10
NUANCE_LIBRARY
Default: default
NUANCE_SESSION_ID
Nuance session timeout in sec.
Default: not set (generated by Nuance)
NUANCE_SESSION_TIMEOUT_SEC
Nuance session timeout in sec.
Default: 900
NUANCE_USER_ID
Nuance user id in sec.
Default: not set
NUANCE_CLIENT_DATA
Client data to inject into the Nuance Event Logs
NUANCE_SUPPRESS_LOG_USER_DATA
Capability to turn off Nuance Event Logs
NUANCE_INITIAL_CONTEXT
Initial context (session data) in JSON format
NUANCE_SKIP_WELCOME_MESSAGE
Turning off welcome message check can speed up the time of the conversation.
Default: false
NUANCE_NLU_ENTITY_VALUE_MODE
Configure how Nuance entities are mapped to Botium entities
Possible values:
- FORCE_LITERAL Nuance entities are mapped as string
- FORCE_STRUCT Nuance entities are mapped as string
- LITERAL_FOR_COMPLEX Flat Nuance entities are mapped as string, complex as JSON
Open Issues and Restrictions
- Voice, and IVR chatbots are not supported (just text based)
- On premise installation of a Nuance chatbot might not work.
- Transfer action is not supported:
- Dialog events are not supported
- Continue actions are not supported