Use built-in slot types in a bot flow
Architect bots support two slot types: built-in slots and custom slots. Built-in slots define how the bot recognizes and handles data in the slot. Built-in slots eliminates the need to create enumeration values for commonly used slot data such as date, time, and duration.
Incorporate built-in slots when you create a slot from the Natural Language Understanding menu. To make it easy to use common slots, you can create a slot with your preferred name and then map it to a slot type from Architect’s built-in library. The slot that you create includes the configuration of the built-in slot type.
Architect includes the following built-in slot types by default:
|NLU slot type||Architect data type||User input examples||Resolved format examples||Notes|
|builtin:amountOfMoney||Currency||“$30.23” or “forty dollars”||
|Converts words that indicate currency into a numeric amount of money.|
|builtin:date||Date||“June 15” or “next Tuesday”||
|When passing date values into or out of a bot flow, make sure that you pass the value as a string in extended ISO-8601 format. For example, 2021-02-16.|
|builtin:number||Decimal||“23” or “three point five”||
Converts numeric words ("five") into digits (such as "5").
This feature does not currently support ordinal numbers (first, second, etc.).
|builtin:time||Time||“3 p.m.” or “three-thirty p.m.”||
|Converts words that indicate time ("four in the morning", "two p m") into a time value ("04:00", "14:00").|
Add a built-in slot to your bot flow
To add a built-in slot to your bot flow, follow these steps:
- Under Natural Language Understanding, click Slots.
- From the Intents page, click the Slots tab.
- Click Add Slot.
- Provide a meaningful name for the slot.
- Under Slot Type, click Existing.
- From the list, select an existing slot type.
- Click Save.
Modify a slot
To modify slot information, from the Slot menu, select a slot and click Edit .
Delete a slot
To delete a slot, from the Slot menu, select a slot and click Delete .