White spirit aging year prediction and key flavor substance identification method and device

By constructing a neural network-based liquor aging year recognition model and SHAP algorithm, the subjectivity problem of the aging year of traditional liquor is solved, the accurate classification of liquor aging years and the identification of key flavor substances are achieved, and the consistency and automation of the identification are improved.

CN120280042APending Publication Date: 2025-07-08WULIANGYE
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510365505.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-26
Publication Date
2025-07-08

AI Technical Summary

Technical Problem

The age of traditional liquor relies on artificial evaluation, which is highly subjective, and it is difficult to achieve standardized and precise judgment, and it is difficult to identify key flavor substances that affect the flavor of aged wine.

Method used

Based on the flavour substance data of liquor, an aging year identification model was constructed, and neural network models such as MLP, LSTM, RNN, CNN, GRU, Transformer were trained for training. The contribution of flavor substances to aging years was analyzed in combination with the SHAP algorithm to identify key flavor substances.

Benefits of technology

The accurate and efficient classification of the aged years of liquor was achieved, the consistency and automation of the identification results were improved, the key flavor substances that significantly affected the identification results of the aged years were identified, the trust of the model was enhanced, and technical support was provided for the identification of the aged years and quality control of the aged years.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120280042A_ABST
    Figure CN120280042A_ABST
Patent Text Reader

Abstract

The invention mainly relates to the technical field of wine brewing, and provides a method and a device for predicting the aging years of white spirit and identifying key flavor substances in the white spirit in order to identify the aging years of the white spirit through the flavor substances in the white spirit, which have the core idea that the method comprises the following steps: acquiring flavor substance data and aging year data of a white spirit sample; constructing a flavor substance-aging year data set; establishing an aging year identification model, and training the aging year identification model based on the established flavor substance-aging year data set; embedding a flavor substance characteristic contribution module for analyzing the contribution degree of flavor substances to white spirit aging year recognition into the trained aging year recognition model; and the aging year identification model embedded with the flavor substance characteristic contribution module outputs the aging year type of the white spirit sample to be detected and the key flavor substance with high aging year identification contribution degree based on the flavor substance data of the white spirit sample to be detected.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of brewing, and in particular relates to a method and device for predicting the aging years of Baijiu and identifying key flavor substances. Background Art

[0002] As a traditional alcoholic beverage, the flavor and quality of Baijiu are affected by various factors. Among them, the aging years are one of the important factors determining the flavor and quality of Baijiu. The main reason is that a series of complex physical and chemical changes occur during the aging process, which will significantly affect the aroma, taste, flavor components, and overall quality of Baijiu. The traditional judgment of the aging years of Baijiu usually relies on manual tasting, and the evaluator judges the aging time of the wine through sensory experience. However, this method has a large subjectivity and is affected by the differences in the experience of the evaluators, making it difficult to achieve standardized and accurate judgment.

[0003] The flavor in Baijiu is complex and is formed by the combined action of various chemical substances. During the aging process, a series of esterification, oxidation-reduction reactions occur in the compounds in Baijiu, and these esterification, oxidation-reduction reactions make important contributions to the aging flavor of Baijiu. Therefore, identifying the key flavor substances that affect the aging flavor is of great significance for improving the quality of Baijiu. Summary of the Invention

[0004] The technical problem to be solved by the present invention is: to provide a method and device for predicting the aging years of Baijiu and identifying key flavor substances, aiming to judge the aging years of Baijiu based on the flavor substances in Baijiu.

[0005] The technical solution adopted by the present invention to solve the above technical problems is:

[0006] On the one hand, the present invention provides a method for predicting the aging years of Baijiu and identifying key flavor substances, and the method includes:

[0007] Step 1: Obtain the flavor substance data and aging year data of Baijiu samples, and construct a flavor substance-aging year data set;

[0008] Step 2: Establish an aging year recognition model, use the flavor substances as the input of the aging year recognition model, and the aging year as the output of the aging year recognition model, and train the aging year recognition model based on the constructed flavor substance-aging year data set;

[0009] Step 3: Embed a flavor substance feature contribution module for analyzing the contribution degree of flavor substances to the aging year recognition of Baijiu into the trained aging year recognition model;

[0010] Step 4: The aging year recognition model after embedding the flavor substance feature contribution module outputs the aging year of the to-be-detected baijiu sample and the key flavor substances with high contribution degrees to the aging year recognition based on the flavor substance data of the to-be-detected baijiu sample.

[0011] Further, the flavor substances include ethyl formate, ethyl acetate, ethyl propionate, ethyl butyrate, ethyl valerate, ethyl caproate, ethyl lactate, furfural, and isoamyl alcohol.

[0012] Further, in Step 1, preprocessing of the established flavor substance-aging year data set is also included, and the preprocessing includes data standardization: normalizing the flavor substance data in the flavor substance-aging year data set to eliminate the influence of different flavor substance orders of magnitude.

