Intent Node

Intent nodes can be used to capture a user response that contains a certain intent, and stores the intent into a variable.

Type in the intent to be captured, then press ENTER. The intent will appear in the list below.

Click the edit button, enter the intent editing screen in the NLU editor.

On the left side, enter templates to be captured. Intent nodes will try to match user input with sentences in the template, and when matched, it will trigger the following dialogue graph.

On the right side, edit slots. Each slot has its own name, and should be based on an Entity as its slot type. It can be either a system entity or an user-defined entity.

Now we can label the templates with intent slots. After labeling, words with labels can be interchanged with other phrases in the entity when the intent node tries to capture an user input.

Let's try it out!

The captured intent will be stored into a variable, whose name is the same as its slot name. That variable can be used in bot's response, as shown below:

Since variables are stored as arrays, (in case of multiple values for the same variable), using ".key" can return all keys of locations, which is also an array. Using ".get(0)" can access the first element of the array, of which the ".key" can be used to get the desired value.