This article is an overview of a multi-part series of tutorials that show you how to build, secure, and scale a chatbot by using Dialogflow on Google Cloud. This tutorial is useful for developers and engineers who are interested in building a chatbot with their own data.
The history of conversation user interfaces is as old as modern computers. ELIZA was an early natural language processing computer system created from 1964 to 1966 at MIT Artificial Intelligence Laboratory. One type of natural language processing computer system are chatbots. A prominent version of conversation chatbots are question-answering systems, which are capable of understanding user questions and replying to them with an answer. For example, IBM's Watson is a question-answering system capable of answering the questions posed in natural language.
Recently, Q&A chatbots have developed significantly with the introduction of products such as Siri, Cortana, and Google Assistant. A typical conversational bot system architecture is outlined in the following diagram.
The system architecture has the following components
- Multichannel integration: Any conversational interface connects with multiple channels, which can be in both voice and text format.
Conversation management: This component is the heart of interface and typically provides the following functionality:
- Speech-to-Text (STT) and Text-to-Speech (TTS): Conversation interfaces have the ability to interact with speech and text.
- Virtual agent: Agents are responsible for managing the flow of the conversation based on the intent or motivation extracted from user conversation. A good conversation interface has an agent system that can handle linear and nonlinear conversations.
Fulfillment interface: No conversation interface system is complete without a robust fulfillment interface, which is required to connect virtual agents to external systems. This interface is required to connect with external systems to fetch dynamic information to continue or fulfill a conversation.
Dialogflow is an end-to-end, build-once, and deploy-everywhere development suite for creating conversational interfaces for websites, mobile apps, popular messaging platforms, and Internet of Things (IoT) devices. You can use it to build interfaces, such as chatbots and conversational interactive voice response (IVR), that enable natural and rich interactions between your users and your business.
As part of building a chatbot, you preprocess data to create topics and then extract and save associated synonyms for given topics. This data is uploaded to Dialogflow Agent, and topics are uploaded in entities. Entities are Dialogflow's mechanism for identifying and extracting useful data from natural language inputs. With entities in place, you create intents in your agent that map user input to responses. In each intent, you define examples of user statements that can trigger the intent, what to extract from the statement, and how to respond.
Dialogflow can connect to external systems on an intent-by-intent basis by using Fulfillment code, which is deployed as a webhook. During a conversation, fulfillment lets you use the information extracted by Dialogflow's natural language processing to generate dynamic responses or trigger actions on your backend.
The tutorials in this series include the following:
- Building a chatbot agent by using Dialogflow.
- Securing and scaling chatbots for production.
- Explore reference architectures, diagrams, tutorials, and best practices about Google Cloud. Take a look at our Cloud Architecture Center.