Creating a Chatbot using Cloud Dialogflow
This post is inspired by Tony Okwechime who presented his talk at Devfest and through that Igained interest. These are my notes part of the Dialogflow course on Pluralsight
Dialogflow — creates an engaging voice and text based conversations interfaces e.g. chatbots powered by AI.
Built on top of Natural Language Processing (NLP) — the interactions between computers and human natural languages. i.e. takes input from natural human input and the computer can extract meaningful information to give the user the correct output.
Building Converstational Experiences with Dialogflow i.e. Chatbots
Chat agents with natural interaction with between customers and your business.
They use Natural Language Understanding uses ML to interact with users not hardcoded scripts. Recognises a users intent and responds accordingly based on its training data.
Use Case :
Connecting business to customers e.g. customer care service
Connecting business to its employees e.g. surfacing data and insights
Controlling IoT Devices e.g. Google Home
Dialogflow — a powerful NLU engine that understands and processes natural language input therefore a natural conversation experience
How DialogFlow Works
Training Data- the input
Proprietary Language Models by Dialogflow
Unique Trained model for each agent as more users engage with your agent
Intent - programmed to handle user requests thus determines what an agent should do.Example handles a pizza order request from a customer. Based on intent you can add a variation of training data.
Fallback intent — when agent doesn’t understand user request.
Follow-up intent — similar to how when humans are conversing every statement or question is followed up by yet another set of statements of questions until the conversation simply fizzles out. Example. order a pizza you get asked whether you want to get a drink too.
Entities — help identify who, what, when, where in a users’ request. In simpler words they help your chatbot extract specific details from a conversation.
Action — action what the agent should do.
NB: You must enable DialogFlow APIs on the GCP Console.
Maintaining Context
Context-enables chatbot to keep the continuity of the conversation dialog. Therefore less repetition.
Making fulfillments
Fulfillment is based on an intent then there is a generated dynamic responses or trigger actions on your back-end. Example. when a user orders pizza store their order e.g. in Cloud Datastore Database. You can use Cloud Functions and enable Webhook in your intent.