[0013] Further, in Step 2, an aging year prediction model is established based on one or more models among MLP, LSTM, RNN, CNN, GRU, and Transformer models.

[0014] Further, the flavor substance feature contribution module analyzes the contribution degrees of flavor substances to the aging year recognition of baijiu based on the SHAP algorithm, specifically including:

[0015] Calculating the SHAP value of each flavor substance for the aging year recognition result of baijiu;

[0016] Evaluating the contribution degree of each flavor substance to the aging year recognition result of baijiu according to the calculated SHAP value;

[0017] Sorting the contribution degrees of all flavor substances, and selecting the flavor substances with contribution degrees higher than the set value as the key flavor substances.

[0018] Further, the training of the established aging year recognition model in Step 2 includes: dividing the established flavor substance-aging year data set into a training set and a test set, training the aging year recognition model using the training set, evaluating the training effect of the aging year recognition model using the test set, and when the accuracy rate of the aging year recognition model on the test set is greater than the preset accuracy threshold, the training of the aging year recognition model is completed.

[0019] Further, during the training process of the aging year recognition model in Step 2, the cross-entropy loss function is used to evaluate the difference between the prediction result of the aging year recognition model and the probability distribution of the true label, and its expression is:

[0020]

[0021] In the formula, M is the number of baijiu samples; C is the number of aging years; p ijis the true aging year label of the i-th Baijiu sample corresponding to the j-th aging year; is the probability that the i-th Baijiu sample is predicted to be of aging year j.

[0022] On the other hand, the present invention also provides a device for predicting the aging year of Baijiu and identifying key flavor substances, and the device includes:

[0023] A dataset acquisition module: used to acquire the flavor substance data and aging year data of Baijiu samples, and construct a flavor substance - aging year dataset;

[0024] A model training module: constructs an aging year recognition model, and trains the established aging year model based on the constructed flavor substance - aging year dataset;

[0025] A flavor substance feature contribution module: used to analyze the contribution degree of flavor substances to the recognition result of the aging year of Baijiu;

[0026] A key flavor substance recognition module: based on the trained aging year recognition model, inputs the flavor substances of the Baijiu sample to be measured into the aging year recognition model, and obtains the recognition result of the aging year of Baijiu and the key flavor substances with a high contribution degree to the recognition result of the aging year of Baijiu.

[0027] The beneficial effects of the present invention are as follows: The method and device for predicting the aging year of Baijiu and identifying key flavor substances according to the present invention establish an aging year recognition model for identifying the aging year of Baijiu based on the flavor substances of Baijiu by means of a neural network model, realizing accurate and efficient classification of the aging year of Baijiu, and improving the consistency and automation degree of the recognition result of the aging year of Baijiu. A flavor substance feature contribution module is embedded in the established aging year recognition model, and while identifying the aging year of Baijiu, the key flavor substances that have a significant impact on the recognition result of the aging year of Baijiu are also identified, explaining the recognition result of the aging year of Baijiu, thereby enhancing the trust in the aging year recognition model and providing technical support for the identification and quality control of the aging year of Baijiu. Description of the Drawings

[0028] Figure 1 is a schematic diagram of the method for predicting the aging year of Baijiu and identifying key flavor substances according to the present invention;

[0029] Figure 2 is a schematic diagram of the changes in the loss function and accuracy during the training process of the aging year recognition model of Baijiu in the embodiment;

[0030] Figure 3 is a schematic diagram of the confusion matrix of the aging year recognition result in the embodiment;

[0031] Figure 4 is a schematic diagram of the mean value ranking of SHAP values of flavor substances corresponding to a certain aging year in the embodiment;

[0032] Figure 5 Schematic diagram of the device for predicting the aging years of Chinese liquor and identifying key flavor substances in the present invention. Detailed implementation manners

[0033] As Figure 1 shown, the method for predicting the aging years of Chinese liquor and identifying key flavor substances according to the present invention includes the following steps:

[0034] Step 1: Obtain the flavor substance data and aging year data of the Chinese liquor sample, and construct a flavor substance - aging year data set.

[0035] The flavor substances in the flavor substance - aging year data set constructed in the present invention may include any compounds that affect the flavor of Chinese liquor, and the data of the flavor substances are represented by the concentrations of the flavor substances.

[0036] As Figure 4 shown, in this embodiment, the flavor substances in the flavor substance - aging year data set include 26 compounds such as ethyl formate, ethyl acetate, ethyl propionate, ethyl butyrate, ethyl valerate, ethyl caproate, ethyl lactate, furfural, and isoamyl alcohol, and the aging year data includes six aging years of 0 year, 1 year, 3 years, 5 years, 8 years, and 10 years.

