0
votes

I am making an alexa skill to get some information about a list of hotels. I have one intent with four slots (customer's name, hotel's name, arrival date, and departure date) and they all are needed. As hotel's name I have four values (with two or three synonyms each). I don't care about the exact name of the hotel but if the user gives a different value than these four I would like alexa to ask again for the hotel's name.

I have tried with "Is this slot required to fulfill the intent? - YES", "Does this slot require confirmation? - NO" (because I do not want four confirmation) and "Does this intent require confirmation? - YES" to ask at the end for a confirmation of the four data.

I generate the aws-lambda code with https://s3.amazonaws.com/webappvui/skillcode/v2/index.html

How can I reprompt a question almost infenitely until the user gives a correct hotel's name?. Now the hotel's name can be anything and I know how to ask for it at the end, in the confirmation message, but I want to know that the information is uncorrect before to ask the user.

Thanks

2

2 Answers

1
votes

As you mention you need the

Is this slot required to fulfill the intent? - YES

But you are missing the configuration in the Validations section

enter image description here


There is an option to create a validation rule

enter image description here


enter image description here


If you have properly defined your slots then the rule to accept the slots values and synonyms should solve your problem.

There you must also write how should alexa ask again for the slot if the answer was not accepted by the rule.

0
votes

A couple of ways to solve this scenario. Depending on your use case.

A. Turn on Auto Delegate in developer console Turn on Auto Delegate in developer console This would let Alexa automatically determine and complete each step of the dialog.

Then on your intent, you can edit the dialog to make the slot as required. slot required

B. Another way is to handle the dialog management in your code. Using Elicitslot directive

http://ask-sdk-node-typedoc.s3-website-us-east-1.amazonaws.com/classes/responsebuilder.html#addelicitslotdirective