In this study, we introduce a new spectroscopy analysis instrument, along with applied research based on the near-infrared spectroscopy (NIRS) of the major components of milk. Firstly, we analyzed and compared the characteristics of existing near-infrared spectrometers. Then, according to the major component spectra of milk, the spectral range, spectral resolution, and other parameters of the analysis instrument were determined, followed by the construction of a spectroscopy-analysis instrument based on acousto-optic tunable filters (AOTFs). Secondly, on the basis of application requirements, we obtained spectral information from a variety of test samples. Finally, qualitative and quantitative testing of the major components of the milk samples was carried out via typical analysis methods and a mathematical model of NIRS. Thus, this study provides a technical reference for the development of spectroscopy instruments and their applied research.