Part 1: GCP DialogFlow Voice Chat Tracking Using Adobe Analytics [Part 1/2]

Introduction#

With the rising chatbots implementations and market viewpoint, it is exceptionally critical for organizations to receive the manner in which they connect with clients. With recent developments in Natural Language Processing, Machine Learning and Artificial Intelligence voice based digital assistants are becoming integral part of everyday lives.

Key Statistics on ChatBots#

  • BusinessInsider predicts that 80% of business want ChatBots by 2020.
  • As per digitalgo.it: The Global ChatBot market is expected to reach $1.25 billion by 2025.
  • A leading press release by Juniper Research claims ChatBots will be game changer for Banking and Health Care, saving $8 billion annually by 2022.

With rise in usage of ChatBots and Voice Based Searches comes the opportunity to optimize voice-app development, increase engagement and understand the impact of consumer voice in context of overall customer experience with ChatBots.

This will be a Two Part series of articles focusing on Creating/Understanding ChatBot Architecture and Key Terminologies [Focusing on Google Assistant] and then integrating Adobe Analytics Tracking to Collect/Measure and optimize user experience.

Part 1: Understanding ChatBot Architecture and Key Terminologies for Google Assistant#

The basic architecture for tracking voice based Digital Assistant can be demonstrated by image below: (image source Adobe Whitepaper)

Voice Analytics Architecture

In order to setup Adobe Analytics tracking we have setup a fictitious Voice based Cab Booking Service called [BookMyRide]. The Key components of setting up ChatBot are explained below:

Actions On Google : Actions on ChatBot [Google Assistant] allows integration between Google Assistant and DialogFlow, letting us use the DialogFlow agents as conversational fulfillment for our Google Actions. This is where we setup default Invocation for our fiction Cab booking Service “Okay Google Open Book My Ride”

DialogFlow : Built on Google Infrastructure, DialogFlow is a service that incorporates Google’s Machine Learning service and performs Google Cloud Speech-To-Text using natural language processing (NLP) powered by AI. This is where we create our conversational chat-bot to understand user query [Intents] and train bot using training phrases and respond appropriately.

Intents : The Intent categorizes user intention for each conversation turn for agent. Multiple Intents are created for a conversation bot in order to map end user expression to best matched intent in our system. When an Intent is matched DialogFlow triggers the actions defined in our chatbot agent.

We have created the following Intents for our Cab Booking Service —

  • Default Welcome Intent : This is invoked as default intent when user launches the app using default invocation “Okay Google Open Book My Ride” (Explained above)
  • Car Type :This Intent let’s user select the car type they would like to book for their ride, We have limited the selection to Sedan, Hatchback and SUV.
  • Destination : The Destination intent ask’s user for the destination for their travel, We have added list of Major Indian Cities to model in order to identify the destination and estimate a fare accordingly.
  • Confirmation : The final step in decision making, this Intent processes and confirm booking /or abort booking as per user response.
  • Default Fallback Intent : The system generated default intent when DialogFlow is unable to match any above user Intent based upon user-expression. This basically notify’s user that his expression was not matched to any Intent. Example “Sorry I couldn’t understand your response. Please try again”

Parameters [Entities] :When an Intent is matched for processing, DialogFlow provides a mechanism to extract data points from end-user query called parameters. This is generally the contextual values which are structured and can easily be used to perform logical evaluation and generate response.

The values from Intent Car Type: SUV, Sedan and Hatchback are entities or parameters. Similarly destination provided by user in Destination Intent is also an entity which is used for logical evaluation of Fare and generate response.

Fulfillment : In order to use Integration [Adobe Analytics Tracking and other sources] our agents needs more than static intent responses. The fulfillment is used to connect our service, take actions based upon user responses and send dynamic responses back to users. In our scenario this is where we calculate the Fare, ETA of cab booked and approximate time of travel to destination.

DialogFlow provides Inline Editor to Build and manage fulfillment directly in Dialogflow via Cloud Functions for Firebase.

Setting up all above components described above, Below is a screen capture for flow of our Voice Based Cab Booking Service:

Closing Notes#

In Part 2 of this article we will focus on setting up FireBase Cloud Functions to handle DialogFlow Firebase Fulfillment, setting up digital datalayer and tracking key metrics for BookMyRide cab service using Adobe Analytics Data Insertion API.

References#

©2020-2022 abhinavpuri.com