>100 Views
May 18, 17
スライド概要
Introduction of Alexa Skills Kit
クラウドで働くIoTおじさん
Alexa Skills Kit AlexaDays 2017〜各地でAlexa、AI、IoTを語る 2017/5/17
Jun Ichikawa @sparkgene infrastructure engineer Favorite services: AWS IoT Amazon Alexa
What is Alexa Skills Kit (ASK)? ▸Collection of self-service APIs ▸Tools ▸Documentation ▸Code samples
What can we build with ASK? Order Foods & Drinks Check bank account Game scores Todays game Get a ride Learn Control smart home device Get latest news
Alexa Skills Types ▸Custom Skills ▸Smart Home Skills ▸Flash Briefing Skills
Custom Skills ▸design your own interaction model ▸interaction name is required ▸customer need to remember interaction name or invocation phrase ▸you can use any server to host custom skill
Flash Briefing Skills ▸only way to add contents to Alexa flash briefing ▹ Alexa, what’s new? ▸pre-recorded audio clips and text-to-speech ▸RSS feed format or JSON format
Smart Home Skills ▸built-in interaction model ▸natural utterances to control device ▹Alexa, turn on living light ▸Alexa need a grant permissions (OAuth) to retrieve device information and control device ▸You need a cloud service to manage customers smart devices ▸Skill must use AWS Lambda function
Skill Type Smart Home Skill Custom Skill Flash Briefing Skill
Custom Skill
How does custom skill work? [1] Alexa, ask weather [2] Invoke Intent with arguments Weather Skill [4] Audio response [4] display card [3] Text response (and card data)
How user invoke custom skills Alexa, ask Plan My Trip to plan a trip from Seattle to Portland on Friday. Alexa ask Plan My Trip to plan a trip from Seattle to Portland on Friday = wake word = starting phrase = Invocation name = some word = slot = connecting word = slot = connecting word = slot
Starting phrase Ask, Begin, Do, Launch, Load, Open, Play, Play the game, Resume, Run, Start, Start playing, Start playing the game, Talk to, Tell, Use But starting phrase is not required. https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/supported-phrases-tobegin-a-conversation
Invocation name ▸User say invocation name to use the skill ▸invocation name must not contain the wake words or launch phrases and connecting words. (Alexa, Amazon, Echo, ask, tell, etc.) ▸must not infringe upon the intellectual property rights of an entity or person. ▸and other... https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/choosing-the-invocationname-for-an-alexa-skill#invocation-name-requirements
Slot Slot contains a collection of word which you want to recognize. There are two type of Slot. ▸ built in type ▸ AMAZON.DATE、AMAZON.NUMBER、AMAZON.US_CITY、 AMAZON.US_FIRST_NAME、etc ▸ custom type ▹ you can create a original list. ▹ ex) ▹ slot “JAWS-UG” = KOBE, OSAKA, NAGOYA, IoT, .... https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/built-in-intent-ref/slot-typereference
Interaction Model
Sample utterance ▸ PlanMyTrip i want to visit {toCity} ▸ PlanMyTrip Plan a trip ▸ PlanMyTrip I'll go to {toCity} on {travelDate} ▸ PlanMyTrip I want to travel from {fromCity} to {toCity} on {travelDate} When users say one of these utterances, the Alexa service sends a request to your service that includes the corresponding intent.
Intent Schema { } "intents": [ { "intent": "PlanMyTrip", "slots": [ { "name": "travelDate", "type": "AMAZON.DATE" }, {"name": "toCity", "type": "AMAZON.US_CITY" }, {"name": "fromCity", "type": "AMAZON.US_CITY" } ] } ] declares the intents that can be handled by the service for a custom skill
How does Plan My Trip work? [1] Alexa, ask Plan My Trip to plan a trip from Seattle to Portland on Friday. [2] Invoke PlanMyTrip with toCity=Portland fromCity=Seattle travelDate=May 19 2017 Plan My Trip Skill [4] Audio response [3] Text response
Alexa Skill Updates
Skill Builder (Beta) and Dialog https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/ask-define-the-vui-with-gui
Skill Builder can make Dialog more easily ▸the old interaction model need to return question if required slot is not passed to your skill ▸skill builder can define question for required slot
Alexa List ▸ You can add and read the Alexa List ▹shopping list ▹to-do list https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/access-the-alexa-shoppingand-to-do-lists
Device Address information ▸ You can get device location ▹ country + zipcode ▹ country + zipcode + address https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/docs/access-the-alexa-shoppingand-to-do-lists
Start building your own skill
6 Steps to Build Your First Alexa Skill ▸ Step 1: Create your free Amazon Developer Account and name your skill ▸ Step 2: Get Space Geek from the GitHub repository ▸ Step 3: Upload code into AWS Lambda ▸ Step 4: Configure and test your code ▸ Step 5: Customize your Alexa skill ▸ Step 6: Fine-Tune and Publish Your Skill https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit/content/fact-skill-1
THANKS! You can find me at @sparkgene