You are currently viewing DialogFlow 2 – Intents and conversation flows

DialogFlow 2 – Intents and conversation flows

Hi again,

Going on with Dialogflow, in this post we will review how the conversation flow is built using intents. Later in the blog we will see how more logic is added with fulfillments.

As we said the agent will be started with an initial intent, in the case of Google Assistant it would be the “Default Welcome Intent”. This intent usually has a greeting and provides the user with directions of what to do with the bot to be able to move forward in the conversation, as the next step will be a user input that we need to capture.

Taking a look to the console it looks like this:

We don’t need training phrases for this intent, but they are there by default, nor parameters, as it is will the event Welcome the one triggering this intent. In the answers we have 2 (or more) options, the the agent will use alternatively, to avoid monotony.

Now the user will tell us what to do next. The agent will be “listening” to the user interactions and will trigger the intent that has a matching training phrase … this will start our conversation.

In my experience we always need to have an intent with some advice of what they can do. This is the one for this bot:

In fact it makes a lot of sense to have 2 or more help intents, one for the initial help, with a more general introduction, and others more to the point in case they are triggered in the middle of the conversation. We will see that later with the use of contexts.

Another intent that we must have is one that will terminate the conversation at any moment that the user is willing to, and again we don’t need any context for this one:

The next step would be to define the alternatives that our users can do with the bot, and I think is to “draw” it in a state diagram.

In this case we will be able to make reservations and check their state, among with asking for help and existing … this would be our flow:

In the boxes I have entered the intent names in black, and in blue the parameters that we will detect in those intents. In the reservation intent we would need the city for the reservation and the date:

In the a later post we will se how to use those parameters and how to generate the contexts to keep the conversation flow.




I work for Google Cloud, but this post are personal ideas and opinions


This Post Has One Comment

  1. Thibaut Saah

    Thanks for this !

Leave a Reply