Back to computer sciencecomputing use cases

Computer ScienceComputingElementaryPrimary

How to run an Hour of AI

The Hour of AI is a free, one-hour introduction to artificial intelligence that schools run each December during Computer Science Education Week. This guide gives three steps to run one, and a free activity where students train a cat-or-dog sorter and explain why it gets some animals wrong.

Title card reading 'How to run an Hour of AI', next to three chat cards: a student says his sorter called two dogs cats, Sparky asks what color the cats in his Cat bin were, and he explains that the sorter thinks orange means cat.

"By using Flint, students are also learning how to use AI effectively. They are learning the importance of effective prompting when asking Flint for explanations in different ways or reflecting on learning by summarising key points."

Richard StraffordRichard Strafford, Computer Science Teacher at The British School of Barcelona

Why this matters

AI shows up in the apps students use every day (Hour of AI how-to guide), and many elementary students believe an AI simply knows the answers. A student who believes that can't tell when an AI is wrong, or why. A class video about machine learning shows the idea once, and the teacher has to wait until the next lesson to find out who still thinks the computer just knows.

What the Hour of AI is, and how to run one

The Hour of AI is a global initiative that gives students a first, hands-on hour with artificial intelligence. It grew out of the Hour of Code and is organized by CodeAI, the nonprofit formerly called Code.org, with a coalition of partners (Hour of AI FAQ). The 2026 event falls during Computer Science Education Week, December 7 to 11, and the activities work any time of year (Hour of AI how-to guide). Hosting one takes no AI or coding experience.

  1. Pick an activity where students teach the AI instead of only using it
  2. Have each student test the AI on cases they didn't choose
  3. Ask each student to explain every mistake from their own examples

The official catalog at hourofai.org lists activities from CodeAI, Google, Minecraft Education, LEGO Education and other groups. The Flint activity on this page is not part of that catalog. It is a free activity you can run as your class's Hour of AI.

In the Flint activity, each student trains a cat-or-dog sorter with animal cards they pick, tests it, and explains each wrong guess to Sparky, Flint's AI tutor. A worksheet can't read a student's explanation, and Sparky answers a wrong one with a hint about the cards that student picked.

Sparky gets Mateo to find the mistake in his own examples

Mateo ends up explaining why his sorter called a dog a cat: every cat he picked was orange. Every student gets the same sorter and test cards, and Sparky's replies depend on the cards each student picks and what they write.

Sparky starts from the student's own sorter and resultsSparky sends Mateo back to the cards he pickedA right answer gets a harder question
M

Mateo

Interest: His orange cat, MangoStarting point: Thinks AI just knows the answers

Sparky

Today YOU are the teacher. Use the Cat or Dog Sorter Trainer below to pick your examples, train your sorter, and test it out!
The Cat or Dog Sorter Trainer interactive Sparky attached to its first message. It shows 12 cat and dog cards, each listing fur color, size and ear shape, a Cat bin and a Dog bin, and buttons to train the sorter, test it and start over.
InteractiveCat or Dog Sorter Trainer

Mateo

it got 2 wrong. the big orange dog and the small white dog with pointy ears. it said they were both cats
Mateo's sorter. His Cat bin holds two orange cats and his Dog bin holds a black dog and a brown dog. The sorter called the big orange dog a cat, with the closest example Orange Cat (big), and called the small white dog a cat. It got 4 of 6 right.
InteractiveMateo's first test: 4 of 6 right

Sparky

Why do you think your sorter called the big orange dog a cat? Think about the dog cards and cat cards you put in the bins.

Mateo

maybe the AI is just bad at dogs

Sparky

Look at the cards you put in the Cat bin. What color were most of those cats?

Mateo

they were both orange. so the sorter thinks orange means cat and the orange dog matched my big orange cat

Understanding check

Now here's a trickier question: imagine a card shows a small fluffy white rabbit with pointy ears. What would your sorter guess, and why?

Mateo

it cant say rabbit because it only knows cat and dog

Blamed the sorter, then traced the mistake to his all-orange Cat bin

Mateo is an example student, and Sparky's replies are shortened.

What Flint did for Mateo

  • Sparky attached the sorter to its first message, and the sorter showed which of Mateo's cards matched each guess.
  • When Mateo blamed the AI, Sparky asked what color the cats in his Cat bin were instead of answering.
  • Once Mateo explained the mistake, Sparky asked what his sorter would do with a rabbit card.

A teacher can't do this by hand for 30 students, and Sparky does it in every student's chat.

The activity page shows who still blames the computer

While the class works, Needs attention shows the teacher which student is stuck and on which message. After three or more students submit, activity analytics lists what the class explained well, where students went wrong, and a follow-up to practice next.

Flint's activity page for Train an AI Sorter: Cat or Dog? Needs attention flags a student who wrote 'the computer is just broken' and stopped testing. Activity analytics says 8 students blamed the sorter before looking at their cards, and suggests a follow-up sorter for apples and oranges.

Example activity page

After a class trains their cat-or-dog sorters

The school and students are made up, and you can click any student to read their chat and see their bins.

Set up the activity for free

The cat-or-dog sorter activity is in Flint's public library, with the sorter, Sparky's guidelines and the greeting already written. Open it, select Use activity to copy it into a free Flint account, assign it to a class, and use Try session myself in the Preview tab to train a sorter as a student first. The Hour of AI how-to guide suggests closing by asking students what surprised them about how AI works, and Sparky ends each chat by asking students to compare their first idea about AI with what they found.

The Hour of AI is a global initiative by Computer Science Education Week (csedweek.org) and the Hour of AI (HourofAI.org) to introduce millions of students to artificial intelligence.

For more computer science activities, see Flint for computer science.

Other use cases

See all use cases →

Learning feels different when it fits you.