Listen here
Lesson 2.1: Data and Algorithms

🧠 Lesson Overview

In this lesson, you’ll learn about the two foundational building blocks of Artificial Intelligence: data and algorithms. These are the core components that make AI systems intelligent — and understanding how they work together will give you a clearer picture of how AI actually learns, makes decisions, and evolves over time.

📊 What Is Data in the Context of AI?

In the world of AI, data is everything. It’s the raw material that AI systems use to learn, make predictions, and take action. This data can take many forms — numbers, text, audio, video, images, sensor readings, or even real-time signals from the environment.

For example:

  • When training an AI to recognise cats in photos, the data consists of thousands of labelled images of cats.

  • A voice assistant like Siri learns from audio recordings and natural language text.

  • A recommendation engine learns from your watch history, clicks, ratings, and browsing behaviour.

The more high-quality data an AI has access to, the better it performs. But this also means that poor, biased, or insufficient data can lead to inaccurate or unfair results. That’s why data preparation, cleaning, and ethical sourcing are crucial in AI development.

⚙️ What Are Algorithms?

An algorithm is a set of instructions or a formula for solving a problem. In AI, algorithms are used to analyse data, identify patterns, and make predictions or decisions based on that data.

Think of it like a recipe. The data is the list of ingredients, and the algorithm is the method for combining them. Some AI algorithms are relatively simple, while others — like those used in deep learning — are highly complex and contain millions of adjustable parameters.

Different types of AI systems use different algorithms depending on the task. For instance:

  • A decision tree might be used for choosing between options based on a set of rules.

  • A neural network might be used for recognising images or translating languages.

  • A clustering algorithm might be used to group similar users or products together.

What they all have in common is that they use mathematics and statistics to learn patterns in data and generalise those patterns to make new predictions.

🔁 How Data and Algorithms Work Together

AI learning happens through a process called training. Here’s how it typically works:

  1. Input data is collected — such as images, text, or audio files.

  2. This data is fed into an algorithm, which tries to learn patterns or rules.

  3. The AI makes predictions or classifications based on those patterns.

  4. The system receives feedback — either from humans or through automated scoring.

  5. The algorithm adjusts itself to improve accuracy.

  6. This process repeats until the system reaches an acceptable level of performance.

This cycle is what enables AI systems to get better over time. The more data they see, and the more feedback they receive, the more accurate and refined their predictions become.

📉 Why Data Quality Matters

AI systems are only as good as the data they are trained on. If you feed an AI biased, outdated, or incomplete data, the results will reflect those flaws.

For example:

  • A facial recognition system trained mostly on light-skinned faces may perform poorly on darker skin tones.

  • A medical AI trained on male patient data might make inaccurate predictions for female patients.

  • An AI that recommends jobs might reflect past inequalities in hiring, perpetuating bias.

This is why data ethics is such a vital part of modern AI development. Engineers must think carefully about what data they use, how it's sourced, and whether it fairly represents all groups.

🧠 Types of Learning Algorithms

There are three main types of learning in AI, each using data differently:

  1. Supervised Learning – The algorithm learns from labelled data. For example, images labelled “cat” or “not cat”.

  2. Unsupervised Learning – The algorithm looks for patterns in unlabelled data, such as grouping similar customers based on their behaviour.

  3. Reinforcement Learning – The AI learns by trial and error, receiving rewards or penalties for its decisions, like teaching a robot to walk or a system to play chess.

Each method has strengths and weaknesses, and the choice depends on the problem being solved.

📦 The Bottom Line

Data and algorithms are the engine and fuel of AI. Data provides the context, and algorithms provide the logic. Together, they allow AI to learn, adapt, and make decisions — sometimes faster and more accurately than humans.

But without good data, even the smartest algorithm is useless. And without strong, ethical algorithms, even great data can be misused. Understanding both sides helps you build, evaluate, and use AI systems more responsibly.

✅ Quick Summary

  • Data is the input that trains AI — it can be text, numbers, images, or sound.

  • Algorithms are the processes that analyse the data and learn from it.

  • AI learns by processing large amounts of data, receiving feedback, and adjusting itself to improve.

  • Data quality and ethical sourcing are critical for responsible and accurate AI outcomes.

  • Different learning methods — supervised, unsupervised, and reinforcement — allow AI to tackle a wide range of challenges.

📝 Reflection Question

Can you think of a time when you interacted with an AI system — like a recommendation or search result — that felt wrong or off? What kind of data or algorithm issues might have caused it?