This is the official code repository for [Controllable Logical Hypothesis Generation for Abductive Reasoning in Knowledge Graphs] (ICLR 2026).
conda create -n ctrlhgen python=3.9
conda activate ctrlhgen
pip install -r requirements.txt As described in the paper, you can run the code in the following steps:
- Sampling
- Supervised training
- Reinforcement learning
bash scripts/sample/sample_full.sh- Without condition
bash scripts/train/wn-g2.sh- With condition
bash scripts/cond-train/wn-g2-pattern.shExample scripts:
bash scripts/optim/wn-g2.shFor training with multi-gpu:
bash scripts/optim/wn-g2-multi.shExample scripts:
bash scripts/test/wn-g2.shbash scripts/optim-test/wn-g2.shWelcome to cite our work!
@article{gao2025controllable, title={Controllable Logical Hypothesis Generation for Abductive Reasoning in Knowledge Graphs}, author={Gao, Yisen and Bai, Jiaxin and Zheng, Tianshi and Sun, Qingyun and Zhang, Ziwei and Li, Jianxin and Song, Yangqiu and Fu, Xingcheng}, journal={arXiv preprint arXiv:2505.20948}, year={2025} }