🌸 April Holiday Revision Packs — ALL subjects, ONE PDF, KSH 40 per grade (PP1–Grade 12)  →  Download Now
📚 Kenya's #1 CBC (now CBE) & IGCSE Learning Platform | 💬 WhatsApp Support
M-Pesa · Visa · PayPal · Instant Download
← All Lessons 🏆 Get Certificate
Lesson 8 of 10
🐶
Lesson 8

Build Your First AI — Pet Recogniser

In 30 minutes, you will train an AI that knows the difference between your pet and other pets. Real AI. Built by you.

⏱ 30 min read 🧠 3 quiz questions 🎯 Pass: 2/3

Today you stop being an AI user — and become an AI builder

Every lesson so far, you've learned ABOUT AI. Today, you will BUILD one. Real AI. With a webcam. With your pet. Or your cup. Or your shoe. Anything you can hold in front of a camera.

What you'll need

  • A laptop or tablet with a webcam (not a phone — the tool works better on a bigger screen)
  • Chrome browser (it works best in Chrome)
  • Two or three things to show the camera (e.g., your pet, a toy, a book)
  • A parent to help with the first steps
  • 30 minutes of quiet time

No coding. No installations. No money. Just a web page.

Step 1: Open Google's Teachable Machine

Ask your parent to go to teachablemachine.withgoogle.com.

Click the big blue button "Get Started". You'll see three options: Image, Sound, Pose. Click Image Project. Then Standard Image Model.

Step 2: Set up your classes

You'll see two boxes: "Class 1" and "Class 2." Rename them to what you'll teach the AI:

  • Class 1: "My Pet" (or "My Shoe" if no pet)
  • Class 2: "Other Thing" (something that's NOT your pet — a book works)

You can add a Class 3 if you want — e.g., "Nothing" (empty space).

Step 3: Record examples

Click the webcam icon under "Class 1." A video feed opens. Hold your pet in front of the camera. Click "Hold to Record." Move the pet around slowly — from different angles, in different light. Keep holding for about 10 seconds. You'll capture about 50-100 images.

Now do the same for Class 2. Hold the book. Record 50-100 images from different angles.

Why lots of examples? Remember Lesson 2: AI learns from variety. If you only show your pet from one angle, it won't recognise the pet from the back. Move. Rotate. Different light. Different rooms. The more variety, the smarter your AI.

Step 4: Train the model

Click the big button "Train Model." Wait 20-60 seconds. Don't close the browser during this time. The computer is doing the "million-tiny-adjustments" from Lesson 2.

Step 5: Test!

When training finishes, a Preview panel appears on the right. Point the webcam at your pet — the AI should say "My Pet: 98%." Point at the book — "Other Thing: 95%." Try a pet-shaped toy. Try something the AI has never seen before. See what happens.

Congratulations. You are now an AI builder.

What to do if it's wrong

If the AI keeps getting things wrong:

  • Record more examples of the class it gets wrong (e.g., more pet photos)
  • Make sure your examples are varied — different lighting, different angles
  • Re-train the model

This is literally what AI engineers at Google, Safaricom, and Apple do. You are doing the same work. Just smaller.

The huge realisation

If you can build an AI that knows your pet, you can build an AI that recognises:

  • Ripe vs unripe mangoes (useful for farmers!)
  • A smiling face vs a sad face (useful for a mood tracker)
  • Different types of leaves (useful for a biology project)
  • Coins of different denominations
  • Anything visible to a camera

You have done something most Kenyan adults haven't done. You built AI. Tell your parents tonight. Show them.

🙋 Do This With Mum or Dad (30 minutes):
Complete the full Teachable Machine project above. Once the AI works, export the model:
Click "Export Model" at the top right. Choose "Upload my model" to get a shareable link. Share this link with us by emailing cbcedukenya@gmail.com. We'll feature the best projects in our WhatsApp community.

🧠 Quick Quiz!

Answer the 3 questions. Get 2 right to unlock the next lesson.

Question 1

What tool did you use to build your first AI?

Question 2

Why should you record many different examples (different angles, lighting)?

Question 3

If your AI gets things wrong after training, what is the best fix?

← Lesson 7
Next Lesson →
Pass the quiz to unlock
📚

Get Free CBC (now CBE) Revision Materials

Join 500+ Kenyan teachers and parents. Get a free sample pack (Grade 7 Maths notes + exam) plus weekly study tips.

No spam. Unsubscribe anytime. We respect your privacy.

S Ask Somo 🇰🇪 FREE · AI TUTOR ×