How to create and configure Slots

icon picker
Intent Recognition | NLU slot + Intent and Fallback subslots

Purpose and general information

@NLU
is a
@Slot
designed to implement speech recognition by the
@Agent
— processing messages in natural language in order to determine the expressed intention (
@Intent
) of the
@Bot User
and, depending on it, move to the appropriate
@Script Branch
.
image.png
An
@NLU
@Slot
is a
@Complex Slot
and cannot exist without its
@Child Slot
s:
@intent
and
@fallback
@Subslot
s, which begin their own
@Script Branch
es to which the transition will be made once the corresponding
@Intent
is recognized.
The
@NLU
@Slot
processes the incoming
@Bot User
‘s
@Request
previously recorded in the
@client_message
@Context Variable
.
An
@NLU
@Slot
recognizes only those
@Intent
s that are enclosed in its
@intent
@Subslot
s; the remaining
@Intent
s existing in the
@Company
do not participate in recognition in this
@NLU
@Slot
. For example, in the image above, the
@NLU
@Slot
will be trained to recognize only the two
@Intent
s that are selected in its
@intent
@Subslot
s. If none of these
@Intent
s are recognized, the
@Conversation
will move to the
@fallback
@Subslot
.

Slot creation and settings

Slot attributes

image.png
Name — the name of the
@Slot
, which will be displayed in the
@Script Tree
. The maximum length of a field value is 40 characters.
Confidence Threshold — the minimum value of confidence in a recognized
@Intent
, expressed as a percentage, at which the
@Intent
is considered recognized and the
@Conversation
can go to its
@Script Branch
(the
@fallback
@Subslot
@Script Branch
). The value can be an integer from 0 to 100.
It is recommended to set the
@Confidence Threshold
value based on the statement that this value should be inversely proportional to the number of
@Intent
s in the
@Slot
: the more
@Intent
s, the lower the
@Confidence Threshold
should be. To begin with, it is recommended to set the value to 15 and change this value depending on the results of testing the
@Agent
. Read more:

Subslot intent attributes

image.png
Name — the name of the
@Slot
, which will be displayed in the
@Script Tree
. The maximum length of a field value is 40 characters. If a name is not entered, the
@Platform
automatically copies the
@Intent
name from the Intent field to the Name field.
Intent
@Intent
, upon recognition of which
@Conversation
will go along the
@Script Branch
following this
@Subslot
.
SHOW INTENT IN A NEW TAB button — by clicking the button, the
@Intent
selected in the field opens in the next browser tab.

Subslot fallback attributes

image.png
Name — the name of the
@Slot
, which will be displayed in the
@Script Tree
. The maximum length of a field value is 40 characters. When creating an
@NLU
@Slot
, the Name field of the
@fallback
@Subslot
is automatically filled with the contents of the Name field of the
@NLU
@Slot
. If the contents of the Name field are removed, the
@Subslot
in the
@Script Tree
will appear without a name.

Subslots intent and fallback

Automatic generation of subslots when creating an NLU slot

When creating an
@NLU
@Slot
, two
@intent
@Subslot
s and a
@fallback
@Subslot
are automatically generated. If there are no
@Intent
s in the
@Company
, then
@Subslot
s with automatically generated
@Intent
s will be created behind the
@NLU
@Slot
:
image.png
These
@Intent
s will appear in
@Company Resources
. About creating
@Intent
s: .
You can replace
@Intent
s in generated
@Subslot
s by expanding the
@Subslot
by double-clicking the mouse, clicking on the name of the
@Intent
and selecting the desired one from the drop-down list and clicking the Save button.
image.png

Adding Intent Subslots

To add a new
@Subslot
, you need to click on the + button. The new
@Subslot
will appear in the
@Script Tree
above the
@Subslot
, which is always located at the bottom.
image.png

Removing Intent and Fallback subslots

To remove an
@intent
@Subslot
, you need to right-click on it and click the Remove Branch button, then click OK in the pop-up dialog box.
image.png
image.png
It is possible to delete any
@intent
@Subslot
if, after deletion, the
@NLU
@Slot
remains at least two
@intent
@Subslot
s.
Removing one of the last two
@intent
@Subslot
s is not possible. When you try to do this, the following error will appear at the bottom center:
image.png
Removing the
@fallback
@Subslot
is not possible. When you try to do this, the following error will appear at the bottom center:
image.png

