Evaluation of the physicochemical content and solid-state fermentation stage of Zhenjiang aromatic vinegar using near-infrared spectroscopy

Abstract As one of the most famous traditional Chinese vinegars, the grains physicochemical content of Zhenjiang aromatic vinegar during solid-state fermentation (SSF) reflects the growth status of microorganisms and the quality of fermentation products. In addition, the time for grain-turning has a significant effect on the quality of fermentation products. In this study, a new evaluation method combined near-infrared (NIR) spectroscopy with partial least squares regression (PLSR) was proposed to predict the physicochemical content of grains and the fermentation stage. The performance of the PLSR models for the total acid and the nonvolatile acid were RMSEP = 0.0371, R p 2 = 0.9760, and RMSEP = 0.0216, R p 2 = 0.9646, respectively. The accuracy ratio of SSF stage judgment was 100%. Experimental results indicate that the proposed method can be used to guide on-site grain-turning and improve the quality of fermentation products.


Introduction
Zhenjiang aromatic vinegar has a long history, and it is a typical example of the solid-state fermentation (SSF) process [1]. It is inoculated by the mash method, rendering Zhenjiang aromatic vinegar its reputation for being "sour but not astringent; fragrant and slightly sweet; strong and fresh; the longer the time, the more fragrant" [2,3]. Therefore, Zhenjiang aromatic vinegar has been favored by consumers worldwide. The main raw materials used for producing Zhenjiang aromatic vinegar are high-quality glutinous rice and bran, which they are brewed through the multi-bacterial mixed fermentation process known as SSF [4]. Zhenjiang aromatic vinegar has won the reputation of "National Intangible Cultural Heritage" [5].
SSF is one of the most important procedures in the production of Zhenjiang aromatic vinegar. The quality of SSF directly affects the yield and quality of the vinegar. In the process of SSF, alcohol is gradually converted into acetic acid via various microorganisms, mainly acetic acid bacteria [6]. This process is accompanied by the formation of various metabolites, such as organic acids, amino acids, and a variety of volatile substances that, to varying degrees, alter the alcohol content, acidity, and water content of the fermented vinegar during various SSF stages [7]. In addition, the operation process varies during different fermentation stages [8,9]. In actual production, to further explore the SSF process, optimize fermentation conditions, and improve fermentation efficiency, the fermentation process was divided into different stages [1]. According to the traditional fermentation process, the SSF is divided into two stages. In the first stage, the raw materials in the fermentation tank are inoculated (the seed is the grains on the seventh day of fermentation), and the grain is turned layer by layer, so the physicochemical content of the vinegar is different at different depths. In the second stage, the vinegar in the fermentation tank is completely turned over. At this time, the physicochemical content tends to be consistent [1,10]. Currently, the detection method in the SSF process is mainly based on manual experience, which cannot obtain real-time information of production conditions. The judgment of the stage of the SSF process is subjective and is easily affected by factors such as seasons and weather, which are not sufficiently, stable [11]. Therefore, the stage judgment model based on NIR spectroscopy used in this study can aid in forming a stable and accurate judgment on the stage of SSF; this could optimize the grain turning process and improve the quality and yield of Zhenjiang aromatic vinegar. Furthermore, it only takes 1 min to collect a spectrum data and it is easy to embed the NIR spectrometer into a mobile temperature measurement platform to realize real-time monitoring of the fermentation status.
Near-infrared (NIR) spectroscopy, as a nondestructive analysis method, has been widely used in various detection fields such as the petrochemical industry [12], medicine [13,14], and agriculture [15][16][17]. Jiang et al. [18] built a model using stable synergy interval partial least squares (SiPLS) and NIR to detect the moisture content and pH value during SSF of wheat straw. Based on NIR spectroscopy data, Sutrisno et al. [19] established a PLS model to predict caffeine content. Teófilo et al. [20] used the ordered predictor's selection (OPS) method to estimate the lignin content in different parts of sugarcane genotypes by using NIR spectroscopy data; Nascimento et al.
[21] developed PLS models using NIR spectroscopy for the determination of soluble solids content (SSC) and the firmness of intact low chilling 'Aurora-1' peach fruit. Suhandy et al. [22] developed a discriminant analysis of the partial least squares (PLS-DA) method to distinguish between coffee types using NIR.
To predict the current fermentation stage and the physicochemical content of vinegar (total acid and nonvolatile acid), PLSR models based on NIR are proposed in this study. First, the collected NIR spectral data were preprocessed to reduce unnecessary information. PLSR models based on the preprocessed NIR spectral data were then established to predict the fermentation stage and the physiochemical content of the vinegar grain. The contribution of this study is the development of a rapid nonde-structive monitoring platform based on NIR spectral data to guide the SSF process.

