Spectra pre-processing consists of removing unwanted variations and artefacts that hinder relevant information in the raw NIR spectra . Selecting the appropriate pre-processing strategy is crucial to enhance the predictive power of the chemometric model; however, this procedure may be timeconsuming and subjective . We therefore adopted a supervised pre-processing selection strategy based on exhaustive search , similar to that proposed by Gerretzen et al. . This strategy enables testing selected pre-processing techniques suitable for NIRS in combination with selected predictive estimators. We employed similar pre-processing techniques for regression and classification, including baseline correction, multiplicative scatter correction, smoothing, and variable scaling. Details on the selected techniques are provided in the Supplemental Information (Table -S4). We selected the optimal pre-processing techniques in cross-validation by minimizing the root mean squared error (𝑅𝑅𝑅𝑅𝑅𝑅𝑅𝑅) in regression and maximizing the weighted balanced accuracy (𝑤𝑤𝑤𝑤𝑤𝑤𝑤𝑤𝑤𝑤) in classification. We evaluated the model predictive ability on the test set considering 𝑅𝑅𝑅𝑅𝑅𝑅𝑅𝑅 for regression, and balanced accuracy (𝑤𝑤𝑤𝑤𝑤𝑤𝑤𝑤) for classification. We here report a short description of these metrics, referring the reader to the Supplemental Information for a more detailed explanation.