|
|
Comments and Discussions
|
|
 |

|
Nice program .. C# Version ?
|
|
|
|

|
the link to visual basic version of the code is not working.. can you let me where can i get the link
|
|
|
|

|
I have had www.madamzena.com up and running since about 1998. This chatterbot has evolved over the years and is a great source of personal joy. People visit her every day from all over the world. She is written in perl and at this point can best be described as spaghetti code. After a pass through preprocessing (spelling correction, starts with "well, .." or "so, ..", slang, lol, etc ) it goes to the first process. There are 26 question files, one for each starting letter of a question. Here is a sample from the 5,507 processing lines in the "W" file, with comments and explanations. For speed, if the first word of the question is greater than the first word of the test line then the search is done with no match. The test words are in upper case for easy reading by the programmer. WILL I<_><random><in>R#YES#OR#NO<out><in>Haven't you made a decision yet.<out><endrandom> The <_> sign separates the question from the answer. Every line must have one and only one. The program checks and logs an error if this is wrong. In this case, the question must be "WILL I", no more, no less. <random>&<endrandom> mark two or more random replies. Each reply has a <in>&<out>. The second reply is clear! The first reply (R#YES#OR#NO) is a look up of replies namely: @list_1 = ( 'yes', 'no', 'absolutely', 'I doubt it', 'probably', 'probably not', 'maybe', 'truly', 'never' ); If there is no closing punctuation, the program adds a period. WILL I WIN *<_><random><in>Do you deserve to win?<out><in>Are you a winner? <out><in>How well do you play?<out><in>Only if you play.<out><endrandom> The * is used to denote with or without more info. "WILL I WIN TONIGHT" and "WILL I WIN" are both decoded as true. A randon choice of 4 replies is returned. WILL I EVER _<_>Ever `is can_be can_seem_like` a `very really _` long time. <resub>WILL I <star1><endresub> The underbar in the question demands more input after the word EVER. \ There are two new concepts in the answer. The use of the backtick (top left above tab on keyboard) is to frame a group of random input. Words joined by an underbar are considered one entry. A lonely underbar is a blank entry. In the case above, a reply could be "Ever can seem like a long time." Note the absence of anything between "a" and "long time". The second concept is resubmit. The term <star1> equal the contents of the underbar in the question, and is sent through the whole process again. The question "WILL I EVER FALL IN LOVE" becomes "WILL I FALL IN LOVE". WILL I _ OR WILL I _<_><random><in>`R#I#AM#CERTAIN_you R#ABSO_you You` will <flip1>.<out><in>`R#I#AM#CERTAIN_you You` will <flip2>.<out><in>zna_bail<out><endrandom> R#I#AM#CERTAIN = @list_1 = ( 'Absolutely', 'Certainly', 'Clearly', 'Definitely', 'Emphatically', 'Evidently', 'I_am certain', 'I_am R#ABSO certain', 'I\'m certain', 'I_am sure', 'I\'m sure', 'Indeed', 'It is `almost _` certain', 'It is clearly true', 'It is R#ABSO true', 'It is `to_be _` expected', 'Naturally', 'Obviously', 'Of course', 'One `can may` assume that', 'Plainly', 'Positively', 'There is `no little` doubt', 'There\'s `no little` question', 'Truly', 'Undoubtedly', 'Unmistakably', 'Unquestionably', 'Without a doubt', 'Yes', 'You `can may` be sure', 'You can be R#ABSO sure', 'You can count on the fact' ); The perl language requires a "\" before the single quote if it is to be ignored. R#ABSO = @list_1 = ( 'absolutely', 'certainly', 'clearly', 'definitely', 'naturally', 'positively', 'really', 'seriously', 'surely', 'totally', 'truly' ); <flip1> processes "my" to "your", "me" to "you", "I" to "you" etc. <flip2> does the same to the second underbar. There is a large ( original ) second processor of question. If no match is found, ( or if the question is asked a second time ), it is tossed into this engine for final processing. The term zna_bail forces the question into this second engine. The tern zna_no means quit this line but continue down the file looking for a match. The question "WILL I CALL HER OR WILL I FORGET HER" could be answered "I am certain you will forget her". WILL I `GET HAVE FIND SEE WIN` A SECOND CHANCE *<_><random><in>Maybe when you are `not_expecting_it rested ready a_little_older older a_little_more_mature more_mature`.<out><in>What went wrong the first time?<out><in>Do you think you `deserve have earned` it?<out><in>R#YES#OR#NO.<out><in>What will you do differently this time?<out><in>zna_bail<out><endrandom> The backtick can be used in the question as well. "WILL I HAVE A SECOND CHANCE" get decoded. WILL I `GET HAVE FIND SEE WIN` A NEW _<_><random><in>Maybe when you are `not_expecting_it rested ready a_little_older older a_little_more_mature more_mature`.<out><in>What `went_wrong happened_to became_of` the old one?<out><in>Do you think you `deserve have earned` a new <flip1>?<out><in>R#YES#OR#NO.<out><in>What will you do differently with this one?<out><in>Tell me about the old one first.<out><endrandom> Same as above, but must have input after A NEW ... WILL I `GET HAVE FIND SEE WIN` A _<_><random><in>Maybe when you are `not_expecting_it rested ready a_little_older older a_little_more_mature more_mature`.<out><in>What would you `do give give_up offer put_out perform` for a <flip1>?<out><in>Do you think you `deserve have earned` a <flip1>?<out><in>R#YES#OR#NO.<out><in>What will you do differently with this one?<out><in>Tell me about the other ones first.<out><endrandom> WILL I `GET HAVE FIND SEE WIN` _<_><random><in>Maybe when you are `not_expecting_it rested ready a_little_older older a_little_more_mature more_mature`.<out><in>zna_bail<out><in>zna_bail<out><in>zna_bail<out><in>zna_bail<out><in>R#YES#OR#NO.<out><endrandom> WILL I L#SIMPLY _<_><resub>WILL I <star1><endresub> L# items are on the question ( left ) side and R# items are on the answer ( right ) side. L#SIMPLY = @list_1 = ( 'a bit', 'absolutely', 'accidentally', 'accidently', 'actually', 'admittedly', 'almost', 'already', 'also', 'always', 'apparently', 'appear to', 'as a matter of fact', 'assuredly', 'at last', 'at least', 'authentically', 'beginning to', 'becoming', 'beyond doubt', 'by chance', 'categorically', 'certainly', 'clearly', 'completely', 'conclusively', 'constantly', 'currently', 'damn well', 'damn', 'darn well', 'darn', 'decidedly', 'deeply', 'definitely', 'desperately', 'doubtless', 'eagerly', 'easily', 'especially', 'entirely', 'even', 'ever', 'exactly', 'extremely', 'finally', 'f***ing', 'fully', 'generally', 'genuinely', 'happen to', 'hereby', 'highly', 'honestly', 'in actuality', 'in effect', 'in fact', 'in point of fact', 'in reality', 'in truth', 'incredibly', 'indeed', 'indubitably', 'insanely', 'just', 'kinda', 'kind of', 'literally', 'merely', 'mildly', 'most of the time', 'most', 'mostly', 'much', 'narrowly', 'naturally', 'nearly', 'normally', 'now', 'obviously', 'occasionally', 'of course', 'often', 'once', 'only', 'originally', 'particularly', 'perfectly', 'personally', 'positively', 'possibly', 'potentially', 'practically', 'precisely', 'presently', 'pretty much', 'pretty well', 'pretty', 'probably', 'quite', 'rather', 'really', 'recently', 'respectfully', 'seriously', 'simply', 'somehow', 'sometimes', 'somewhat', 'some what', 'so', 'sort of', 'still', 'strongly', 'sure as hell', 'sure', 'surely', 'then', 'terribly', 'therefore', 'thoroughly', 'totally', 'truly', 'typically', 'unambiguously', 'ultimately', 'unconditionally', 'undoubtedly', 'unfortunately', 'unquestionably', 'usually', 'utterly', 'verily', 'veritably', 'very', 'way', 'well', 'wholly', 'without a doubt', 'without question' ); A case of strip it out and resubmit. ); WILL I DIE `SOON YOUNG THIS_WEEK THIS_YEAR`<_><resub>WHEN WILL I DIE<endresub> WILL I *<_><random><in>`My The` crystal `ball _` `shows says`: Ask `me _` again later.<out><in>R#YES#OR#NO.<out><in>R#ABSO.<out><in>zna_bail<out><in>zna_bail<out><endrandom> This is the giant catch all for all unresolved "WILL I ..." including just plain "WILL I".
-- modified 6-Jun-13 13:42pm.
|
|
|
|

