Abundant amounts of solid waste are produced due to the processing of various agricultural goods, such as garbage incineration. This agricultural waste management strategy causes a significant increase in air pollution and environmental deterioration. Several methods are widely applied to treat agricultural waste; the pyrolysis process, which includes burning biomass feedstocks without oxygen, is one of the most recommended. Pyrolysis of agricultural waste can produce biochar, bio-oil, and syngas. Pyrolysis is a complicated procedure that depends on feedstock characteristics such as feed composition (i.e., carbon, hydrogen, and oxygen elemental composition), fixed carbon, and volatile matter. Investigation of the individual property of the feedstock on the overall product yield by experimental or computational study is laborious and time-consuming. Therefore, the machine learning technique is applied in this paper to develop a robust and accurate model to predict the agricultural waste bio-oil yield. A total of 387 data points are gathered from various literature sources. This paper utilizes the proximate analysis, ultimat analysis of the agricultural feedstock, and pyrolysis reaction conditions as input features. Eight different machine-learning algorithms, i.e. adaptive boosting, artificial neural network, categorical boosting, decision tree with bagging, k nearest neighbor, light gradient boosting, random forest, and extreme gradient boosting are deployed for this objective. In addition, a SHAP analysis with a bar plot and a beeswarm plot is built to identify the input variables that had the greatest impact on bio-oil production. The categorical boost model gave the lowest root mean squared error of 2.65 out of all the models and had the greatest R2 value of 93.2% on the testing dataset. The SHAP analysis of the developed model for identifying the feature importance and the beeswarm plot is also performed, which shows that for the pyrolysis of agricultural waste, the hydrogen content is one of the most crucial parameters for the maximization of bio-oil yield.