do pip install chatterbot-corpus
Then
Make the following changes to your code
remove the following lines
bot.set_trainer(ListTrainer)
bot.set_trainer(ChatterBotCorpusTrainer)
bot.train("chatterbot.corpus.english")
Add the following
trainer = ChatterBotCorpusTrainer(bot)
trainer.train('chatterbot.corpus.english')
Remove the following
training on english dataset
for files in os.listdir('./english/'):
data=open('./english/'+files,'r').readlines()
data=open('./english/'+files,'r').readlines()
trainer.train(data)
It should work now.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
do pip install chatterbot-corpus
Then
Make the following changes to your code
remove the following lines
bot.set_trainer(ListTrainer)
bot.set_trainer(ChatterBotCorpusTrainer)
bot.train("chatterbot.corpus.english")
Add the following
trainer = ChatterBotCorpusTrainer(bot)
trainer.train('chatterbot.corpus.english')
Remove the following
training on english dataset
for files in os.listdir('./english/'):
data=open('./english/'+files,'r').readlines()
data=open('./english/'+files,'r').readlines()
trainer.train(data)
It should work now.