[0037] Perform pre - processing on the established flavor substance - aging year data set, specifically including:

[0038] Data augmentation: Perform data augmentation on the concentrations of the flavor substances in the training set of the flavor substance - aging year data set in the form of small - range data fluctuations;

[0039] Data standardization: Perform normalization processing on the flavor substance data to eliminate the influence of different compound magnitudes.

[0040] In this embodiment, the sklearn.preprocessing.StandardScaler function is used to define the standardization method, and the flavor substance data features are standardized to a distribution with a mean of 0 and a standard deviation of 1. In order to ensure that the same standardization parameters can be used during model training and application, in this embodiment, the pickle.dump function is used to save the flavor substance standardization parameters as a pkl - format file for convenient subsequent reading.

[0041] Step 2: Establish an aging year identification model, use the flavor substances as the input of the aging year identification model, and the aging years as the output of the aging year identification model, and train the aging year identification model based on the constructed flavor substance - aging year data set.

[0042] The aging year recognition model is established based on one or more of the basic neural network structures such as MLP, LSTM, RNN, CNN, GRU, and Transformer.

[0043] In this embodiment, an aging year recognition model is built using an MLP network based on the PyTorch library. Specifically:

[0044] class MLPModel(nn.Module):

[0045] def __init__(self, input_dim, output_dim):

[0046] super(MLPModel, self).__init__()

[0047] self.fc1 = nn.Linear(input_dim, 128)

[0048] self.fc2 = nn.Linear(128, 64)

[0049] self.fc3 = nn.Linear(64, output_dim)

[0050] self.relu = nn.ReLU()

[0051] def forward(self, x):

[0052] x = self.relu(self.fc1(x))

[0053] x = self.relu(self.fc2(x))

[0054] x = self.fc3(x)

[0055] return x

[0056] In this embodiment, since 26 flavor substances are considered in the constructed flavor substance - aging year dataset, the input dimension input_size = 26, and the other hyperparameters are: num_classes = 6.

[0057] The established flavor substance - aging year dataset is divided into a training set and a test set. The training set is used to train the aging year recognition model, and the test set is used to evaluate the training effect of the aging year recognition model. When the accuracy of the aging year recognition model on the test set is greater than the preset accuracy threshold, the training of the aging year recognition model is completed.

[0058] During the training process of the aging year recognition model, based on the torch.nn.CrossEntropyLoss function, the cross-entropy loss function is called to measure the difference between the predicted result of the aging year and the probability distribution of the true label. Its expression is:

[0059]

[0060] In the formula, M is the number of liquor samples; C is the number of aging years; p ij is the true aging year label of the i-th liquor sample corresponding to the j-th aging year; is the probability that the i-th liquor sample is predicted as aging year j.

[0061] In this embodiment, during the training process, the change of the loss function value of the training set and the accuracy of the test set is as Figure 2 shown. This embodiment can achieve 100% accuracy in aging year classification for all test set data. The confusion matrix of the classification result is as Figure 3 shown.

[0062] Step 3: Embed a flavor substance feature contribution module for analyzing the contribution degree of flavor substances to the recognition of the aging year of liquor into the trained aging year recognition model.

[0063] The flavor substance feature contribution module analyzes the contribution degree of flavor substances to the recognition of the aging year of liquor based on the SHAP algorithm, specifically including:

[0064] Calculate the SHAP value of each flavor substance to the recognition result of the aging year of liquor;

[0065] According to the calculated SHAP value, evaluate the contribution degree of each flavor substance to the recognition result of the aging year of liquor;

[0066] Sort the contribution degrees of all flavor substances, and select the flavor substances with contribution degrees higher than the set value as key flavor substances;

[0067] The SHAP algorithm is:

[0068]

[0069] In the formula, φ j is the SHAP value of flavor substance data j; N is the set of all flavor substances; S is the flavor substance subset; v(S) is the output value of the model when only including the flavor substance subset S; |S| is the size of the flavor substance subset S; |N| is the total number of flavor substances.

[0070] In this embodiment, after the model training is completed, the SHAP values corresponding to the flavor substances are calculated for all the test set data. Taking the aging year of 10 years as an example, the mean ranking chart of the SHAP values of the flavor substances is as Figure 4 shown. It can be seen that among the flavor substances, compounds 24, 25, 4, 11, and 18 are the five flavor substances with the highest SHAP value contributions, and they play a positive promoting role in the aging year classification.

[0071] Step 4: The aging year recognition model after training identifies the aging year of the to-be-detected white liquor sample and the key flavor substances with high contribution degrees to the aging year prediction based on the flavor substances of the to-be-detected white liquor sample.

[0072] The present invention also provides a device for predicting the aging year of white liquor and identifying key flavor substances, as Figure 5 shown. The device includes:

[0073] A dataset acquisition module: used to acquire the flavor substance data and aging year data of the white liquor sample, and construct a flavor substance - aging year dataset;

