Hello world tutorial

In this article, you will learn basic concepts of creating Flow.

Hello world tutorial

In this tutorial, we are going to build a flow bot to display a “hello world” for the users. We are also going to train an intent to understand a greeting and reply with the text “hello world”.

Create a flow

  1. Open the Flow dashboard.
  2. Select the Flows view and click the plus icon to create a new flow.

  1. Drag and drop a Text trigger.
  2. Click SAVE.

  1. Rename your flow to Hello World.

  1. Drag and drop the Text trigger.

Train the intent

  1. After dragging and dropping the text trigger, type in hello in the Text trigger.

  1. Click the TRAIN button to add training examples to the intent.

  1. Rename the intent to Intent Greeting.

To give the bot the ability to respond to a variety of inputs, add additional examples. The AI engine will start using NLP (Natural Language Processing) when it has at least 5 examples.

📘

Note: The more examples, the better the AI engine will work. We advice to add at least 10 examples for an intent to work well

After adding the examples, Click SAVE and return to the flow.

Add a reply

The bot is now trained to understand a greeting

  1. Drag and drop a text reply to the flow.
  2. Type in Hello World as the text.

  1. Drag and drop a Text reply.

  1. Reply with the text “Hello World”.

Reply in context

The bot understands a greeting and can reply with Hello World. We can now reuse our trained intent to respond differently when a user greets the bot.

  1. Select the LIBRARY tab in the sidebar.
  2. Drag and drop the Intent Greeting below the reply.
  3. Add a Text reply after with “Hello Again!”

  1. Drag and drop the Intent Greeting from your library to the flow.

Source

You can download the completed project and import it within a Flow project.