Where can I found the offline documentation for NLTK? It's not in usr/share/doc, where I mostly find docs of Python modules. And there is no nltk-doc package that can be installed.
Okay so it definitely doesn't come with any package. However it can be built. So first:
sudo apt-get install python-epydoc
This is needed to build the documentation. Then I made this script to automate the build process for you:
#!/bin/bash
NLTK_VERSION=$(python -c 'import nltk; print nltk.__version__')
NLTK_URL=$(python -c 'import nltk; print nltk.__url__')
EPYDOC_OPTS = --name=nltk --navlink="nltk ${NLTK_VERSION}"\
--url=${NLTK_URL} --inheritance=listed --debug
# Rebuild from scratch
[[ -e ~/python-nltk-docs ]] && rm -rf ~/python-nltk-docs
mkdir ~/python-nltk-docs
epydoc ${EPYDOC_OPTS} -o ~/python-nltk-docs /usr/share/pyshared/nltk
This will drop html docs into ~/python-nltk-docs for your viewing. I basically pulled this together from their doc Makefile.
Here is what I did, get the NLTK website code from their Github. This way I could do 'search' on the API documentation also.
https://github.com/nltk/nltk.github.com
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With