1. An ML engineer is configuring an Automated ML job in Azure Machine Learning to predict customer churn. The dataset is highly imbalanced, with only 3% positive (churned) labels. The engineer wants Automated ML to automatically try techniques to address class imbalance and to optimize for the minority class. Which two configuration settings should the engineer apply to the AutoML classification job? (Select TWO)
- A. Set the primary_metric to 'AUC_weighted' or 'average_precision_score_weighted' instead of 'accuracy'✓ Correct
- B. Enable featurization with the mode set to 'auto' so that Automated ML can apply SMOTE oversampling and class-weight balancing✓ Correct
- C. Set enable_class_balancing=True in the AutoML classification task settings
- D. Set the n_cross_validations parameter to 1 to reduce training time and allow more iterations
- E. Set blocked_models to exclude LogisticRegression, because it cannot handle imbalanced datasets
Explanation
Using a weighted or macro-averaged metric such as AUC_weighted or average_precision_score_weighted ensures that Automated ML's model selection is driven by performance on the minority class, rather than being dominated by the majority class as with raw accuracy. This is the recommended primary metric change for imbalanced classification. Setting featurization mode to 'auto' enables Automated ML's automatic featurization pipeline, which includes class imbalance detection and mitigation techniques such as oversampling (SMOTE) and class-weight adjustments. There is no enable_class_balancing parameter in the Azure Machine Learning Automated ML SDK v2 API; this is a distractor reflecting a plausible but non-existent setting. Setting n_cross_validations to 1 effectively disables cross-validation, which would produce unreliable performance estimates especially on an imbalanced dataset, and is counterproductive. LogisticRegression supports class_weight='balanced' natively and is one of the models that handles imbalance reasonably well; blocking it would reduce the model search space without benefit.