The following tutorials demonstrate Interface Agent Markup Language (IAML) authoring and development in VB.
<iaml>
<speak> Hello, World! </speak>
<expression type="smile"
/>
</iaml>
Well, this script is probably the simplest one. Remember that AIML is conform to the XML standard. It always start with the tag "<iaml>" and ends with "</iaml>". This script let the agent say "Hello, world!" and smile afterwards.
...
Dim Genie as Object
Set Genie = CreateAgent (MSAgentControl, "msagent.cfg")
ExecuteScript ("sample.aiml")
InsertScript ("<speak> I'm Genie! </speak>")
...
Before using the toolkit for IAML, you need to install Haptek and MSAgent animation package and get the toolkit library first. You can add the characters to your application interface by adding the corresponding ActiveX controls. The first two lines of the sample program declare a MS Agent character. Once you have the character created, you can use IAML APIs to control what the character is going to say and act (the rest three lines). In the sample program, Genie character is created by reading a configuration file, "msagent.cfg". The file only contains two lines of text, "name=Genie" and "engine=MSAgent", which tells that the character name is Genie and it is a MS Agent character. Then the character act according to the script file, "sample.aiml", which is shown above. After that, a line of IAML script is inserted to the end, which let the character say "I'm Genie".
For more information, see detailed specification of the language and programming interface. Or contact Jun Xiao to arrange a quick demo of how to use the toolkit.
Last modified on 9/5/2002