0

We have an intent with a custom slot called topic. The values of this slots could be for example:

Sports, Science, Cinema, TV

So our sample Utterances are like this:

{topic}
tell me about {topic}
what do you know about {topic}
i love {topic}

This works correctly if the users uses phrases like the ones in the sample utterances. But, is there a way to achieve the following?

We want the user to be able just to say anything between and after the {topic} . Something like:

{any} {topic} {any} - {what do you think about} {sports} {my friend?}

or

{any} {topic} - {i hate everything related with } {sports}

Is there a way for Alexa Skill to extract the {Topic} from any random phrase?

1 Answers1

0

There is a reason to keep User's input organized (you just increase the probability of correct slot recognition) with sample utterances. But :) some time ago I've found this topic: https://stackoverflow.com/a/53334157/2823106, actually it's a hack on Alexa but you can create the catchAll slot and try something like {catchAll} {Topic} {catchAll}. The problem I expect here is that Alexa won't recognize the Topic correctly but give it a try.

slawciu
  • 775
  • 4
  • 15
  • Does not work for me, finally i have found a workaround for the solution. It seems that with Amazon.Person allows you to catch all the utterance. Then when I have the utterance in the backend i search on the string the words that I need as the topic because all the topics are dynamic and i can set on the {locale}.json. I use Amazon.Person because the Amazon.SearchQuery doesn't allow you to have the utterance like this : {topic}. It needs to have some statics words. – David Matilla May 04 '20 at 06:41