A PyTorch based implementation of Tree-LSTM from Kai Sheng Tai's paper Improved Semantic Representations From Tree-Structured Long Short-Term Memory Networks.
First run the script ./fetch_and_preprocess.sh
This downloads the following data:
and the following libraries:
python sentiment.py --name <name_of_log_file> --model_name <constituency|dependency> --epochs 10
We have not fully test on fine grain classification yet. Binary classification accuracy on both model are the same in original paper.
Kai Sheng Tai for the original LuaTorch implementation
Pytorch team for Python library
Riddhiman Dasgupta for his implement on sentiment relatedness https://github.com/dasguptar/treelstm.pytorch which I based on as starter code.
MIT