Overview

Get an overview of how NativeChat works and what you need to create a successful chatbot.

NativeChat is a cloud product for building and deploying chatbots into various channels. It makes it easy to create chatbots on top of existing systems.

Chatbots can interact with users in a natural way by understanding natural language expressions. Then they can generate reactions and responses based on a cognitive flow definition.

Development does not require a definition of extensive decision trees and exhausting training process.

Here is a recent webinar recording that can give you the overview of the NativeChat platform - what are the benefits, how to use it etc.

How does it work?

1. Deciding what kind of chatbot to build

NativeChat works best for transactional chatbots. These are bots focused on conversing about very specific things. One bot can only handle a handful of simple processes before it becomes too complex to develop, train and maintain.

So what are the criteria for the processes that a bot is best suited to handle?

Automate repetitive tasks

A task that can be very well described and broken into simple steps is an ideal candidate. Each occurrence of the process should be exactly or very close to the previous. Examples of these are submitting support tickets, booking resources, checking the status of orders and similar. In each of these cases, you have specific information to ask about in a particular order. For humans doing this, it is a boring and mundane routine.

Automate most frequent tasks

Bots are ideal for automating processes which are simple but require a lot of time and effort from your customer support team. They are quick to resolve by humans but the sheer volume of requests is what burdens and distracts your customer support team. Help your staff focus on the hard stuff by relieving easy tasks to a bot.

2. Conversations & Training

Once you’ve figured what task you want to automate with a chatbot, it’s time to think about how people talk to you in these cases.

For example, when someone wants to check the status of their upcoming flight they might ask “Is Oceanic Flight 815 going to be on time?” or alternatively “Will Oceanic Flight 815 depart on time?”.

The process of making a NativeChat bot understand such natural language is called Training.

When you train your bot, you provide it with multiple examples of how people could say the same thing.

You do the training for each conversation and entity within the training section of your NativeChat chatbot.

Conversation

The conversation in NativeChat is a logical grouping of questions that the bot can ask the users. One conversation would have one specific goal and many steps that lead to achieving that goal.

You need to train the bot with a few examples of how people would ask about that goal or information so that the bot can identify the correct conversation from the Cognitive Flow that needs to be started.

Entity

Entities are the specific pieces of information that the bot needs to understand. Example entities for a trip are departure city, departure date, arrival city, and arrival date.

There are different types of entities - dates, numbers, locations etc.

So when the user says “I’m flying from London” the bot will extract London as value for an entity of type Location.

You can also define your own custom entity types like Company, Doctor, Office or other types specific to your data.

Lookup strategies

When training a bot to understand natural languages and discover entity values, there are 3 different approaches.

  • trait lookup - when an entity value is not explicitly entered by a user but it can be understood from his or her expression. “Can you call me? / Contact me by phone” both mean the same thing said in a different way but the intent is the same.
  • keyword match - this is when the bot looks for exactly the words it was trained with in order to extract the value.
  • regex - when the bot needs to collect data in very specific format. E.g. email address, or phone number. The other 2 strategies cannot help in such cases.

Dynamic training

Often you’ll have a lot of data stored in your enterprise systems that you’ll want your bot to understand. So instead of manually entering and transferring this data to NativeChat, you can provide a REST API endpoint which NativeChat can use to extract training data from.

If you are a hospital with 120 doctors that needs a booking chatbot, you can dynamically train NativeChat to understand doctor names when someone is asking “Can I visit <doctorname> today?”.

Question answering

Question and answer training can be used for small talk or FAQ scenarios where the bot understands the user question or phrase and directly provides an answer. For example, when the user says bye, thanks the bot can reply with you are welcome.

3. Cognitive Flow

In order to create a conversational intelligence for your chatbot, you are required to describe all conversations in a structured format. For each conversation, you will be able to define Steps that describe a process. Example of a conversation can be submitting a HelpDesk request, booking a doctor’s appointment, or requesting days off from an HR system. A Step can either extract data from the user using Natural Language Processing (NLP) or simply send a message to the user informing him of an event.

The Cognitive Flow is described in JSON format within the NativeChat Portal by accessing the Cognitive Flow tab.

Automatic slot-filling

Slot-filling is a machine algorithm where you have a defined number of pieces of information (called slots) that needs to be gathered from the user. Each slot corresponds to an entity and a step in your cognitive flow definition. Thanks to Natural Language Processing, NativeChat can automatically fill some (or all) of the slots if the user writes them in some part of the conversation.

For example, if you need to collect data for an appointment that requires a user to select a doctor, a date and a time you can define 3 entities and 3 steps in the cognitive flow. And if the user says something like “Can I visit Dr. Smith on Wednesday afternoon?” NativeChat will automatically fill the 3 matching entity values with Dr. Smith (doctor), 21-03-2018 (date) and 12:00PM (time) and continue the conversation.

Bot Memory

NativeChat chatbots have long-term and short-term memory.

  • short-term memory - this is where all the information from the current conversation with a user is stored and you can use it in your cognitive flow.
  • long-term memory - after a conversation is completed, all the information from the short-term memory is saved in the long-term memory.

Information in the long-term memory can be used for displaying suggestions to the user or automatically pre-filling some of the data in a conversation by using the suggestions reaction

Linear vs decision-tree

The steps of the conversation you define in the Cognitive Flow are executed in a linear way, one after the previous.

You can add conditions to each step so it is executed only if the conditions are met.

In a conversation with a user, the chatbot will always try to finish the conversation by running all the available steps.

Types of conversations

There are 2 types of conversations the chatbot can have depending what you are trying to achieve with them.

Goal conversations

The goal is to complete a specific business process, e.g. book an appointment, make a request, etc. When the bot is having a goal conversation it will try to complete all the steps and keep asking the user questions.

Support conversations

These are used to help the user achieve a business process, such as provide billing info, get help, answer FAQs and etc. Support conversation can also be referenced from multiple goal conversations. If you need to collect contact information from the user, you can create a support conversation “Contact Information” once and then redirect to it from all goal conversations that need to collect such information. When the user completes a support type conversation the bot switches back to the original goal conversation and proceeds with the remaining steps.

Types of steps

  • question - allows you to extract a specific entity from a conversation and preserve it in the bot memory.
  • message - simply send a message to the user
  • command - commands are not messages visible by the user but tell the chatbot how to continue.
  • webhook - retrieve or send REST API requests
  • confirmation - prompt user for confirmation
  • entities-confirmation - prompt user for confirmation of several entities

4. Testing

Before you publish your chatbot, you need to make sure that it performs well.

Test console

The NativeChat development portal has a built-in testing console where you can test your bot. The console gives you log with all that happens during a chat session - NLP understanding, validation results, webhook responses etc.

Proxy bot

NativeChat provides a fast and easy way of testing your bot on some of the channels without having to publish it. This is achieved through official proxy bots for Alexa, Viber, Facebook and MS Teams. To learn how to use them refer to the Proxy Bots article.

5. Publishing

When you are done developing your bot, you can publish in one or more of the channels supported by NativeChat.

NativeChat supports a variety of channels. The publishing is a quite straightforward process for each channel. You can check the specifics in the documentation section Publishing.

6. Improving your bot

Once your chatbot is live, you’ll most certainly need to improve it as you see some actual usage patterns.

To check the conversations the users are having with your chatbot, go to Bot Memory > Conversation History. There you can see all the interactions your bot has had. You can filter the list to see only unsuccessful conversations or a particular conversation.

When you see a message from a user that the bot didn’t understand correctly or at all, you can adjust your training data or the cognitive flow to better handle such cases.