# Feature extraction

> Canonical: https://skillalmanac.com/glossary/feature-extraction | Last verified: 2026-11-25 | Index status: index-eligible

Feature extraction is an overloaded term in machine learning. It can mean turning raw data such as text or images into numerical features a model can use, or reusing intermediate representations from a pretrained model as input to another.

Also called: feature extraction machine learning, feature extraction deep learning, featurization, feature extractor.

## In plain language

Feature extraction means turning raw material into a list of measurements a learning system can work with. A photo is just a grid of colours, and an email is just text; before a model can learn from them, something has to describe them as numbers, such as word counts or edge patterns. A well-known limit is that the choice matters: if the numbers leave out what is important, the model cannot recover it later. The word is used in two ways, so check which one a writer means.

## Technical definition

The Google ML glossary calls feature extraction an overloaded term: it can mean retrieving intermediate feature representations from an unsupervised or pretrained model for use as input to another model, or it can be a synonym for feature engineering. Separately, the scikit-learn user guide defines it as converting arbitrary data such as text or images into numerical features, for example CountVectorizer producing a word-count matrix, and says it is very different from feature selection, which operates on features that already exist. IBM lists PCA, LDA, t-SNE and TF-IDF among extraction methods and says extraction reduces dimensionality or complexity.

## How it shows up when you use agents

Coding agents do not usually run feature extraction by themselves, but they write the code for it. Ask [Claude Code](/tools/claude-code) or Cursor for a text classifier and the script will likely vectorise text first, which is feature extraction in the scikit-learn sense. In retrieval work, an [embedding](/glossary/embedding) model can illustrate the Google glossary's first sense when representations from a pretrained model are used as input to another model; its second sense is a synonym for feature engineering.

What breaks when the term is misunderstood: you ask for "feature extraction" and the agent builds something different from what you meant, such as selecting columns instead of converting text. Say which meaning you want, name the input and the desired numerical form, and ask the agent to show a sample of the output before training anything.

For an inductive evaluation, fit learned preprocessing on training data only, including vocabulary and IDF statistics, then transform each validation or test example with the fitted mapping. Computing test features from their own inputs is legitimate; fitting corpus statistics on the test set is the leakage risk. See [Feature engineering](/glossary/feature-engineering) and [Dimensionality reduction](/glossary/dimensionality-reduction).

## Common confusions

- **Feature extraction versus feature selection.** scikit-learn says extraction transforms arbitrary data into numerical features, while selection is applied to features that already exist.
- **Feature extraction versus feature engineering.** The Google glossary says extraction can be a synonym for feature engineering, so context decides.
- **Hand-designed versus learned features.** TF-IDF has a specified formula but usually fits vocabulary and inverse-document-frequency statistics from a corpus. A pretrained network supplies representations learned during its training. Neither distinction means all feature mappings are fixed or reduce dimensionality.
- **Extraction versus information extraction.** Pulling dates out of a document is information extraction, a different task from building model inputs.
- **Myth.** That fewer features means a better model. Reducing dimensionality can discard information the task needs.

## Worked examples in this catalogue

### [data-analysis-eda](https://skillalmanac.com/skills/skill-almanac/data-analysis-eda)

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

What you see: The skill is a fixed exploratory-analysis procedure and CSV profiler that keeps findings descriptive, evidenced and caveated.

Why it exercises the concept: Looking at a dataset's columns is the step before deciding which features to build. The catalogue has no feature-extraction skill, so this is a contrast case, not a demonstration.

### [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: The skill checks train, validation and test files for duplicates, shared groups, time and label leakage and prints JSON.

Why it exercises the concept: Features computed with information from the test split cause leakage. The skill checks the split, not the features, so it is adjacent and does not extract anything.

### [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: The skill reads Hugging Face datasets through the Dataset Viewer API: metadata, rows, search and filters.

Why it exercises the concept: It lets you inspect raw data that would later be turned into features. It does not run extraction.

## Related terms

- [Feature engineering](https://skillalmanac.com/glossary/feature-engineering.md)
- [Dimensionality reduction](https://skillalmanac.com/glossary/dimensionality-reduction.md)
- [Principal component analysis (PCA)](https://skillalmanac.com/glossary/principal-component-analysis.md)
- [Embedding](https://skillalmanac.com/glossary/embedding.md)
- [Transfer learning](https://skillalmanac.com/glossary/transfer-learning.md)
- [Machine learning (ML)](https://skillalmanac.com/glossary/machine-learning.md)

## Sources

- [Feature extraction — scikit-learn user guide](https://scikit-learn.org/stable/modules/feature_extraction.html), scikit-learn (accessed 2026-11-24)
- [Machine Learning Glossary — feature extraction](https://developers.google.com/machine-learning/glossary#feature-extraction), Google for Developers (accessed 2026-11-24)
- [What is feature extraction?](https://www.ibm.com/think/topics/feature-extraction), IBM (accessed 2026-11-24)

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