Materials
Test location: 350 samples (175 samples from the upper layer, 175 samples from the bottom layer) were collected from the Vinegar Making plant, Zhenjiang Hengshun Co., Ltd., Jiangsu Province, China. NIR data and the physicochemical content of the vinegar were collected for three fermentation cycles: September 18-October 6, October 10-27, and October 31-November 17, 2019. Sampling was performed every day before the grain turning. During the sampling period, two depth points were selected, and sampling was performed from top to bottom (at 30 and 80 cm). The samples (200 g per sample) were quickly placed into the sampling bag, then the physicochemical content was determined and an NIR spectrum sample was prepared. The production site and collected samples are shown in Figure 1.

NIR scanning
According to the spectrometer operation process, it is checked by black and white board when the machine is started every day. In order to avoid human error and reduce the measured noise, the NIR spectral absorbance of the vinegar sample was measured 10 times, and the average value was used as the final data for further analysis.

Measurement of physicochemical content
After collecting the spectral data, 50 g of the vinegar distillate sample was weighed out. Thereafter, 200 mL of distilled water was added, and the solution was allowed to rest for 30 min. Next, it was stirred for 5 min with a stirrer. Then, a filter with three layers of gauze was used to collect the filtrate.
The total acid was detected according to the method of GB/T5009.41-2003 [23]: 1 mL of the filtrate was pipetted into a 100 mL beaker, and 100 mL of distilled water was added. Then, the electrode was inserted, a magnetic stir bar was added, and the beaker was placed on the magnetic stirrer. Finally, the operator started spinning the magnet, used the automatic potentiometric titrator to perform acid-base neutralization titration until a pH of 8.20 was reached, and recorded the volume of the standard titration solution consumed by sodium hydroxide. It was measured three times in parallel, and the average value was taken. The acid content was determined using Eq. (1): x is the total acid content in the sample (calculated as acetic acid); v 1 is the volume of NaOH standard titrant consumed in the determination of the sample dilution; v 2 is the volume of NaOH standard titrant consumed in the determination of the reagent blank; 0.06 is the mass of acetic acid equivalent to 1.00 mL sodium hydroxide standard solution [c (NaOH) = 0.10 mol/L], and v is the sample volume.
Nonvolatile acid was detected according to the method of GB18187-2000 [24]. The operator pipetted 2 mL of filtrate, added 8 mL of water, and put it in a single-boiling distillation device. When the distillate of purified water reached 180 mL, heating was stopped and the residual liquid was poured into the distillation beaker. The operator added water to obtain a total volume of 120 mL, inserted the electrode, added a stir bar, and placed the beaker on a magnetic stirrer. Then the operator started spinning the magnet and used an automatic potentiometric titrator for acid-base neutralization titration until a pH of 8.20 was reached. The consumption of hydrogen was recorded. The volume of the sodium standard titration solution was measured three times in parallel, and the average value was obtained. The nonvolatile acid content was determined using Eq. (2): x is the content of nonvolatile acid in the sample (calculated as lactic acid); v 1 is the volume of the standard titration solution of NaOH consumed in the determination of sample dilution, v 2 is the NaOH consumed in the determination of the blank, the volume of the standard titrant, and 0.09 is the mass of lactic acid equivalent to 1.00 mL of sodium hydroxide standard solution [c (NaOH) = 0.10 mol/L].

Spectral analysis and prediction model
2.5.1 Spectral data preprocessing: The original spectra contain distracting information, such as redundancy, irrelevant information, and noise. Before establishing the NIR quantitative model, some preprocessing methods were used to reduce unnecessary information. Standard normal variate transformation (SNV) was used to reduce the effects of particle size unevenness and nonspecific scattering on the particle surface. The NIR spectra also reflect the changes in the physicochemical contents during the SSF of vinegar. In this study, a marine optical NIRQuest512 NIR spectrometer was used to collect spectral absorbance in the range of 900-1700 nm. The original and preprocessed spectral data are shown in Figure 2. The optimal number of latent variables (LVs) of the PLSR models was determined by the cumulative contribution [25][26][27].

PLSR model:
The NIR spectral data were used as the input, and the physicochemical data and the vinegar fermentation stage were used as outputs to establish a PLS model. The general underlying model of PLS is S ∈ R n×m is the estimated feature matrix from preprocessed NIR, Y ∈ R n×p is the response matrix, T ∈ R n×l and U ∈ R n×l are the projections of S and Y, respectively; P ∈ R m×l and Q ∈ R p×l are the orthogonal loading matrices; E and F are residuals. Assume that T and U satisfy U TB B ∈ R l×l is the parameter matrix. Assuming S p ∈ R np×m is the predictive feature matrixY p ∈ R np×p is the actual response matrix, and the predictive response matrix. Y p ∈ R np×p can be expressed as Two criteria are used to assess the performance of the developed model, namely, the root mean square error (RMSE), correlation coefficients (R 2 ) and RPD. The criteria were calculated as follows: y i ∈ Y p is the ith actual value, y i ∈ Y p is the ith predictive value, y is the mean value of the actual value, and n p is the number of validation sets.
3 Results and discussion

