## 4 Discussion  
This study demonstrates that Vis-NIR spectroscopy, when integrated with a tailored data analysis pipeline, can effectively detect cumulative mechanical damage in prunes. Although the employed methods--CWT preprocessing, UVE-based feature selection, and SVM classification--are individually established, their combination was optimized to capture the progressive, nonlinear spectral changes induced by repeated low-energy impacts. Compared with alternative preprocessing-modeling configurations, the CWT-UVE-SVM pipeline achieved the best classification performance, underscoring the value of method alignment with the biological characteristics of bruise evolution. Among all classifier-preprocessing combinations, CWT consistently enhanced the model performance across metrics. Its multiscale decomposition capabilities enable the retention of both global shape and localized variations in spectral curves, which is especially effective in capturing subtle spectral distortions caused by internal tissue disruption [45]. UVE further contributed by extracting stable and physiologically relevant wavelengths--particularly in the 600-900 nm region--known to reflect water content, pigment changes, and tissue integrity [46]. The spectral bands selected by UVE align  
Figure 5: Confusion matrix of the CWT-UVE-SVM model for four-level classification of cumulative damage in prunes. well with biological signatures of cellular breakdown and water redistribution during damage accumulation. SVM performed best under the reduced feature space created by UVE, likely due to its ability to generalize in high-dimensional, small-sample scenarios. While ensemble methods like RF and XGBoost showed slightly better performance in the initial preprocessing-modeling comparisons (Table 1), SVM ultimately outperformed them after UVE-based variable selection. This outcome may be attributed to its ability to construct stable decision boundaries when irrelevant features are removed [47]. Although less interpretable than ensemble models, SVM remains a robust option under constrained data conditions. Ensemble methods, on the other hand, remain highly competitive in broader contexts and may benefit from further tuning in future work. In addition to prioritizing model interpretability and deployment feasibility, our study adopted a standardized modeling pipeline using default or empirically chosen hyperparameters, which helps minimize overfitting and model selection bias under small-sample conditions. This trade-off supports reproducibility but may limit performance optimization. Future work could explore automated hyperparameter tuning strategies to further enhance the classifier accuracy. Furthermore, while this study focused on three commonly used classification models (SVM, RF, and XGBoost) to represent diverse algorithmic families, future studies could benefit from evaluating additional interpretable and lightweight classifiers such as decision trees. These models offer advantages in terms of transparency and deployment efficiency, especially in resource-constrained or real-time applications. Notably, the observed similarity across accuracy, precision, recall, and F1-score stemmed from the combination of a balanced dataset (with equal sample sizes for each class) and the use of macro-averaged evaluation metrics. Since the classifier performed consistently across the four damage levels--intact, mild, moderate, and severe--the resulting metrics naturally converged to similar values. This consistency suggests model stability rather than evaluation bias. To enhance operational feasibility, spectral measurements were conducted at the equator of the prune, balancing spectral consistency and industrial adaptability. This acquisition zone is compatible with operations by commercial fruit sorting systems, which rarely support full-surface scanning. Thus, the proposed detection protocol aligns with real-world constraints and favors scalability in postharvest applications [48]. However, several challenges must be addressed for its industrial implementation.