2 · Features & labels (the words makers use)
To train a model, you need two simple ideas. Once you have these, the rest of the course is mostly practice. Meet features and labels.
A feature is a clue the model looks at. It's one piece of information about an example. If you were sorting fruit, the features might be color, size, and shape. For a photo, the features are really the pixels — the tiny colored dots — and the patterns inside them (edges, blobs, textures). You usually don't pick pixel-features by hand; the model finds useful ones itself. The point to remember: features are the "what it notices."
A label is the right answer you're teaching. It's the name of the category an example belongs to. If you're teaching "apple vs. banana," then apple and banana are your two labels. Labels are how the model knows it guessed right or wrong while it's learning. The point to remember: labels are the "what it should say."
Put them together and you get one training example: some features (the clues) plus a label (the right answer).
| Example | Features (clues) | Label (right answer) |
|---|---|---|
| A photo of a red round fruit | color: red, shape: round | apple |
| A photo of a long yellow fruit | color: yellow, shape: long | banana |
| A clip of a barking sound | the sound's pitch & rhythm | dog |
Two flavors of ML you'll hear about:
- Supervised learning — you give examples with labels, like the table above. "Supervised" just means a human supplied the right answers. This is what you'll do in this course, and it's the most common kind.
- Unsupervised learning — you give examples with no labels and ask the model to group similar ones on its own. Useful, but harder to steer. We'll stick with supervised.
So your whole job as a trainer is: gather good examples, label them correctly, and let the model find the pattern. Simple to say — and the next lessons are all about doing it well.
Think about it. You want to teach a model "cat vs. dog" from photos. What are your two labels? Name two features (clues) the model might use to tell them apart.
Sources
- Code.org. How AI Works (machine learning, training data). https://code.org/curriculum/how-ai-works
- Common Sense Education. AI literacy lessons (how AI is trained on data). https://www.commonsense.org/education/collections/ai-literacy-lessons-for-grades-6-12