Avian influenza virus (AIV) is one of the major pathogens affecting the health of laying hens, causing substantial economic losses worldwide. Early warning of AIV outbreaks can significantly reduce the occurrence and spread of the disease. Currently, machine learning-based models for predicting AIV outbreaks often overlook crucial management factors, including vaccination and disinfection practices, resulting in certain limitations in their predictive performance. In this study, data encompassing 4 categories and 17 subcategories were collected from 220 laying hen farms and subsequently partitioned into a train dataset and an independent test dataset. The train dataset was used for model development and hyperparameter optimization through stratified 5-fold cross-validation, while the independent test dataset was reserved exclusively for model evaluation. XGBoost, Support Vector Machine (SVM), Random Forest (RF), LightGBM, as well as Soft-voting and Hard-voting ensemble methods combining the four algorithms were employed for model training and testing. Among them, the LightGBM model achieved the best performance, with an accuracy of 84.62 %, a recall of 89.47 %, a precision of 80.95 %, and an F1-score of 85.00 % in predicting AIV outbreaks. Furthermore, to better interpret the influence of different parameters on model performance, this study conducted a Shapley additive explanation method (SHAP) on the LightGBM model, providing in-depth insights into the top 5 features contributing most significantly to the model and the bottom 3 features with the least impact. The methods proposed in this study provided new technological approaches and insights for avian influenza early warning, with SHAP being employed for the first time in this field. The primary LightGBM implementation ultimately used in this study has been made publicly available on GitHub (https://github.com/STBCKS/AIV-WARNING-CODE/blob/main/AIV.py).