GluonNLP relies on the recent version of MXNet. The easiest way to install MXNet is through pip. The following command installs the latest version of MXNet.

pip install --upgrade mxnet>=1.3.0


There are other pre-build MXNet packages that enable GPU supports and accelerate CPU performance, please refer to this tutorial for details. Some training scripts are recommended to run on GPUs, if you don’t have a GPU machine at hands, you may consider running on AWS.

After installing MXNet, you can install the GluonNLP toolkit by

pip install gluonnlp

Install from Master Branch

If you are interested in trying out features on master branch that hasn’t been released yet, you have the option of installing from master branch directly.

Install from GitHub

Use the following command to automatically download and install the current code on master branch:

pip install

Install from Source Code

You can also first check out the code locally using Git:

git clone
cd gluon-nlp

then use the provided to install into site-packages:

python install


You may need to use sudo in case you run into permission denied error.

Alternatively, you can set up the package with development mode, so that local changes are immediately reflected in the installed python package

python develop


The master branch may rely on MXNet nightly builds which are available on PyPI, please refer to this page for installation guide.