Neuro-Symbolic Query Compiler
- URL: http://arxiv.org/abs/2505.11932v1
- Date: Sat, 17 May 2025 09:36:03 GMT
- Title: Neuro-Symbolic Query Compiler
- Authors: Yuyao Zhang, Zhicheng Dou, Xiaoxi Li, Jiajie Jin, Yongkang Wu, Zhonghua Li, Qi Ye, Ji-Rong Wen,
- Abstract summary: This paper presents QCompiler, a neuro-symbolic framework inspired by linguistic grammar rules and compiler design, to bridge this gap.<n>It theoretically designs a minimal yet sufficient Backus-Naur Form (BNF) grammar $G[q]$ to formalize complex queries.<n>The atomicity of the sub-queries in the leaf ensures more precise document retrieval and response generation, significantly improving the RAG system's ability to address complex queries.
- Score: 57.78201019000895
- License: http://creativecommons.org/licenses/by-nc-sa/4.0/
- Abstract: Precise recognition of search intent in Retrieval-Augmented Generation (RAG) systems remains a challenging goal, especially under resource constraints and for complex queries with nested structures and dependencies. This paper presents QCompiler, a neuro-symbolic framework inspired by linguistic grammar rules and compiler design, to bridge this gap. It theoretically designs a minimal yet sufficient Backus-Naur Form (BNF) grammar $G[q]$ to formalize complex queries. Unlike previous methods, this grammar maintains completeness while minimizing redundancy. Based on this, QCompiler includes a Query Expression Translator, a Lexical Syntax Parser, and a Recursive Descent Processor to compile queries into Abstract Syntax Trees (ASTs) for execution. The atomicity of the sub-queries in the leaf nodes ensures more precise document retrieval and response generation, significantly improving the RAG system's ability to address complex queries.
Related papers
- Enhancing SPARQL Query Rewriting for Complex Ontology Alignments [0.0]
This article proposes an innovative approach for the automatic rewriting of SPARQL queries from a source to a target.<n>It uses the principles of equivalence transit as well as the advanced capabilities of large language models such as GPT-4.<n>It provides a flexible solution for querying heterogeneous data.
arXiv Detail & Related papers (2025-05-02T14:38:13Z) - Effective Instruction Parsing Plugin for Complex Logical Query Answering on Knowledge Graphs [51.33342412699939]
Knowledge Graph Query Embedding (KGQE) aims to embed First-Order Logic (FOL) queries in a low-dimensional KG space for complex reasoning over incomplete KGs.
Recent studies integrate various external information (such as entity types and relation context) to better capture the logical semantics of FOL queries.
We propose an effective Query Instruction Parsing (QIPP) that captures latent query patterns from code-like query instructions.
arXiv Detail & Related papers (2024-10-27T03:18:52Z) - Pathformer: Recursive Path Query Encoding for Complex Logical Query Answering [20.521886749524814]
We propose a neural one-point embedding method called Pathformer based on the tree-like computation graph, i.e., query tree.
Specifically, Pathformer decomposes the query computation tree into path query sequences by branches.
This allows Pathformer to fully utilize future context information to explicitly model the complex interactions between various parts of a path query.
arXiv Detail & Related papers (2024-06-21T06:02:58Z) - Semantic Parsing for Complex Data Retrieval: Targeting Query Plans vs.
SQL for No-Code Access to Relational Databases [2.933060994339853]
We investigate the potential of an alternative query language with simpler syntax and modular specification of complex queries.
The proposed alternative query language is called Query Plan Language (QPL)
We present ways to address the challenge of complex queries in an iterative, user-controlled manner.
arXiv Detail & Related papers (2023-12-22T16:16:15Z) - Decomposing Complex Queries for Tip-of-the-tongue Retrieval [72.07449449115167]
Complex queries describe content elements (e.g., book characters or events), information beyond the document text.
This retrieval setting, called tip of the tongue (TOT), is especially challenging for models reliant on lexical and semantic overlap between query and document text.
We introduce a simple yet effective framework for handling such complex queries by decomposing the query into individual clues, routing those as sub-queries to specialized retrievers, and ensembling the results.
arXiv Detail & Related papers (2023-05-24T11:43:40Z) - HPE:Answering Complex Questions over Text by Hybrid Question Parsing and
Execution [92.69684305578957]
We propose a framework of question parsing and execution on textual QA.
The proposed framework can be viewed as a top-down question parsing followed by a bottom-up answer backtracking.
Our experiments on MuSiQue, 2WikiQA, HotpotQA, and NQ show that the proposed parsing and hybrid execution framework outperforms existing approaches in supervised, few-shot, and zero-shot settings.
arXiv Detail & Related papers (2023-05-12T22:37:06Z) - From Parse-Execute to Parse-Execute-Refine: Improving Semantic Parser
for Complex Question Answering over Knowledge Base [11.72232145568396]
KoPL has been proposed to explicitly model the reasoning processes, which achieved the state-of-the-art on complex KBQA.
We show that such simple strategy can significantly improve the ability of complex reasoning.
arXiv Detail & Related papers (2023-05-05T08:20:09Z) - Sequential Query Encoding For Complex Query Answering on Knowledge
Graphs [31.40820604209387]
We propose sequential query encoding (SQE) as an alternative to encode queries for knowledge graph (KG) reasoning.
SQE first uses a search-based algorithm to linearize the computational graph to a sequence of tokens and then uses a sequence encoder to compute its vector representation.
Despite its simplicity, SQE demonstrates state-of-the-art neural query encoding performance on FB15k, FB15k-237, and NELL.
arXiv Detail & Related papers (2023-02-25T16:33:53Z) - Logical Message Passing Networks with One-hop Inference on Atomic
Formulas [57.47174363091452]
We propose a framework for complex query answering that decomposes the Knowledge Graph embeddings from neural set operators.
On top of the query graph, we propose the Logical Message Passing Neural Network (LMPNN) that connects the local one-hop inferences on atomic formulas to the global logical reasoning.
Our approach yields the new state-of-the-art neural CQA model.
arXiv Detail & Related papers (2023-01-21T02:34:06Z) - Tree-Augmented Cross-Modal Encoding for Complex-Query Video Retrieval [98.62404433761432]
The rapid growth of user-generated videos on the Internet has intensified the need for text-based video retrieval systems.
Traditional methods mainly favor the concept-based paradigm on retrieval with simple queries.
We propose a Tree-augmented Cross-modal.
method by jointly learning the linguistic structure of queries and the temporal representation of videos.
arXiv Detail & Related papers (2020-07-06T02:50:27Z)
This list is automatically generated from the titles and abstracts of the papers in this site.
This site does not guarantee the quality of this site (including all information) and is not responsible for any consequences.