sentence embedding by Smooth Inverse Frequency weighting scheme
Python
1,087
22 commits
updated Jul 23, 2019
This is the code for the paper "A Simple but Tough-to-Beat Baseline for Sentence Embeddings".
The code is written in python and requires numpy, scipy, pickle, sklearn, theano and the lasagne library. Some functions/classes are based on the code of John Wieting for the paper "Towards Universal Paraphrastic Sentence Embeddings" (Thanks John!). The example data sets are also preprocessed using the code there.
To install all dependencies virtualenv is suggested:
$ virtualenv .env
$ . .env/bin/activate
$ pip install -r requirements.txt
To get started, cd into the directory examples/ and run demo.sh. It downloads the pretrained GloVe word embeddings, and then runs the scripts:
Check these files to see the options.
The code is separated into the following parts:
For technical details and full experimental results, see the paper.
@article{arora2017asimple,
author = {Sanjeev Arora and Yingyu Liang and Tengyu Ma},
title = {A Simple but Tough-to-Beat Baseline for Sentence Embeddings},
booktitle = {International Conference on Learning Representations},
year = {2017}
}
114 followers · starred Jul 2019
1,449 followers · starred Jan 2018
388 followers · starred Dec 2017
65 followers · starred Mar 2020
sentence embedding by Smooth Inverse Frequency weighting scheme
Python
1,087
22 commits
updated Jul 23, 2019
This is the code for the paper "A Simple but Tough-to-Beat Baseline for Sentence Embeddings".
The code is written in python and requires numpy, scipy, pickle, sklearn, theano and the lasagne library. Some functions/classes are based on the code of John Wieting for the paper "Towards Universal Paraphrastic Sentence Embeddings" (Thanks John!). The example data sets are also preprocessed using the code there.
To install all dependencies virtualenv is suggested:
$ virtualenv .env
$ . .env/bin/activate
$ pip install -r requirements.txt
To get started, cd into the directory examples/ and run demo.sh. It downloads the pretrained GloVe word embeddings, and then runs the scripts:
Check these files to see the options.
The code is separated into the following parts:
For technical details and full experimental results, see the paper.
@article{arora2017asimple,
author = {Sanjeev Arora and Yingyu Liang and Tengyu Ma},
title = {A Simple but Tough-to-Beat Baseline for Sentence Embeddings},
booktitle = {International Conference on Learning Representations},
year = {2017}
}
114 followers · starred Jul 2019
1,449 followers · starred Jan 2018
388 followers · starred Dec 2017
65 followers · starred Mar 2020