An Introduction to Using AWS and ASK to Build Voice Driven Experiences
-
Upload
amazon-web-services -
Category
Technology
-
view
2.266 -
download
0
Transcript of An Introduction to Using AWS and ASK to Build Voice Driven Experiences
![Page 1: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/1.jpg)
An Introduction to Using AWS and ASK to Build Voice Driven Experiences
DAVE ISBITSKIPRINCIPAL EVANGELIST, ALEXA AND ECHO
@TheDaveDev
![Page 2: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/2.jpg)
10:15am-‐11amAn Introduction to Using AWS and ASK to Build Voice Driven Experiences
11am-‐2:30pm Open Hack
2:45pm-‐3pm Raffle
Alexa Skills so far = ?
Dev Portal = http://developer.amazon.com/ask AWS portal = http://aws.amazon.com
DEVELOPER DAY AGENDA
![Page 3: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/3.jpg)
3
http://developer.amazon.com/askhttp://developer.amazon.com/blog
![Page 4: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/4.jpg)
What is Alexa?
![Page 5: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/5.jpg)
Alexa, Hello.
![Page 6: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/6.jpg)
Alexa platform
![Page 7: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/7.jpg)
Connected Home (CoHo) and Lighting API
![Page 8: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/8.jpg)
Alexa App
http://alexa.amazon.com
![Page 9: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/9.jpg)
Alexa Skills Kit (ASK) Overview
![Page 10: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/10.jpg)
ALEXA SKILLS KIT (ASK)https://developer.amazon.com/ask
![Page 11: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/11.jpg)
ALEXA VOICE SERVICE (AVS)https://developer.amazon.com/avs
![Page 12: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/12.jpg)
THE ALEXA FUNDhttps://developer.amazon.com/alexafund
![Page 13: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/13.jpg)
Alexa is the cloud service used by Amazon Echo
The Alexa Skills Kit allows developers to build new Skills (new voice experiences) for Echo
ALEXA SKILLS KIT
![Page 14: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/14.jpg)
Alexa Architecture
Amazon Alexa
ServiceGUI cards are rendered in the Amazon Alexa app
User audio is streamed to the service
Audio responses are rendered on-device
![Page 15: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/15.jpg)
Creating your ownALEXA SKILLSAlexa Skills have two parts:
Configuration data in Amazon Developer Portal
Hosted Service responding to user requests
![Page 16: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/16.jpg)
Alexa Skills Kit Architecture
Amazon Alexa Service
Developer’s Application
Service
Amazon’s Developer
PortalApplication, intents, sample data Developer Service URL EndPoint
Configured through portal
User intents and arguments are sent to the developer service
GUI cards are rendered in the Amazon Alexa app
User audio is streamed to the serviceAudio responses are rendered on-device
Text response and/or GUI card data is returned
![Page 17: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/17.jpg)
Sample Interactions ofALEXA SKILLSOne and done
“Alexa, start Astrology and get the Pisces horoscope.”[Horoscope Provided]
Conversation“Alexa, start Astrology”[“What’s your sign?”]“Pisces”[Horoscope Provided]
![Page 18: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/18.jpg)
DemoConfiguring a new Alexa Skill
![Page 19: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/19.jpg)
Building an Alexa SkillHOSTED SERVICE• Adheres to ASK service interface• Uses HTTP over SSL/TLS on port 443• Must be Internet-accessible• Presents a trusted certificate matching
domain name– Can use self-signed certificate for
development– Trusted certificate required for
certification
![Page 20: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/20.jpg)
Building an Alexa SkillHOSTED SERVICE• You define interactions for your Voice
App through Intent Schemas• Each intent consists of two fields. The
intent field gives the name of the intent. The slots field lists the slots associated with that intent.
• Slots can be any internal types such as AMAZON.LITERAL, AMAZON.NUMBER, AMAZON.DATE, etc. or they can be ones you create.
![Page 21: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/21.jpg)
Building an Alexa SkillHOSTED SERVICE• The mappings between intents and the
typical utterances that invoke those intents are provided in a tab-separated text document of sample utterances.
• Each possible phrase is assigned to one of the defined intents.
• GetHoroscope what is the horoscope for {pisces|Sign}
• GetHoroscope what will the horoscope for {leo|Sign} be {next tuesday|Date}
![Page 22: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/22.jpg)
The Amazon Alexa ServiceWILL POST EVENTSLaunchRequest
Maps to onLaunch() and occurs when the user launches the app without specifying what they want
IntentRequestMaps to onIntent() and occurs when when the user specifies an intent
SessionEndedRequestMaps to OnSessionEnded() and when the user ends the session
![Page 23: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/23.jpg)
Alexa ServiceExamining the JSON Requests from
![Page 24: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/24.jpg)
![Page 25: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/25.jpg)
Handling Amazon Alexa ServiceREQUESTS• You will need to handle POST requests to
your service over port 443 and parse the JSON
• You need to check the session variable to see if the user started a new session or if request is from existing one
• Requests always Include a type, requestId and timestamp
• requestId maps directly to LaunchRequest, IntentRequest and SessionEndedRequest
![Page 26: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/26.jpg)
Increasng Accuracy withCUSTOM SLOTS• Created inside Interaction Model
page once in the Developer Portal• Greaty reduces the number of
spoken utterances required• Can define as many as you need with
values line seperated• Can be combined with existing
AMAZON internal types
![Page 27: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/27.jpg)
Changing Alexa’s inflection with SSML• Alexa automatically handles normal punctuation, such as
pausing after a period, or speaking a sentence ending in a question mark as a question.
• Speech Synthesis Markup Language (SSML) is a markup language that provides a standard way to mark up text for the generation of synthetic speech.
• Tags supported include: speak, p, s, break, say-as, phoneme, and w.
![Page 28: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/28.jpg)
Existing Customer withACCOUNT LINKING• Allow your customers to link their
existing accounts with you, to Alexa. • Customers are prompted to log in to
your site using their normal credentials with webview url you provide.
• You authenticate the customer and generate an access token that uniquely identifies the customer and link the accounts.
![Page 29: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/29.jpg)
Testing Your Skill SERVICE SIMULATOR• Enabled once a Skill has been
configured in the Developer Portal• Use spoken utterances to generate
ad hoc results• Use JSON to verify requests• Combine with AWS Lambda Unit
Tests to verify both client and service side Alexa end points
![Page 30: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/30.jpg)
![Page 31: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/31.jpg)
DemoMy Colors Alexa Skill – JavaScript and Node JS
![Page 32: An Introduction to Using AWS and ASK to Build Voice Driven Experiences](https://reader031.fdocuments.in/reader031/viewer/2022030316/587404981a28ab6f1d8b5d8b/html5/thumbnails/32.jpg)
10:15am-‐11amAn Introduction to Using AWS and ASK to Build Voice Driven Experiences
11am-‐2:30pm Open Hack
2:45pm-‐3pm Raffle (5 FireTVs: 2 for Skills, 3 Random)
Alexa Skills so far = ?
Dev Portal = http://developer.amazon.com/ask AWS portal = http://aws.amazon.com
DEVELOPER DAY AGENDA