|
very interesting!
|
|
|
|

|
the article has been updated and the broken links are all been corrected
|
|
|
|

|
would u please help with the links. the article is good but useless without the links working. please consider it asap
|
|
|
|

|
hi , if you have code of chat bot 6 to 14 , kindly send me them ,
I
modified 8-Aug-12 5:54am.
|
|
|
|

|
why does the links just show me a page that doesnt work
its like selling stuffs to me
|
|
|
|

|
looks like the hosting site for the downloads isn't there anymore.
I might have the source files some where on my backup external. If I find it I'll post it here.
|
|
|
|
|

|
Is there a significant reason?
Thanks
|
|
|
|

|
i would have have to use an Xml parser but i don't experience Xml parsers
|
|
|
|

|
Previously most of the links in the current article were not directing to the corresponding chatbot source code.
Now this problem has been completely corrected, so all the source code can accessed directly from the article itself.
|
|
|
|

|
No it's not!! All links point to ai-programming.com which does not exist!
Please update links or kindly send files for chatbot3 and up to darshandzend@gmail.com
|
|
|
|

|
Excelente article, but you should put an demo or Source code excamples.
Regards.
|
|
|
|

|
Always interesting to see how people put these things together - to see how the author treats certain issues and handles unexpected events.
C# code link seems to be broken?
|
|
|
|

