# Machine learning (ML)

> Canonical: https://skillalmanac.com/glossary/machine-learning | Last verified: 2026-11-24 | Index status: index-eligible

Machine learning is the subset of artificial intelligence focused on algorithms that learn the patterns of training data and then make inferences about new data without explicit, hard-coded instructions.

Also called: ML.

## In plain language

Machine learning is a way to train software, called a model, to make predictions or generate content using data. IBM contrasts it with rules-based AI using an email spam filter. A rules-based approach has a person devise the criteria for spam by hand. A learned spam filter instead fits a model to example emails. For a parameterized classifier, training can adjust model parameters to reduce prediction error.

## Technical definition

A trained model applies patterns it learned from training data to infer an output for a real-world task, and IBM calls deploying a model AI inference. Supervised learning uses labeled data to make predictions. Unsupervised learning identifies patterns in unlabeled data. Deep learning is the subset of machine learning driven by deep artificial neural networks.

## How it shows up when you use agents

Google's glossary defines inference in large language models as "the process of using a trained model to generate a response to an input prompt." See [AI model](/glossary/ai-model) for the trained model itself.

Agents are also used for machine learning work such as loading a dataset, splitting it and evaluating a model. Google's glossary says the examples in a dataset are traditionally divided into a training set, a validation set and a test set. For two learning setups, see [supervised learning](/glossary/supervised-learning) and [unsupervised learning](/glossary/unsupervised-learning).

## Common confusions

- **Machine learning versus AI.** Machine learning is a subset of [artificial intelligence](/glossary/artificial-intelligence). IBM puts it this way: all machine learning is AI, but not all AI is machine learning.
- **Algorithm versus model.** In IBM's spam example, machine learning requires selecting an algorithm and a dataset of sample emails, and the newly trained model has learned how to identify spam.
- **Learned versus rules-based.** IBM says rules-based AI requires a data scientist to manually devise the criteria for spam.
- **Machine learning versus deep learning.** Deep learning is a subset of machine learning. See [Deep learning](/glossary/deep-learning).

## Worked examples in this catalogue

### [split-leakage-check](https://skillalmanac.com/skills/skill-almanac/split-leakage-check)

Status: illustrative example from the item's own documentation, not executed for this page.

What you see: Checks train, validation and test files for duplicates, shared groups, time and label leakage; prints JSON.

Why it exercises the concept: Google's glossary says each example in a dataset should ideally belong to only one of the training, validation and test sets.

### [huggingface-datasets](https://skillalmanac.com/skills/huggingface/huggingface-datasets)

Status: illustrative example from the item's own documentation, not executed for this page.

What you see: Reads Hugging Face datasets through the Dataset Viewer API: metadata, rows, search and filters.

Why it exercises the concept: IBM's spam example trains a model on a dataset of sample emails.

## Related terms

- [Artificial intelligence (AI)](https://skillalmanac.com/glossary/artificial-intelligence.md)
- [Supervised learning](https://skillalmanac.com/glossary/supervised-learning.md)
- [Unsupervised learning](https://skillalmanac.com/glossary/unsupervised-learning.md)
- [Deep learning](https://skillalmanac.com/glossary/deep-learning.md)
- [Neural network](https://skillalmanac.com/glossary/neural-network.md)
- [AI model](https://skillalmanac.com/glossary/ai-model.md)
- [Data mining](https://skillalmanac.com/glossary/data-mining.md)

## Sources

- [Linear regression: Gradient descent](https://developers.google.com/machine-learning/crash-course/linear-regression/gradient-descent), Google for Developers (accessed 2026-11-24)
- [What is machine learning?](https://www.ibm.com/think/topics/machine-learning), IBM (accessed 2026-11-24)
- [Machine Learning Glossary](https://developers.google.com/machine-learning/glossary), Google for Developers (accessed 2026-11-24)
- [What is machine learning?](https://developers.google.com/machine-learning/intro-to-ml/what-is-ml), Google for Developers (accessed 2026-11-24)

Definitions are written by Skill Almanac from the sources above and checked against them on 2026-11-24. [Glossary index](https://skillalmanac.com/glossary.md).
