Abstract
Ethanol stability is an important indicator for evaluating the quality and heat-processing suitability of raw milk. Traditional ethanol stability testing relies on destructive laboratory procedures, which are not suitable for large-scale industrial use. In contrast, parameters such as protein, fat, lactose and other basic compositional indicators are already measured routinely in dairy plants through sensor-based or spectroscopic systems. This provides the basis for developing a non-destructive soft sensing approach for ethanol stability. In this study, a soft sensing model was developed to predict ethanol stability from commonly monitored raw-milk intake indicators. An autoencoder was used to examine feature correlations and select variables with stronger relevance to ethanol stability. TabNet was then applied to build the classification model, and a TabDDPM-based data generation method was introduced to address class imbalance in the dataset. The proposed model was trained and tested using three years of industrial raw-milk intake data from a dairy company. It achieved an accuracy of 92.57% and a recall of 90.26% for identifying ethanol-unstable samples. These results demonstrate the model's strong potential for practical engineering applications in real-world dairy quality monitoring.