Introduction:
In this article, we explain how to create an intent and then how to work with it.
Create a new intent:
Let's create an intent for ordering a pizza.
- Go to Build > Understanding and open the Intents tab.
- In the field Create new intent enter the name of your intent (order_pizza), and click (+) to create it.
- In the field Add new utterance, add an utterance for you intent. In our pizza example, this could be phrases like 'I would like a pizza please', 'I want to buy a pizza with mushrooms and pineapple', 'Order pizza', 'pizza please'.
- Click Save examples to save your utterances.
- Click Train
Mark utterances with entity values:
Next, look for entities in your utterances, and mark them with entity values.
To mark utterances with entity values:
- Double click on the word you want to mark. The marked word is displayed in the Value field.
- From the Entity field, select the entity that you want to associate the value to. In our case, this is pizza.topping.
- Click Save examples to save your utterances.
- Click Train
Create an entity from within an utterance:
When you're marking your utterances and find that you don't have an appropriate entity yet, you can create one from within an utterance (so that you don't have to switch from intents to entities):
- In the utterance, mark the entity value for your new entity. In our case, we want to create a new entity 'pizza.size', so we mark 'medium'.
- In the Entity field, enter the name of your new entity.
- Click Save examples to save your utterances.
- Click Train