Explainable artificial intelligence for groundwater quality prediction and hydrochemical interpretation
摘要
Over the past decades, groundwater quality has declined significantly due to rapid urbanization, excessive fertilizer usage, and climate-driven hydrogeochemical changes. Accurate prediction and interpretation of groundwater quality therefore require advanced data-driven approaches integrated with domain knowledge. This study proposes an interpretable hybrid artificial intelligence framework for groundwater quality prediction and analysis using explainable artificial intelligence (XAI) and advanced machine learning algorithms. A total of 135 groundwater samples were collected from Tamil Nadu, India and analysed for 16 physicochemical parameters. The dataset was pre-processed through data cleaning, feature scaling, and outlier detection. Several machine learning models, including XGBoost, Random Forest, LightGBM, and CatBoost, were optimized using Optuna-based hyperparameter tuning and integrated through a stacked ensemble framework. The meta-learner achieved the best predictive performance (R2 = 0.938, RMSE = 0.237, MAE = 0.184). Water Quality Index analysis identified ammonia (NH₃), iron (Fe), and chromium (Cr) as dominant contaminants. Model interpretability using SHAP, LIME, and permutation importance revealed the buffering role of hydrochemical ions such as HCO₃⁻ and Ca2⁺, while spatial AI mapping indicated localized industrial contamination. The proposed framework improves predictive reliability while providing interpretable insights to support sustainable groundwater management.