Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Course: Artificial Intelligence Question: Write down a code in python in input base. In this case, the chatbot should continue until the reservation in a

Course: Artificial Intelligence

Question: Write down a code in python in input base. In this case, the "chatbot" should continue until the reservation in a restaurant gets accomplished. So code in python should be like that the reservation in restaurant is complete, otherwise it will continue till reservation. If the input person don't want reservation, the reservation will complete; but it is not the required objective. NOTE: Need comments .

image text in transcribed

Lab 1 - Agents (Chatbot) UTSA - CS3793 & CS5233 - Artificial Intelligence Spring 2020 Task Now that you're familiar with Python, write a short program: a (very) basic chatbot! It won't be passing the Turing test any time soon, but it's a good warm-up for this course. The specific situation that you will be implementing your chatbot will be in a restaurant setting. Details Assume that the chatbot is at the welcome table in a restaurant. Upon running your python program, your chatbot will wait for user input, then respond to each input until a new negotiated reservation gets accomplished. The output must look as shown in this sample conversation: Bot: Hello, welcome to XYZ restaurant. You: SDSFASDF Bot: Hello, welcome to XYZ restaurant. You: Hello Bot: How are you feeling today? You: Good Bot: That's good to read. Do you already have a reservation? You: Nope Bot: Would you like to make one now? You: Yes Bot: When would you like your reservation for? You: Sunday at 4 pm Bot: Sure, I can help you with that. A table for how many people? You: 5 Bot: It's all set. Have a good day! You: Thank you, bye! abc123-lab1.ipynb Create a new Python 3 notebook named abc123-lab1.ipynb. Add a text cell at the top of the notebook with your full name and UTSA ID. Create a new section in the notebook and name it "Lab 1 - Agents(Chatbot)". Access sections by opening the left menu/arrow and choosing the Table of Contents. Add a code cell in this new section, add code to run your chatbot. Chatbot The chatbot itself will be rule-based - that is, it will answer input from the user with predefined responses. When run, your bot should prompt the user for input, as above, wait for that input, and choose an appropriate response. The responses in yellow color above show where the user can answer differently. The chatbot should include possible answers to various interactions, as shown with a grey color background in the example above. Note that an incorrect answer to a specific question will lead the chatbot to repeat the question. The chatbot should continue until the reservation gets accomplished. To avoid repeated responses, your bot should choose if it has more than one correct response to user input. The chatbot can also finish when the user says that he/she does not want to make a reservation. For the user's response for when is the reservation wanted it will only verify if within the message exists one day of the week is a good answer. The table should include a minimum of 5 possible responses of the user per

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Systems Introduction To Databases And Data Warehouses

Authors: Nenad Jukic, Susan Vrbsky, Svetlozar Nestorov

1st Edition

1943153191, 978-1943153190

More Books

Students also viewed these Databases questions