Facebook pixel tracking

The Science and Information (SAI) Organization publishes open-access peer-reviewed journals in computer science and artificial intelligence.

Contact Info
Website thesai.org
Follow Us
Contact Info
Follow Us
Research Article | Open Access |

XPathia: A Deep Learning Approach for Translating Natural Language into XPath Queries for Non-Technical Users

Author 1: Karam Ahkouk Author 2: Mustapha Machkour
International Journal of Advanced Computer Science and Applications (IJACSA) · Vol. 16, No. 6 · Published 2025

DOI: 10.14569/IJACSA.2025.01606102

Abstract

XPath is a widely used language for navigating and extracting data from XML documents due to its simple syntax and powerful querying capabilities. However, non-technical users often struggle to retrieve the needed information from XML files, as they lack knowledge of XML structures and query languages like XPath. To address this challenge, we propose XPathia, a novel deep learning-based model that automatically translates natural language questions into corresponding XPath queries. Our approach employs supervised learning on an annotated XML dataset to learn accurate mappings between natural language and structured XPath expressions. We evaluate XPathia using two standard metrics: Component Matching (CM) and Exact Matching (EM). Experimental results demonstrate that XPathia achieves a state-of-the-art performance with an accuracy of 25.85% on the test set.

Keywords

How to Cite this Article

Ahkouk, K., & Machkour, M. (2025). XPathia: A Deep Learning Approach for Translating Natural Language into XPath Queries for Non-Technical Users. International Journal of Advanced Computer Science and Applications, 16(6). https://doi.org/10.14569/IJACSA.2025.01606102

Ahkouk, Karam, and Mustapha Machkour. "XPathia: A Deep Learning Approach for Translating Natural Language into XPath Queries for Non-Technical Users." International Journal of Advanced Computer Science and Applications, vol. 16, no. 6, 2025, https://doi.org/10.14569/IJACSA.2025.01606102.

@article{Ahkouk2025,
  title     = {XPathia: A Deep Learning Approach for Translating Natural Language into XPath Queries for Non-Technical Users},
  journal   = {International Journal of Advanced Computer Science and Applications},
  volume    = {16},
  number    = {6},
  year      = {2025},
  publisher = {The Science and Information Organization},
  author    = {Karam Ahkouk and Mustapha Machkour},
  doi       = {10.14569/IJACSA.2025.01606102},
  url       = {https://doi.org/10.14569/IJACSA.2025.01606102}
}

Open Access — licensed under a Creative Commons Attribution 4.0 International License. Unrestricted use, distribution, and reproduction in any medium, even commercially, as long as the original work is properly cited.

Call for Papers - Important Dates

Volume 17 No. 12, December 2026
Paper Submission Due November 25, 2026
Review Notification December 15, 2026
Publication Date December 31, 2026