Add intents to determine user intention of utterances
Add intents to your LUIS app to identify groups of questions or commands that have the same intention.
Intents are managed from top navigation bar's Build section, then from the left panel's Intents.
On the Intents page, select Create new intent.
In the Create new intent dialog box, enter the intent name,
GetEmployeeInformation, and click Done.
Add an example utterance
Example utterances are text examples of user questions or commands. To teach Language Understanding (LUIS), you need to add example utterances to an intent.
On the GetEmployeeInformation intent details page, enter a relevant utterance you expect from your users, such as
Does John Smith work in Seattle?in the text box below the intent name, and then press Enter.
LUIS converts all utterances to lowercase and adds spaces around tokens such as hyphens.
Intent prediction discrepancy errors
An utterance in an intent might have an intent prediction discrepancy between the selected intent and the prediction score. LUIS indicates this discrepancy with a red box around the Labeled intent on the row of the example utterance.
In the top navigation, select Train. The prediction discrepancy is now gone.
When a red line is under a word or phrase in the example utterance, an entity prediction error has occurred. You need to correct it.
Add a custom entity
Once an utterance is added to an intent, you can select text from within the utterance to create a custom entity. A custom entity is a way to tag text for extraction, along with the correct intent.
See Add entity to utterance to learn more.
Entity prediction discrepancy errors
The entity is underlined in red to indicate an entity prediction discrepancy. Because this is the first occurrence of an entity, there are not enough examples for LUIS to have a high-confidence that this text is tagged with the correct entity. This discrepancy is removed when the app is trained.
The text is highlighted in blue, indicating an entity.
Add a prebuilt entity
For information, see Prebuilt entity.
Using the contextual toolbar
When one or more example utterances are selected in the list, by checking the box to the left of an utterance, the toolbar above the utterance list allows you to perform the following actions:
- Reassign intent: move utterance(s) to different intent
- Delete utterance(s)
- Entity filters: only show utterances containing filtered entities
- Show all/Errors only: show utterances with prediction errors or show all utterances
- Entities/Tokens view: show entities view with entity names or show raw text of utterance
- Magnifying glass: search for utterances containing specific text
Working with an individual utterance
The following actions can be performed on an individual utterance from the ellipsis menu to the right of the utterance:
- Edit: change the text of the utterance
- Delete: remove the utterance from the intent. If you still want the utterance, a better method is to move it to the None intent.
- Add a pattern: A pattern allows you to take a common utterance and mark replaceable text and ignorable text, thereby reducing the need for more utterances in the intent.
The Labeled intent column allows you to change the intent of the utterance.
Train your app after changing model with intents
Learn more about adding example utterances with entities.
Send feedback about: