I am trying to set the name for my database in chatterbot. Here is the code:-
from chatterbot import ChatBot
from chatterbot.trainers import ListTrainer
import os
def train_bot():
chatbot = ChatBot('Bot',
storage_adapter='chatterbot.storage.SQLStorageAdapter',
databse="mydb",
trainer='chatterbot.trainers.ListTrainer')
for file in os.listdir('G:/Django Chatbot/SRC/chat_bot/data/'):
convData = open(r'G:/Django Chatbot/SRC/chat_bot/data/' + file, encoding='UTF-8').readlines()
chatbot.set_trainer(ListTrainer)
chatbot.train(convData)
print("Training completed")
train_bot()
I have referred to the documentation here. The sqlite3 database gets created with name 'db.sqlite3'. I want to change this name to be 'mydb.sqlite3' as specified in the code.
your problem is that you wrote databse
instead of database