PyKEEN-NSX: A Modular Framework for Static, Dynamic and Schema-Aware Negative Sampling in PyKEEN
Not on the map. Why?
Abstract (arXiv)
Embedding methods have become popular due to their scalability on link prediction and/or triple classification tasks on Knowledge Graphs (KGs). Embedding models are trained relying on both positive and negative samples of triples. However, since KGs generally contain only positive assertions, negative samples are artificially generated through negative sampling strategies, ranging from simple random corruption to more sophisticated approaches that exploit structural, semantic, or embedding information. The design and implementation of advanced negative samplers remains challenging, as most popular Knowledge Graph Embedding (KGE) libraries provide support only for basic strategies and lack a unified framework for developing more advanced and customized solutions. To address this gap, we introduce PyKEEN-NSX, an extension of PyKEEN, the popular KGE framework, that provides a modular engineered abstraction for negative sampling. The proposed architecture separates the generation of candidate negative pools, conditioned on an explicit context, from the selection strategy, enabling the development and integration of static, schema-aware and dynamic approaches within a consistent framework. Based on this abstraction, we implement six negative samplers, while remaining fully compatible with existing PyKEEN workflows and pipelines. As a proof of concept, we study negative availability across four datasets, showing that constrained pools frequently fall below the requested number of negatives, so that the encoded criterion is to a large extent replaced by the random fallback that supplements them.
Key facts. No citing papers in the map yet (data through 7 Oct 2026). Builds on 12 of its 21 references that are in the map. First posted on arXiv 31 Aug 2026.
Builds on
12 of 21 references.
References · 12
- 2019RotatE: Knowledge Graph Embedding by Relational Rotation in Complex Spacecited by 893
- 2015A Review of Relational Machine Learning for Knowledge Graphscited by 264
- 2020A Survey on Knowledge Graph-Based Recommender Systemscited by 170
- 2020PyKEEN 1.0: A Python Library for Training and Evaluating Knowledge Graph Embeddingscited by 77
- 2018NSCaching: Simple and Efficient Negative Sampling for Knowledge Graph Embeddingcited by 42
- 2015Type-Constrained Representation Learning in Knowledge Graphscited by 34
- 2017Analysis of the Impact of Negative Sampling on Link Prediction in Knowledge Graphscited by 22
- 2024Negative Sampling in Knowledge Graph Representation Learning: A Reviewcited by 9
- 2023Negative Sampling with Adaptive Denoising Mixup for Knowledge Graph Embeddingcited by 7
- 2019Distributional Negative Sampling for Knowledge Base Completioncited by 5
- 2025Enhancing PyKEEN with Multiple Negative Sampling Solutions for Knowledge Graph Embedding Modelscited by 1
- 2026Return of the Schema: Building Complete Datasets for Machine Learning and Reasoning on Knowledge Graphscited by 1
Built on by
Not cited yet.