Coffee Bag Premium Classifier

Binary classifier predicting whether a retail coffee bag is premium (1) or standard (0) from its brand, origin, roast, grind, and packaging facts.

Source data

Trained on ssg1/coffee-bags-tabular, a classmate-built tabular dataset for 24-679 (Fall 2026), Carnegie Mellon University. is_premium is a fixed threshold on price-per-ounce; the price columns that define it are excluded from the feature set to avoid data leakage. Features: altitude_masl, weight_g, altitude_stated, brand, origin, processing, roast_level, grind.

Training

Selected via AutoGluon TabularPredictor AutoML search (presets="medium_quality", eval_metric="balanced_accuracy", 5-minute time budget, bagging/stacking disabled). Best model: LightGBM.

Test results (6 original bags)

Metric Value
Accuracy 0.667
Balanced accuracy 0.667
Precision (premium) 0.667
Recall (premium) 0.667
F1 (premium) 0.667

Intended use and limitations

Classroom exercise (24-679). 356 rows total, a small, non-random sample of retail coffee bags. Not validated for real purchasing decisions.

Load

import cloudpickle, huggingface_hub
path = huggingface_hub.hf_hub_download("CXu0630/2026-24679-coffee-premium-classifier", "autogluon_predictor.pkl")
predictor = cloudpickle.load(open(path, "rb"))
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Dataset used to train CXu0630/2026-24679-coffee-premium-classifier