Focus on quantum-inspired representation learning and text classification.
This repository is supported by Benyou Wang, Qiuchi Li, Donghao Zhao, Chen Zhang and Amit.
- PyTorch > 1.0.0
- Tensorflow
- NLTK
- QDNN (Global Mixture)
- LocalMixtureNN (Local Mixture)
- MLLM
- SentiQDNN
- FastText
- CNN
- LSTM
- Download the data at https://www.dropbox.com/s/zpu2wx5bq54agk8/data.zip?dl=0, and put the downloaded data folder in the root directory.
- Download the Glove embeddings at http://nlp.stanford.edu/data/glove.6B.zip, and put the downloaded embeddings folder in the root directory.
- Set up a configuration file and put it into directory /config. Details about how to configurate could be referred to in /config/config_qdnn.ini.
- First, you should make it clear which network you will use, i.e. network_type.
- Second, if you are using a network utilizing sentiment lexicon as external information such as SentiQDNN, we should set strategy in configuration file to multi-task.
- Plus, you need specify other details like dataset_name, sentiment_dic_file, batch_size, lr, etc.
- Modify the configuration file you will use in run.py as
config_file = 'config/config_*.ini'
- Type in command line
python run.py
If you find our work is useful, please kindly cite our papers:
@misc{li2018quantuminspired,
title={Quantum-inspired Complex Word Embedding},
author={Qiuchi Li and Sagar Uprety and Benyou Wang and Dawei Song},
year={2018},
eprint={1805.11351},
archivePrefix={arXiv},
primaryClass={cs.CL}
}
@misc{wang2019semantic,
title={Semantic Hilbert Space for Text Representation Learning},
author={Benyou Wang and Qiuchi Li and Massimo Melucci and Dawei Song},
year={2019},
eprint={1902.09802},
archivePrefix={arXiv},
primaryClass={cs.CL}
}