Knowledge graphs store facts as typed links, such as (person, born in, city). Their relation vocabularies are long-tailed: a few relation types have tens of thousands of links, and many have only dozens. Models that learn each relation's behaviour from its own links are confidently wrong on the rare ones, which is where a user most needs an honest "I don't know."
We propose a Gaussian process (GP) for link prediction in which the similarity between two relation types is not learned freely. It is computed from how the relations physically connect in the graph: how often one relation's tail entity is another's head, how often two relations share a head, and so on. A GP is a probabilistic model that places a distribution over functions and returns a predictive variance along with each prediction. Because relation similarity comes from cheap connection-pattern counts rather than from a relation's own links, a relation with twenty training links inherits covariance, and therefore both predictions and uncertainty, from structurally similar frequent relations. We make this tractable at knowledge-graph scale by placing inducing variables on a product of entity anchors and relation types. Inducing variables are a small set of summary function values the GP conditions on in place of all the data. We store their posterior mean in a low-rank tensor format.
Core Claim
The claim is narrow and testable. On large-vocabulary knowledge graphs, a scalable GP whose relation covariance is fixed by the graph's connection-motif structure will give better-calibrated and more accurate predictions on rare relations than the same GP with a freely learned relation covariance. On frequent relations it will match the free version. The new ingredient is where the inter-relational dependency comes from. Three lines of prior work each touch part of this, and none does all of it:
- Structural relation correlations without uncertainty. TACT showed that relation correlations are encoded in seven topological connection patterns (head-to-tail, tail-to-tail, head-to-head, tail-to-head, parallel, loop, none). It is deterministic and expensive, reporting roughly 9 hours on FB15k-237 v1 against 20 minutes for GraIL.
- Scalable coupled outputs with a free mixing matrix. Heterogeneous Multi-output GP Prediction couples outputs scalably, but through a freely learned mixing matrix over Euclidean inputs.
- GPs on graphs or tensors, without structural relation covariance. GGPN brings GPs into multi-relational graph networks through a relation-aware kernel approximated with random Fourier features. Its kernel is pairwise and conditioned per relation, so it never builds a relation-by-relation covariance from graph structure. Scalable Nonparametric Multiway Data Analysis puts GPs on tensor entries but splits the tensor into independent local blocks and has no notion of relation schema.
Our contribution is to turn TACT-style motif statistics into a positive semi-definite relation kernel. We compute them with sparse matrix products, not per-link subgraph extraction. We then embed that kernel in a sparse variational GP over triples.
Research Program
Kernel. A triple $(h, r, t)$ receives a latent score $f(h,r,t)$, which a Bernoulli likelihood with sampled negatives maps to link probability. The covariance is a sum over motif types:
$$k\big((h,r,t),(h',r',t')\big) = \sum_{q=1}^{Q} w_q \, k_E(\mathbf{e}_h,\mathbf{e}_{h'})\, \big[\exp(-\beta_q L_q)\big]_{r r'} \, k_E(\mathbf{e}_t,\mathbf{e}_{t'}).$$
The symbols are defined as follows:
- $Q$ is the number of motif types used (up to TACT's six non-null patterns).
- $L_q$ is the normalized Laplacian of a weighted graph over relation types. Its edge weight between $r$ and $r'$ counts motif-$q$ co-occurrences. For example, the head-to-tail count is the number of entities that are the tail of an $r$-link and the head of an $r'$-link, read off products of the sparse incidence matrices.
- $\exp(-\beta_q L_q)$ is a diffusion kernel on that relation graph with learned length $\beta_q$.
- $w_q \ge 0$ are learned weights.
- $k_E$ is an RBF kernel on learned entity embeddings $\mathbf{e}$, which play the role of latent inputs as in a GP latent-variable model.
The sum of $Q$ separable terms is not separable overall. It therefore escapes the single-coregionalization restriction noted for linear-model-of-coregionalization approaches. The relation side has only $2Q$ free parameters, so rare relations cannot overfit it.
Scalability. Each motif term is a latent process with inducing variables on $m$ entity anchors × all $R$ relations × $m$ entity anchors. We give the inducing covariance a Kronecker form and store the variational mean in tensor-train format. This is the device TT-GP used for continuous grids; we transfer it to a discrete relation mode. Per-step cost is dominated by $O(Q(m^3 + R^3))$ for the Kronecker factor inverses, plus a per-triple cost linear in tensor-train rank. For FB15k-237, with $R=237$, and the biomedical graph ogbl-biokg this is small. Motif counting is a one-off sparse computation, not TACT's per-query subgraph work.
Analysis. We will measure how predictive variance on a relation shrinks as its training links grow. The expectation is that motif-kernel variance falls faster at low counts because it borrows strength. We will also measure whether the learned $w_q$ concentrate on interpretable patterns, such as head-to-tail for compositional relations.
Baselines
Naive reference. A deterministic factorization model from the facebookresearch/kbc codebase (CP and ComplEx), with post-hoc temperature scaling fitted on validation data. This tells us whether any Bayesian machinery is needed. The reference point on FB15k-237 is TransF's reported Hits@10 of 47.2% in Knowledge Graph Embedding with Multiple Relation Projections. We expect tuned factorization models to exceed it, and we will report our own runs.
Strongest existing GP method. GGPN, because it already combines GP uncertainty with relation-aware structure. The file reports only relative gains on FB15k-237: MRR improved by 1.69% and Hits@1 by 2.65% over CompGCN. No reported absolute MRR for GGPN on FB15k-237 was found on Lacuna, so we will reimplement it and treat our own run as the reference. Beating GGPN means equal or better overall MRR, with significantly lower negative log-likelihood and expected calibration error on the rare-relation stratum.
Ensembles. A five-member deep ensemble of the best kbc model. This is the standard uncertainty competitor.
Key ablation: free-form LMC. The identical GP, with identical inducing structure and tensor-train rank, but each $\exp(-\beta_q L_q)$ replaced by a freely learned low-rank coregionalization matrix of matched rank. This isolates the proposal's ingredient.
Independent ablation. The same GP with a diagonal relation kernel, i.e. independent per-relation processes.
Fairness. All methods share splits, negative-sampling scheme, embedding dimension, a fixed GPU-hour budget, and an equal random-search budget of 30 configurations.
Why not just…?
Why not just learn the relation covariance freely, as in multi-output GPs? This is the real threat. On frequent relations, a free low-rank coregionalization matrix in the style of Heterogeneous Multi-output GP Prediction will likely match or beat a fixed structural kernel, because it has more freedom. The proposal stands only if the free matrix fails where data are scarce: a rare relation's row of the matrix is estimated from its own few links, whereas motif counts use every link touching its entities. The free-LMC ablation, stratified by relation frequency, settles this directly. If it matches the motif kernel below 50 training links, we drop the claim.
Why not just use deterministic embeddings with ensembles or temperature scaling? GGPN's comparison against CompGCN, 80.88% versus 76.47% accuracy on MUTAG, suggests Bayesian function modelling helps on noisy, sparse graphs. However, that comparison did not include ensembles, so the corpus does not rule this alternative out. Our ensemble baseline under equal compute is the test, with the emphasis on calibration for rare relations rather than headline MRR.
Why not just use similarity of pretrained relation embeddings as the relation kernel? A relation embedding for a rare relation is learned from the same few links, so it carries the same estimation noise as a free matrix. We will include this variant, a cosine kernel on kbc relation embeddings, as a third relation-kernel option in the ablation.
Why not just use TACT's relational correlation network? It captures the same motifs but is deterministic and costs hours even on small inductive splits. Our timing comparison on FB15k-237 v1 will show whether the sparse-count kernel removes that cost. TACT reports AUC-PR 98.30 on FB15k-237 v4 as its accuracy reference.
Proposed Experiments
Small-scale sanity check. On Rummel's Nation data, an exact-GP version must reach the reported MRGP AUC of 0.8556 from Multi-Relational Learning with Gaussian Processes. The tensor-train sparse version must stay close to the exact one. This verifies the approximation before scaling up.
Main transductive experiment. FB15k-237 and ogbl-biokg (via the aryopg/biokge benchmarking code). WN18RR, with only 11 relations, serves as a control where structural relation kernels should matter little. Metrics are:
- MRR and Hits@{1,10} under the standard filtered protocol;
- triple-classification negative log-likelihood and expected calibration error;
- risk–coverage curves, which measure how accuracy changes as the model is allowed to abstain on its least-confident predictions.
All metrics are reported overall and stratified into relation-frequency bins.
Decisive long-tail experiment. We select 30 frequent FB15k-237 relations and subsample their training links to 10, 20, and 50, keeping the full graph otherwise. This creates controlled rare relations with known ground truth. Success means the motif kernel beats free-form LMC, relation-embedding kernels, and ensembles on held-out NLL and calibration at 10–20 links, while staying within noise of them on the unsubsampled relations.
Robustness check. Following GGPN's concern about false edges, we inject 10% random corrupted triples. Motif counts are aggregates and should degrade gracefully. Wall-clock time and memory are reported against GGPN at matched accuracy.
References
- Topology-Aware Correlations Between Relations for Inductive Link Prediction in Knowledge Graphs
- Heterogeneous Multi-output Gaussian Process Prediction
- Multi-Relational Graph Representation Learning with Bayesian Gaussian Process Network
- Scalable Nonparametric Multiway Data Analysis
- Scalable Gaussian Processes with Billions of Inducing Inputs via Tensor Train Decomposition
- Knowledge Graph Embedding with Multiple Relation Projections
- Multi-Relational Learning with Gaussian Processes