Need help with srai and passing star

  • 2 Replies
  • 1605 Views
*

Freddy

  • Administrator
  • **********************
  • Colossus
  • *
  • 6252
  • Mostly Harmless
Need help with srai and passing star
« on: January 30, 2013, 10:40:03 pm »
I have this code :

Code: [Select]
<?xml version="1.0" encoding="utf-8" ?>
<aiml version="1.0">

<category>
<pattern>MUSIC *</pattern>
<template><srai>MP3</srai></template>
</category>

<category>
<pattern>MP3 *</pattern>
<template>I will play <star index="1"/></template>
</category>
</aiml>

But it only partly works.

If I type 'MP3 some song' the bot will say 'I will play some song'.

I tried to use srai but I can't seem to figure out how to pass the * to the category so that this also works : 'Music some song'

Cheers   :)


*

Freddy

  • Administrator
  • **********************
  • Colossus
  • *
  • 6252
  • Mostly Harmless
Re: Need help with srai and passing star
« Reply #1 on: January 30, 2013, 10:56:38 pm »
Nevermind, found it :

Code: [Select]
<?xml version="1.0" encoding="utf-8" ?>
<aiml version="1.0">

<category>
<pattern>MUSIC *</pattern>
<template><srai>MP3 <star/></srai></template>
</category>

<category>
<pattern>MP3 *</pattern>
<template>I will play <star index="1"/></template>
</category>
</aiml>

I didn't put <star/> in the first pattern..  :idiot2:
« Last Edit: January 31, 2013, 11:20:35 am by Freddy »

*

Art

  • At the end of the game, the King and Pawn go into the same box.
  • Global Moderator
  • *******************
  • Prometheus
  • *
  • 4700
Re: Need help with srai and passing star
« Reply #2 on: February 01, 2013, 12:52:55 am »
Freddy,

You've confirmed it...you really ARE your own best friend!! ;)
In the world of AI, it's the thought that counts!

 


Spikes in neural networks
by korrelan (New Users Please Post Here)
February 22, 2018, 01:24:28 pm
Young Alpha
by LOCKSUIT (Bot Conversations)
February 22, 2018, 12:33:08 am
They Are Coming For US!
by LOCKSUIT (General Robotics Talk)
February 21, 2018, 08:27:54 pm
XKCD Comic : Self-Driving Issues
by Tyler (XKCD Comic)
February 21, 2018, 12:00:06 pm
Why we laugh. (or cry) - very funny videos included
by keghn (General AI Discussion)
February 20, 2018, 10:27:51 pm
Emergence of the universe's PURPOSE !!!!
by keghn (Future of AI)
February 19, 2018, 04:54:20 pm
XKCD Comic : 2018 CVE List
by Tyler (XKCD Comic)
February 19, 2018, 12:01:26 pm
the emergence of AI
by LOCKSUIT (Future of AI)
February 19, 2018, 05:04:07 am

Users Online

33 Guests, 1 User
Users active in past 15 minutes:
ivan.moony
[Trusty Member]

Most Online Today: 38. Most Online Ever: 208 (August 27, 2008, 09:36:30 am)

Articles