Furthermore, a cross-region dataset validation was
carried out to evaluate generalizability of the model.
The average accuracy rate of the hybrid model was
higher than 91% for the three diverse water basins
(urban, agricultural, and industrial), indicating its
capability to accommodate different environmental
status and contamination uncertainty. Its performance
was even shown to be durable to noise and missing
values, due to the robust pre-processing and feature
imputation methods.
In conclusion, the findings suggest that the hybrid
CNN-LSTM-XGBoost model, modified by the
explainable AI and real-time structure, outperforms
in predictive performance and operational
applicability. It does not only mitigate the drawbacks
of existing models, but also a scalable and intelligent
framework for preemptive water contamination
control is proposed. This renders it a useful
instrument for environmental authorities, policy
makers and smart city infrastructures in their attempts
to safeguard water quality and human health.
5 CONCLUSIONS
This study develops a new intelligent hybrid machine
learning model for online measurement of water
contamination level prediction and classification
based on diverse environmental and temporal
features. The model integrates the merits of CNN,
LSTM and XGBoost, and performs well not only in
high accuracy but also in robustness heterogeneity of
geographical and contamination situation.
Incorporating explainable AI technologies such as
SHAP ensure outputs are transparent and
interpretable, and fills an important gap within
current environmental decision support systems. In
addition, its capability to run in realtime, as well as
uncertainty quantification and stakeholder friendly
dashboard, make it a practical and scalable solution
for the contemporary water quality monitoring
problems. By effectively integrating deep learning,
classical ML, and domain-specific environmental
knowledge, this framework represents a major step
toward intelligent, responsive and reliable water
contamination management.
REFERENCES
Abba, S. I., et al. (2021). Comparative analysis of machine
learning algorithms for water quality prediction.
Environmental Science and Pollution Research, 28,
12345–12356.
Ahmed, M., et al. (2019). Prediction of water quality using
machine learning algorithms. Environmental
Monitoring and Assessment, 191(11), 1–12.
Aldhyani, T. H., et al. (2020). Water quality prediction
using machine learning algorithms. Environmental
Monitoring and Assessment, 192(3), 1–14.
Azrour, M., et al. (2021). Machine learning algorithms for
efficient water quality prediction. Modeling Earth
Systems and Environment, 8, 2793–2801.
Barzegar, R., et al. (2020). CNN model for predicting
dissolved oxygen in water bodies. Environmental
Monitoring and Assessment, 192(7), 1–12.
Elshewey, A. M., Youssef, R. Y., El-Bakry, H. M., &
Osman, A. M. (2025). Water potability classification
based on hybrid stacked model and feature selection.
Environmental Science and Pollution Research, 32,
7933–7949.
Fu, Y., et al. (2021). Temporal convolutional network for
long-term water quality prediction. Journal of
Hydrology, 593, 125–136.
Grbčić, L., et al. (2021). Coastal water quality prediction
based on machine learning with feature interpretation
and spatio-temporal analysis. arXiv preprint
arXiv:2107.03230.
Guo, H., Chen, Z., & Teo, F. Y. (2024). Intelligent water
quality prediction system with a hybrid CNN–LSTM
model. Water Practice & Technology, 19(11), 4538–
4555.
Haq, R. A., & Harigovindan, V. (2022). LSTM-based water
quality prediction system for aquaculture. Aquaculture
Engineering, 96, 102–110.
Khosravi, K., et al. (2025). Enhanced water quality
prediction model using advanced hybridized
resampling alternating tree-based and deep learning
algorithms. Environmental Science and Pollution
Research, 32, 6405–6424.
Khullar, S., & Singh, N. (2022). Bi-LSTM model for water
quality parameter forecasting of the Yamuna River.
Environmental Monitoring and Assessment, 194(1), 1–
12.
Kumar, N. A., & Vellaichamy, J. (2025). A deep learning
approach for water quality assessment: Leveraging
gated linear networks for contamination classification.
Ingénierie des Systèmes d’Information, 30(2), 349–
357.
Liu, Y., et al. (2020). Long short-term memory network for
water quality prediction in the Yangtze River Basin.
Water, 12(1), 1–15.
Najah, A., et al. (2021). Machine learning approaches for
water quality prediction: A review. Environmental
Science and Pollution Research, 28, 123–145.
Othman, M., et al. (2020). Water quality index prediction
using artificial neural networks. Environmental
Monitoring and Assessment, 192(5), 1–10.
Paneru, B., & Paneru, B. (2024). LLMs & XAI for water
sustainability: Seasonal water quality prediction with
LIME explainable AI and a RAG-based chatbot for
insights. arXiv preprint arXiv:2409.10898.
Shafi, J., Ijaz, R., Koul, A., & Ijaz, M. F. (2025). Data-
driven water quality prediction using hybrid machine