Skip to main content

Understanding Intents in Dialogflow

Dialogflow is a highly robust and dynamic natural language understanding platform that allows you to quickly build highly scalable conversational chatbots by leveraging the power of Artificial Intelligence (AI).

You can easily create highly customizable chatbots for variety of channels like web applications, mobile applications, Facebook page, social media apps and much more. It provides seamless integration with variety of channels like Facebook, Viber, Telegram, Slack and much more.

But in order to start working on building a chatbot yourself, lets connect the dots to get a clear picture of entire chatbot development process in Dialogflow. To create a chatbot, let us understand some of the nuances of the Dialogflow.

What are Intents?

Intents help Dialogflow ascertain the real intent or motive of the user messages. You can provide a set of certain training phrases that can help Dialogflow get trained to recognize similar such phrases and trigger a specific intent whenever such phrases are encountered.

Lets look at this example, if you want to create a chatbot that can display current score of Indian or any cricket team and for that you need to first know the name of the user who is interacting, then first you can create an intent name GetName (you can give any name as you want) and then provide different training phrases or user expressions that will help Dialogflow to trigger this intent.

Creating Intents

To create an intent inside a Dialogflow bot, follow the steps below:

  1. Select the desired chatbot.
  2. Select the Entities option.
  3. Enter the desired intent name.
  4. Add many training phrases to trigger this intent.
  5. Click the Save button.



Training Phrases

Lets dive deep into the actual training phrases that will be used to train Dialogflow to invoke this intent when user inputs exact or similar phrases. From the above example where we have to fetch user name from the user expression, we can provide different expressions that will broaden the scope of training and extract the exact name of the user. You can provide expressions like as shown below:

  1. Nikhil is my name
  2. My name is Nikhil
  3. Nikhil
  4. I am Nikhil
  5. This is Nikhil
  6. Nikhil and how are  you? 

      and so on.

There is no limit to the number of user expressions you can enter as training phrases. You can train Dialogflow to extract certain entities from these phrases, which we will cover in our subsequent blogs on Entities.

You can also test out your intent by enter the relevant training phrase in the try it now text box in the panel on right hand side.



Any response that you set gets displayed in the Default Response section.

In the subsequent parts of the blogs, we will dwelve deep to further know concepts like Entities, Fulfillment, Webhooks, Contexts and much more.

Till that time, happy coding!


Comments

  1. Very nice blog...will explore further

    ReplyDelete
    Replies
    1. Thanks foryour valuable inputs will post more blogs

      Delete
  2. Very well explanation of the subject with minute details and examples.

    ReplyDelete
  3. This article is good for the person who are into such work. So your target audience is of similar interests, this is good article. If your article is to target layman, then you have to bring yourself to zero first, questions like what is dialogue flow and chatbots, what is intents, expression. Trust me if you bring it to tune of layman, you will write your success stories.

    Best of luck
    Warm Regards
    Saurabh Thanekar

    ReplyDelete
    Replies
    1. Thanks Saurabh! for your valuable inputs and sparing time to read this blog. Will surely consider your suggestions.

      Delete
  4. Very well written in an easy to understand language!

    ReplyDelete
  5. Very informative article by covering all the technicality of dialoge flow

    ReplyDelete

Post a Comment

Popular posts from this blog

Using Entities in Dialogflow to Extract Vital Information

Having learned about Intents in our previous blog , in this blog we will shed light on another interesting topic of Entities in Dialogflow . Entities provide an efficient way to capture and extract crucial information like name, country, location and any custom information from user inputs. Entities can be mainly categorized into three types: 1.  System Entities : These are build-in entities provided by Dialogflow through which you can identify and extract most common type of data like name, country, date, email address etc. 2. Custom Entities : These are user-defined entities that are useful to extract custom data from the user inputs. For example, you can define a Fruit entity type that can identify and map different fruit types like Mango, Apple etc.        3.  Session Entities : As the name suggests, these entities remain active only for the session for which they have been created. They provide additional capability through which we can update custom entity types with new

SOAP Vs REST – An Overview

Both SOAP and REST provides an efficient means of communication through exchange of data between two applications using web services. Although both are unique in their approach, they score over each other depending upon their suitability in various use cases. What is SOAP? SOAP (Simple Object Access Protocol) is a platform agnostic web communication protocol that uses only XML to exchange data. It adheres to strict message structure of Envelop, Header, Body and Fault (error) that enhances security and uses http to communicate between different applications. What is REST? REST (Representational State Transfer) is an architectural style to exchange data through efficient utilization of resources accessed using a unique URI. REST rides on HTTP/HTTPS to exchange data and supports XML, HTML, plain text and JSON data for API requests and responses. SOAP Vs REST – Which One to Select Both SOAP and REST have their own architectural styles that are flexible, scalable, and fulfil var