It occurred to me that I haven't explicitly stated the process I use for creating content for my chat-bots. I have written about the process in multiple posts but in this one I'll condense all of that material.
- I decide on a topic that needs to be covered. Sometimes the topics are a matter of 'imperatives' (things the chat-bots should or must know e.g. What is the topic of Atomic's PhD?). At other times they are 'descriptives' (topics that say something about their character and personality). And on other occasions they are topics suggested or attempted by the audience.
- Pandorabots offers a service called Pandorawriter that converts dialog to AIML categories (http://bandore.pandorabots.com/botmaster/en/pandorawriter). In that on-line interface I write a 'traditional' script - each character gets a line in turn. This script always starts with Romeo delivering the topic. Usually this line is just the topic rather than a complete sentence or thought. For example, I'd start with 'sex' rather than 'Do you remember having sex?'
- The script develops over 26 lines. Each line is a single sentence - this is one of the constraints of the Pandorawriter. This is actually a very positive constraint. It does mean that I have to use some non-standard punctuation and comma splices are common and you'll see a lot of dashes in the dialogue. However, on the upside it forces a consistency, economy and brevity on the tone of their language.
- Originally I had decided on 20 lines of dialogue for each script. However, after several months of writing I found that I kept blowing through this self-imposed upper limit. It was when I was writing a file called 'swearing_option2' that I knew I had to increase the limit. In this script Atomic and Romeo play out a Rosencrantz and Guildenstern like game of 'tennis' where Romeo alphabetically lists all the body parts that Atomic no longer has. It ends with Atomic admitting defeat but Romeo adds one more shot.
Romeo - Just one more - no zygomaticus.
Atomic - Hey, I smile on the inside.
This is a '5% Gag', only five percent of the audience will get it, but those that do will really appreciate it. The zygomaticus is the cheek muscle that allows us to smile.
- The scripts are now 26 lines long. I try to use some structural device that will bring the script to a conclusion that is hinted at by the topic or the introductory remarks. Circular closure of a three-part structure. However, there are times when a character will simply have a bit of a rant - a pet peeve will be allowed out of the box.
- Once the script is written I covert it AIML. This file I save with the Atomic prefix e.g Atomic_swearing_option2.aiml. Then I delete the first line of the script and convert the file again, this time with the Romeo prefix e.g. Romeo_swearing_option2.aiml. This simple strategy is really useful. Deleting the first line changes the order of the lines in the AIML categories - pattern becomes template and vice versa. Therefore, output from Atomic becomes input for Romeo and vice versa for the entire script. The Romeo file contains an empty template tag at the end that I manually fill - usually with a bland, generic phrase. Any other editing is done in a program called TextWrangler - it's free and very good at dealing with the XML structure of AIML.
- Each file is then uploaded to the appropriate chat-bot. It only took one mistake in the uploading before I decided to strictly conform to my file naming convention that includes the chat-bot's name.
- This is when the fun begins. I start rehearsing with the chat-bots through the Flash interface. I watch the performance. Occasionally, and its happening more often the more scripts I write, the output from one bot will trigger a different topic in the other. Sometimes this is joyful serendipity - other times it's just rubbish. I go back to the AIML files, adjust the content for both halves of the script, upload again - and rehearse again.
- The final step is designed to allow Atomic to start the appropriate script from a multitude of possible inputs. Anything that contains the topic should fire the script. So ''Do you remember having sex?' and 'Do you have sex?' should fire the sex script. However, there are scripts that cover 'sex and food' and 'sex and sport' which should not be triggered by a question about sex alone. All of this is controlled by a file called 'Atomic_srai-01.aiml'. This I'll talk about in another post because it is too big a topic for here.
1 comment:
Hi Mike
My DCA work involves looking at memes (ideas) and how they got into certain feature films. (using Csikszentmihalyi, CREATIVITY, 1996, ie his idea of memes, etc)
It strikes me as an interesting thought (though possibly a nightmare to implement, and outside the scope of your remit here I am sure) - What if a program like this had a feature where the audience (user) could indicate their mirth, after each line (or punchline) was delivered.
ie A series of buttons called `GET IT?'
YES - LOL
YES - but only 50% funny
YES - but not funny
NO.
ie What this would do is enable tracking of memes, and how far they have spread in culture.
eg When they guys (Atomic/Romeo) say "Im sorry Dave Im afraid I cant do that" (for eg)
If the user gets it (knows the reference from `2001') is one thing, but if they find it amusing (in context) is another thing
Also, conversely, if they dont know the line/reference (have never seen - or heard of - HAL from 2001) then they would presumably respond: NO.
This would be a sort of measure of how culturally literate the user (audience member) was.
Or; not, too. :)
Anyway, just thought it was an interesting idea.
Anyway it all seems to work really well.
Cheers
Joe
Post a Comment