Slot operation

The
@NLU
@Slot
is trained on
@Training Dataset
of
@Intent
s added as its
@Subslot
@intent
. About filling
@Training Dataset
: .
The
@NLU
@Slot
receives the
@client_message
@Context Variable
as input, processes it, recognizes the
@Intent
, and transfers the
@Conversation
to the recognized
@Intent
@Script Branch
. If no
@Intent
is recognized with the proper level of confidence, the
@Conversation
goes to the
@fallback
@Subslot
.

Intent recognition process

Training: The
@NLU
@Slot
is trained on samples of
@Intent
s added as its
@intent
@Subslot
s.
Important: if the
@Agent
was edited, but the changes affected only the contents of other
@Slot
s, in addition to
@NLU
@Slot
, then when the
@Agent
is retrained, the
@NLU
@Slot
will not be retrained.
Receiving a
@Request
: the
@NLU
@Slot
receives the
@Bot user’s Message
— the text in the
@client_message
@Context Variable
.
Classification of the
@Request
: the message is classified from the
@client_message
@Context Variable
and arranges all
@Intent
s of this
@NLU
@Slot
according to the level of confidence in them — confidence (expressed as a percentage, the same as CONFIDENCE THRESHOLD).
Creation of the
@nlu_result
@Context Variable
in the
@Chat Context
: the
@nlu_result
@Context Variable
is created, the value of which becomes a json object containing information about the top 5 recognized
@Intent
s in descending order of their confidence.
Example: [{'intent_name': 'size', 'confidence': 0.9993743300437927}, {'intent_name': 'product_in_stock', 'confidence': 0.00019508253899402916}, {'intent_name': 'model_price', 'confidence': 0.00012844 608863815665} , {'intent_name': 'address', 'confidence': 0.00010525238758418709}]
Transition to
@intent
:
@Intent
with maximum confidence, provided that this confidence >= CONFIDENCE THRESHOLD from the settings of this
@NLU
@Slot
, is the
@Intent
by which the
@Request
is recognized. Consequently:
The
@Conversation
will go to the
@Script Branch
of this
@intent
@Subslot
;
the
@intent_name
@Context Variable
appears in the
@Chat Context
ー the name of the recognized
@Intent
;
the
@intent
@Context Variable
appears in the
@Chat Context
— the identifier of the recognized
@Intent
;
the
@confidence
@Context Variable
appears in the
@Chat Context
— the level of confidence that the
@Request
belongs to a specific
@Intent
, expressed as a percentage.
The
@intent
and
@confidence
@Context Variable
s exist in the
@Chat Context
until the next execution of the same or another
@NLU
@Slot
in this
@Agent
.
Transition to
@fallback
: If the confidence of all
@Intent
s is below CONFIDENCE THRESHOLD from the settings of this
@NLU
@Slot
, then it is considered that not a single
@Intent
was recognized, as a consequence:
The
@Conversation
will go to the
@fallback
@Subslot
@Script Branch
;
the
@error
@Context Variable
appears in the
@Chat Context
— the error text. This
@Context Variable
exists in the
@Chat Context
until:
next execution of the same or another
@NLU
@Slot
;
@Regular Expression Slot
execution;
@External Request
@Slot
execution.
Available languages to recognize by NLU Slot
4
Language
Abbreviation in the dropdown list
1
Russian
image.png
2
English
image.png
3
Portuguese
image.png
4
Ukrainian
image.png
5
Spanish
image.png
6
Vietnamese
image.png
7
Thai
image.png
8
Indonesian
image.png
9
Malay
image.png
10
Filipino
image.png
11
Serbian
image.png
12
German
image.png
13
Polish
image.png
14
French
image.png
15
Pakistani (urdu)
image.png
16
Kyrgyz
image.png
17
Arabian
image.png
There are no rows in this table
Want to print your doc?
This is not the way.
Try clicking the ⋯ next to your doc name or using a keyboard shortcut (
CtrlP
) instead.