Skip to content

Commit

Permalink
Download chatterbot-corpus directly from GitHub
Browse files Browse the repository at this point in the history
  • Loading branch information
gunthercox committed Feb 24, 2019
1 parent c26a14d commit 92dd93d
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 5 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
![Chatterbot: Machine learning in Python](https://i.imgur.com/b3SCmGT.png)
![ChatterBot: Machine learning in Python](https://i.imgur.com/b3SCmGT.png)

# ChatterBot

Expand Down
3 changes: 2 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
chatterbot-corpus>=1.2,<1.3
git+git://github.com/gunthercox/chatterbot-corpus@master#egg=chatterbot_corpus
mathparse>=0.1,<0.2
nltk>=3.2,<4.0
pymongo>=3.3,<4.0
python-dateutil>=2.7,<2.8
sqlalchemy>=1.2,<1.3
pint>=0.8.1
pyyaml>=4.2b1,<4.3
11 changes: 10 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,16 @@
with open('README.md') as f:
LONG_DESCRIPTION = f.read()

REQUIREMENTS = []
DEPENDENCIES = []

with open('requirements.txt') as requirements:
REQUIREMENTS = requirements.readlines()
for requirement in requirements.readlines():
if requirement.startswith('git+git://'):
DEPENDENCIES.append(requirement)
else:
REQUIREMENTS.append(requirement)


setup(
name='ChatterBot',
Expand All @@ -54,6 +62,7 @@
package_dir={'chatterbot': 'chatterbot'},
include_package_data=True,
install_requires=REQUIREMENTS,
dependency_links=DEPENDENCIES,
python_requires='>=3.4, <4',
license='BSD',
zip_safe=True,
Expand Down
4 changes: 2 additions & 2 deletions tests/test_corpus.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ def test_load_corpus_hindi(self):

self.assertTrue(len(list(corpus_data)))

def test_load_corpus_indonesia(self):
data_files = corpus.list_corpus_files('chatterbot.corpus.indonesia')
def test_load_corpus_indonesian(self):
data_files = corpus.list_corpus_files('chatterbot.corpus.indonesian')
corpus_data = corpus.load_corpus(*data_files)

self.assertTrue(len(list(corpus_data)))
Expand Down

0 comments on commit 92dd93d

Please sign in to comment.