Intellectual model for generating adaptive WEB selectors based on GNN

Authors

  • O.S. Morozov Vinnytsia National Technical University
  • A.A. Yarovyi Vinnytsia National Technical University

DOI:

https://doi.org/10.31649/1681-7893-2025-50-2-142-149

Keywords:

software, information technology, intelligent systems, automated testing, graph neural networks (GNN)

Abstract

The article discusses the problem of DOM selector instability, which is one of the key reasons for flaky tests in modern automated web resource testing systems. It is shown that traditional approaches to selector formation, both manual and automated, do not take into account the global context of the DOM structure and are ineffective in the case of dynamic interface changes. The feasibility of using graph neural networks (GNN) as a tool for modelling the DOM tree in the form of a directed graph, taking into account the semantic, attributive, and structural features of nodes, is justified.

A theoretical model for building adaptive DOM selectors, combining GNN with a decision-making agent, is proposed. A mathematical representation of the DOM graph, a system of node features (one-hot tag encoding, binary attributes id/class/data-testid, depth, number of descendants, position among neighbours) has been developed, and selector evaluation metrics have been formalised: uniqueness, accuracy, completeness, F1-measure and length. An agent reward function has been formed that optimises the balance between accuracy, stability, and compactness of the selector.

It has been shown that the combination of DOM (Document object model) graph representations and a decision optimisation mechanism allows the creation of selectors that are resistant to structural changes in web pages and reduces the need for manual test maintenance. The proposed model forms the theoretical basis for the creation of intelligent automated testing systems capable of adapting locators during DOM changes without the need for a complete analysis of the interface by the tester.

Author Biographies

O.S. Morozov, Vinnytsia National Technical University

аспірант кафедри комп’ютерних наук

A.A. Yarovyi, Vinnytsia National Technical University

доктор технічних наук, професор, завідувач кафедри комп’ютерних наук

References

Lawson, R. Web Scrapping with Python; Packt Publishing: Birmingham, UK, 2015

K. Parikh, D. Singh, D. Yadav, and M. Rathod, “Detection of web scraping using machine learning,” Open access international journal of Science and Engineering, pp. 114–118, 2018.

Kipf, T. N. & Welling, M. Semi-supervised classification with graph convolutional networks. International Conference on Learning Representations (2017). DOI:

https://doi.org/10.48550/arXiv.1609.02907.

Veličković, P. et al. Graph attention networks. International Conference on Learning Representations (ICLR, 2017). DOI: https://doi.org/10.48550/arXiv.1710.10903.

Jianan Zhao, Xiao Wang, Chuan Shi, Binbin Hu, Guojie Song, and Yanfang Ye. 2021. Heterogeneous graph structure learning for graph neural networks. In Proceedings of the AAAI Conference on Artificial Intelligence. 4697–4705. DOI: https://doi.org/10.1609/aaai.v35i5.16600.

Zheng Y, Liu Y, Xie X, et al. Automatic web testing using curiosity-driven reinforcement learning. In: Proceedings of the 43rd International Conference on Software Engineering, 2021. 423–435. DOI: https://doi.org/10.48550/arXiv.2103.06018.

Vu Nguyen, Thanh To, and Gia-Han Diep. 2021. Generating and selecting resilient and maintainable locators for Web automated testing. Software Testing, Verification and Reliability 31, 3 (2021), e1760. DOI: https://doi.org/10.1002/stvr.1760.

Nguyen, L. M., Hui, S. C., & Fong, C. A. (2013). Large-scale multiobjective static test generation for web-based testing with integer programming. IEEE Transactions on Learning Technologies, (1), 46–59. DOI: https://doi.org/10.1109/TLT.2012.22.

M. T. Taky, Automated Testing With Cypress. PhD thesis, 2021.

Sanjay Dutta, What is One-hot Encoding in Machine Learning? A Comperehesive Guide with examples. Medium. Режим доступу https://medium.com/@sanjay_dutta/what-is-one-hot-encoding-in-machine-learning-a-comprehensive-guide-with-examples-090f037a6bbe

B. Yeoh and H. Wang, “Grown+ up: A “graph representation of a webpage ” network utilizing pre-training,” in Proceedings of the 31st ACM International Conference on Information & Knowledge Management, pp. 2372–2382, 2022. DOI: https://doi.org/10.1145/3511808.3557340.

Sheng Jia, Jamie Kiros, Jimmy Ba, “DOM-Q-NET: Grounded RL on Structured Language”. International Conference on Learning Representations (2017). DOI:

https://doi.org/10.48550/arXiv.1902.07257

Y. Lan, Y. Lu, Z. Li, M. Pan, W. Yang, T. Zhang, and X. Li, “Deeply reinforcing android gui testing with deep reinforcement learning,” in Proceedings of the 46th IEEE/ACM International Conference on Software Engineering, 2024, pp. 1–13. DOI: https://doi.org/10.1145/3597503.3623344

Ali Hassaan Mughal. 2025. An Autonomous RL Agent Methodology for Dynamic Web UI Testing in a BDD Framework. DOI: https://doi.org/10.48550/arXiv.2503.08464

Downloads

Abstract views: 0

Published

2026-01-12

How to Cite

[1]
O. Morozov and A. Yarovyi, “Intellectual model for generating adaptive WEB selectors based on GNN”, Опт-ел. інф-енерг. техн., vol. 50, no. 2, pp. 142–149, Jan. 2026.

Issue

Section

Systems Of Technical Vision And Artificial Intelligence, Image Processing And Pattern Recognition

Metrics

Downloads

Download data is not yet available.