Setting up Dialogflow in Landbot

Learn how to create a basic flow in Landbot that uses Natural Language Processing from Dialogflow to process user inputs and give correct answers.

Welcome to the third lesson of our Dialogflow course, where we'll be teaching you how to create a basic but useful flow in Landbot. If you haven't watched the previous lessons, we strongly recommend you do so before this one to avoid getting lost.

In this lesson, we will guide you through building a flow that gathers information from the user, sends it to Dialogflow for processing, and gives back the correct answer using Natural Language Processing. We'll connect the question text block's back to the Dialogflow block to make a conversational loop.

First, we'll show you how to correctly set the first input of the welcome message. Every bot created has a default welcome message, we'll then set the welcome message to display an open question with no buttons to the user. We'll create a set a variable block after the welcome message to link the @welcome variable to a new variable, @input, which will correspond to the user's first input. This way, all the user's inputs will be saved under the same variable.

Next, we'll use Dialogflow. We'll create a Dialogflow block after the set a variable block and select our agent. There are three main sections in the block: the agent selection, the set-up request, and the save the response. We'll set the @input variable for the set-up request and create a string variable called df_response for the response from Dialogflow.

We'll then create a question text block for the user to see the responses from Dialogflow and get the user's new response. We'll save the new user's answer in our @input variable and connect the question block path back to the Dialogflow block. We'll handle the other two outputs, the yellow and red, by duplicating our question text block and connecting the remaining paths to the block, which will display the response from the Default Fallback intent.

After setting up this basic flow, we'll test the bot and show you how it responds to trained and untrained questions. In the next lesson, we'll teach you how to train your Dialogflow Agent with new intents to create a FAQ bot. So tune in to our next lesson and see you there!

00:00 Intro

00:18 Overview

00:42 Setting up Dialogflow in Landbot

3:51 Testing the chatbot

4:30 Outro

Course episodes

Key Takeaways

  • Create a basic flow and test the bot
  • Build a conversational loop in Landbot

Please note that 'Variables' are now called 'Fields' in Landbot's platform.