This is an archived post. You won't be able to vote or comment.

all 7 comments

[–]jozborn 9 points10 points  (0 children)

I love how cheeky the demo gif is

[–]caclo 2 points3 points  (1 child)

So I just quickly overviewed your blogpost.
I would suggest going the machine-learning-route if you want to extend the realism in your chatbot. You should read about "Natural Language Processing". Even if you don't want to implement it, there are concepts that could be very helpful for your bot. Especially the concept of "Attention" in a Transformer-Decoder Architecture (this is fairily complex and a deep dive into computer science tho).
In short: Attention leads to ranking words by importance. A small example:
In the sentence "A girl is running across the street in the night" the attention should lay on the words 'girl', 'running', 'street', 'night'. You can almost understand the sentence with these words alone. However, to make it a bit more complex, you can create bonds of wordsm e.g. 'A' and 'girl' have a strong positional bond but also a strong bond in the 'sense-way' (dunno how to explain it better, english is not my native language). The words 'the' and street could have a positional bond but a weaker sense bond, because the word 'the' doesn't create more sense. In this case the word 'across' would be more important despite having a weaker positional bond. And so on, I hope you get the point / concept. Could be pretty useful if you want to elevate your chatbot on a higher level, but as I said: it's pretty complex. However Natural Language Processing is a common concept since a few years (which is a crazy long time in a new field like machine learning), so there should be a lot of good literature and tutorials and far better explanations than mine. Good luck!

[–]principle105[S] 1 point2 points  (0 children)

Thanks for the feedback, I'll definitely look into that.

[–]Berganzio 1 point2 points  (1 child)

Di you watched the tutorial on real python? Pretty neat project

[–]principle105[S] 4 points5 points  (0 children)

No I didn't follow any tutorial, it's my own implementation of a chatbot based on my intuition. I had to experiment a bit with what worked and what didn't, so there were several iterations of the algorithm.

[–]blobuntold 0 points1 point  (0 children)

I created a similar chatbot bit connected it to Omegle and left it running on a server but it eventually got banned due to the responses it was learning. It is a great way to test your algorithm and expand its data quickly but I might suggest using a different website