Abstract
We consider the problem of classification in a comparison-based setting: given a set of objects, we only have access to triplet comparisons of the form "object A is closer to object B than to object C." In this paper we introduce TripletBoost, a new method that can learn a classifier just from such triplet comparisons. The main idea is to aggregate the triplets information into weak classifiers, which can subsequently be boosted to a strong classifier. Our method has two main advantages: (i) it is applicable to data from any metric space, and (ii) it can deal with large scale problems using only passively obtained and noisy triplets. We derive theoretical generalization guarantees and a lower bound on the number of necessary triplets, and we empirically show that our method is both competitive with state of the art approaches and resistant to noise.
Introduction
In many real-world scenarios, explicit feature vectors or direct distance metrics are unavailable. Instead, data often comes in the form of ordinal comparisons, such as "Movie A is more similar to Movie B than to Movie C." Traditionally, utilizing such data requires ordinal embedding, a process that reconstructs a Euclidean representation of objects to satisfy these triplet constraints. However, embedding is computationally expensive—often requiring $O(n^3)$ triplets—and assumes a Euclidean structure that may not exist.
TripletBoost addresses this by asking: can we learn a classifier directly from these triplets without the intermediate embedding step? This approach is particularly valuable when triplets are obtained passively and contain noise, bypassing the need for expensive coordinate reconstruction.
The TripletBoost Algorithm
TripletBoost adapts the well-known AdaBoost framework to the comparison-based setting. The core innovation lies in the definition of Weak Triplet Classifiers.
A weak classifier selects two reference points, $x_j$ and $x_k$, and divides the space into two regions: points closer to $x_j$ and points closer to $x_k$. Because triplets are often sparse (passive collection), a weak classifier may "abstain" from making a prediction if no triplet exists to determine the relative distance of a point to the chosen references. The algorithm iteratively selects the most accurate weak classifiers and combines them into a strong ensemble, re-weighting examples to focus on those previously misclassified.
Theoretical and Empirical Evaluation
The authors provide a new theoretical lower bound, showing that $\Omega(n\sqrt{n})$ random triplets are sufficient to avoid a classifier that simply abstains—a much more optimistic requirement than the $O(n^3)$ needed for full embedding. Furthermore, TripletBoost is metric-agnostic, functioning in any unknown metric space.
Empirical evaluations on datasets like Iris, Moons, and MNIST demonstrate several key strengths:
- Scalability: TripletBoost successfully handled datasets with $10^4$ examples, whereas traditional ordinal embedding methods (like tSTE) became too slow to finish once datasets exceeded $10^3$ examples.
- Noise Tolerance: As an ensemble method, TripletBoost is highly resistant to noise. On the "Moons" dataset with 20% noise, it maintained high accuracy while "CompTree" (a comparison-tree baseline) saw a significant performance drop.
- Metric Independence: The algorithm's performance remains stable across various distance metrics (cityblock, cosine, Euclidean), confirming its versatility.
On the real-world 1m MovieLens dataset, TripletBoost predicted the correct genre as its top choice in ~83% of cases using only user-rating-derived triplets.
Conclusion
TripletBoost offers a direct, efficient path from ordinal comparisons to classification. By bypassing the embedding step, it achieves superior scalability and robustness to noise. Future work may further refine generalization bounds by accounting for specific metric space geometries, potentially reducing data requirements even further for simpler spaces.
Summary updated