Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
I have often thought about trying to make a UNIX Bot using KSH (some awk). One that would learn by recording the users replies, adding it to its own, etc.
Just curious if anyone has ever done or tried anything like this? Or have any ideas on the best way to go about it, or if it is indeed doable. Whatever.
Comments?

User replies to what sort of input request ?
I could see expect with it's conditional handling of responses being helpful.

ex
File containing replies:hello:hi.howdy.hola.greetings
User inputs hello (via read[?]), the bot would look on its list and see that hello already has replies (hi.howdy...etc)
It would then then choose a word on the second part of that example (after the : )
It would then echo its reply, and wait for another response from the user. The thing is, I want to make it so the bot would learn. So after it picks one of those words and echo's it, it adds that word to the list and adds the users reply. For example say the bot says howdy, and the human replies with how are you. The line
howdy:how_are_you.
would be added to the file. So if later on someone says howdy to the bot, it then knows to use the phrase how_are_you to the user, thus mimicing typical human speech.

I picture ties to a RDBMS with weighted responses. If the computer prompts
howdy
and the user reponds "fine, thank you" 3 times and one occurance of "Doing allright" then the response mechanism should see that "fine, thank you" is more likely.

![]() |
![]() |
![]() |

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |