This repository contains the implementation of WorldGraph, a graph world model for learning and predicting graph transitions at three levels:
- T1 — node level: node addition, deletion, and property change;
- T2 — edge level: edge addition, deletion, and property change;
- T3 — graph level: structural changes of local subgraphs.
WorldGraph combines a multi-granularity graph encoder, a history-aware state encoder, a transition Controller, and transition-aware reinforcement learning.
Use Python 3.10 or newer and install the dependencies with:
pip install -r requirements.txtThe processed datasets are available from the GWM-Zero Hugging Face dataset repository. Download the required .pt files and place them under data/processed/, preserving their filenames.
Run commands from the repository root. The default command trains five seeds and uses the validation split for model selection.
python main.py --task T1 --dataset trade --device cuda:0Available datasets: trade, genre, and reddit.
python main.py --task T2 --dataset un_vote --device cuda:0Available datasets: trade, un_vote, contact, and socialevo.
python main.py --task T3 --dataset flights --device cuda:0Available datasets: flights, contact, and enron.
If you find our work useful in your research, please consider citing our paper, WorldGraph: Graph-Native World Modeling. Thank you!
@misc{ding2026worldgraphgraphnativeworldmodeling,
title = {WorldGraph: Graph-Native World Modeling},
author = {Zezhong Ding and Yipeng Li and Xike Xie},
year = {2026},
eprint = {2609.34159},
archivePrefix = {arXiv},
primaryClass = {cs.LG},
url = {https://arxiv.org/abs/2609.34159}
}