Skip to Content
What is AI?Self-guided student course

Lesson 2 of 6 · 15 minutes

Action: How AI Learns from Patterns

How does AI work?

  1. First you give the AI lots and lots of data. What kind of data depends on what you are trying to teach it.
  2. The AI analyzes the data to find patterns.
  3. The AI uses the patterns to make predictions.
What you want to teachData you providePattern it might findPrediction it makes
Understand people talkingLots of recordings of people talking, with transcripts of what was saidWhenever it hears a "ssss" sound, the word contains a c or an sIt hears a new word with a "ssss" and an "oh" sound and guesses "so" (it might be wrong, maybe the word is "sew"!)
Make up a storyLots of different storiesMost stories have a happy endingIt ends a story with the main character winning a race
Play tic-tac-toeThe moves from lots of games and who won each oneThe player with the middle square wins more oftenIt takes the middle square if it is available
Model
An AI model is a program that has been trained on a set of data to recognize patterns and make decisions or predictions. Each AI tool uses an AI model.

Whenever you use a website, app, or tool that uses AI, there is an AI model behind the scenes.

Activity 3: Are you as smart as AI? (4 minutes)

Let's see if you can find a pattern and make your own prediction. This table shows how long it took someone to walk different distances.

Distance walkedNumber of seconds
1 meter2
2 meters4
3 meters6
4 meters8
5 meters?

Are you as smart as AI?

How many seconds will it take to walk 5 meters?

Regression
A model that represents a relationship between at least two different variables. The model lets you predict the effect on one variable when you change the other.
Linear regression
A regression model that can be drawn as a straight line.

More factors, better predictions

Regression is used for real predictions too. Arctic sea ice expands and thickens in winter, then shrinks and thins in summer. This affects shipping routes as well as the lands and lives of Arctic peoples. Scientists use AI to predict how much ice will melt from one month to the next.

Factors included in those AI models are things like:

  • ice thickness
  • temperature
  • surface area of the ice

When several factors affect an outcome, you want to give the AI data about as many of them as possible to get the best predictions.

Think like a scientist

Your answers are saved in this browser only. You can copy or download everything you wrote from the last lesson.

Activity 4: Sort like a classifier (5 minutes)

Here are two groups of things. Look for the pattern.

Group AGroup B
SunflowerDog
Oak treeEagle
CactusSalmon
FernFrog

Are you as smart as AI?

Where should the kangaroo go?

Classification
Classification models decide how data should be sorted into groups.

Are you as smart as AI?

Where does a coffee mug go?

Classification in the real world

Classification AI could be used to automatically sort trash on a conveyor belt. A camera analyzes what is going by, classifies each item as paper, plastic, or metal, and sends it to the right bin.

Activity 5: Can AI predict a dice roll? (3 minutes)

Someone rolls a dice four times and gets 1, then 6, then 1, then 6.

Are you as smart as AI?

What will the next roll be?

Confidence
A number between 0 and 100 (0 is lowest, 100 is highest) that indicates how likely it is that a prediction made by an AI model is accurate.

Remember

AI finds patterns in data and uses them to make predictions. It works well when there is a real pattern, and it will still answer when there is not. Always ask how confident the AI is, and whether a human has checked its work.

Finished this lesson?

Mark it complete so you can pick up where you left off.