Abstract:Grains, as the cornerstone of the global food supply, require quality inspection that is crucial for ensuring food safety and improving production efficiency. Traditional laboratory methods, while accurate, are time-consuming and costly, making them unsuitable for online, real-time monitoring. Near-infrared (NIR) spectroscopy, with its advantages of rapid, non-destructive, and multi-component simultaneous detection, has been widely applied in grain quality inspection. However, the high dimensionality, complexity of NIR spectral data, and variations among different instruments, environments, and samples pose challenges to modeling methods and model transfer. This review summarizes the application of NIR spectroscopy in online grain quality inspection, systematically outlining the development from traditional linear modeling (e.g., partial least squares regression), nonlinear modeling (e.g., support vector machines, artificial neural networks) to deep learning methods (e.g., convolutional neural networks). It focuses on the strategies, challenges, and latest advances of model transfer techniques in addressing issues such as instrument differences, environmental changes, and sample diversity, including calibration transfer with and without standards. Furthermore, this review summarizes the challenges, experiences, and future research directions in practical industrial applications, aiming to provide references for the widespread application of NIR technology in the grain industry.