Assessing avocado ripeness accurately is essential for post-harvest management and quality control. This study uses Near-infrared (NIR) spectroscopy and machine learning to classify avocados as Raw or Harvestable. To improve existing categorization methods, a non-invasive, cost-effective, and efficient solution is needed. Chiang Mai's Royal Project Gardens yielded 120 kg of Buccaneer avocados. An affordable NIR sensor collected spectral data at 18 wavelengths. Multiplicative Scatter Correction (MSC) and outlier elimination improved spectral quality. Outlier reduction and MSC improved spectral quality. Spectral characteristics enabled a Random Forest model to classify 99 % with an area under the curve (AUC) of 0.99. This study introduces a reliable, automated ripeness classification system to improve agricultural precision. Next, the AI model will be optimized for mobile edge devices to make it more accessible to small farmers.