In this tutorial we will import 1000 intents into ServisBOT
The following items are required before importing intent and actions into the ServisBOT platform.
ServisBOT has a limit of 50 intents per bot in order to maximize the accuracy of using different NLP services. In order to import and use 1000 intents as part of a virtual Assistant, 20 bots will be needed. Use the secret created in the prerequisites steps.
For this demo, use the
Lex Bot blueprint.
Take note of your bot’s name in the system and then use our common definition format to define the intents, utterances, and actions.
Sample Utterance File
bot, intent, utterance Sbimport, welcome, hi Sbimport, welcome, hello Sbimport, welcome, hey Sbimport, howAreYou, how are you Sbimport, howAreYou, sup Sbimport, howAreYou, how are u Sbimport, botimport, how does the intent import work Sbimport, botimport, what does the import function look like Sbimport, botimport, How do I import intents
Actions are expected to be in the following CSV file format.
bot, intent,lifecycleTrigger ,type , value Sbimport, welcome, fulfilment, message, hi! Sbimport, howAreYou, fulfilment, markup, "<TimelineMessage>\n\t<Card title='Im doing great!' imgUrl='https://picsum.photos/250/250/?random&g' alt='Lovely image' />\n</TimelineMessage>" Sbimport, botimport, fulfilment ,message ,You first set up your csvs for intents and for actions, then import them
* Bot: the botname for the bot you are assigning it to
* Intent: the intent alias you want to set an action for
* lifecycleTrigger: Whether you want your action to be triggered when the intent is detected (but slots are still pending)
Detection, or once an intent is ready to be fullfilled.
* Value, the value of the response
lifecycleTrigger and type are optional columns. Everything defaults to “Fulfillment” and “message”
You can use either the Portal or the ServisBOT CLI to import your intents.
Intent tab of each Bot page you can use the
Import Intent button to upload your utterance and action CSV files.
“botName” relates to the name of the ServisBot bot that you created - not the name of your AWS Lex Bot. “utterances.csv” and “actions.csv” can be supplied as the directory path to each associated file.
sb-cli intent import utterances.csv actions.csv
Available in version 2.11.1 and later
After importing intents, you should be able to see your intents by navigating back to your bot detail pages, and exploring the
Bot ArmySection of portal