Developing the Ambience Manager Skill

As always, we will be making use of the Alexa Skills Kit (ASK) Console to configure the Ambience Manager Skill:

  1. Navigate to https://developer.amazon.com/alexaand click on the Sign In button located in the top-right corner of the screen:
Figure 6.17: Alexa Skills portal
  1. After signing in, click on the Alexa Skills Kit menu item on the top-left, and from the menu, select Get Started Alexa Skills Kit:
Figure 6.18: Alexa Skills Portal – signing in
  1. On the screen that appears next, click on the Start a Skill button, located in the center of the screen:
Figure 6.19: Alexa Skills Portal – starting a skill
  1. This should land you on the ASK Console:
Figure 6.20: Alexa Skills Portal – ASK Console

Click on the Create Skill button located at the bottom of the screen.

  1. The next screen is the Create a new skill screen, which will require a SkillName to proceed further:
Figure 6.21: Naming the skill

Please name the skill Ambience Manager and click on the Next button.

  1. The next page will display the type of prebuilt interaction models that can be added to the skill:
Figure 6.22: Choosing a Custom interaction model for the skill

Click on the Select button under the Custom model to select it, and click on the Create skill button in the top-right corner of the screen.

  1. After skill creation, we will need to configure its Interaction Model via the dashboard:
Figure 6.23: Ambience Manager Skill dashboard

We will configure the Interaction Model by completing the Skill builder checklist.

  1. Select the first option, Invocation Name, under the Skill builder checklist to land on the following screen:
Figure 6.24: Providing an Invocation Name

Enter the Skill Invocation Name as ambience manager and click on the Save Model button in the top-left corner.

  1. Click on the Build tab item to end up on the Skill builder checklist, which should have the Invocation Name option marked and selected since we just completed setting it up:
Figure 6.25: Setting up Intents, Samples, and Slots after setting up Invocation Name

Now, as our Invocation Name is set up, please select the Intents, Samples, and Slots item from the checklist to land on the Add Intent screen:

Figure 6.26: Creating the One-Shot Intent

Name the intent OneShotFetchTemperatureIntent and click on the Create custom intent button.

  1. Clicking on the Create custom intent button should land you on the Sample Utterances page for the OneShotFetchTemperatureIntent intent:
Figure 6.27: Configuring the One-Shot Intent

Did you notice how we called our intent as a One Shot... intent. The One-Shot intents are different than regular intents due to the fact that One-Shot intents launch your skill and ask it to do some work (fetch some data, and so on). Please note that the naming convention of starting the name of the intent with OneShot... is not mandatory and you can name it what you like, however it is a good practice that the intent name reflects its purpose. One-Shot intents are simply a different way of launching a skill. You will also notice this difference when we write our Lambda code.

We can now add a few utterances for our model, as shown in the following screenshot:

Figure 6.28: Adding Sample Utterances for the One-Shot Intent

Please click on the Save Model button after configuring the utterances.

  1. Once you have finished setting up the utterances, select the Build tab (as seen in Figure 6.28) to land on the dashboard:
Figure 6.29: Building the Model

Finally, select the Build Model option to build the Interaction Model. The process should take a few minutes. The Build Model button on the dashboard should turn green after the build finishes successfully.

  1. After the Interaction Model has finished building, we now need to supply it with a Lambda endpoint to connect to. We will postpone this step for a little bit while we code our Lambda. But before we start configuring the Lambda, click on the Endpoint button on the dashboard shown in the preceding screenshot to navigate to the Endpoint screen:
Figure 6.30: Copying the ARN endpoint

Select AWS Lambda ARN from the given options, and copy the Skill ID from this page and save it somewhere. We will need it shortly.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.144.45.153