We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 79e9a03 commit 1cddaa7Copy full SHA for 1cddaa7
chatbot.py
@@ -0,0 +1,21 @@
1
+from chatterbot import ChatBot
2
+from chatterbot.trainers import ChatterBotCorpusTrainer
3
+
4
5
+if __name__ == "__main__":
6
+ chatbot = ChatBot(
7
+ "Training example",
8
+ storage_adapter="chatterbot.storage.SQLStorageAdapter",
9
+ database_uri="sqlite:///database.sqlite3",
10
+ )
11
12
+ trainer = ChatterBotCorpusTrainer(chatbot)
13
14
+ trainer.train("chatterbot.corpus.english")
15
16
+ # ubuntu_trainer = UbuntuCorpusTrainer(chatbot)
17
+ # ubuntu_trainer.train()
18
19
+ while True:
20
+ user_input = input("> ")
21
+ print(chatbot.get_response(user_input), flush=True)
0 commit comments