|
Has anyone been able to download the c# code examples for chatterbot14 etc? I am really interested in looking at the example to see how I can implement something similar in my own project.
Thanks
|
|
|
|

|
Hi if you have code of chatbot 6 to 14 then kindly send me them. I am working on similar project. Regards!
|
|
|
|

|
Anyone got the full source code for this examples?
|
|
|
|

|
Man! Like your article...it's when I got to the end of your article and saw the prolog code...it made me want to get sick into the bucket...cos I've used it as part of my B.Sc in I.S and have argued with the dept of IT in college saying it was useless for real-world reality type of jobs - that was 7 years ago.... but otherwise a fine article! Well done!
#define STOOPID
#if STOOPID
Console.WriteLine("I'm stoopid!");
#endif
|
|
|
|

|
The article is good, but marred by many, many grammatical and spelling errors, which is a shame. It is somewhat ironic that an article that even mentions these characteristics as a way in which a judge can adjudicate a Turing contest suffers from the same flaw.
I realize that perhaps English is not the author's first language, so having a proofreader go over it before submission would have greatly enhanced the article's impact.
|
|
|
|

|
Ozbear, the problem with people like you is that you have probably never left your grammar-speaking conclave. The world is global and is not about grammar. Rather than complement the author on doing such a great job, you chose to focus on the obvious; you sound like an idiot focusing on what was obvious to others. Lousy coders are usually empty vessels....
|
|
|
|

