Contents
We are working on the SVM hypothesis function, the decision rule used to make predictions after training. In the linear primal form, the canonical classifier is
where is the weight vector and is the intercept. In the kernelized dual form, the score is computed through support vectors and dual coefficients, and the prediction is still the sign of that score. This assumes binary labels, usually .
Deep Breakdown
The hypothesis function is the final predictive rule of a Support Vector Machine. After the optimization is solved, whether in primal or dual form, the model needs a way to classify a new input vector . For a linear SVM in primal form, the prediction rule is:
This means:
- compute the score ,
- if the score is positive, predict class ,
- if the score is negative, predict class .
So the classifier is based on which side of the separating hyperplane the point falls. The quantity
is often called the decision function or score function. The actual prediction is just its sign. For kernel SVMs, the same idea remains, but the score is written in dual form:
and then:
Here:
- are dual coefficients,
- are training points,
- are training labels,
- is the kernel function,
- only support vectors have nonzero or effectively nonzero .
Inputs:
- trained SVM parameters,
- a new feature vector .
Outputs:
- predicted class ,
- optionally the raw score .
Why it matters in DA/DS:
- it is the actual prediction rule used in production,
- it explains how margin-based training turns into classification decisions,
- it shows the difference between linear and kernel SVM prediction,
- it reveals the operational role of support vectors,
- it helps interpret confidence-like distance from the boundary.
This object links directly to:
- margin, because the sign comes from the side of the margin boundary,
- support vectors, because in the dual form only they matter,
- kernels, because the kernelized hypothesis replaces direct dot products,
- primal and dual formulations, because both produce the same classification logic.