TECHNOLOGY

ogbl-wikikg2: head prediction and tail prediction must keep relation direction

In this article
THE QUICK TAKE

Corrupting a head and corrupting a tail create different completion queries; an inverse relation is a modeling definition rather than an automatic endpoint swap.

Represent a typed assertion explicitly

The ogbl-wikikg2 specification defines relation-bearing triples and head-or-tail replacement for completion evaluation. Preserve the roles of every field. A graph edge without its relation identifier loses the meaning that distinguishes otherwise identical endpoint pairs. Reversing endpoints while leaving the relation unchanged can express a different and invalid assertion, so an undirected adjacency conversion is not a neutral storage optimization for this task.

Keep corruption direction attached to candidates

A head-completion query holds the relation and tail fixed, while a tail-completion query holds the head and relation fixed. Candidate arrays must therefore retain which side they replace. A generic pair-scoring adapter can accidentally send head candidates through the tail path and still produce numerically plausible scores. Test the adapter with an asymmetric relation and inspect the exact triples presented to the model before running the full evaluation.

Define inverse relations deliberately

Some embedding architectures introduce inverse relation identifiers to reuse scoring logic. That can be valid when the model and training representation define it consistently, but it is not equivalent to swapping endpoints under the original relation identifier. Record how inverse identifiers are allocated and prevent collisions with supplied relations. When restoring a checkpoint, preserve that mapping alongside entity and relation dictionaries; otherwise the same embedding row can silently acquire a different semantic role.

Keep the evaluation candidate protocol intact

The official link evaluator consumes positive and negative scores for ranking. It does not reconstruct which entity replacement produced those scores. Preserve the benchmark candidates and any prescribed filtering before evaluation. A rank among sampled alternatives is not automatically a rank among every entity in the knowledge graph. Report the actual protocol rather than equating every result labeled MRR with an identical search population and filtering policy.

Separate graph completion from factual certainty

The official knowledge-graph example shows the implementation context for this task. A successful completion score measures the benchmark relationship, not independent confirmation that a predicted assertion is universally true. The existing typed-research-graph guide and entity-identity guide provide related foundations. For a reproducible experiment, keep typed assertions, dictionary versions, corruption directions and candidate membership visible through the entire scoring pipeline.

Earn rental income from GPUs

Have idle GPUs or looking to fund AI infrastructure? Retrivium finds a rental platform, sets up the server and helps you assess income and costs with a pilot.

Explore GPU hosting
← All articles