Before you begin
Prerequisites
- Understand triples, link prediction, and train/validation/test splits.
- Read 28.1 on benchmark contracts and 28.2 on ranking metrics.
Learning objectives
- Detect exact, inverse and alias-mediated cross-split redundancy.
- Distinguish legitimate transductive entity overlap from violations of an inductive contract.
- Compute raw and filtered ranks and explain what filtering cannot repair.
Overview
A link-prediction score is evidence about a specified experiment. It is not automatically evidence that a system can discover a new scientific relationship. If the answer has already reached the model through another representation, the experiment may reward recovering an encoding convention. If a competing answer is true but absent from the benchmark, the same experiment may penalize a useful prediction. This lesson separates these two problems: leakage concerns information available to the learner; false negatives concern the meaning of the evaluation labels. Raw and filtered ranking address only part of the second problem. [1] [2]
Build on 28.1 on benchmark contracts and 28.2 on metrics and calibration. The parent chapter's objective is to design an evaluation that tests the intended deployment setting. Here the practical question is: what would a model have been allowed to know when this query actually arrived?
Throughout the worked examples, papers, researchers and methods are fictional. Treat the proposed audit as a design exercise, not as an experiment on LUMINA's production data. Its three outputs are deliberately separate: a list of suspicious cross-split facts, a declaration of entity visibility, and a reproducible ranking calculation. A single reassuring aggregate score cannot substitute for those records.
Historical and scientific foundations
Bordes, Usunier, Garcia-Duran, Weston and Yakhnenko's TransE paper (2013) described both raw and filtered link-prediction evaluation. It recognized that corrupting a true triple can produce another triple already known to be true. The filtered protocol removes such competing known answers, while retaining the particular test answer whose rank is measured. This is a correction to the comparison set, not a new model or a guarantee that every remaining candidate is false. [1]
Toutanova and Chen (2015) compared observed graph features with latent representations. Their analysis showed how direct links and inverse or near-duplicate relations could make established benchmarks easier than their intended reasoning task. They constructed FB15KSelected with 237 relations after removing redundant relation types and excluding certain directly connected evaluation pairs. Those choices define a more restrictive task; the paper itself notes that some excluded links could legitimately occur in practice. [2]
Dettmers, Minervini, Stenetorp and Riedel's ConvE work, published at AAAI in 2018, further demonstrated the strength of a simple inverse-rule baseline on WN18 and FB15k and introduced WN18RR as a revised benchmark. The methodological lesson is to compare complex models with shortcuts that the dataset might permit. Removing one known shortcut does not certify a dataset against every other one. [3]
A different foundation concerns missing knowledge. RDF's model-theoretic semantics does not make an unasserted triple false merely because it is absent: truth and entailment are defined with respect to interpretations and assumptions. This logical point should not be confused with a learning algorithm's engineering decision to sample unobserved triples as negative training examples. That decision needs its own justification. [10]
Core explanation
Define the information boundary first
For this lesson, call information leakage a violation of the experiment's declared information boundary: an answer, equivalent fact or prohibited signal becomes available during fitting, selection or prediction. A benchmark shortcut is broader: a permitted signal can make the task much easier than the scientific capability being claimed. A redundant edge can be both, but the categories need not coincide. The distinction helps interpret the historical benchmark diagnoses and recent inductive evaluation work. [2] [8]
Write the boundary as a concrete contract: training triples, validation labels, inference-time support edges, entity descriptions, external model versions, candidate entities and timestamps. For a proposed scholarly system, for example, a paper's abstract may be legitimate evidence for extracting its reported method. The same abstract may reveal the answer in a purported experiment predicting that method before the paper was available. The defect is the mismatch between the evidence and the claim.
Four checks that answer different questions
Exact duplicates repeat the same canonical triple across partitions. Semantic duplicates express the same fact through aliases or redundant predicates. Inverse redundancy expresses it with reversed arguments and an inverse relation. Test triples may therefore be recoverable even when the literal intersection of training and test files is empty. Relation-pair overlap was central to the analysis by Toutanova and Chen; ConvE's inverse baseline makes the consequence visible. [2] [3]
Entity leakage requires a more careful statement. In a transductive task, training and test queries can involve the same entities; the held-out object is an edge. In an entity-disjoint inductive task, test entities must instead be unseen during training. GraIL explicitly investigates generalization to unseen entities and graphs through local subgraph reasoning. Thus entity overlap is not a universal error: it is an error when it violates the chosen generalization claim. [5]
For the proposed scholarly audit, resolve verified aliases before checking that boundary. Two identifiers for the same researcher do not create two independently unseen people. Conversely, similar names do not establish identity. A preprint and a journal article may be versions of one work or separately modeled documents; record the modeling decision instead of merging them automatically. Check feature provenance as well as identifiers: a withheld edge can still be encoded in an exported description or an embedding trained from a prohibited graph snapshot.
Unobserved is not verified false
A corrupted triple replaces a head or tail to create a comparison candidate. It can be false, unknown, or another true answer. CoDEx is valuable here because its authors supplied plausible, verified-false negative triples, alongside completion datasets and classification experiments. That is stronger evidence about falsity than absence alone, although it does not turn every other missing edge into a negative label. [6]
Distinguish a false negative in the dataset from a model's false-negative decision. The former means a true fact is being treated as a negative example; the latter means a decision rule rejected a positive case. During training, mislabeled negatives can oppose the desired learning signal. During ranking evaluation, an unrecorded true competitor can push the designated answer down. Neither effect is repaired merely by calling the metric filtered.
Raw and filtered ranking
Let C be the declared candidate entities for a tail query (h, r, ?), and let t be the target. Assume larger scores are better. With distinct scores, raw rank is 1 + count(e in C: score(e) > score(t)). Let K be the evaluator's known-positive triples. Filtered ranking uses C' = {e in C: e = t or (h,r,e) not in K}. The target must remain. This is the TransE filtering principle written explicitly for a fixed candidate set. [1]
For ties, specify a policy rather than trusting sort order. PyKEEN distinguishes optimistic, pessimistic and realistic ranks; realistic rank averages the first and last tied positions. Its documented validation/HPO filtering uses training plus validation positives, whereas final test evaluation uses training, validation and test positives. Test labels used privately by a final evaluator are not permission to use them for early stopping, parameter selection or training-negative construction. [4]
A useful consequence can be derived directly: with unchanged scores, target and tie convention, removing competitors cannot worsen that target's rank. Improved filtered rank therefore need not represent any improvement in the model. It represents a different question asked of the same scores. It still depends on how complete and correct the known-positive set is.
Worked examples
An answer hidden in another edge
Suppose training contains (PaperA, writtenBy, ResearcherR), while test contains (ResearcherR, authorOf, PaperA). In this fictional schema, the two predicates are declared exact inverses. A rule that reverses the first edge answers the second without discovering a new authorship fact. The file-level triple intersection is nevertheless empty. If the intended task is recovering unknown authorship, keep these equivalent facts in the same partition. If the intended task is applying inverse rules, retain them and name that task accurately.
Now replace PaperA in the test file with PaperA_alias, a verified second identifier for the same paper. Raw identifier checks miss the problem again. Canonicalization reveals it. But if PaperA_alias were only a similar title with unresolved identity, treating it as identical would corrupt the audit. Preserve an unresolved-alias report rather than converting uncertainty into a clean bill of health.
One query, three evaluation interpretations
For fictional query (PaperB, usesMethod, ?), the benchmark target is Method1. The scores below are invented and fixed; no model was trained to produce them.
| Candidate | Score | Evaluator's record |
|---|---|---|
| Method2 | 0.9 | Another known positive |
| Method3 | 0.8 | Unknown |
| Method1 | 0.7 | Target positive |
| Method4 | 0.2 | Verified false in this toy example |
Raw rank is 3, giving reciprocal rank 1/3 for this query. Filtering Method2 gives rank 2 and reciprocal rank 1/2. Method3 remains because the evaluator has no positive record for it. If subsequent evidence establishes Method3 as another method used by PaperB, a revised known-positive set would give rank 1. That last calculation is a hypothetical label update, not a claim that Method3 is true. None of these changes alters the score vector.
To test ties, assign Method3 score 0.7. After removing Method2, Method1 and Method3 occupy positions 1 and 2. Optimistic rank is 1, pessimistic rank is 2, and realistic rank is 1.5. The reciprocal of realistic rank is 2/3; it is not the average of the two reciprocal ranks, which is 3/4. Choose the intended statistic explicitly. This arithmetic follows the documented tie definitions. [4]
Finally, imagine an entity-disjoint claim with ResearcherR present in both partitions. That violates the claim even if every authorship edge is different. Under a transductive contract, the same overlap is expected. The audit must report the entity sets and the declared task together, rather than labeling every overlap as contamination.
Practice and implementation
The following original Python example uses only the standard library and fictional data. It was executed during this article's checks. It detects declared inverse equivalence after a supplied alias mapping and computes realistic ranks. It does not infer aliases, discover inverse predicates, inspect model pretraining, or prove a dataset leakage-free.
ALIASES = {"PaperA_alias": "PaperA"}
def canonical(triple):
h, r, t = triple
h, t = ALIASES.get(h, h), ALIASES.get(t, t)
if r == "authorOf":
return (t, "writtenBy", h)
return (h, r, t)
train = {("PaperA", "writtenBy", "ResearcherR")}
test = {("ResearcherR", "authorOf", "PaperA_alias")}
assert not train.intersection(test)
overlap = {canonical(x) for x in train} & {
canonical(x) for x in test}
assert overlap == {("PaperA", "writtenBy", "ResearcherR")}
def rank(scores, target, known_positive=()):
# Known positives are query-specific candidate identifiers.
retained = {e: s for e, s in scores.items()
if e == target or e not in known_positive}
value = retained[target]
greater = sum(s > value for s in retained.values())
equal = sum(s == value for s in retained.values())
return 1 + greater + (equal - 1) / 2
scores = {"Method2": .9, "Method3": .8,
"Method1": .7, "Method4": .2}
known = {"Method1", "Method2"}
assert rank(scores, "Method1") == 3
assert rank(scores, "Method1", known) == 2
assert rank(scores, "Method1", set(scores)) == 1
tied = dict(scores, Method3=.7)
assert rank(tied, "Method1", known) == 1.5
print("canonical overlaps:", len(overlap))
print("raw / filtered:", rank(scores, "Method1"),
rank(scores, "Method1", known))
The observed output is canonical overlaps: 1 and raw / filtered: 3.0 2.0. The all-known-positive assertion is intentional: it checks that filtering cannot accidentally delete the target. Exact floating-point equality defines ties here; production evaluation should document numerical precision and any tolerance policy.
For a real implementation, use the following proposed sequence. First freeze source snapshots and the deployment question. Second, document identity and relation-equivalence rules, retaining their provenance. Third, assign equivalent facts to groups and split groups rather than independently splitting their representations. Fourth, construct reciprocal training edges only from permitted training facts. Finally, export separate learner inputs and evaluator-only labels, with file hashes and a manifest of the candidate and filtering policies.
For example, augmenting every original authorship triple with its inverse and then randomly splitting the expanded rows can put one representation in training and the other in test. Split equivalence groups first. Adding reciprocal edges from the resulting training graph is a different operation: it does not introduce a held-out fact by itself. For a symmetric predicate, the reverse can use the same relation name; the grouping rule must account for that declared symmetry as well.
Keep the test set sealed from iterative model development. Dataset curators may inspect cross-split redundancy while constructing a benchmark, but changes prompted by such inspection create a revised benchmark and must be disclosed. If an existing test set has already guided repeated design choices, create a fresh holdout for the final claim. Do not conceal the intervention by publishing only the improved number.
Run simple diagnostics before expensive training: exact intersections, declared-equivalence intersections, entity-set intersections under the chosen contract, inverse-rule performance, and results grouped by relation and visibility category. Save counts and examples of findings, not merely a Boolean assertion. For unresolved identity pairs, measure sensitivity under plausible resolutions or describe the remaining uncertainty. These are proposed audit practices derived from the failure mechanisms above, not a validated universal cleaning algorithm.
Limitations and common mistakes
Cleaning can change the research question. Removing every easily inferred fact may create a difficult benchmark that poorly represents the intended service. A production graph may legitimately contain reciprocal relations or multiple sources supporting the same claim. The relevant decision is which information is available for the prediction being evaluated, not whether the graph looks redundant. The historical FB15KSelected construction explicitly acknowledged this tradeoff. [2]
Filtering is neither deduplication nor truth discovery. It removes known alternative answers during scoring. It does not erase answers already absorbed into model parameters, remove duplicate test queries, or validate unknown candidates. A separate label audit is required when unknown facts are treated as negatives. Verified negatives such as those supplied with CoDEx help answer a narrower classification question; their existence does not establish global completeness. [6]
Candidate policies can dominate comparisons. Ranking against every entity, a type-restricted set, or sampled competitors yields different experiments. OGB documents dataset-specific candidate policies, including type-constrained corruption for ogbl-biokg. A raw score from one policy and a filtered score from another cannot isolate the effect of filtering. Keep candidates fixed for that comparison and report the policy for every result. [7]
Identity separation does not eliminate all shortcuts. Distinct entities may still have highly similar neighborhoods, repeated source documents or equivalent features. Conversely, a low score after cleaning does not by itself identify which shortcut mattered: cleaning can change sample size and difficulty. Use controlled comparisons where feasible and distinguish observed performance changes from causal explanations. These cautions motivate the recent studies below.
Recent advances and publications
The bounded research search covered directly relevant work from November 2024 through the 7 November 2026 cutoff, alongside earlier foundations. Shomer, Revolinsky and Tang's Towards Better Benchmark Datasets for Inductive Knowledge Graph Completion is a published KDD 2025 paper; the inspected author manuscript is arXiv v3, dated 24 June 2025. They evaluated Personalized PageRank, a relation-agnostic heuristic, and found it competitive on several existing inductive benchmarks. Their analysis links this behavior to shorter positive-pair distances created by dataset sampling. A graph-partitioning construction mitigated the shortcut and changed measured model performance. The result concerns the studied benchmark constructions, not a proof that every inductive method merely memorizes topology. [8]
Brière, Stosskopf, Loire and Baudot's 2026 Bioinformatics article examines leakage in biomedical link prediction across three knowledge graphs and decoder-only and GNN-based models. Its reported methods include redundancy control, degree-preserving permutation experiments, and comparison of random/cold-start splits with an independent Orphanet test set. The abstract reports a performance drop on the independent set and no evidence that degree alone drives predictions. That latter result prevents an overbroad claim that any degree signal is necessarily illegitimate. [9]
For the biomedical study, the author abstract and figure captions were accessible; the publisher full-text route and PMC page were blocked during this run. Accordingly, this lesson reports only those verified high-level methods and findings, without numerical effect sizes or claims about uninspected implementation details. These are benchmark investigations, not prospective demonstrations that predicted treatments work. Together, the two recent studies broaden the audit beyond literal duplicate triples to dataset construction and the relevance of the held-out population.
Real-world applications
OGB provides a documented example of evaluation choices attached to real knowledge sources. Its ogbl-wikikg2 benchmark uses Wikidata snapshots from May, August and November 2015 for training and subsequent additions, retaining entities and relation types from the earliest snapshot. Its biomedical benchmark instead uses a random split and explains the difficulty of establishing accurate times for underlying observations. These are explicit task constructions, not interchangeable estimates of all future knowledge discovery. [7]
The biomedical leakage study provides a practical motivation for independent evaluation in drug-repurposing research. Its comparison with Orphanet-derived test information asks whether familiar benchmark splits reflect another relevant source of examples. The lesson is about evaluating research models; it does not establish clinical effectiveness or deployment safety. [9]
A proposed scholarly application would rank candidate links from papers to methods or claims to evidence. Keep multiple supporting papers as distinct provenance records, while grouping representations of the same target fact when a split requires independence. If the objective is discovering new evidence, record when the evidence became accessible; if it is organizing existing literature, allow that literature and evaluate the organization task directly. Preserve unknown candidate status so a promising unrecorded claim can be sent for evidence review rather than automatically counted as false.
Key lessons and practice question
Audit three things separately: what the model could know, which facts the evaluator recognizes, and which competitors enter each ranking. Equivalent facts can cross a split without identical triples. Entity overlap is interpreted relative to a transductive or inductive contract. Filtered ranking removes known alternatives while retaining the target; it cannot repair training leakage or establish the falsity of missing facts.
Practice question. A fictional test query asks who wrote PaperC. Training includes the inverse authorship statement. The target researcher scores 0.6, another known coauthor scores 0.9, and an unknown candidate scores 0.8. All scores are distinct. What are the raw and filtered ranks, and would a perfect filtered result prove discovery of new authorship?
Answer. Raw rank is 3; filtering the known coauthor gives rank 2. The unknown candidate stays. Even a rank of 1 would not prove discovery: the inverse training edge already supplies the authorship answer under the declared schema. Fix or relabel that experiment's information contract before interpreting its score. Then separately investigate whether the unknown candidate is genuinely false, true but unrecorded, or unresolved.
References
- Antoine Bordes; Nicolas Usunier; Alberto Garcia-Duran; Jason Weston; Oksana Yakhnenko (2013). Translating Embeddings for Modeling Multi-relational Data. Advances in Neural Information Processing Systems 26, pp. 2787–2795. published. Accessed 2026-11-07.
- Kristina Toutanova; Danqi Chen (2015). Observed versus latent features for knowledge base and text inference. 3rd Workshop on Continuous Vector Space Models and their Compositionality, pp. 57–66. published. DOI: 10.18653/v1/W15-4007. Accessed 2026-11-07.
- Tim Dettmers; Pasquale Minervini; Pontus Stenetorp; Sebastian Riedel (2018). Convolutional 2D Knowledge Graph Embeddings. AAAI 32(1); author manuscript arXiv:1707.01476. published. DOI: 10.1609/aaai.v32i1.11573. Accessed 2026-11-07.
- PyKEEN developers (n.d.). Understanding the Evaluation. Official documentation, version 1.11.1. official documentation. Accessed 2026-11-07.
- Komal Teru; Etienne Denis; Will Hamilton (2020). Inductive Relation Prediction by Subgraph Reasoning. ICML, PMLR 119, pp. 9448–9457. published. Accessed 2026-11-07.
- Tara Safavi; Danai Koutra (2020). CoDEx: A Comprehensive Knowledge Graph Completion Benchmark. EMNLP, pp. 8328–8350. published. DOI: 10.18653/v1/2020.emnlp-main.669. Accessed 2026-11-07.
- Open Graph Benchmark team (n.d.). Link Property Prediction. Official dataset and evaluation documentation. official documentation. Accessed 2026-11-07.
- Harry Shomer; Jay Revolinsky; Jiliang Tang (2025). Towards Better Benchmark Datasets for Inductive Knowledge Graph Completion. 31st ACM SIGKDD Conference on Knowledge Discovery and Data Mining V.2; author manuscript arXiv:2406.11898v3, 24 June 2025. published. DOI: 10.1145/3711896.3737438. Accessed 2026-11-07.
- Galadriel Brière; Thomas Stosskopf; Benjamin Loire; Anaïs Baudot (2026). Benchmarking the impact of data leakage on the performance of knowledge graph embedding models for biomedical link prediction. Bioinformatics 42(8), btag608; abstract and figure captions inspected. published. DOI: 10.1093/bioinformatics/btag608. Accessed 2026-11-07.
- W3C RDF Working Group (2014). RDF 1.1 Semantics. W3C Recommendation, 25 February 2014. published. Accessed 2026-11-07.