Skip to content

Commit

Permalink
Merge branch 'develop' into Update_Vader_Rules
Browse files Browse the repository at this point in the history
  • Loading branch information
alvations authored Aug 20, 2019
2 parents c52e477 + 6028f2c commit 403d9f1
Show file tree
Hide file tree
Showing 286 changed files with 14,630 additions and 14,385 deletions.
9 changes: 9 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -47,3 +47,12 @@ web/api/*.rst

# pyenv files
.python-version

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ matrix:
# - python: '2.7'
# env: TOXENV="flake8"

- python: '2.7'
env: TOXENV="py-travis"
# - python: '2.7'
# env: TOXENV="py-travis"

- python: '3.5'
env: TOXENV="py-travis"
Expand Down
12 changes: 12 additions & 0 deletions AUTHORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@
- Helder
- Michael Heilman
- Ofer Helman
- Christopher Hench
- Bruce Hill
- Amy Holland
- Kristy Hollingshead
Expand Down Expand Up @@ -236,16 +237,27 @@
- Anlan Du
- Pulkit Maloo <https://github.com/pulkitmaloo>
- Brandon M. Burroughs <https://github.com/brandonmburroughs>
- John Stewart <https://github.com/free-variation>
- Iaroslav Tymchenko <https://github.com/myproblemchild>
- Aleš Tamchyna
- Tim Gianitsos <https://github.com/timgianitsos>
- Philippe Partarrieu <https://github.com/ppartarr>
- Andrew Owen Martin
- Adrian Ellis <https://github.com/adrianjellis>
- Nat Quayle Nelson <https://github.com/nqnstudios>
- Yanpeng Zhao <https://github.com/zhaoyanpeng>
- Matan Rak <https://github.com/matanrak>
- Nick Ulle <https://github.com/nick-ulle>
- Uday Krishna <https://github.com/udaykrishna>
- Osman Zubair <https://github.com/okz12>
- Viresh Gupta <https://github.com/virresh>
- Ondřej Cífka <https://github.com/cifkao>
- Iris X. Zhou <https://github.com/irisxzhou>
- Devashish Lal <https://github.com/BLaZeKiLL>
- Gerhard Kremer <https://github.com/GerhardKa>
- Nicolas Darr <https://github.com/ndarr>
- Hervé Nicol <https://github.com/hervenicol>


## Others whose work we've taken and included in NLTK, but who didn't directly contribute it:
### Contributors to the Porter Stemmer
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ NLTK uses [Travis](https://travis-ci.org/nltk/nltk/) for continuous integration.
The [`.travis.yml`](https://github.com/nltk/nltk/blob/travis/.travis.yml) file configures the server:

- `matrix: include:` section
- tests against supported Python versions (2.7, 3.5 and 3.6)
- tests against supported Python versions (3.5, 3.6, 3.7)
- all python versions run the `py-travis` tox test environment in the [`tox.ini`](https://github.com/nltk/nltk/blob/travis/tox.ini#L105) file
- tests against Python 3.6 for third-party tools APIs

Expand Down
34 changes: 34 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,37 @@
Version 3.5 2019-08-07
* drop support for Python 2
* minor bug fixes and clean ups

Thanks to the following contributors to 3.5:
Nicolas Darr, Gerhard Kremer, Liling Tan

Version 3.4.4 2019-07-04
* fix bug in plot function (probability.py)
* add improved PanLex Swadesh corpus reader

Thanks to the following contributors to 3.4.4:
Devashish Lal, Liling Tan

Version 3.4.3 2019-06-07

* add Text.generate()
* add QuadgramAssocMeasures
* add SSP to tokenizers
* return confidence of best tag from AveragedPerceptron
* make plot methods return Axes objects
* don't require list arguments to PositiveNaiveBayesClassifier.train
* fix Tree classes to work with native Python copy library
* fix inconsistency for NomBank
* fix random seeding in LanguageModel.generate
* fix ConditionalFreqDist mutation on tabulate/plot call
* fix broken links in documentation
* fix misc Wordnet issues
* update installation instructions

Thanks to the following contributors to 3.4.3:
alvations, Bharat123rox, cifkao, drewmiller, free-variation, henchc
irisxzhou, nick-ulle, ppartarr, simonepri, yigitsever, zhaoyanpeng

Version 3.4.1 2019-04-17

* add chomsky_normal_form for CFGs
Expand Down
2 changes: 1 addition & 1 deletion nltk/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.4.1
3.5
87 changes: 43 additions & 44 deletions nltk/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
Natural Language Processing with Python. O'Reilly Media Inc.
http://nltk.org/book
"""
from __future__ import print_function, absolute_import

import os

Expand All @@ -27,16 +26,16 @@
# in the file VERSION.
try:
# If a VERSION file exists, use it!
version_file = os.path.join(os.path.dirname(__file__), 'VERSION')
with open(version_file, 'r') as infile:
version_file = os.path.join(os.path.dirname(__file__), "VERSION")
with open(version_file, "r") as infile:
__version__ = infile.read().strip()
except NameError:
__version__ = 'unknown (running code interactively?)'
__version__ = "unknown (running code interactively?)"
except IOError as ex:
__version__ = "unknown (%s)" % ex

if __doc__ is not None: # fix for the ``python -OO``
__doc__ += '\n@version: ' + __version__
__doc__ += "\n@version: " + __version__


# Copyright notice
Expand All @@ -53,18 +52,18 @@
The Natural Language Toolkit (NLTK) is a Python package for
natural language processing. NLTK requires Python 2.6 or higher."""
__keywords__ = [
'NLP',
'CL',
'natural language processing',
'computational linguistics',
'parsing',
'tagging',
'tokenizing',
'syntax',
'linguistics',
'language',
'natural language',
'text analytics',
"NLP",
"CL",
"natural language processing",
"computational linguistics",
"parsing",
"tagging",
"tokenizing",
"syntax",
"linguistics",
"language",
"natural language",
"text analytics",
]
__url__ = "http://nltk.org/"

Expand All @@ -76,24 +75,24 @@

# "Trove" classifiers for Python Package Index.
__classifiers__ = [
'Development Status :: 5 - Production/Stable',
'Intended Audience :: Developers',
'Intended Audience :: Education',
'Intended Audience :: Information Technology',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Scientific/Engineering',
'Topic :: Scientific/Engineering :: Artificial Intelligence',
'Topic :: Scientific/Engineering :: Human Machine Interfaces',
'Topic :: Scientific/Engineering :: Information Analysis',
'Topic :: Text Processing',
'Topic :: Text Processing :: Filters',
'Topic :: Text Processing :: General',
'Topic :: Text Processing :: Indexing',
'Topic :: Text Processing :: Linguistic',
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Intended Audience :: Education",
"Intended Audience :: Information Technology",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: Apache Software License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Topic :: Scientific/Engineering",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Scientific/Engineering :: Human Machine Interfaces",
"Topic :: Scientific/Engineering :: Information Analysis",
"Topic :: Text Processing",
"Topic :: Text Processing :: Filters",
"Topic :: Text Processing :: General",
"Topic :: Text Processing :: Indexing",
"Topic :: Text Processing :: Linguistic",
]

from nltk.internals import config_java
Expand All @@ -107,16 +106,16 @@
# Override missing methods on environments where it cannot be used like GAE.
import subprocess

if not hasattr(subprocess, 'PIPE'):
if not hasattr(subprocess, "PIPE"):

def _fake_PIPE(*args, **kwargs):
raise NotImplementedError('subprocess.PIPE is not supported.')
raise NotImplementedError("subprocess.PIPE is not supported.")

subprocess.PIPE = _fake_PIPE
if not hasattr(subprocess, 'Popen'):
if not hasattr(subprocess, "Popen"):

def _fake_Popen(*args, **kwargs):
raise NotImplementedError('subprocess.Popen is not supported.')
raise NotImplementedError("subprocess.Popen is not supported.")

subprocess.Popen = _fake_Popen

Expand Down Expand Up @@ -158,11 +157,11 @@ def _fake_Popen(*args, **kwargs):

from nltk import lazyimport

app = lazyimport.LazyModule('nltk.app', locals(), globals())
chat = lazyimport.LazyModule('nltk.chat', locals(), globals())
corpus = lazyimport.LazyModule('nltk.corpus', locals(), globals())
draw = lazyimport.LazyModule('nltk.draw', locals(), globals())
toolbox = lazyimport.LazyModule('nltk.toolbox', locals(), globals())
app = lazyimport.LazyModule("nltk.app", locals(), globals())
chat = lazyimport.LazyModule("nltk.chat", locals(), globals())
corpus = lazyimport.LazyModule("nltk.corpus", locals(), globals())
draw = lazyimport.LazyModule("nltk.draw", locals(), globals())
toolbox = lazyimport.LazyModule("nltk.toolbox", locals(), globals())

# Optional loading

Expand Down
Loading

0 comments on commit 403d9f1

Please sign in to comment.