← all concepts

Classifier

A model that assigns one or more labels to an input — the fundamental pattern behind query intent models, spam detectors, sentiment models, and content detection.

Listen

In the world of machine learning, a classifier is a model trained to assign labels to input data. It is the most common task in the field. When you give a classifier a search query, it can determine the intent. Give it a block of text, and it can analyze the sentiment.

Classifiers come in several different types. Binary classifiers choose between two labels, while multi-class models choose one label from three or more options. Multi-label classifiers can assign several labels at once, recognizing that a search query might be both informational and local. Finally, token classifiers label individual words or characters within a sequence rather than the entire text.

Modern text classifiers are built by fine-tuning pre-trained transformer encoders. Developers add a classification head, which is usually a single linear layer, on top of the encoder. The entire model is then trained on labeled examples. During this training, the encoder learns to create representations that make the classification head's job easy, while the head learns where to draw the decision boundaries.

A typical portfolio of these models includes specialized tools trained for single, specific tasks. These include models that detect query intent, identify AI-generated content, spot link spam, analyze sentiment, and determine whether a search query requires grounded, highly factual results.

What a classifier is

A classifier is a model trained to assign a label — or set of labels — to an input. Given a search query, it outputs an intent category. Given a block of text, it outputs a sentiment score. Given a web page, it outputs whether links on it are organic or paid. Classification is the most common task in applied machine learning, and most of DEJAN's production models are classifiers of one form or another.

Types of classifiers

Binary classifiers output one of two labels. Multi-class classifiers output one label from a set of three or more. Multi-label classifiers can assign several labels simultaneously — a query might be both informational and local, for example. Token classifiers assign a label to each individual token in a sequence rather than to the whole input; LinkBERT and LinkjeBERT work this way, labelling each token as O (not a link position) or LINK.

How classifiers are built

Modern text classifiers are almost always built by fine-tuning a pre-trained transformer encoder. A classification head — typically a single linear layer — is added on top of the encoder's output representation, and the whole model is trained on labelled examples. The encoder learns to produce representations that make the classification head's job easy; the head learns the decision boundary.

DEJAN classifiers

DEJAN's classifier portfolio covers query intent (ALBERT-based, 8 labels), query well-formedness (ALBERT-based, binary), AI content detection (DeBERTa-v3, binary), link spam detection (binary), sentiment (7-point multi-label), and the grounding classifier (DeBERTa-based, binary: deserves grounding vs. does not). Each is a specialist — trained on one task, deployed for that task only.

Related concepts

Concept