From b6728272e84a16c9eb4c44efa7313992a35ac911 Mon Sep 17 00:00:00 2001 From: msnau Date: Tue, 25 Aug 2026 23:35:45 +0200 Subject: [PATCH] Chatbot WIP --- Chatbot | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/Chatbot b/Chatbot index dab5cb1..d8cf871 100644 --- a/Chatbot +++ b/Chatbot @@ -1,12 +1,31 @@ # -*- coding: utf-8 -*- # Kommentar Test +import random print ("Hallo! Willkommen bei MikaGPT. Was kann ich für Sie tun?") -uinput = (input("Bitte Eingabe beginnen ").lower().split()) +woerter = { + "test": "bro... dies ist ein Test", +} -while uinput: +zwoerter = ["Oh, wirklich?", "Nuh uh"] + +while True: + uinput = (input("Bitte Eingabe beginnen ").lower().split()) if "bye" in uinput: print("MikaGPT wird nun beendet.") break + randoma = set(uinput).isdisjoint(set(woerter)) + + if randoma == True: + print (random.choice(zwoerter)) + + for antworten in uinput: + if antworten in woerter: + (woerter[antworten]) + + + + # if uinput not in zwoerter: + # print (random.choice(woerter))