question

listening-for-echos avatar image
listening-for-echos asked

strict matching of slot values

I have a skill that simply needs to know if an utterance is from a specific list of custom words or not. I built an intent with a custom list containing those words. However, the intent sometimes fires with words that are not on the list. The list of words is fairly long and changes now and then, so I would very much prefer to not have to check in javascript every single time the intent is received, whether the utterance is actually from the custom list. Basically, I am looking for an intent that has strict matching of slot values. Is this not possible?
alexa skills kitsubmission testing certification
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

jjaquinta avatar image
jjaquinta answered
It is not possible using custom slots. An alternative approach is to code different intents, one for each value. Then provide utterances to map value to intents. I think will be slightly stricter. However, you have to bear in mind, when Alexa gives you a word not on your list, that it is because it doesn't have a high confidence in matching one of the words in your list. So that by restricting it to your list (by one means or another) your hit rate will go down. Effectively it will be the same as matching against your list and rejecting if it's not on the list. What several of us have resorted to is phonetic matching. (DoubleMetaphone is popular.) In Starlanes, I actually a 5 tier system of matching what Alexa recognized a person as saying to an actual value in a list. It still isn't perfect but gives a better usability than just rejecting and asking the user over and over. Oh, last suggestion. List and number the options and ask the user to respond by number. Not a great user experience either, but, again, better than asking over and over.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.