Measurement of physicochemical content
The changes in the physicochemical content during the fermentation cycle are shown in Figure 3. In the first stage (1-8 days), the total acid in the upper layer is higher than the total acid in the bottom layer. In the second stage (9-18 days), the total acid in the bottom layer is higher than that in the upper layer ( Figure 3 (A)). The nonvolatile acid in the upper layer is slightly higher than that in the bottom layer during the first stage. In the second stage, the acidity of the nonvolatile acid in the bottom layer and the upper layer is relatively close (Figure 3 (B)).

Prediction of the physicochemical content
In the past decades, the physicochemical and hyperspectral detection are the main monitoring methods for SSF of vinegar. However, both physicochemical detection and hyperspectral detection were too complicated to be suitable for the production site of vinegar factories. Three hundred and 50 samples obtained in the experiment were randomly divided into the calibration set (244 samples, 70%) and the validation set (106 samples, 30%). R 2 and RMSE were used to evaluate the performance of the PLS.
Based on the different depths at the time of sample collection, the whole data was divided into two subsets, bottom layer and upper layer, each with 175 samples. The NIR spectrum was set as an input variable after preprocessing by SNV, and the physicochemical content was set as the response variable. The results are shown in Table 1.
As shown in Table 1, the accuracy of the prediction model for total acid and nonvolatile acid is relatively high, and the optimal number of latent variables (LVs) for the bottom and upper layers is 19 and 18, respectively. As a result, the performance of PLSR models for the total acid and the nonvolatile acid in the bottom layer and upper layer is shown in Figure 4 and Table 2. It is clear the PLS model using NIR spectral data accurately predicts physicochemical content.
The performance among the proposed method, LS-SVM and BP-ANN based on the NIR data was shown in Table 3. In the comparison, the Monte Carlo method with 100 times was implemented. Compared with LS-SVM and BP-ANN, the proposed method achieved best results.

Prediction for the fermentation stage
At different fermentation stages of SSF, the grain-turning operation of the machine varies, which has a great influence on the final quality of the vinegar. Therefore, it is important to predict the current fermentation stage of vinegar to guide grain-turning operations and improve the quality of the vinegar. In this study, 175 samples at the bottom layer were selected and divided into a training set and a prediction set at a ratio of 7:3. The diversion stage was used as the output; spectral data were used as the input, and the PLS model was established. The accuracy rate was used to evaluate the correction of the PLS models where N c and N are the number of correctly distinguished samples and the total number of samples in the analysis set, respectively. According to the accumulated contribution, the final number of LVs is 13. The accuracy ratio of stage prediction is P = 100%.

Physicochemical content prediction and grain-turning guidance
To guide the actual grain turning and improve the vinegar quality during the entire SSF process, a portable detection system was designed and shown in Figure 5. Loading the portable spectrometer on the moving temperature measurement platform can be used to determine the stage of SSF online. Temperature also has a great influence on the health of microorganisms in the vinegar mash. Zhenjiang aromatic vinegar has different temperature thresholds in different stages of the SSF, and the SSF is divided into two stages. When the temperature exceeds the threshold, the microorganisms will be killed; the temperature is below the threshold, which is not conducive to the growth and reproduction of microorganisms. Temperature monitoring is combined with the fermentation stage judgment, which is easy to find problems in time and implement corresponding adjustments. In the first stage, the vinegar temperature may reach 45°C, while, in the second stage, the temperature will stabilize between 38 and 42°C. The main purpose of grain turning is as follows: (1) The alcohol fermentation product in the bottom layer is fully mixed with the vinegar in the upper layer to expand the cultivation of microorganisms, such as acetic acid bacteria. (2) The temperature is reduced, and oxygen is added to ensure the acetic acid activity of microorganisms, such as bacteria. We were able to predict the physicochemical content based on the spectral data collected by the portable spectrometer on the mobile platform; then we determined the current stage of the vinegar, and used the real-time temperature measured by the mobile platform to determine whether diversion was required.

Conclusions
The PLSR models based on NIR spectroscopy of 900-1700 nm were established to predict the physicochemical content and the fermentation stage of SSF. The results show that the PLS models provide accurate and reliable results. The performance of the PLSR models for the total acid was RMSEP = 0.0402, R p 2 = 0.9902 (bottom layer), and RMSEP = 0.034, R p 2 = 0.9618 (upper layer). The performance of the PLSR models for the nonvolatile acid was RMSEP = 0.0286, R p 2 = 0.9556 (bottom layer), and RMSEP = 0.0147, R p 2 = 0.9736 (upper layer). In addition, the accuracy ratio of stage prediction was 100%. The proposed prediction platform realizes the prediction of the physicochemical content of vinegar and online guidance of the action of grain turning. The current detection method is single-point manual random sampling, while the NIR spectroscopy was used to realize multi-point real-time  The proposed method provides judgment basis and theoretical support for workers' operations.