Text classification is sorting pieces of text into set categories, such as spam or not spam, positive or negative, or which topic a message is about.
In plain words
A model reads a piece of text and picks one label, or several, from a fixed list. It learns from examples that people have already labelled. Two common kinds are topic classification, which asks what the text is about, and sentiment analysis, which asks what opinion it expresses. Some very large companies rely on it in real products.
A quick example
An email service runs every incoming message through a classifier trained on labelled emails. Messages it scores as spam go to the spam folder; the rest land in your inbox.
Where you'll meet it
- Spam filters and content moderation.
- Routing support tickets and tagging reviews by sentiment.
Related
Sources
- DocsText classification, Google Machine Learning Guides · read 29 Sept 2026
- DocsText classification, Hugging Face Transformers documentation · read 29 Sept 2026
Checked by WhatIsAI against the sources above · 29 Sept 2026. Spotted an error? Report it.