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..

Using ^match
 
 

I’m confused by the documentation on how to use match.

I want it to match in the control script when I get input with the words you, your or yourself.

So I have this line in ~control:

if (match(” [you your yourself]”)) { ^repeat() [ok] Talk about yourself not me. }
and everything else in an else block.

But in the trace I can see that match is failing when i type “you”.

So what am I doing wrong?

 

 
  [ # 1 ]

1) you didnt separate each token with a space…..  CS normally gets this data from a fact which has been compiled as a pattern.

I am modifying chatscript to
1) compile your input on the fly
2) accept you naming a rule whose pattern it will use

This should be released later tonight along with better ^match documentation

 

 
  login or register to react
‹‹ Editing and saving facts      Building a DLL ››