Giter VIP home page Giter VIP logo

tkgelib's Introduction

ECEformer

Transformer-based Reasoning for Learning Evolutionary Chain of Events on Temporal Knowledge Graph

ECEformer is a novel Transformer-based reasoning model for TKG to learn the Evolutionary Chain of Events. It will appear in SIGIR 2024 (arXiv version).

Installation

The repo requires python>=3.7, anaconda and a new env is recommended.

conda create -n eceformer python=3.7 -y # optional
conda activate eceformer # optional
git clone [email protected]:seeyourmind/TKGElib.git
cd ECEformer
pip install -e .

Data

First download the standard benchmark datasets. The Data folder can be downloaded from GDELT & ICEWS14/05-15, ICEWS18, YAGO11k & WikiData12k. Then process the dataset using the commands below.

cd data
# for GDELT/ICEWS14/ICEWS05-15/ICEWS18
# e.g. python preprocess.py icews14
python preprocess.py $dataset_name
# for YAGO11k and WikiData12k
python preprocess_intravel.py $dataset_name

Training

Configurations for the experiments are in the /config folder.

python -m kge start config/gdelt-best.yaml

The training process uses DataParallel in all visible GPUs by default, which can be overrode by appending --job.device cpu to the command above.

Evaluation

You can evaluate the trained models on dev/test set using the following commands.

python -m kge eval <saved_dir>
python -m kge test <saved_dir>

Acknowledgment

Thanks LibKGE and HittER for providing the preprocessing scripts and the base frameworks.

Citation

@inproceedings{fang-sigir-2024-eceformer,
    title = "Temporal Knowledge Graph Completion, Context Information Mining, Link Prediction, Evolutionary Chain of Event",
    author = "Fang, Zhiyu and Lei, Shuai-Long and Zhu, Xiaobin and Yang, Chun and Zhang, Shi-Xue and Yin, Xu-Cheng and Qin, Jingyan",
    booktitle = "Proceedings of The 47th International ACM SIGIR Conference",
    year = "2024"
}

tkgelib's People

Contributors

seeyourmind avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.