How to create your Agent

icon picker
Creating an Agent in Excel

Import from Excel file

By importing an
@Agent
⁠
@Script
⁠
from an Excel file, it is possible to create FAQ
@Agent
⁠
s with a question-answer structure, and the
@Agent
⁠
's response may consist of several consecutive messages.

Acceptable file extensions

At the moment, Excel files with the following extensions are available for download:
.xlsx

Excel File Format

The Excel file you upload must have the following characteristics:
File structure: ​
image.png
⁠
⁠
1st line:
the value of cell A1 is the text language;
the value of cell B1 is the language code for the
@Agent
⁠
’s NLU model (the language that will be recognized by the
@NLU
⁠
@Slot
⁠
). The code can be written in any register. More details in the table
Broken link
⁠
).
The 2nd line must be empty. Otherwise, the import will fail: error messages will be displayed and the
@Agent
⁠
will not be imported into the
@Platform
⁠
. ​
image.png
⁠
⁠
Starting from the 3rd line there is a table with data for creating a FAQ-Bot:
@Training Dataset
⁠
for
@Intent
⁠
s that will be included in
@Agent
⁠
@Script
⁠
, names of
@Intent
⁠
s and answers to them:
Column A:
name: intent in cell A3;
contents: names of
@Intent
⁠
s that will be included in the
@Agent
⁠
@Script
⁠
.
Column B:
name: examples in cell B3;
contents:
@Training Dataset
⁠
for
@Intent
⁠
s. The
@Training Phrase
⁠
s are written starting from the cell opposite the name of the
@Intent
⁠
and below. ​
image.png
⁠
⁠
Column C:
name: message in cell C3;
content:
@Agent
⁠
responses to
@Intent
⁠
s. Contains any text data, including links to files that can be used as
@Agent
⁠
responses; randomization of
@Agent
⁠
responses is also supported (more details: ). ​
image.png
⁠
⁠
Columns D and E:
optional fields. If the
@Agent
⁠
must respond in several messages rather than in one, then you can specify from 1 to 3 consecutive messages.
filled in similarly to column C.
To indicate the
@Agent
⁠
’s response to
@fallback
⁠
(in case none of the
@Intent
⁠
s are recognized. More details: ) ​
image.png
⁠
⁠
The value of the
@fallback
⁠
cell is written in the
@Intent
⁠
column;
The cells in the examples column remain empty. If the cells are full, their values are ignored when importing the file;
The message column/columns indicate the
@Agent
⁠
’s response to
@fallback
⁠
.
Available languages to recognize and their codes
4
Language
Excel
1
Russian
ru
2
English
en
3
Portuguese
pt
4
Ukrainian
uk
5
Spanish
es
6
Vietnamese
vi
7
Thai
th
8
Indonesian
id
9
Malay
ms
10
Filipino
tl
11
Serbian
sr
12
German
de
13
Polish
pl
14
French
fr
15
Pakistani (urdu)
ur
16
Kyrgyz
ky
17
Arabian
ar
There are no rows in this table
⁠

Contents of the imported Agent

General principle of constructing the
@Script
⁠
When you import a file into the
@Platform
⁠
, an
@Agent
⁠
is created with the following
@Script
⁠
structure:
image.png
⁠
⁠
⁠
@Start
⁠
@Slot
⁠
;
Then an
@NLU
⁠
@Slot
⁠
with
@intent
⁠
@Subslot
⁠
s for each
@Intent
⁠
from the uploaded file and a
@fallback
⁠
@Subslot
⁠
;
⁠
@intent
⁠
and
@fallback
⁠
@Subslot
⁠
s are followed by
@Slot
⁠
s with
@Agent
⁠
messages/responses, if they are specified in the downloaded file in the message column. Otherwise,
@Slot
⁠
s with
@Agent
⁠
messages/responses will not be created;
At the end of each
@Script Branch
⁠
there is a
@Wait For Reaction
⁠
@Slot
⁠
.
Logic for creating an
@intent
⁠
@Subslot
⁠
branch
For each
@Intent
⁠
from the downloaded file:
An
@Intent
⁠
is created in the
@Company Resources
⁠
with the
@Training Dataset
⁠
specified in the file;
⁠
@Intent
⁠
s are created in accordance with the rules of importing
@Intent
⁠
s.
⁠
@Intent
⁠
s containing less than 2
@Training Phrase
⁠
s will be ignored during import: they will not appear in the
@Company Resources
⁠
and the corresponding
@Subslot
⁠
s will not be created for them with the
@Script Branch
⁠
.
This
@Intent
⁠
is set in the
@intent
⁠
@Subslot
⁠
;
From 1 to 3
@Text
⁠
or
@Attachment
⁠
@Slot
⁠
s are created with
@Agent
⁠
messages/responses following this intent
@Subslot
⁠
. The content of the
@Text
⁠
or
@Attachment
⁠
@Slot
⁠
s corresponds to the content of the message columns (C, D, E columns) for a given
@Intent
⁠
: ​
image.png
⁠
​
image.png
⁠
⁠
if the cells in the message columns are empty, then
@Text
⁠
or
@Attachment
⁠
@Slot
⁠
s are not created after the
@intent
⁠
@Subslot
⁠
;
if several cells of one
@Intent
⁠
are filled in one message column, then a
@Text
⁠
@Slot
⁠
is created and the contents of each cell are imported as one of the
@Agent
⁠
’s random responses (more about randomization of responses: ). ​
image.png
⁠
​
image.png
⁠
⁠
In the
@Slot
⁠
@Markdown
⁠
is disabled by default and the
@Savepoint
⁠
option is disabled.
Cells in the message columns containing text matching the pattern <file link> + text or text + <file link> will be imported as
@Attachment
⁠
@Slot
⁠
s, the fields of which are filled in as follows: ​
image.png
⁠
⁠
image.png
⁠
⁠
Name field — filled with the first 40 characters of the text from the cell accompanying the link
Source field — filled with a link from the cell
Caption field — filled with text from the cell accompanying the link
Primary type field — the file type is set according to the extension in the link:
Image — jpg, jpeg, png, gif, bmp
Audio — mp3, wav, wma, aac, ogg
Video — mp4, mov, avi, wmv, flv, mkv
In the
@Slot
⁠
@Markdown
⁠
is disabled by default and the
@Savepoint
⁠
option is disabled.
The remaining cells in the message columns are imported as
@Text
⁠
@Slot
⁠
s.
Logic for creating a
@fallback
⁠
@Subslot
⁠
branch
The
@fallback
⁠
@Subslot
⁠
is created;
If the file contains a response to a
@fallback
⁠
,
@Text
⁠
or
@Attachment
⁠
@Slot
⁠
s are created behind the
@fallback
⁠
@Subslot
⁠
in order from column C to column E in the table; ​
image.png
⁠
⁠
image.png
⁠
⁠
If the file contains several
@fallback
⁠
lines, then when importing the file, the text for the response is transferred from the first of them, the remaining
@fallback
⁠
lines are ignored;
If there is no
@fallback
⁠
in the file or the corresponding cells in the message column are not filled in, then during import a
@fallback
⁠
@Subslot
⁠
is created followed by a Wait For Reaction
@Slot
⁠
. ​
image.png
⁠
⁠
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.