Neural-Symbolic Models for Logical Queries on Knowledge Graphs
Zhaocheng ZhuMikhail GalkinZuobai ZhangJian Tang
Presents a neural-symbolic framework that executes complex first-order logic queries over incomplete knowledge graphs by combining graph neural networks with product fuzzy logic, providing interpretable intermediate steps and state-of-the-art reasoning accuracy.
Knowledge graphs organize real-world facts into structured networks of entities and relationships, serving as critical infrastructure for applications such as drug discovery, semantic search, and automated decision support. A central challenge is answering complex First-Order Logic queries—questions requiring multi-hop reasoning alongside logical operations like conjunction (AND), disjunction (OR), and negation (NOT). Traditional symbolic methods provide transparent, step-by-step reasoning but fail on incomplete graphs where facts are missing. Conversely, recent neural embedding models can infer missing information but operate as opaque black boxes, making their intermediate reasoning steps impossible to verify or interpret.
The article introduces and evaluates the Graph Neural Network Query Executor (GNN-QE), a hybrid neural-symbolic framework designed to answer complex logical queries over incomplete knowledge graphs while maintaining step-by-step interpretability.
The framework decomposes complex logical queries into continuous operations over "fuzzy sets"—probabilistic representations of entity memberships. It implements relational transitions between entities using a Graph Neural Network architecture adapted from knowledge graph completion and executes logical operations using product fuzzy logic. To ensure robust generalization on incomplete data, the system incorporates "traversal dropout" during training to prevent the network from memorizing direct graph paths. In addition, the framework introduces a non-recursive batched execution pipeline using postfix notation, allowing efficient GPU processing across diverse and previously unseen query structures. The model was evaluated across 14 standard query types on three established benchmark datasets: FB15k, FB15k-237, and NELL995.
The evaluation produced four key findings. First, GNN-QE established a new state of the art in answering complex logical queries, achieving average relative performance improvements of 22.3% on positive logical queries and 95.1% on queries containing negation compared to leading embedding baselines like ConE. Second, it demonstrated strong sample efficiency, matching or exceeding prior models' full-dataset performance even when trained on only 1% of the training data. Third, the model accurately estimated the total number of correct answers without requiring explicit cardinality supervision, achieving Spearman rank correlations ranging from 0.89 to 0.95 against ground truth. Fourth, the architecture enabled direct inspection and visualization of intermediate reasoning variables, allowing users to audit intermediate entity rankings and identify precisely where reasoning errors occur.
These results demonstrate that organizations do not have to choose between the predictive power of neural networks and the transparency of symbolic systems. In high-stakes environments—such as clinical research, compliance monitoring, and intelligence analysis—the ability to verify intermediate reasoning significantly reduces operational risk and accelerates failure diagnosis. Furthermore, the model's exceptional sample efficiency substantially lowers the computational resources and data labeling required to deploy reasoning systems.
Organizations developing knowledge graph reasoning systems should consider adopting neural-symbolic architectures over pure embedding methods, especially when handling complex queries with negation or when regulatory compliance mandates explainability. Future implementation efforts should focus on integrating GNN-QE with natural language interfaces to enable end-to-end question answering directly from conversational input.
Users should note that while the method performs robustly on standard benchmarks, its accuracy remains bounded by the underlying coverage and quality of the knowledge graph. Missing baseline facts in incomplete graphs can occasionally lead to false intermediate deductions. Further development is also required to scale the framework efficiently to massive, web-scale graphs containing millions of entities.
- Paper: Modeling Relational Data with Graph Convolutional Networks, Michael Schlichtkrull et al. (2018). This paper establishes relational graph convolutional networks for link prediction and knowledge graph completion, providing the foundational message-passing architecture that GNN-QE adapts for relation projections.
- Paper: A Survey on Knowledge Graphs: Representation, Acquisition, and Applications, Shaoxiong Ji et al. (2020). This survey offers a comprehensive overview of knowledge graph representation learning, completion, and logical rule reasoning that contextualizes the problem space addressed by GNN-QE.
- Paper: A Review of Relational Machine Learning for Knowledge Graphs, Maximilian Nickel et al. (2015). This paper reviews core statistical and relational machine learning paradigms for knowledge graphs, clarifying traditional symbolic and latent-space reasoning methods.
- Paper: Convolutional 2D Knowledge Graph Embeddings, Tim Dettmers et al. (2017). This work introduces expressive convolutional embeddings for multi-relational link prediction on knowledge graphs, framing the missing-link reasoning problem addressed by GNN-QE.
- Paper: Markov logic networks, Matthew Richardson et al. (2006). This foundational paper combines first-order logic with probabilistic graphical modeling, establishing the principles of soft logical reasoning that underpin fuzzy logic operations over knowledge graphs.
- Paper: Graph Neural Networks: A Review of Methods and Applications, Jie Zhou et al. (2018). This survey outlines the core message-passing mechanisms and representational properties of graph neural networks necessary to understand multi-hop graph neural execution.
- Paper: Not All Neuro-Symbolic Concepts Are Created Equal: Analysis and Mitigation of Reasoning Shortcuts, Emanuele Marconato et al. (2023). This paper analyzes and mitigates reasoning shortcuts in neuro-symbolic predictors, extending the investigation into the reliability and faithful interpretability of neural-symbolic logic execution.
- Paper: Efficient Rectification of Neuro-Symbolic Reasoning Inconsistencies by Abductive Reflection, Wen-Chao Hu et al. (2025). This work explores efficient neuro-symbolic error correction via abductive reflection, advancing hybrid neural-symbolic reasoning frameworks beyond feedforward query execution.
- Paper: Unifying Large Language Models and Knowledge Graphs: A Roadmap, Shirui Pan et al. (2023). This roadmap charts future paradigms combining neural language reasoning with structured symbolic knowledge graphs for complex multi-hop question answering.
- Paper: StructGPT: A General Framework for Large Language Model to Reason over Structured Data, Jinhao Jiang et al. (2023). This work develops an iterative framework for reasoning over structured knowledge graphs and tables using modular neural executors and language models.
- Paper: NodePiece: Compositional and Parameter-Efficient Representations of Large Knowledge Graphs, Mikhail Galkin et al. (2022). This paper provides a parameter-efficient, compositional representation method that scales complex multi-relational graph reasoning to massive knowledge graphs.