|
The purpose of writing these articles is to impart knowledge to others. To the degree that poor grammar/spelling occurs, that transfer is impeded. What you say is partially true in that -I- can get the gist of what the author is writing. However, think of a reader for whom English is not their first language and has to employ automated and/or human translators, where misspelt words cannot be found in their dictionaries. Their job is made that much more difficult. If something is worth writing, it is worth writing well. It is mind boggling that a third party could take offense at this.
|
|
|
|

|
so what? do you want your money back or something? you're lucky you got anything at all, let alone with perfect spelling and grammar. this is free information, if you don't like it, don't take it. furthermore, if you think you can do better, then do it. have you offered to work with the author to proofread? or do you just want everything and give nothing?
|
|
|
|

|
I will address your response as follows. According to you: >> The purpose of writing these articles is to impart knowledge to others. To the degree that poor grammar/spelling occurs, that transfer is impeded. Perhaps; sometimes, the purpose might be to demonstrate one's knowledge, convince one that the subject matter is firmly grasped, etc. No one is thinking "I have to teach this subject matter and impart knowledge, so my grammar must be perfect." Your statement is a fallacy. >>What you say is partially true in that -I- can get the gist of what the author is writing. However, think of a reader for whom English is not their first language and has to employ automated and/or human translators, where misspelt words cannot be found in their dictionaries. Their job is made that much more difficult. ??? What??? This reasoning is silly. Insignificant issue for many reasons. You certainly did not use a translator. >>If something is worth writing, it is worth writing well. Did you just criticize the author, again? That the author did not do a good job because of grammatical errors? The problem is you confuse technical proficiency with grammatical smarts. The author is clearly technically proficient. I seriously doubt that you are. I will take the technical proficiency and let you have your grammatical smarts anyday. I certainly have not seen an Ozbear tutorial in this forum. >>It is mind boggling that a third party could take offense at this. This is perfectly my concern. If you want no responses to your criticisms of other creative works, do not post on this forum. Your comment was also directed at members as you refer to the author in the third person. Get a life dude....
|
|
|
|

|
Too many misspellings/grammatical errors
|
|
|
|

|
Thanks Gonzales,
I was looking for such a simple but very effective tutorial about chatbots.
This could be base for upcoming AI coders.
Thanks once again.
K.Sant.
|
|
|
|

|
The Chatbot Tutorial is now available in Visual Basic and will eventualy be made available in other languages as well (Lisp, Prolog and Pascal)
VB Chatbot Tutorial
modified on Wednesday, June 17, 2009 8:18 AM
|
|
|
|

|
That is awesome man! But... the downloads are broken. I can't download chatbot11.zip for example. 404 errors...
|
|
|
|

|
Hi... My name is Sara. I am making a chatbot as a project of Artificial Intelligence with my 2 more group members. We saw your code in C#. This is very helpful. We could find only 1st 5 chatbots links. Can you send me All 15 chatbots code in C# please? That will be a great favor. And it will help us a lot. Regards!
|
|
|
|

|
hi, i'm alejandro from argentina, very nice!!!
we need more articles like this
Dios existe pero duerme...
Sus pesadillas son nuestra existencia.
(Ernesto Sabato)
|
|
|
|

|
not even close to a resonable nlp
|
|
|
|

|
What do you mean?? . This code is only meant to be a Chatbot program, a littlebit like Eliza and other Chatbots.
The real limitation with it so far is the size of the database which is very small compare to other Chatbots
|
|
|
|

|
It's a very simple Chatbox, I agree the size of the database is very small but the understanding is definately in the right direction.
Most of the bigger chatbots do rely on having a huge knowledgebase from whcih to compare and pull sentenses from.
James Binary Warrior.
|
|
|
|
 |
|
|
General News Suggestion Question Bug Answer Joke Rant Admin
|
Tutorial on making an artificial intelligence chatbot
| Type | Article |
| Licence | CPOL |
| First Posted | 1 May 2009 |
| Views | 94,165 |
| Downloads | 0 |
| Bookmarked | 112 times |
|
|