Dictionary is a functionality that is a table with data uploaded to the Platform, used in conjunction with the Slot Synonym.
The Dictionary is an object of the Company’s Resources, that is, it is accessible from all Agents of this Company. During Training, a Trained Agent Model is created, which contains a copy of all the Dictionaries involved in the Scenario at the time of Training.
Dictionary format
The file uploaded as a Dictionary has the following characteristics:
- Format
.csv
; - File Contents:
- 1st column — name: ‘entity’, content: names of Entities (sets of Synonyms);
- 2nd column – the name of ‘synonyms’, contents: sets of Synonyms listed separated by commas
- The names of the Entities can be repeated.
- Synonyms in different Entities can be repeated.
- The Synonym case does not affect the recognition result.
- If there are “duplicates” in one Dictionary — strings in which both the name of the Entity and the sets of Synonyms coincide (even if the order of these Synonyms in the strings are different) — the “duplicates” will not be imported during the import of this Dictionary, only the first of the “duplicate” strings will be imported.
Important: recognition of dictionary Entities works qualitatively and flexibly only in Russian and Ukrainian languages, in other languages (if the dictionary is in another language or mixed languages) recognition will occur only by the exact coincidence of the desired string with the Synonym in the list of Synonyms (without endings, declensions, etc.)
List of dictionaries
- A list of all the Company’s Dictionaries is available on the VOCABULARIES tab after switching to the Agent’s BotBuilder
Important: despite the fact that the transition to the List of Dictionaries comes from the BotBuilder of a specific Agent, this list contains Dictionaries available to all Agents of the Company.
The limit on the number of Dictionaries for one Company is 20 pieces. When the limit is reached, when you try to load a new Dictionary, you will receive an error notification at the bottom.
Uploading a new Dictionary in the company’s resources
To create a new Dictionary, the user should:
- Go to the BotBuilder of the desired Agent by clicking on the Design button;
- Go to the VOCABULARIES tab;
- Click on the + Create New button;
- Enter the name of the Dictionary in the Name field. The maximum length of a field value is 1000 characters. When the maximum value is reached, no further characters are entered into the field;
- Upload a file for the Dictionary by clicking the Upload your vocabulary button or by dragging and dropping the file into the window.
It is possible to upload the same Dictionary file multiple times.
- Save the entered data by clicking the Save button.
Export-import of dictionaries during export-import of the Agent
When exporting an Agent, all Dictionaries contained in its Script are also exported. An agent with Dictionaries included in it is exported as a .cfg file. When importing an Agent, the Dictionaries used in it are imported, while:
- If the Company has a Dictionary containing an identical file, there is no duplication of the Dictionary. In this case, the Dictionary from the Company Resources will be used in the Agent Script.
- If the Company has a Dictionary with the same name, but a different file, the import will occur.
- If the Company does not have such a Dictionary, it will be imported and will appear in the list of Dictionaries.
Editing the dictionary
To change the name or file of an already downloaded Dictionary, the user should:
- Go to the list of Dictionaries.
- Click on the line with the Dictionary that you want to change;
- Edit the dictionary:
- To change the name, click on the name field and change its contents;
- .To update the Dictionary file, you need to upload a new file by clicking the Upload your vocabulary button or by dragging the file to the window;
- Save the entered data by clicking the Save button.
- The changes will take effect only after the Agent is retrained.
Delete a dictionary
To delete a single one, the user should:
- Go to the list of Dictionaries.
- Click on the needed Vocabulary and then to Delete button next to , which the user wants to delete;
- Confirm the action in the modal window by clicking the DELETE VOCABULARY button.
- If trying to delete a Dictionary that is used in the Agent(s) Script, the user will receive a warning that should first remove it from the Script.