Generative Representation Learning on Hyper-relational Knowledge Graphs via Masked Discrete Diffusion

Jaejun Lee, Seheon Kim, Joyce Jiyoung Whang

Introduction

Traditional Knowledge Graphs (KGs) typically represent information as simple subject-relation-object triplets. However, real-world facts are rarely that simple. Hyper-relational Knowledge Graphs (HKGs) address this complexity by incorporating "qualifiers"—key-value pairs that provide essential context. For example, a fact about a movie winning an award might include qualifiers specifying the "year" and the "category."

Historically, the primary computational task for HKGs has been link prediction. This task assumes that nearly all components of a fact are known, leaving only a single blank to be filled. The authors of this paper argue that this assumption is overly restrictive and unrealistic for real-world scenarios, where data is often highly incomplete or entirely new facts need to be discovered. To bridge this gap, they introduce a novel paradigm called fact generation and propose KREPE (Contextual HKG REPresentation Learning via Masked DiscretE Diffusion), a model capable of generating valid hyper-relational facts from scratch or from arbitrarily masked queries.

The Challenge: Beyond "Fill-in-the-Blank"

In real-world applications, we frequently encounter situations where multiple components of a fact—or even the entire fact—are missing simultaneously. Existing models struggle with this because the search space for a complete hyper-relational fact is combinatorially explosive.

While Large Language Models (LLMs) have shown remarkable generative capabilities in text, they are not inherently "graph-native." The paper demonstrates that powerful LLMs like GPT-4 and Gemini often fail to respect the rigid structural and relational constraints of specific knowledge graphs. They tend to produce "hallucinations" that, while semantically plausible in natural language, are structurally invalid or factually incorrect within the strict confines of an HKG.

Methodology: The KREPE Architecture

To tackle the fact generation task, KREPE relies on two foundational pillars:

1. Contextual Message Passing

To understand the "meaning" of an entity or relation, KREPE examines the facts in which it participates. A critical innovation here is avoiding the "self-information trap." When updating a component's representation, standard message passing can lead to the trivial retention of self-information. KREPE explicitly excludes the target component's own information during the update. This forces the model to learn the component's identity based solely on its surrounding context, preventing simple label memorization and vastly improving its ability to infer missing pieces.

2. Masked Discrete Diffusion

KREPE treats fact generation as an iterative denoising process, utilizing a bi-level noising strategy during training:

  • Inter-fact noise: The model stochastically samples a subset of the graph to serve as the "observed" structure, teaching it to handle incomplete global information.
  • Intra-fact noise: It randomly masks an arbitrary number of components within a single fact, ranging from just one missing piece to an entirely masked fact.

The model is trained using an any-order autoregressive (AO-AR) objective, which is mathematically equivalent to masked discrete diffusion. This allows KREPE to model the joint probability distribution of multiple missing components simultaneously, rather than predicting them in isolated silos. Furthermore, the authors implemented a caching strategy for the iterative decoding process, keeping inference costs manageable even for highly complex queries.

Key Results and Insights

KREPE was evaluated on three standard HKG benchmarks: WD50K (a Wikidata subset linked to FB15K-237), WikiPeople (focused on human-centric facts), and WikiPeople- (with literal values removed to isolate relational structure).

The results highlight several major breakthroughs:

  • Unification of Tasks: By leveraging a diffusion framework, KREPE successfully unifies discriminative link prediction and generative fact generation into a single training objective.
  • State-of-the-Art Link Prediction: KREPE achieved SOTA results on traditional link prediction benchmarks (WD50K and WikiPeople), proving that a generative objective enhances the quality of learned representations even for discriminative tasks.
  • Dominance in Fact Generation: In the highly challenging "Generation from Scratch" task—where the model starts with zero information—KREPE achieved an accuracy of 0.717 on WD50K and 0.855 on WikiPeople-. This performance more than doubles that of the best LLM-based baselines.
  • Robustness: The model maintained high accuracy across both targeted (one known component) and arbitrary masking scenarios, demonstrating graceful handling of varying levels of missing information.

Limitations and Future Directions

While KREPE represents a significant leap forward, the authors note a few limitations. Currently, the model operates in a transductive setting, meaning it relies on a fixed set of entities and relations seen during training. Adapting the architecture for inductive scenarios—handling entirely unseen entities or relations—is a primary goal for future research.

Additionally, scaling this diffusion-based approach to massive, billion-node graphs will require further optimizations in the stochastic structure sampling process. Finally, as with any powerful generative model, there is a risk of generating high-fidelity false information, underscoring the need for robust verification mechanisms in downstream applications.

Summary updated

BibTeX
@inproceedings{lee2026generative,
  author = {Jaejun Lee and Seheon Kim and Joyce Jiyoung Whang},
  title = {{Generative Representation Learning on Hyper-relational Knowledge Graphs via Masked Discrete Diffusion}},
  booktitle = {International Conference on Machine Learning},
  year = {2026},
  url = {https://openreview.net/forum?id=lRZmoqiAPg},
}
Figure