AI from Zero · Lesson 3 of 6

How AI sees, hears, and speaks

From face unlock to voice assistants, the one trick behind all of it: turning pictures and sound into numbers a machine can work with.

Beginner9 minute read

Your phone unlocks when it sees your face. Your voice assistant writes down what you say. It feels like the machine is looking and listening the way you do. It is not. Underneath, there is one humble trick that makes all of it possible, and once you see it, computer vision and speech recognition stop being magic.

Everything becomes numbers

A computer cannot see a photo or hear a sound. It can only work with numbers. So the very first step in any AI that deals with images, audio, or text is to turn that thing into numbers.

  • An image is a grid of tiny dots called pixels, and each pixel is just a number for how bright or what colour it is.
  • A sound is a wave, measured thousands of times a second, giving a long list of numbers.
  • Text is split into pieces and each piece is swapped for a number too.

Once the picture or sound is a big list of numbers, the AI can do what it is good at: find patterns in numbers. That is the whole secret.

Try it: what the AI really sees

Here is a simple picture. You see a shape. The computer sees only numbers, one for the brightness of each pixel. Flip between the two views.

Interactive

An image is just numbers

Toggle between what you see and what the AI sees.
Same picture, two views. To the AI there is no picture at all, only this grid of brightness numbers to find patterns in.

Then it spots patterns

Once an image is numbers, an AI trained on millions of examples (remember lesson 2) learns which patterns of numbers mean "an edge", then "an eye", then "a face". Speech works the same way: patterns in the sound numbers become sounds, then words. The AI is not understanding in a human sense. It is matching patterns it has seen before, incredibly fast.

Why this matters
Face unlock, photo search, voice typing, and self-driving cars all run on this same two-step idea: turn the real world into numbers, then find learned patterns in those numbers.

Where you meet it every day

  • Face unlock turns the camera image into numbers and checks the pattern against you.
  • Voice assistants turn your speech into numbers, then into words.
  • Photo apps group pictures of the same person by matching number patterns.
Coming up next
Turning text into numbers and finding patterns is also how ChatGPT works, and that is the big one. It is the very next lesson.
Scroll to Top