## 5 Discussion  
### Contribution of Reinforcement Learning with Support Tasks  
Our experiments demonstrate that reinforcement learning with support tasks--specifically key-value and triple-relationship extraction--plays a critical role in enhancing generalization to unseen schemas. Compared to purely supervised learning, our method provides explicit semantic supervision during training, which teaches the model to better understand the structural and property-level semantics of Cypher queries. This leads to more accurate and interpretable query generation across diverse domains. Compared to prior approaches, such as Neo4j's Text2 Cypher [7] and CoBGT [21], our method introduces two key distinctions. First, while [7] relies heavily on large language models fine-tuned with comprehensive data, it lacks explicit semantic task supervision and struggles with generalization to structurally different schemas. CoBGT [21], on the \begin{table}
\begin{tabular}{c c c} \hline \hline
**Method** & Ours & Gemma-2\_9B [30] \\ \hline
**Parameter size** & 3B & 9B \\ \hline
**Execution score** & 56.23\% & 45.41\% \\ \hline \hline \end{tabular}
\end{table} 
Table 8: Execution score comparison on dataset 2. \begin{table}
\begin{tabular}{l l l} \hline \hline
**Question** & **Supervised Fine-Tuning** & **Further Reinforcement Learning Model** \\ \hline \multirow{3}{*}{What are the orders that were placed on 1996-08-09?} & MATCH (\(\circ\)Order) & MATCH (\(\circ\)Order) \\  & WHERE o.OrderDate = & WHERE o.OrderDate = '1996-08-09’ \\  & datetime(’1996-08-09T00:00:00Z’) & RETURN o.OrderID (correct) \\  & RETURN o.OrderID (wrong) & \\ \hline \multirow{3}{*}{Which items were purchased by customers residing in Mexico from the beverages category?} & MATCH (\(\circ\)Customer)-[:PLACED]- \\  & \textgreater{}(\(\circ\)Order)-[:CONTAINS]-\textgreater{}(p:Product) & \textgreater{}(\(\circ\)Order)-[:CONTAINS]-\textgreater{}(p:Product)- \\ \cline{1-1} \cline{2-3}  & WHERE p.CategoryID = ‘Beverages’ & [:BELONGS\_TO]-\textgreater{}(cat:Category) \\ \cline{1-1} \cline{2-3}  & AND c.Country = ’Mexico’ & WHERE c.Country = ’Mexico’ AND \\ \cline{1-1} \cline{2-3}  & RETURN DISTINCT p.ProductName & cat.CategoryName = ’Beverages’ \\ \cline{1-1} \cline{2-3}  & RETURN p.ProductName (correct) \\ \hline \hline \end{tabular}
\end{table} 
Table 9: Some output comparing supervised fine-tuning model and further reinforcement learning model. other hand, introduces semantic guidance via graph processing, but it is less flexible in adapting to new domains due to its reliance on a preprocessed graph structure. In contrast, our method leverages the pretrained knowledge of language models combined with schema-aware prompt construction and response guidance, offering a more adaptable and lightweight solution for diverse and unseen graph structures. Approaches like GraphQ IR [6] and rule-based methods [5] attempt to bridge the semantic gap through intermediate representations or template construction. However, these methods are less effective in handling informal or complex natural language compared to large language models (LLMs). Our approach leverages LLMs through prompt-based training, while enhancing semantic understanding through guided supervised and reinforcement learning. Specifically, we incorporate auxiliary support tasks into the training process, enabling the model to better capture the structural and semantic patterns required for Cypher query generation. Research in [15,16] adopts a system-level or prompt-based approach to improve Text2 Cypher performance by leveraging large language models (LLMs). However, their focus remains primarily on system architecture rather than training optimization. As these methods do not involve adapting or fine-tuning the model itself, they typically rely on powerful LLMs such as ChatGPT. This reliance limits their applicability in local or private deployment settings, where computational resources and privacy constraints may limit the use of large cloud-based models.