Aktionen

ChatterBot

Aus exmediawiki

https://github.com/gunthercox/ChatterBot

Vorteile

  • multilingual
  • einfach trainier- und erweiterbar

chatterbot-docs:

https://www.tutorialdocs.com/tutorial/chatterbot/simple-example.html

https://chatterbot.readthedocs.io/en/latest/setup.html

examples/howtos

https://dev.to/sahilrajput/build-your-first-chatbot-in-5-minutes--15e3

SMS:

https://chatbotslife.com/how-to-create-an-intelligent-chatbot-in-python-c655eb39d6b1

voice:

https://github.com/gunthercox/chatterbot-voice

web:

How create Chatbot in Few minutes Using Python or Flask: https://mc.ai/how-create-chatbot-in-few-minutes-using-python-or-flask/

https://www.edureka.co/blog/how-to-make-a-chatbot-in-python/

https://github.com/chamkank/flask-chatterbot

https://dev.to/sahilrajput/build-a-chatbot-using-flask-in-5-minutes-574i

with python-google-search: https://towardsdatascience.com/build-a-simple-chatbot-with-python-and-google-search-c000aa3f73f0

code-snippets:

https://www.programcreek.com/python/example/105342/chatterbot.ChatBot

training-data

https://github.com/gunthercox/chatterbot-corpus

https://github.com/gunthercox/chatterbot-corpus/tree/master/chatterbot_corpus/data/english

https://www.kaggle.com/kausr25/chatterbotenglish

https://github.com/shubham0204/DatasetArchives/blob/master/chatbotnlp.zip?raw=true
errors

OSError: [E050] Can't find model 'en'.

python -m spacy download en


text preprocessing (.yml file)

insert string on the begining of each n line

sed '0~2 s/^/string /g' < input.file`

  • 0~2 jede zweite zeile definieren
  • s zeichen ersetzen (in diesem konkreten sinne einfügen)
  • /^/ zeilenanfang definieren
  • /string/ string der eingefügt werden soll
  • /g steht für global
save it in file

sed -i'0~2 s/^/string /g' input.file


if z.b. Fragezeichen in der zeile insert string on beginning of line

sed -n '/?/{s/^/string /; p}' input.file

  • -n keine zeilen printen außer wir definieren diese (siehe p)
  • /?/ sucht die zeilen in der die regex ? auftaucht
  • s/^/string /; siehe oben
  • p print
save it in file...

sed -n '/?/{s/^/strrrr/; p}' input.file > new.file

little cheatsheets sed

https://wiki.ubuntuusers.de/sed/#Anwendungsbeispiele

https://www.cyberciti.biz/faq/bash-prepend-text-lines-to-file/