From: Toby D. <tj...@sf...> - 2005-05-15 03:49:32
|
Yes, that's a good point. A *very* intelligent chatbot might talk as slowly as a human. Toby On 5/13/05 8:50 PM, "Daryl Van Humbeck" <dva...@sf...> wrote: > Not to mention a delay so they're not hogging bandwidth, etc. > You also want to be able to follow their conversation, not have this > whole long list of stuff they've said to read. > > Daryl. > > Toby Donaldson wrote: > >> Good point. At least one of the chabots must be able to "take the >> initiative" and start the conversation. The simplest way is probably just to >> have it send a "hello" message as soon as it begins the conversation. >> >> Toby >> >> >> On 5/13/05 3:42 PM, "Alex Tsai" <caf...@gm...> wrote: >> >> >> >>> Hi everyone, >>> >>> This chatbot looks good for an early stage - I'm trying to remember >>> all that stuff about the Smack library from first year, but I think I >>> know what it's doing. To get two chatbots talking to each other, >>> there would have to be some external input first, wouldn't there? >>> >>> -Alex >>> >>> On 5/13/05, Toby Donaldson <tj...@sf...> wrote: >>> >>> >>>> Thanks Daryl, >>>> >>>> I was accidentally only looking in the csimage package. >>>> >>>> Could you make two or more chatbots, and have them talk to each other? >>>> >>>> Also, can you make a non-Jabber interface for easily testing the chatbots? >>>> It shouldn't be too hard. >>>> >>>> The important thing is to make sure that the design of the chatbot is >>>> well-done, so that you can just use the same chatbot in the Jabber >>>> interface >>>> or the non-jabber interface. Also, the chabot interface should not assume >>>> it >>>> is talking to a human or another chabot ... It should view the incoming >>>> messages simply as strings from some unknown source. Of course, a >>>> particular >>>> chatbot might be designed to work just with people, but those details >>>> should >>>> go into the chabot, not into the chatbot interface. >>>> >>>> Toby >>>> >>>> >>>> On 5/13/05 11:54 AM, "Daryl Van Humbeck" <dva...@sf...> wrote: >>>> >>>> >>>> >>>>> It should be under csjava.chatbot.*, though if you're viewing the CVS >>>>> tree through SourceForge's viewer, it's csjava.csjava.chatbot.*. >>>>> There are three files, MessageListener.java, JabberBotFramework.java, & >>>>> JabberBotTest.java. >>>>> The version numbers (if you need them) are 1.3, 1.2, & 1.1, respectively. >>>>> >>>>> I don't think that changing it from threaded to event-listening would be >>>>> too hard, I'd just have to change it a little bit. >>>>> >>>>> I noticed I also need to add some more JavaDoc comments to indicate what >>>>> certain methods do. >>>>> I should be updating it some soon. >>>>> >>>>> The demo I have does exactly what you suggested, though I think I might >>>>> be able to make it a little more interesting by sending something like >>>>> "You sent this:", then whatever they sent. >>>>> >>>>> Suggestions as to what it should do would be appreciated, although I >>>>> don't have much experience with text-based user interaction. >>>>> >>>>> Daryl. >>>>> >>>>> Toby Donaldson wrote: >>>>> >>>>> >>>>> >>>>>> Daryl, >>>>>> >>>>>> I just updated from the CVS tree, and I don't see the Jabber code. >>>>>> Where should I look for it? >>>>>> >>>>>> I think it's probably simpler to use events instead of threads for the >>>>>> asynchronous chatting, if you know what I mean. Treat the messages >>>>>> that come from the Jabber server like events. The Smack library should >>>>>> have support for this. >>>>>> >>>>>> Also, I've been chatting with a Surrey high school IT teacher about >>>>>> running a Turing Test contest using Jabber, and if a demo is ready I'd >>>>>> like to let him try it (i.e. at least chat to it). >>>>>> >>>>>> Toby >>>>>> >>>>>> Daryl Van Humbeck wrote: >>>>>> >>>>>> >>>>>> >>>>>>> Hi, all! >>>>>>> >>>>>>> The Jabber chatbot framework is now at a state of some usefulness, >>>>>>> you can log-in to a server, listen for messages and send messages. >>>>>>> >>>>>>> It uses Jivesoft's Smack toolkit (which made the framework code >>>>>>> _much_ smaller), so you'll need to download it and point the projects >>>>>>> classpath to two of the files, smack.jar and smackx.jar, in order to >>>>>>> use the program. >>>>>>> >>>>>>> Just so you know, the test program logs into jabber.org, so if only >>>>>>> one person uses the bot unaltered, it will log into jabber.org with >>>>>>> the username "csjavaChatBot," and everyone can chat with it. >>>>>>> >>>>>>> I probably shouldn't have used threads to listen for messages, but I >>>>>>> hadn't been sure of how it works, so I'll probably change it later. >>>>>>> >>>>>>> To log into a server, just create a new instance of >>>>>>> JabberBotFramework, using the host name, username, and password (and >>>>>>> optionally, port) that you want to use. >>>>>>> The constructor will throw an org.jivesoft.smack.XMPPException if a >>>>>>> problem occurrs, so you need to catch it. >>>>>>> >>>>>>> For examples, look at the file JabberBotTest.java in the same package >>>>>>> as the JabberBotFramework, csjava.chatbot.*. >>>>>>> >>>>>>> To send a message, you just call .sendMessage(msg, to), where msg is >>>>>>> the String message to send, and to is the username to send it to. >>>>>>> >>>>>>> To listen for messages, add a MessageListener to your copy of the >>>>>>> JabberBotFramework with .addMessageListener(messageListener). >>>>>>> >>>>>>> That's basically it. If you want more functionality (it currently >>>>>>> only supports text messages), please post saying so. >>>>>>> Though I'm not sure how to recieve HTML, etc. messages. >>>>>>> >>>>>>> Anyway, here it is. >>>>>>> >>>>>>> Daryl. >>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>> >>>>>> >>>>> >>>>> >>>> -- >>>> Dr. Toby Donaldson >>>> School of Computing Science >>>> Simon Fraser University >>>> >>>> >>>> ------------------------------------------------------- >>>> This SF.Net email is sponsored by Oracle Space Sweepstakes >>>> Want to be the first software developer in space? >>>> Enter now for the Oracle Space Sweepstakes! >>>> http://ads.osdn.com/?ad_id=7393&alloc_id=16281&op=click >>>> _______________________________________________ >>>> csjava-developer mailing list >>>> csj...@li... >>>> https://lists.sourceforge.net/lists/listinfo/csjava-developer >>>> >>>> >>>> >>> >>> >> >> >> > > -- Dr. Toby Donaldson School of Computing Science Simon Fraser University |