Introduction
Knowledge Graphs (KGs) serve as the backbone for structured information retrieval, yet the development of a truly "general" foundation model for KGs has been hindered by a persistent divide between structural reasoning and semantic understanding. Traditional approaches often excel at either navigating the graph's topology or interpreting the textual nuances of its components, but rarely both. This paper introduces MERRY (Multi-pErspective Reasoning sYstem), a foundation model designed to bridge this gap. By integrating structural graph data with textual descriptions, MERRY generalizes across diverse tasks, including "in-KG" link prediction and "out-of-KG" complex question answering, across 28 distinct datasets.
The Dual Silos of Knowledge Graph Reasoning
Current foundation models for KGs typically suffer from two primary limitations. First, they are modality-limited, focusing predominantly on the graph's structure—the "dots and lines"—while ignoring the rich semantic information contained in entity and relation descriptions. Second, they are task-limited, primarily optimized for Knowledge Graph Completion (KGC). While these models can fill in missing links within a known schema, they often struggle with Knowledge Graph Question Answering (KGQA), where the model must interpret natural language queries and reason over external logic.
To address these issues, MERRY tackles three core technical challenges:
- Semantic Disparity: Aligning the high-dimensional vector space of Graph Neural Networks (GNNs) with the semantic space of Large Language Models (LLMs).
- Task Balancing: Dynamically adjusting the reliance on text versus structure depending on the specific requirements of the task.
- Inductive Generalization: Enabling the model to reason over entirely new graphs with unseen entities and relations.
Methodology: The MERRY Framework
MERRY utilizes an encoder-decoder framework centered on Conditional Message Passing (CMP). Unlike standard GNNs that produce static node embeddings, CMP conditions node representations on the specific query being processed, allowing for more targeted reasoning.
Key Architectural Components
- Query Conditional Structural Encoding (QCMP): This module focuses on the "meta-topology" of the graph. By learning how relations interact abstractly, it allows the model to generalize to relations it has never encountered during training.
- Global Structural Semantic Encoding (GCMP): To bridge the semantic gap, MERRY leverages Llama 3 (8B) to extract textual features from entity and relation descriptions. These features are then processed through a CMP layer, ensuring that the semantic information is contextualized within the graph's structure.
- Dynamic Text-Adaptive Fusion (DTAF): A cross-attention mechanism that weights the importance of textual versus structural data. For instance, in common-sense reasoning tasks, the model may prioritize textual semantics, whereas for simple link prediction, it may rely more heavily on structural patterns.
- Flexible Edge Scoring: To mitigate noise in complex subgraphs, MERRY employs a bilinear scoring mechanism that filters out edges irrelevant to the query, streamlining the reasoning path.
Experimental Setup and Results
The model underwent pre-training on three hybrid KGs: WN18RR, FB15k-237, and CodexMedium. Its performance was then evaluated across 28 datasets, covering both inductive KGC and KGQA.
Inductive Reasoning
MERRY was tested on 27 inductive datasets categorized into IndE (unseen entities, fixed relations) and IndER (unseen entities and relations). The model achieved State-of-the-Art (SOTA) results on 12 out of 24 benchmarks, outperforming specialized models such as ULTRA and ProLINK. This demonstrates MERRY's robust ability to handle "zero-shot" scenarios where it must predict links in entirely novel graphs.
Knowledge Graph Question Answering (KGQA)
On the CommonsenseQA (CSQA) benchmark—a dataset requiring reasoning over external knowledge—MERRY achieved an accuracy of 74.9%. This performance surpasses established baselines like GreaseLM (74.2%) and QA-GNN (73.4%), highlighting the effectiveness of its dual-modality approach.
Discussion and Insights
The success of MERRY underscores the role of text as a universal translator. By utilizing LLM-encoded descriptions, the model can reason about a novel relation (e.g., "is_author_of") by understanding the word's semantics rather than relying on a fixed embedding ID. Furthermore, the authors' "parameter-free" strategy for LLM feature extraction—pre-computing features offline—allows for scalability without the prohibitive memory costs of simultaneous LLM and GNN training.
Limitations and Future Directions
Despite its strengths, MERRY faces several challenges:
- GNN Smoothing: As with many deep GNNs, increasing layer depth can lead to feature smoothing, where node representations become indistinguishable, potentially limiting reasoning depth.
- Data Dependency: The model assumes the availability of textual descriptions for all entities and relations. Performance may degrade in sparse or poorly documented KGs.
- Storage Overhead: While offline feature extraction saves GPU memory, storing high-dimensional features for billion-node graphs remains a significant engineering challenge.
Future research will focus on optimizing the GNN update loop for more efficient LLM integration and improving robustness in the face of missing textual metadata.
Summary updated