Chatterbot: data error

Created on 24 Apr 2019  路  10Comments  路  Source: gunthercox/ChatterBot

error
this is the error i got every time i run it.
i don't know what to do.please tell me what to do.

All 10 comments

pip install chatterbot-corpus

This will install the corpus which is a separate package.

solve
thank you very much for your help

problem
problem2
what should i do now.please help me

by the way i fix that problem.sorry for that. now i got a new problem.i don't know how to fix this one.
problem
please help me with this problem.

bot.train(data)
should be
trainer.train(data)

after trainer.train(data) this shows
problem

Tell me something.I am giving you the file. Tell me where i did wrong.
chatbot.zip
Please help.I need your help fast.Please do something.

Hello @sadmansad2003 ,

Just realized what you did here.
Please check it in the docs.

You don't have to read the file manually, let the trainer do that for you.

replace this part:

for files in os.listdir('data/english/'):
 data = open('data/english/' + files , 'r').readlines()
 trainer.train(data)

With this:

trainer.train(
    "./data/english/"
)

and it should be fine. :)

@Orfeous thanks you very much.my problem is solve.

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

Was this page helpful?
0 / 5 - 0 ratings