FA

5 min read

AI, machine learning and deep learning: what is the difference?

Deep learning is a kind of machine learning, and machine learning is one way of building artificial intelligence. Knowing the difference helps you choose the right tool.

An abstract rendering of fine threads branching and joining, like connections in a network.
Photo: Google DeepMind, Pexels

The three terms are often used as if they meant the same thing, and in the news they mostly do. In a project they do not. They name three nested circles: artificial intelligence is the widest, machine learning sits inside it, and deep learning sits inside machine learning. Knowing where a tool falls tells you what it needs (rules, data, or a great deal of data and computing power) and what it can and cannot be trusted with.

Artificial intelligence: the goal

Artificial intelligence is the broad field of making computers do tasks that we would call intelligent if a person did them: understanding language, recognising what is in a picture, planning a route, playing a game, making a decision from evidence.

The term says nothing about how the task is done. For decades much of AI was written by hand: experts turned their knowledge into rules ("if the temperature is above this and the pressure below that, raise an alarm"), and the program followed them. Such rule-based systems still run in many places, and for a narrow problem with clear rules they are often the right choice: they are predictable and easy to check.

Their limit shows when the rules are too many to write down. Nobody can list the rules for telling a cat from a dog in a photo, or for understanding every way a customer might ask about a late delivery.

Machine learning: learning from examples

Machine learning is the part of AI where the program is not given the rules but learns them from examples. You show it many cases with the right answer (past loan applications and whether they were repaid, emails marked as spam or not) and a learning algorithm adjusts a model until its answers match. The model can then answer new cases it has not seen.

There are three common ways to learn:

  • Supervised learning: every example has the right answer attached. Most business uses fall here: predicting demand, sorting documents, estimating a price.
  • Unsupervised learning: the examples have no answers, and the model looks for structure on its own, such as groups of similar customers or unusual transactions.
  • Reinforcement learning: the model acts, receives a reward or a penalty, and learns which actions lead to better results over time. It is used in games, in robot control and in parts of training language models.

Classic machine-learning methods (decision trees, linear models, gradient boosting) remain the strongest choice for many problems with tables of data: rows and columns, such as sales records or sensor readings. They train fast, need modest hardware and are easier to explain.

The quality of a machine-learning model depends on its data more than on anything else. Examples that are few, wrong, or unlike the real cases the model will meet give a model that is wrong in the same way.

Deep learning: many layers

Deep learning is the part of machine learning that uses neural networks with many layers. Each layer turns its input into a slightly more useful representation: in an image, the first layers respond to edges and colours, later ones to shapes, and the last ones to whole objects. "Deep" refers to this stack of layers, not to any deeper understanding.

The difference that matters in practice is that deep learning can work directly on raw data: pixels, sound waves, text. Older methods needed people to design the features first (the length of a sentence, the number of edges in an image). That is why deep learning drove the progress of the last fifteen years in:

It has a cost. Deep models usually need far more examples, and training them needs graphics processors (GPUs) or similar hardware. Their reasoning is also harder to inspect: a deep network can be accurate and still be hard to explain when it is wrong.

Where generative AI fits

Generative AI, the kind that writes text, draws images or produces speech, is not a fourth circle. It is a use of deep learning: models trained on very large amounts of text or images to produce new content of the same kind. Large language models are deep-learning models, trained with machine-learning methods, in pursuit of the old goal of artificial intelligence. All three terms apply to them at once.

Which one does a project need?

Choose by the problem, not by the newest term:

  • Clear rules, little room for error: a rule-based system, or ordinary software. If you can write the rules down, you often do not need learning at all.
  • A table of past records and a number or category to predict: classic machine learning is usually the place to start. It is cheaper, faster and easier to check than a deep model.
  • Images, sound or free text: deep learning, usually by adapting a model that has already been trained on similar data rather than training one from nothing.
  • Language tasks such as answering questions or drafting text: a language model, connected to your own documents when the answers must be about your organisation (we compared the ways to do this in fine-tuning or RAG?).

In every case, start with the data you actually have and a way to measure whether the result is right. A simple model that is measured honestly is worth more than an advanced one that nobody has tested on real cases.

Three common misunderstandings

  • "AI means a language model." Language models are one recent kind of AI. Most AI in factories, banks and logistics is still classic machine learning or rules.
  • "More data always fixes it." More data helps only if it is correct and looks like the cases the model will face. Repeating the same errors at a larger scale does not.
  • "A deep network understands." It finds patterns that were useful in its training data. When a case falls outside those patterns, it can be confidently wrong.

If you are deciding which of these approaches fits a problem in your organisation, contact us to discuss it.

TopicsAIMachine learningDeep learning