Context | DialogFlow

Three types of Dialogflow contexts

You might not have realized this, but there are actually three types of Dialogflow contexts. And I recommend only one of them. Implicit and auto-generated contexts When you use the slot filling feature, which I do not recommend, you are using implicit, auto-generated contexts. (Note: I use auto-generated and system generated interchangeably, they mean the same thing). These contexts are auto-generated because you didn’t create them but they are automatically generated by the system when you define a parameter as being required. They are implicit, because their presence cannot be used to infer candidate intents. Explicit and auto-generated contexts When you use the follow-up intents feature, you will notice that Dialogflow automatically adds an output context to the parent intent…

Bot Frameworks | DialogFlow

Dialogflow vs RASA NLU

I have created a small eBook to explain the differences between Dialogflow and RASA NLU if you are trying to choose one or the other. Note: you can right click on the images below and open in a new tab or window to see a larger, full size picture. Table of Contents Excerpt Buy the eBook You can buy the eBook from Gumroad by clicking on the link below.  

DialogFlow | Multilingual Bots

Reader Question: What if a specific system entity isn’t available in all languages in a multi-lingual bot?

I got this question from a reader on my article on creating multi-lingual bots (not to be confused with non-English bots which only use a single language). If the system entities isn’t available for another language, say bahasa indonesia, does this means that I cannot create add bahasa indonesia as one of the language of the multilanguage bot? The answer to this question is a little involved, and depends on many factors. Also, if your bot will “evolve” over time, then you definitely need to read this article. Check all the system entities available for your language You can do this by going to the Dialogflow system entities examples page and filtering by language. The first thing you will note…

DialogFlow | Knowledge Connector

Dialogflow Knowledge Connector : Pros and Cons

A reader asked me this question recently: Do you think the beta knowledge base within Dialogflow is useful? Or are their better ways in to implement a FAQ bot with Dialogflow? There are two types of FAQ chatbots you can create in Dialogflow. 1 You can use the knowledge connector feature (beta) 2 You can use regular intents Knowledge Connector example I recently created a knowledge connector bot and integrated it with Telegram. This is what it looks like: A few things to note: I used Telegram because of the ease of integration. You can use any channel integration and get similar results. There are multiple results per user query. In the screenshot above, there are 3 results In Dialogflow,…

DialogFlow | Integrations

How to integrate Telegram with Dialogflow

In this tutorial, I explain how to integrate your Dialogflow bot with the Telegram chat app. Why I prefer Telegram when creating tutorials I usually prefer to use Telegram for creating tutorials and demos. There are a few reasons for this: The process of creating the bot inside Telegram is quick since you can do it by sending messages to a designated “BotFather” account Telegram has only a single access token, so the integration steps are fewer Telegram supports a few rich responses such as buttons Hyperlinks in the text response of Dialogflow are automatically converted to clickable links inside the Telegram chat window Telegram supports multiple responses per message (for example, the 1-click web demo doesn’t support this) How…

DialogFlow | Slot Filling

A Guide to Dialogflow Slot Filling

When I first started consulting in Dialogflow, I noticed a pattern. A lot of clients who came to me had made a complete mess of their chatbots, and all of them were using the slot filling (required parameters) feature. When you use required parameters in Dialogflow, you are telling Dialogflow – “please ensure that this parameter is actually collected from the user”. When you mark a parameter as required, it will trigger slot filling – and Dialogflow will keep prompting the user until they provide the input. As of this writing (Feb 2020), there isn’t any way to limit the maximum number of retries. I don’t recommend that people use slot filling in their Dialogflow chatbots. It makes your bot…

DialogFlow | Feature Updates

Dialogflow Mega Agent Tutorial

Dialogflow recently introduced the Mega Agent feature. In this tutorial, I explain how you can get started with these Mega Agents. Why use the Mega Agent As the documentation mentions, there are a couple of main reasons to use mega agents: If you have a really large agent (>2000 intents), you have no option but to use mega-agents at this point. But if you are looking to use it to “simplify” your agent management across multiple teams, mega-agent is not an obvious solution to that problem. Also, I am not going to tell you whether you should use mega agents for your particular use case. The answer to that question depends on many factors and you need to consider a…

DialogFlow

How to learn Dialogflow in a week

Recently, I got some feedback from a course student: Since Aravind offers so many dialogflow courses. I hope that he can offer a suggested list: tell us which course sequence should we follow: one after another. So I have written this article to help my course students, but I also think it will be useful for anyone who wants to learn Dialogflow in a systematic way. With that out of the way, here is my recommendation. Day 1 Building Blocks In my view, everyone should first learn Dialogflow’s building blocks – intents, entities, contexts and basics of webhooks – before going on to more advanced topics. You can check out my step by step Dialogflow guide to get started with…

Conversation Design | DialogFlow

Reader Question: Do I need a contextual fallback intent for every single context?

I got this question on my YouTube channel: Hi, I’m new to DF and really appreciate your videos. I totally agree with keeping the context lifespan to 1, as otherwise it makes the conversation really messy. I guess the only situation I have found that this falls down is here, where the default fallback intent then effectively deletes the context, causing re-prompting to fail. I have a complex conversation, and I want a general fallback intent that reprompts the user and maintains the context. Is there any way of creating that, as otherwise I am going to need a fallback for every single one of my (many) contexts. This is a very good question, and the answer is the usual…

DialogFlow | Integrations

Reader Question: Can I use a single agent for Facebook, WhatsApp and website bot?

I recently got this question from a reader. We need help in creating a chatbot for one of our clients. ….. The main problem we have is the language that we need to use: (mentions a language not supported by Dialogflow). The second is that we would like it to work the same on: Facebook, WhatsApp and website. I wouldn’t recommend this. Rich controls The main reason for this is that you are not utilizing all the benefits you get from the UI across all the three channels. Specifically, you have rich controls in these channels which can improve your conversation flow in a few different ways. Speed up user input For example, you cannot have buttons inside your WhatsApp…

Conversation Design | DialogFlow

Build Better Dialogflow Bots

A systematic approach to building and analyzing your Dialogflow bot’s behavior will go a long way towards helping you develop better Dialogflow bots. In this article, I introduce the CTFS framework which will be very useful for analyzing your Dialogflow bot’s behavior. If you have used contexts in your Dialogflow agent, and have ever wondered why a completely different intent (than what you expected) matched the user query, you should read this article. A puzzle This is the first part of a series which introduces some theory about how Dialogflow works under the hood. First, here is a little puzzle: Before you move on to the next part, try and explain to yourself what is going on. Puzzle Explanation So…

DialogFlow | NodeJS | Webhooks

Deploy NodeJS Webhook to Google Cloud

This tutorial was a series of posts which was first published in October 2017. There have been many updates in Google Cloud after this tutorial was first created, so it may not be the best learning resource for this topic. A couple of things to note: almost certainly, the interface will look different today and the screenshots may not be up to date whenever I ask you to click on a certain link, it is understood that you are already logged in to your Google account (that is, many of these links take you directly to specific feature pages inside the Google Cloud Console) If you would like me to update this tutorial, please leave a comment below. If I…