HomeAI & Machine LearningKnowledge Graph Embeddings: TransE vs RotatE Link Prediction

Knowledge Graph Embeddings: TransE vs RotatE Link Prediction

A toy knowledge graph of cities, countries and continents, embedded in 3D. Compare how TransE (translation) and RotatE (rotation) score and rank candidate tail entities for the same link-prediction query.

AI & Machine Learning3DAdvanced60 FPS📱 Mobile-adapted
ds-topic-71 ↗ Open standalone

A small knowledge graph of continents, countries and capital cities lives here as points in a real 3D embedding space, exactly the way production knowledge-graph-embedding systems represent entities. Two relations connect them — capital_of and part_of — and two scoring models compete to predict missing links: TransE, which represents a relation as a translation vector added to the head, and RotatE, which represents it as a rotation. Pick a head entity and a relation, switch between the two models, and watch the predicted point, the ranked candidate list and the true tail's rank change live, making visible exactly why the choice of relation operator matters for real link prediction.

⚙ Under the hood

A toy knowledge graph of cities, countries and continents embedded in 3D space, where you compare how TransE (translation) and RotatE (rotation) score and rank candidate tail entities for the same link-prediction query.

knowledge graphembeddingsTransERotatElink predictionmachine learning

3D · Three.js / WebGL renderer · 60 FPS target · runs fully client-side, no install

What did you find?

Add reproduction steps (optional)