[0074] A model training module: constructs an aging year recognition model, and trains the established aging year model based on the constructed flavor substance - aging year dataset;

[0075] A flavor substance feature contribution module: used to analyze the contribution degree of the flavor substances to the recognition result of the aging year of the white liquor;

[0076] A key flavor substance recognition module: based on the trained aging year recognition model, inputs the flavor substances of the to-be-detected white liquor sample into the aging year recognition model to obtain the recognition result of the aging year of the white liquor and the key flavor substances with high contribution degrees to the recognition result of the aging year of the white liquor.

Claims

1. Method for predicting aging years of Chinese liquor and identifying key flavor substances, characterized in that, The method includes: Step 1: Obtain the flavor substance data and aging year data of the baijiu sample, and construct a flavor substance-aging year dataset; Step 2: Establish an aging year recognition model, use the flavor substances as the input of the aging year recognition model, and the aging year as the output of the aging year recognition model, and train the aging year recognition model based on the constructed flavor substance-aging year dataset; Step 3: Embed a flavor substance feature contribution module for analyzing the contribution degree of flavor substances to the recognition of the aging year of baijiu into the trained aging year recognition model; Step 4: The aging year recognition model after embedding the flavor substance feature contribution module outputs the aging year of the baijiu sample to be measured and the key flavor substances with a high contribution degree to the recognition of the aging year based on the flavor substance data of the baijiu sample to be measured.

2. The method for predicting the aging years of Chinese liquor and identifying key flavor substances according to claim 1, wherein The flavor substances include ethyl formate, ethyl acetate, ethyl propionate, ethyl butyrate, ethyl valerate, ethyl caproate, ethyl lactate, furfural, and isoamyl alcohol.

3. The method for predicting the aging years of Baijiu and identifying key flavor substances according to claim 1, characterized in that Step 1 also includes preprocessing the established flavor substance-aging year dataset, and the preprocessing includes data standardization: normalizing the flavor substance data in the flavor substance-aging year dataset to eliminate the influence of the quantity levels of different flavor substances.

4. The method for predicting the aging years of Chinese liquor and identifying key flavor substances according to claim 1, characterized in that In Step 2, an aging year prediction model is established based on one or more of the MLP, LSTM, RNN, CNN, GRU, and Transformer models.

5. The method for predicting the aging years of Chinese liquor and identifying key flavor substances according to claim 1, characterized in that The flavor substance feature contribution module analyzes the contribution degree of flavor substances to the recognition of the aging year of baijiu based on the SHAP algorithm, specifically including: Calculating the SHAP value of each flavor substance for the recognition result of the aging year of baijiu; Evaluating the contribution degree of each flavor substance to the recognition result of the aging year of baijiu according to the calculated SHAP value; Sorting the contribution degrees of all flavor substances, and selecting the flavor substances with a contribution degree higher than the set value as the key flavor substances.

6. The method for predicting the aging years of liquor and identifying key flavor substances according to claim 1, wherein The training of the established aging year recognition model in Step 2 includes: dividing the established flavor substance-aging year dataset into a training set and a test set, using the training set to train the aging year recognition model, using the test set to evaluate the training effect of the aging year recognition model, and when the accuracy rate of the aging year recognition model on the test set is greater than the preset accuracy rate threshold, the training of the aging year recognition model is completed.

7. The method for predicting the aging years of Chinese liquor and identifying key flavor substances according to claim 1, wherein During the training process of the aging year recognition model in Step 2, the cross-entropy loss function is used to evaluate the difference between the prediction result of the aging year recognition model and the probability distribution of the true label, and its expression is: Where M is the number of baijiu samples; C is the number of aging years; p ij is the true aging year label of the i-th baijiu sample corresponding to the j-th aging year; is the probability that the i-th baijiu sample is predicted to be the aging year j.

8. An apparatus for predicting the aging years of liquor and identifying key flavor substances, which is used to implement the method for predicting the aging years of liquor and identifying key flavor substances according to any one of claims 1-7, and is characterized in that, The device includes: A dataset acquisition module: used to obtain the flavor substance data and aging year data of the baijiu sample, and construct a flavor substance-aging year dataset; A model training module: constructs an aging year recognition model, and trains the established aging year model based on the constructed flavor substance-aging year dataset; A flavor substance feature contribution module, used to analyze the contribution degree of flavor substances to the recognition result of the aging year of baijiu; Key flavor substance identification module: Based on the trained aging year identification model, input the flavor substances of the liquor sample to be tested into the aging year identification model to obtain the aging year identification result of the liquor and the key flavor substances with a high contribution degree to the aging year identification result of the liquor.

Citation Information

Cited By

  • Method for detecting and analyzing content of liquid flavor substances in beverage

    CN121364222A