Introduction to Machine Learning


Introduction to Machine Learning

Hope
Today we’re climbing machine learning in five levels, from “What does a computer learn?” to the hard questions about how these systems affect society. The basic idea is that computers can learn patterns from data—sometimes from far more examples than a person could examine—and use those patterns to make guesses about new things.

Corey
So the computer isn’t being handed a rule for every possible case. It sees examples, learns patterns from them, and then tries to apply those patterns to something it hasn’t seen before.

Hope
Exactly. Imagine teaching a computer to tell cats from dogs. A child might notice that dogs and cats have different bodies, ears, or ways of standing. But if you show the computer one picture, it won’t suddenly know what all cats and dogs look like. It needs many examples.

Corey
And it can still get things wrong. A picture of a jackal might look dog-like, and the computer could guess “dog”—which is not a ridiculous guess, since a jackal is a kind of dog. The important point is that machine learning produces predictions, not guaranteed answers.

Hope
A person can also question the categories. If someone asks, “Is this a cat or a dog?” and the picture shows a human, a child can say, “Neither—it’s a person.” That kind of response is a reminder that the question itself can be too narrow.

Corey
Practice matters, too. Think about a school test: if the review gives you practice with the kinds of problems on the test, you have a chance to learn how to solve them. A machine also needs examples to practice on before it can make predictions about new examples.

Hope
But there’s a big difference in scale. A person may learn a useful pattern from just one or two examples, while a machine-learning system may need tens of thousands or even millions to become very good at recognizing cats and dogs. On the other hand, a person can’t quickly look through ten million pictures, while a machine can process huge collections of data.

Corey
That makes machine learning a powerful tool, including for people who want to use math and coding skills to build things. But the tool is only as useful as the examples and task we give it.

Hope
Level two: where do we encounter it? One familiar example is a music recommendation. If you listen to an artist such as Melanie Martinez, a service might suggest another song because it has some quality in common with the music you like.

Corey
A person might describe that quality as a creepy vibe, or notice a filtered, deep voice. Those impressions can be easy for us to recognize but difficult to spell out precisely for a computer. We could tell a system to look at things like pitch, pacing, or tone; with many examples, it may also learn patterns we didn’t explicitly tell it to look for.

Hope
Recommendations are one kind of prediction. Advertising is another. Companies may use data about people’s behavior and circumstances to predict what ads might interest them. That can feel uncanny, but it doesn’t mean the system is literally reading someone’s mind.

Corey
Right. People can be predictable in aggregate: we often do ordinary things such as eat meals and go to familiar places. A company can use information already collected about people to make predictions from those patterns. That makes it important to think about what data is being collected and how it’s used.

Hope
An algorithm is a set of steps or a process for completing something. Machine-learning systems use algorithms to find patterns and make predictions, but they’re not good at everything people are good at.

Corey
A machine can analyze enormous volumes of material—for example, videos posted to TikTok—and help make recommendations at a scale people couldn’t manage by watching every video. People, meanwhile, can often learn from only a few examples and use good judgment in ways that are hard to reduce to a prediction.

Hope
People can also imagine a future they want, even if it doesn’t exist yet. A machine is good at predicting from what it has seen in the past, but that doesn’t make it a creative inventor or give it human judgment. Deciding where we want to go remains our responsibility.

Corey
Level three: the methods. Suppose Gmail needs to sort a new email into a category, such as spam or not spam. A person might look at keywords, whether the sender and recipient exchanged messages before, and what happened to those messages in the past.

Hope
Those clues are called features: details that may help distinguish one category from another. Feature engineering is the work of deciding which details might be useful. For instance, if someone who doesn’t speak Russian suddenly receives lots of email in Russian, language could be a useful clue—but a person would have to think of it.

Corey
In supervised learning, we have labeled examples, and the system tries to learn which features indicate one label rather than another. A classic classification task might use examples already labeled “spam” or “not spam.” One practical approach is sometimes called the kitchen-sink approach: try many features you can think of and see what works.

Hope
Unsupervised learning is different because we don’t necessarily have labels. Instead, we’re trying to discover structure in the data—for example, groups or clusters of similar points. The math involves deciding what “similar” means, including how to think about distance between points.

Corey
So supervised learning starts with labels and learns how to predict them; unsupervised learning starts without those labels and tries to find patterns or structure. Those are different goals, so the methods don’t simply differ by name.

