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

Noise conundrum
 
 

Imagine the following exchange:

user: book off 3 days from next mon
bot: ok, that’s Monday 29th Feb to Wed 2nd Mar. Is that correct?
user: no just tuesday

The intention of the user was to change the period to a single day, next Tuesday.

The “no” is handled as an interjection (no problem with that), leaving “just tuesday” as the next sentence. But then “just” is removed as noise because it starts the sentence. That means my final sentence is merely the day name, which if the user had said that to begin with would have the intention of moving the 3 day period to start on that day, i.e. “no (from) tue”.

If the user says “no only tuesday” that I can match the “only” and perform the desired intention.


But I’m stumped as to a good way to proceed.

I don’t really want to change the livedata files, because of things like “just do it”. They seem perfectly good things to do in the vast majority of situations.

I’ve played around with changing $cs_token and using ^analyze() in a prepass topic but not wholly satisfactorily. I can detect the word “just” after the “no” and I can replace it with “only” for example. But when I reset $cs_token back to the standard default and do ^analyze() on the new string then the multiple sentence processing appears to break and only the “no” is handled. %more is true, but ^fail(SENTENCE) does go on to the next sentence as it would ordinarily do if I hadn’t done the ^analyze().

 

 

 
  [ # 1 ]

So… a bit of complexity.

You can when processing the sentence “tuesday”, detect from CS interface variable that it did do a noise-reduction transformation.  So in that case above, you want to NOT do that. Which means changing the Cstoken to not do the noise file (and auto resetting it at the end—i do a compare of the current cs token with the std for the bot and autochange it back during postprocessing).  When you removed noise-reduction, then do ^retry(SENTENCE) and it “should” now remain and you presumably will end up back at the same place.

 

 
  login or register to react