AI Zone Admin Forum Add your forum

NEWS: Chatbots.org survey on 3000 US and UK consumers shows it is time for chatbot integration in customer service!read more..

bot in pattern
 
 
<category><pattern><bot name="name"/> IS MY NAME</pattern>
<
template>What a coincidenceI am <bot name="name"/> too.</template>
</
category

Just came across this. Besides ‘bot’ which other elements can be used in ‘pattern’?

 

 
  [ # 1 ]

I don’t think you can do that. Where did you see it?

 

 
  [ # 2 ]

Actually, Steve, in that particular instance, you can, but only when the ATTRIBUTE is “name”.

Take a look at the second row of the table at:

http://www.alicebot.org/documentation/aiml-reference.html

You’ll see that <bot name=“name” > is legal in the pattern, but other <BOT> tag attributes aren’t allowed there.

 

 
  [ # 3 ]

So I guess then that this is ‘bot’ element is replaced during compilation?

 

 
  [ # 4 ]

I guess that would depend on the interpreter, and whether it supports multiple chatbots what might share portions of the stored AIML. In the case of Program O, which does, in fact, support multiple chatbots, it would have to be done “on the fly”.

 

 
  [ # 5 ]

I can probably use asset paths in the input patterns for that. I had been thinking about it, but never found a concrete use for it, guess I found one. It would basically translate to this:

#bot.name is my name 

really getting to the bottom of aiml this way…

 

 
  [ # 6 ]

Despite what the reference says, it doesn’t work. I just made a quick category in Mitsuku:

<category>
<
pattern><bot name="name"/> 123</pattern>

<
template>If you can read thisit works.</template>
</
category

and got this:

Human: Mitsuku 123
Mitsuku: That’s me. Why are you counting?

Which indicates that my category “Mitsuku *” was called instead of the bot name one. Just in case “Mitsuku” overrides “bot name”, I changed Mitsuku’s name to Mitsuku111, for which I have no categories, and got a match to * instead of the bot name category.

 

 
  [ # 7 ]

If the engine was able to parse the file, it probably means that there was the intention to support this, but something went wrong. It’s in the definition file so…  Bugger.

 

 
  [ # 8 ]

I agree. The category compiled fine whereas when I tried one with bot name=“age”, it came up with an error.

There’s no harm in include it in your interpreter, as it would add improved functionality. However, no AIML currently exists that will use this feature.

 

 
  [ # 9 ]

doing it now.

 

 
  login or register to react