|
View:
New views
2 Messages
—
Rating Filter:
Alert me
|
|
|
Two stars getting combined into one???I'm having trouble making sense of the AIML recursion. Is this AIML wrong?
<category> <pattern>SWAPPROPERTY * *</pattern> <template> <set name="first"><star/></set> <set name="second"><star index="2"/></set> <myprocessor action="swap"/> </template> </category> <category><pattern>SWAP * FOR *</pattern><template><srai>SWAPPROPERTY <star index="2"/> <star/></srai></template></category> <category><pattern>REVERSE ORDER OF * AND *</pattern><template><srai>SWAPPROPERTY <star index="2"/> <star/></srai></template></category> Here is the output, showing some debugging information. Note how the two stars, "first" and "second", end up being concatenated into a single string, "firstsecond". And then the second star ends up blank. [YourBot] JUDGE> swap first for second Multiplexor: responding to [swap first for second] for nbl SampleBot.... Multiplexor.getReply: responding to [swap first for second] on topic SWAPPROPERTY firstsecond for nbl SampleBot.... Multiplexor.getMatchResult: responding to [swap first for second] on topic SWAPPROPERTY firstsecond.... stars found: [first, second] Multiplexor.getMatchResult: responding to [SWAPPROPERTY firstsecond] on topic SWAPPROPERTY firstsecond.... stars found: [SWAPPROPERTY firstsecond] Multiplexor.getMatchResult: responding to [RANDOM PICKUP LINE] on topic SWAPPROPERTY firstsecond.... So, my question is, why do the two stars turn into one concatenated star? Is my AIML broken, or is this a bug? Thanks, Rascal _______________________________________________ programd mailing list programd@... http://aitools.org/mailman/listinfo/programd |
|
|
Re: Two stars getting combined into one???This probably has to do with whitespace handling, not the two turning
into a single star, though I'm not sure I follow what you're showing with the output there. What version of the code are you using, by the way? codger4110@... wrote on 05/03/2007 06:50 PM: > I'm having trouble making sense of the AIML recursion. Is this AIML wrong? > > > <category> > <pattern>SWAPPROPERTY * *</pattern> > <template> > <set name="first"><star/></set> > <set name="second"><star index="2"/></set> > <myprocessor action="swap"/> > </template> > </category> > <category><pattern>SWAP * FOR *</pattern><template><srai>SWAPPROPERTY <star index="2"/> <star/></srai></template></category> > <category><pattern>REVERSE ORDER OF * AND *</pattern><template><srai>SWAPPROPERTY <star index="2"/> <star/></srai></template></category> > > > Here is the output, showing some debugging information. Note how the two stars, > "first" and "second", end up being concatenated into a single > string, "firstsecond". And then the second star ends up blank. > > > [YourBot] JUDGE> swap first for second > Multiplexor: responding to [swap first for second] for nbl SampleBot.... > Multiplexor.getReply: responding to [swap first for second] on topic SWAPPROPERTY firstsecond > for nbl SampleBot.... > Multiplexor.getMatchResult: responding to [swap first for second] on topic SWAPPROPERTY > firstsecond.... > stars found: [first, second] > Multiplexor.getMatchResult: responding to [SWAPPROPERTY firstsecond] on topic SWAPPROPERTY firstsecond.... > stars found: [SWAPPROPERTY firstsecond] > Multiplexor.getMatchResult: responding to [RANDOM PICKUP LINE] on topic SWAPPROPERTY firstsecond.... > > > So, my question is, why do the two stars turn into one concatenated star? Is my AIML broken, or is this a bug? > > > Thanks, > Rascal > > > _______________________________________________ > programd mailing list > programd@... > http://aitools.org/mailman/listinfo/programd programd mailing list programd@... http://aitools.org/mailman/listinfo/programd |
| Free Forum Powered by Nabble | Forum Help |