Refining Text2Cypher on Small Language Model with Reinforcement Learning Leveraging Semantic Information

  • Tran, Quoc-Bao-Huy
  • Waheed, Aagha Abdul
  • Mudasir, Syed
  • Chung, Sun-Tae
Citations

WEB OF SCIENCE

0
Citations

SCOPUS

0

초록

Text2Cypher is a text-to-text task that converts natural language questions into Cypher queries. Recent research by Neo4j on Text2Cypher demonstrates that fine-tuning a baseline language model (a pretrained and instruction-tuned generative model) using a comprehensive Text2Cypher dataset can effectively enhance query generation performance. However, the improvement is still insufficient for effectively learning the syntax and semantics of complex natural texts, particularly when applied to unseen Cypher schema structures across diverse domains during training. To address this challenge, we propose a novel refinement training method based on baseline language models, employing reinforcement learning with Group Relative Policy Optimization (GRPO). This method leverages extracted semantic information, such as key-value properties and triple relationships from input texts during the training process. Experimental results of the proposed refinement training method applied to a small-scale baseline language model (SLM) like Qwen2.5-3B-Instruct demonstrate that it achieves competitive execution accuracy scores on unseen schemas across various domains. Furthermore, the proposed method significantly outperforms most baseline LMs with larger parameter sizes in terms of Google-BLEU and execution accuracy scores over Neo4j's comprehensive Text2Cypher dataset, with the exception of colossal LLMs such as GPT4o, GPT4o-mini, and Gemini.

키워드

Text2Cypherreinforcement learningsmall language modelfine-tuning
제목
Refining Text2Cypher on Small Language Model with Reinforcement Learning Leveraging Semantic Information
저자
Tran, Quoc-Bao-HuyWaheed, Aagha AbdulMudasir, SyedChung, Sun-Tae
DOI
10.3390/app15158206
발행일
2025-07
유형
Article
저널명
APPLIED SCIENCES-BASEL
15
15