You may connect an AI Integration like Wit.ai or Dialogflow to make your bot handle large volumes of messages. With AI, your bot can
- Detect the topic of a message
- Detect important values and phrases from a message
BotDistrikt works with a sub-topic of AI called Natural Language Understanding (NLU) only. BotDistrikt's Rules, Stories, and Engagement tools help assist with other topics like Natural Language Processing (NLP).
A text message. In every AI integration, a text message is also called an utterance. Utterances may be used to train and test AI integrations to detect intents, entities, and traits.
The topic of an utterance. Every AI integration makes an assumption that there are several hundreds of ways of saying the same thing. With this assumption in mind, AI integrations use utterances as questions, and produce topics - or intents, as answers. An intent is trained with an initial set of utterances from the developer. After an intent is trained, the AI platform receives live utterances from Users through your bot, and finds which intent value most closely answers an utterance.
Several utterances can be answered with just 2 intents
Intents should only be used in Rules, but never for assignments or storage with Actions.
Every AI platform allows you to train only 1 set of intents.
Important values in an utterance. Keywords and regular expressions are a good way to pick out important values, but they sometimes can be missed when handling large volumes of messages. Entities scale better on larger volumes, and can have multiple types of values - text, numbers, dates, phrases, or even geographical coordinates.
Unlike an intent, an entity has 2 facets; a name and a value. Its type is a default value of the AI platform itself.
Entities can be used in Rules, but are better used for assignments or storage with Actions.
Every AI platform allows you to train multiple sets of entities.
An unstructured or non-obvious entity. Traits should be used for categorical classification of utterances for which there is no direct association between the keywords of an utterance with its meaning. Traits can only be of one type - Text.
Traits detected from utterances
Traits can be used in Rules, but are better used for assignments or storage with Actions.
Every AI platform allows you to train multiple sets of traits.
A value between 0 and 1, indicating the probability of an intent, entity, or trait being detected correctly. When handling large volumes of utterances, AI platforms can never be perfectly right or wrong. There can sometimes be false positives. As a result, AI platforms provide confidence levels to tell you how likely it thinks an intent, entity, or trait it detected was correct.
Confidence levels can also be used in your Rules to ensure your bot only responds to minimum confidence thresholds that you set.
Intents are detected with confidence levels
After an AI integration detects intents, entities, and traits, the detected values are stored in your bot's NLP context in a conversation session with a User. They can then be used in your Rules to make your bot respond to Messages.
For example, using the above confidence level table, let's assume we have connected the Dialogflow integration. Then we can create a Rule called "user said hello" with 2 conditions
We set a minimum confidence threshold of 0.8 for the "greeting" intent in our Rule
After this, this conversation can occur with a user
Bot detected greeting intent, AND its confidence exceeds the minimum threholdBot: Greetings! How are you today?
However, this conversation can occur with a user as well
User: Yo, how you doin
Bot recognizes greeting intent, but its confidence does not exceed the minimum thresholdBot: I'm sorry, I don't understand what that means
If you use an AI integration, it is imperative to train your bot with very similar words and tonality of how you expect your users to speak with your bot. This way, it can be trained to answer questions for your ideal customer profiles, and not for any random person who will not get any value from your bot.