Hope
Reinforcement learning is another approach. You can picture a system facing a decision, choosing an action, and learning through many trials which actions help it reach a goal. The idea has been used for tasks such as teaching a robot to navigate a room.

Corey
If the robot bumps into a chair or falls into a pit, that’s a setback; by exploring and trying again, it can eventually learn a route to the goal. A Roomba is an everyday reminder of a robot navigating a physical space, though the key reinforcement-learning idea is learning through choices and trials.

Hope
Deep learning uses neural networks and very large amounts of data. A system can iterate on a network structure until it makes useful predictions. It can be powerful, but choosing a method depends on the task and the data—not on the assumption that the newest or most complicated approach is always best.

Corey
For example, deep learning may make sense when you have enough high-quality data, preferably labeled usefully, and you can accept that the system may be difficult to interpret—or are prepared to do additional work to understand it. Some problems can be solved with simpler tools such as linear regression or other statistical approaches; others are much harder.

Hope
Choosing poorly can leave you with a system that’s technically impressive but practically useless. One telecom company built a deep-learning system that accurately predicted which customers might leave. But people didn’t know why a particular customer was predicted to quit, so they didn’t know what action might help.

Corey
The solution wasn’t necessarily to discard the accurate prediction. It was to build an interpretable system on top of it and do more work to understand the reasons. That example shows why accuracy alone may not be enough: people may need an explanation to make a prediction useful.

Hope
Level four: machine learning for language. Researchers might use it to study persuasion in online text—trying to detect the intent behind a persuasive message, who it targets, or what makes the technique effective. One choice is whether to use deep learning to extract features automatically or more traditional tools, such as lexicons or template matching.

Corey
Which approach is better can depend on the use case. A system that works automatically may suit one task, while another task may need fine-grained control and interpretability. That tension matters when a model learns from large amounts of online language.

Hope
A language model trained on internet text can reflect patterns in that text, including uncomfortable, inappropriate, or biased language. One way to explore possible bias is to compare prompts such as “the woman was” and “the man was,” then look at words that commonly follow each phrase.

Corey
But that kind of comparison is only a qualitative way to investigate. It doesn’t guarantee how a model will behave in any particular instance. System creators should be honest about what they’ve observed so people can judge whether the risk is acceptable for their own use case.

Hope
There’s also a creative side to newer language systems. They can generate long, grammatical passages. The interesting question is how to combine that capability with the human ability to give words meaning and provide structure.

Corey
That points to a broader question: as machine-learning tools have become easier to use, is that entirely a good thing? Tools can now make in a few lines of code what once took far more complicated, messy code, and more people can experiment and build with them.

Hope
That accessibility is exciting, but getting a system into the world is not just a matter of writing the model. Data may be unavailable, low quality, or unrepresentative. You also have to think about transparency, whether people will adopt the system, and how data was collected and will be used.

Corey
And when a system automates decisions based on real-world data, existing biases and problems can be magnified. That means we need to understand why the data looks the way it does, what its limitations are, and how the whole process should be documented—not just whether the model runs.

Hope
Machine learning is being used differently across industries. Some areas, such as actuarial science and operations research, may use it less than people expect; other areas, such as fintech and adtech, may use it extensively. A strong appetite for data can mean that more and more is collected, but collecting data doesn’t automatically solve a problem.

Corey
Some applications, including agriculture, may have promising stories but still face obstacles to becoming economically viable. Resources often flow toward problems with high financial value or toward topics that are fashionable to publish on. In areas where the value of collecting data is less obvious, that data collection may be delayed—and the delay can reinforce itself.

Hope
There’s also a concern that academic work can drift away from real-world use. If students work with standard datasets without asking what a model is for or how the data was collected, they can miss the conditions that determine whether a system will work responsibly outside the classroom.

Corey
So even as programming skills remain useful, the bigger picture matters: who will use the system, what explanations they need, what biases may be present, and what fairness should mean in that setting. Those questions are part of the machine-learning work, not an optional afterthought.

Hope
And there’s reason to be optimistic. Machine learning has the potential to reduce harm, give us useful information, and help people make better decisions. But using that potential well requires us to face the challenges and be clearer about what fairness means.

Corey
The five levels lead to one practical lesson: learn the tools, but also ask what the system is predicting, what examples it learned from, whether its predictions can be understood, and who could be affected. Machine learning can have an impact in many fields, and our choices shape whether that impact serves the right purposes.

Ask anything
We've read this whole study set, so questions about it get the best answers.