My Friend, The Chatbot
My friend, the chatbot
age group (5-11)
Deploy a chatbot to answer your questions
We’re going to design a chatbot to teach your computer to recognize questions about your name, age, family, and more!
Users will solve text classifications problem by training a machine learning model to recognize questions by adding examples of how those questions could be asked to the chatbot. These examples will belong to 4 different classes (Greetings, Name, Age, Nationality, and Siblings). Then, they will export the model Scratch to make a chatbot that answers those questions.
WHAT IS IMAGE CLASSIFICATION?
Classification is a supervised learning technique in which the computer uses input data (in this project, text as input data) to learn and then classify new observations. Further information can be found in the second course of Level2, Supervised Learning, in the AI Master Program.
You will learn to
After completing this project, you will learn how to:
- Collect data and split it into training and testing datasets.
- Train a computer to recognize questions
- Computers could be trained to recognize the intent behind the text.
- Understand how chatbots are used to automate answering people’s questions.
The dataset includes many examples of statements related to Greetings, Name, Age, Nationality, and Siblings to use to train the model on how to react to different questions.. This dataset will be used to train your ML model on how to do the classification task on its own . You will need to make sure that your split your data into training dataset and testing dataset so that you know how to assess the performance of your ML model.
1. Select transformer
You will select your favorite AI transformer which you will train to do tasks like humans! If you want your transformer to become more intelligent, you will have to keep training it on different tasks by creating different projects.
One day, you will be able to transfer your AI transformer's brain into a physical robot that you can use in the future!
2. DEFINE THE PROBELM. START YOUR PROJECT
First, create a project and name it so you know what kind of project it is. Naming is important. A project combines all of the steps in solving a problem, from the pre-processing of datasets to model building, evaluation, and deployment. Using projects makes it easy to collaborate with others.
After adding the project’s name and description, click on CREATE
3. SELECT YOUR ML MODEL
In this step, you will need to select one of the ML models in order to solve your problem, that is classifying text. You will find a computer vision model (Make Me See), Natural Language Processing model (Make Me Read), Voice Recognition (Make Me Hear), and a tabular model (Make Me Count). In our case, you will need to train your AI transformer to how to classify text , therefore, you need to select MAKE ME READ.
More AI capabilities (models) will be added to the platform, so stay tuned! These models will help you to accelerate the process of creating a trained AI model that solves your problem, and thus export into your app to start using it!
4. COLLECT YOUR DATA
This is the most important step in any ML project. In fact, data preprocessing is 70-80% of any ML project. In this section, you will need to manually add text examples or import the My Friend, The Chatbot dataset from our data library
First, Name the first class (Greeting) and add examples like “Good morning”, “Good afternoon”, “How are you doing?” etc.
Second, name the second class (Name) and add some examples like “What is your name?” “What should I call you?” “Who are you?” etc.
Third, name the third class (Age), then add examples like “How old are you?” “Age”, “Old”, “Can I know your age?” etc.
Fourth, name the fourth class (Nationality), then add some examples to it like “Where are you from?”, “Which country are you from?” “Nationality”, etc.
Finally, name the last class (Siblings) and add examples like “How many siblings do you have?” “Do you have sisters?” “Do you have brothers?” etc.
5. TRAIN YOUR MODEL
Right now, and after you completed training your model, you are ready to test it by type a new text .
Just make sure that you don’t use an example from the dataset that you used in the training part, otherwise, you are cheating!
Type a new statements to assess the performance in the preview section. If you like the confidence score, you can export your model. Otherwise, go back to the "collect data" step and check whether you have used sufficient text in the training dataset.
Click TRAIN ME to start the training. This may take a few moments.
EXPORT YOUR MODEL
If you are happy with the testing results, you can "Export" your ML model using our API into your own website, application or even to your robot or any machine!
If you are not happy with the confidence score, you will need to check your training data classes again, and make sure that you have clean and sufficient number of examples for each data class. Keep in mind the concept of GIGO (garbage in, garbage out) which means that the quality of your ML model output is determined by the quality of your input, i.e. training dataset.
build project on scratch
A. Click on the green flag to execute the project
B. Now, feel free to start to chat with your friend and ask him whatever you want.