nltk fixes

I've tested this on windows & linux and these commits fix the bugs in corpus.doctest and data.doctest, can someone test them just in case any commits break other tests, thanks.