Table reservation CUI design
This document describes the design of a conversational user interface (CUI) for table reservations so that all stakeholders can stay in sync on goal and scope. The table reservation module provides a conversational service that enables user to make, view and cancel table reservations. The conversational experience of each functionality is described in detail below.
The design and implementation of this module are based on the following two assumptions:
- The user ID can be obtained without asking from the chatbot runtime.
- A reservation will remain valid until it is expired or canceled by the user. While businesses may change plans and render some reservations invalid, this module does not cover those scenarios.
Make a reservation
To make a reservation, the user can simply say something like, "I'd like to make a reservation," and the chatbot will then ask for the required information. The information that is needed to make a reservation includes the following (captured by slots):
useId
String Required. A unique identifier for the user making the reservation.numberOfGuests
Int Required. The number of guests attending the reservation.date
LocalDate Required. The date of the reservation.time
LocalTime Required. The time of the reservation.
Once the user has provided all of the required information, the chatbot will confirm the reservation and take the necessary action.
The service's conversational behavior is described in the following contextual snippets:
Happy path
- Description: Make the reservation and inform the user of the reservation details.
- Precondition: N/A
- Annotated conversationjson
User: "Hi, I'd like to reserve a table, please." Chatbot: "How many people will you need the reservation for?" User: "There will be two of us." Chatbot: "Which day will you be joining us on?" User: "December 25th, 2022." Chatbot: "What time would you like the reservation for?" User: "3:00 PM." Chatbot: "Are you sure to book a table for 2 at 3:00 PM on Sunday, December 25, 2022?" User: "Yes." Chatbot: "Your reservation has been made. We'll see you at 3:00 PM on Sunday, December 25, 2022. You can check the reservation under your ID: xxxx."
- End state: Slots
useId
,numberOfGuests
,date
andtime
are filled.json{ "useId": "1234567890", "numberOfGuests": 2, "date": "2022-12-25", "time": "15:00" }
Inform reservation failure
- Description: Informs the user when the reservation failed to be created.
- Precondition: Slots
useId
,numberOfGuests
,date
andtime
are all filled. - Annotated conversation:json
Chatbot: "Are you sure to book a table for 2 at 3:00 PM on Sunday, December 25, 2022?" User: "Yes." Chatbot: "I'm sorry, the table you requested is not available. Would you like to try a different time or date?"
- End state:
- Keep the filling for slots
useId
andnumberOfGuests
. - Clear up slots:
date
andtime
.
- Keep the filling for slots
Handle invalid input
- Description: When the chatbot receives a value for a slot that is not serviceable, it will ask the user to provide another value. Using the
date
as an example. - Precondition: Slots
useId
andnumberOfGuests
are filled. - Annotated conversation:json
Chatbot: "Which day will you be joining us on?" User: "This Sunday." Chatbot: "Sunday, December 25, 2022 is not available. Please choose another date. Which day will you be joining us on?"
- End state:
- Slots
useId
andnumberOfGuests
are filled. - Slot
date
is active.
- Slots
Handle value replacement
- Description: When the user requests a change to a slot value, the chatbot will update the slot with the new value. Using the
date
as an example. - Precondition: Slots
useId
,numberOfGuests
anddate
are filled,. - Annotated conversation:json
User: "Can I change the date to this Saturday?" Chatbot: "Sure, the date is changed from Sunday, December 25, 2022 to Saturday, December 24, 2022."
- End state: Slot
date
is filled with new value.
View reservations
Users can view their reservations by simply asking the chatbot to "show me my reservations." The chatbot will then display a list of all of the user's current reservations. To do this, the chatbot needs the following information:
useId
String Required. The ID of the user whose reservations are being viewed.
The service's conversational behavior is described in the following contextual snippets:
Happy path
- Description: Displays a list of all of the user's current reservations.
- Precondition: N/A
- Annotated conversation:json
User: "Show me my reservations." Chatbot: "Here are your current reservations: a table for Sunday, December 25, 2022, at 3:00 PM."
- End state: Slot
useId
is auto filled.
No valid reservations
- Description: When the user asks to see their reservations and there are none, the chatbot will inform the user that there are no valid reservations associated with their account.
- Precondition: N/A
- Annotated conversation:json
User: "Show me my reservations." Chatbot: "Sorry, I can't find any valid reservation associated with your account. Please check to make sure that you made the reservation with your current account."
- End state: Slot
useId
is auto filled.
Cancel a reservation
Users can cancel their reservation by simply asking the chatbot to "cancel my reservation." The chatbot will then ask the user to determine the specific reservation that they want to cancel. To cancel a reservation, the chatbot needs the following information:
useId
String Required. The ID of the user.reservationId
String Required. The ID of the reservation that will be cancelled.
The service's conversational behavior is described in the following contextual snippets:
Happy path
- Description: Cancel the reservation and inform the user of the cancellation.
- Precondition: N/A
- Annotated conversation:json
User: "Cancel my reservation." Chatbot: "Sure. Can you tell me which reservation you would like to cancel?" "1. Sunday, December 25, 2022, 3:00 PM" "2. Monday, December 26, 2022, 7:00 PM" User: "The second" Chatbot: "Okay, I see that reservation. Is this the correct reservation?" User: "Yes, that's correct." Chatbot: "Thank you. The reservation has been canceled successfully."
- End state: Slot
useId
is autofilled,reservationId
is user filled.