This tutorial will show you how to set up a new project and create a chatbot from scratch.
Are you working on an existing project? Then you don't need to set up a new one. Feel free to skip ahead to the next tutorial.
Never built a chatbot before? This short tutorial video explains you the key steps to creating a chatbot and the terminology used on the Chatlayer.ai platform.
For this tutorial, we’ll create a conversational interface called Choo-choo: a digital assistant to help people book train tickets.
To get started, please make sure you have valid log-in credentials to access the Chatlayer.ai platform.
Log in using your credentials on https://cms.staging.chatlayer.ai/
To start, click the
+ Add bot button to create a new bot
Choo Choo (your first name) as the name of your bot
English as the primary language. This is the language your bot will use
(Optional: you can add other languages if you want a multilingual bot)
Create to create your new bot
In the menu on the left, click on
Bot dialogs. Enter the
General flow by clicking the flow icon
After entering the flow, you will see an empty chatbot flow containing only the standard predefined dialog states. Your screen should look something like this:
The first thing we need to do is create a greeting. Greetings allow your bot to introduce itself and help users understand its functionalities and personality. Greetings are an important way to set the proper expectations of a bot.
Our Choo Choo bot will start each conversation. You can edit this greeting in the
introduction bot dialog.
Zoom in (or out) by use the scrolling wheel. Click and drag to move through the dialog tree.
Click on the edit icon of the
introduction bot dialog
Chatlayer.ai supports multiple content types. Depending on the channel your bot will use (Facebook, Slack, Skype, Google Home, ...) these will be rendered slightly differently. Since this is our first bot and our first message, let's start with a simple text message:
Delete the predefined greeting message by clicking on the Trash icon.
Hello. Please configure the introduction dialog state with a meaningful message.
Replace it with the following text:
Hello there! My name is Choo Choo, a digital assistant that will keep you on track.
Text in the section 'Add bot message' to add a second message and enter the following text:
How can I help you today?
The result will be:
Just like in normal conversations, your users won't like it when your bot always replies with the exact same messages. That's why Chatlayer.ai supports random messages. In a Text Message block, you can add multiple alternatives to the same message. Chatlayer.ai will randomly pick one of these messages, making your dialogue feel more natural and human.
Just below 'How can I help you today?', click on
Add random message and enter the following text:
What can I do for you?
Tip: you can add as many random messages as you like.
Save to save all the changes you made in the
introduction bot dialog.
Time to check if we configured everything correctly. To do so, it's not necessary to publish your bot to a channel like Facebook Messenger or Slack. You can see how your bot replies by using our built-in emulator.
Click on the Emulator icon in the lower right corner to test your bot.
If you have configured everything correctly, Choo Choo will now reply with the right messages. You can ignore the debug button for now, but this will be useful later when you want to debug more complicated flows.