## 1 Introduction  
With the increasing adoption of graph databases, such as Neo4j, across diverse domains like biomedical research [1], social networks [2], recommendation systems [3], and RAG [4], the demand for user-friendly Cypher query interfaces has grown significantly. While the Cypher query language provides powerful expressiveness for querying graph data, its usage remains challenging for many non-expert users due to its technical complexity. This challenge motivates the task of translating natural language into Cypher queries--commonly known as Text2 Cypher. The Text2 Cypher task raises several key challenges. First, the model for the task requires an understanding of both the user's text inputs and the underlying graph schemas. Second, Cypher query includes flexible patterns, directional relationships, and variable-length path queries that introduce additional complexity. Finally, models trained on a specific schema often struggle to generalize when presented with new or unseen schemas, so that cross-schema generalization becomes a critical benchmark for real-world deployment. Early rule-based methods [5; 6] attempted to bridge the semantic gap between natural language and graph queries, but these approaches lacked generalization and scalability. Recent approaches based on LLMs show promising outcomes [7]. Since LLMs are pre-trained, instruction-tuned, and aligned with human preference on massive amounts of text datasets, they learn various language patterns, logical forms, and contextual structures. This enables them to interpret natural language in a generalizable way, including understanding and generating graph queries across different domains. But existing LLMs have been trained more on ordinary text datasets. Neo4j's Text2 Cypher [7] constructs a comprehensive Text2 Cypher dataset, which contains 44,387 instances consisting of input texts, corresponding cypher outputs, and schemas, and demonstrates through experiments over various 'pretrained and instruction-tuned generative language models' (hereafter, we call baseline LMs as in [7]) that fine-tuning with such a comprehensive Text2 Cypher dataset enhances the performance. Nonetheless, we can observe that fine-tuning alone is insufficient to capture the full syntactic and semantic diversity of Cypher queries across domains. To address this challenge, we propose a refined training method of Text2 Cypher based on the baseline SLM (small-scale baseline LM)s by reinforcement learning with Group Relative Policy Optimization (GRPO) [8], which leverages semantic information such as key-value properties and triple relationship of the input texts extracted during refining training process so that the proposed method tunes the fine-tuned model more effectively so as to produce more syntactically and semantically accurate queries. We implement our proposed refinement method on a baseline SLM like Qwen2.5-3B-Instruct [8]. For the baseline SLM, we first apply further fine-tuning with a home-grown Text2 Cypher dataset and Neo4j's Text2 Cypher dataset [6]. Then, we apply reinforcement learning with support tasks. The support tasks are supposed to extract semantic information, such as key-value and triple relationships, under guidelines contained in input prompts. We evaluate the proposed method in a cross-schema setting under environments with separate training and testing schemas. Experimental results show that our proposed method achieves 85% execution accuracy on unseen schemas. By comparison with the latest performance results reported in Neo4j's recent paper [7], the proposed method applied to Qwen2.5-3B-Instruct (3B parameter size) outperforms several fine-tuned open-weighted language models even with bigger parameters with respect to Google-BLEU [9] and execution accuracy score [10].