Google Dialogflow CX
Dialogflow CX is an enhanced version of the Dialogflow bot solution. You can read about the differences between versions here.
Table of Contents
- How to integrate your Dialogflow CX with VCC Live IVR?
- Dialogflow CX process parameters
- Welcome Intent in Dialogflow CX
- Handling Parameters
- Using Actions and Parameters in VCC IVR
- Use Dialogflow CX Parameters on the Agent Script
How to integrate your Dialogflow CX with VCC Live IVR?
First, you need to create your Dialogflow structure on the Google Dialogflow interface.
To learn more about creating Dialogflow structures on a Google workspace, please visit the official Google Dialogflow site.
Then, to access Dialogflow in VCC Live, do the following:
Navigate to project > Channels > Voice > Inbound
In the Processes tab, you can find the Actions drop-down menu. Here you can select Media service and insert it into your IVR structure
Dialogflow CX process parameters
To successfully initialize a Dialogflow CX voicebot in your IVR, you need to pass on various parameters in Initialization parameters
endpoint: The endpoint that VCC Live shall access based on your region in Google, e.g.: “europe-west3-dialogflow.googleapis.com:443”
projects: The technical name of your project in Google, e.g.: “vcc-test”
locations: The location where your Dialogflow agents are hosted, e.g.: “europe-west3”
languageCode: The language in which the voicebot is initialized, e.g.: “en”
model: The transcription model that shall be used for the bot, e.g.: “latest_short”. Read more about models here.
agents: The ID of your agent to be used. For example, this can be found in the URL of your Dialogflow CX agent, e.g.: “../agents/e16fa3bb-8a70-4706-943f-d945a9ba89b9/..”
event: Optional, the name of the event you would like to initialize the process with
intent: Optional, the name of the intent you would like to initialize the process with
Note: You can generate your Credential file on the Google Cloud Platform interface by following this guide.
See example below:
{
"endpoint": "europe-west3-dialogflow.googleapis.com:443",
"projects": "test-project",
"locations": "europe-west3",
"languageCode": "en",
"model": "telephony_short",
"agents": "00000000-0000-0000-0000-000000000000",
"event": "",
"intent": ""
}
Welcome Intent in Dialogflow CX
In a default setup, Dialogflow CX expects your customer to introduce itself.
- If the customer’s introduction matches the Default Welcome Intent on the Start Page, then the appropriate response is played. Read more about the Default Welcome Intent here.
- If the customer’s introduction doesn’t match any intent on the Start Page, then the sys.no-match-default response is played with one of the responses.
- If the customer doesn’t introduce itself, then the sys.no-input-default response is played with one of the responses. The time period for no input can be changed in Agent settings -> Speech and IVR -> Enable advanced speech settings -> No speech timeout. The default is 5 seconds Read more about it here.
To avoid missing initial customer input, you can add a Playback or Read-back process in the IVR before the voicebot.
Handling Parameters
You can pass on parameters to Dialogflow CX in the section Input parameters / Parameters. They need to be in the following format:
{
"customerName": "${source}",
"phones": ["${source}", "${destination}"],
"number": 312312,
"boolean": true
}
In Dialogflow CX you can reference them by using $session.params.parametername.
Note: When you send parameters from VCC Live to Dialogflow CX, don’t forget to use a Query data process before gathering that data in the IVR.
You can also use parameters generated by Dialogflow CX. (Read about how to do it here.)
In the IVR process, you can capture the following with unique IVR parameters:
- Action variable name: the name of the last event/intent that was performed before ending the Dialogflow CX process
- Context parameters variable name: all context parameters defined by users on the Dialogflow CX interface
- Response variable name: the entire response
- Error variable name: the error response, if any
Using Actions and Parameters in VCC IVR
If you would like to use an action or a parameter from Dialogflow in VCC IVR (e.g. to navigate the user to agent queue if certain conditions are met), then do the following
- In Dialogflow under your selected Route, check the Fulfillment and Parameter presets sections. You can create a parameter by entering it’s name and value (e.g. ‘humanagent’ and ‘yes’). You can read more about parameters here.
- In the Dialogflow process, capture context parameter names by entering a variable name separately, e.g. $contextvariable
- Later on in the IVR, you can build logic on such variables. As an example, in an IF process, you can check whether $contextvariable.humanagent LIKE yes is true and then navigate the customer to a queue in VCC’s IVR.
Use Dialogflow CX Parameters on the Agent Script
On an agent script, you can use the Script JS SDK to reference variables that you used to store Dialogflow CX parameters.
You can create a function in the following way to get the variable: vcc.getScriptVariable(‘global.ivr.variable’) where ‘variable’ is what you have defined in your IVR process.
Related articles
There's always more to learn. Discover similar features by visiting related articles:
Comments
Can’t find what you need? Use the comment section below to connect with others, get answers from our experts, or share your ideas with us.
There are no comments yet.