diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a979ee7 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/venv \ No newline at end of file diff --git a/chatbot.py b/chatbot.py new file mode 100644 index 0000000..855fa3f --- /dev/null +++ b/chatbot.py @@ -0,0 +1,17 @@ +from nltk.chat.util import Chat, reflections + +pairs = [ + [ + r"(.*)nazywam się (.*)", + ["Cześć %2, jak się dzisiaj czujesz?",] + ] +] + +chatbot = Chat(pairs, reflections) + +def hello(): + print("Przedstaw się\n") + chatbot.converse() + +if __name__ == "__main__": + hello() \ No newline at end of file