The 'Pizza order' solution contains a flow to order pizzas with different kinds of crusts and toppings. Before the final order is sent, the user will be prompted for a confirmation. At this point, more toppings can be added or removed.
This solution showcases the following Teneo concepts:
Concept | Description |
---|---|
Entities | Contain all possible pizza crusts and all possible toppings. |
Flow listeners | Pickup relevant information (like pizza crusts or toppings) at any point in the flow. |
Flow variables | Store relevant information and return it to the user for confirmation. |
Loop back | Allows to summarize the order for the user and ask for additional toppings. |
Skip conditions | Avoid asking for things the user already mentioned. |
This is the outline of the solution's main flow User wants to order a pizza:
One way of how a pizza can be ordered is by classical slot filling, where the bot guides the user to the next slot to be filled:
User: I want to order a pizza
Bot: Which crust would you like? Italian/thin or American/pan?
User: Italian, please.Bot: Which toppings do you want on your thin pizza?
User: I'll take ham and mushrooms.Bot: So, I have a thin pizza with the following toppings: ham, mushrooms - Any other toppings you would like to add?
User: No.Bot: Alright, thanks for your order. We are now preparing your thin pizza with mushrooms and ham.
However, the user does not need to wait for the bot prompting for information: all information can be given when it suits the user best, just like in a human interaction. The bot will listen for the crust type and up to 4 toppings and store them:
User: I want to order an American pizza with cheese, onions, and pepperoni
Bot: So, I have a pan pizza with the following toppings: cheese, onions, pepperoni - Any other toppings you would like?
User: I'll have some mushrooms as well.Bot: Ok, I have updated your order. So, I have a pan pizza with the following toppings: cheese, mushrooms, onions, pepperoni - Any other toppings you would like?
User: NoBot: Alright, thanks for your order. We are now preparing your pan pizza with cheese, mushrooms, onions, pepperoni - Enjoy!
Finally it is possible to not only add but also remove toppings:
User: I want to order a thin pizza with broccoli, mozarella and salami
Bot: So, I have a thin pizza with the following toppings: broccoli, onions, mozarella, salami - Any other toppings you would like?
User: I'll have some bacon instead of salami and remove the broccoli please.Bot: Ok, I have updated your order. So, I have a thin pizza with the following toppings: bacon, onions, mozarella - Any other toppings you would like?
User: NoBot: Alright, thanks for your order. We are now preparing your thin pizza with bacon, onions, mozarella - Enjoy!
The solution contains the following components:
Was this page helpful?