Voice Applications for Alexa and Google Assistant

Book description

Voice Applications for Alexa and Google Assistant is your guide to designing, building, and implementing voice-based applications for Alexa and Google Assistant. Inside, you'll learn how to build your own "skills"—the voice app term for actions the device can perform—from scratch.



About the Technology

In 2018, an estimated 100 million voice-controlled devices were installed in homes worldwide, and the apps that control them, like Amazon Alexa and Google Assistant, are getting more powerful, with new skills being added every day. Great voice apps improve how users interact with the web, whether they’re checking the weather, asking for sports scores, or playing a game.



About the Book

Voice Applications for Alexa and Google Assistant is your guide to designing, building, and implementing voice-based applications for Alexa and Google Assistant. You’ll learn to build applications that listen to users, store information, and rely on user context, as you create a voice-powered sleep tracker from scratch. With the basics mastered, you’ll dig deeper into multiuse conversational flow and other more-advanced concepts. Smaller projects along the way reinforce your new techniques and best practices.



What's Inside

  • Building a call-and-response skill
  • Designing a voice user interface
  • Using conversational context
  • Going multimodal
  • Tips and best practices


About the Reader

Perfect for developers with intermediate JavaScript skills and basic Node.js skills. No previous experience with voice-first platforms is required.



About the Author

Dustin A. Coates is a developer who focuses on voice and conversational applications. He’s currently the voice search lead at Algolia and is also a Google Developers Expert for Assistant as well as cohost of the VUX World podcast.

We interviewed Dustin as a part of our Six Questions series. Check it out here.



Quotes
Embrace the voice revolution, and start building delightful Alexa skills using this book.
- From the foreword by Max Amordeluso, EU Lead Evangelist Alexa

An indispensable reference for voice practitioners, whether you’re new to the field or a grizzled veteran.
- John Kelvie, Bespoken

Dustin weaves together high-level concepts with super-pragmatic, in-the-trenches explanations.
- John Gillilan, bondad.fm

What separates Dustin’s approach from others is the conceptual sensitivity he brings to the hardest problems in multimodal interface and voice-activated AI.
- Lin Nie, Dataminr

Table of contents

  1. Cover
  2. Titlepage
  3. Copyright
  4. contents in brief
  5. contents
  6. foreword
  7. preface
  8. acknowledgments
  9. about this book
    1. Who should read this book
    2. How this book is organized: A roadmap
    3. About the code
    4. liveBook discussion forum
    5. about the author
    6. about the cover illustration
  10. Chapter 1: Introduction to voice first
    1. 1.1 What is voice first?
    2. 1.2 Designing for voice UIs
    3. 1.3 Anatomy of a voice command
      1. 1.3.1 Waking the voice-first device
      2. 1.3.2 Introducing natural language processing
      3. 1.3.3 How speech becomes text
      4. 1.3.4 Intents are the functions of a skill
      5. 1.3.5 Training the NLU with sample utterances
      6. 1.3.6 Plucking pertinent information from spoken text
    4. 1.4 The fulfillment code that ties it all together
    5. 1.5 Telling the device what to say
    6. Summary
  11. Chapter 2: Building a call-and-response skill on Alexa
    1. 2.1 Skill metadata
      1. 2.1.1 Interaction model
      2. 2.1.2 Invocation name
      3. 2.1.3 Intents
      4. 2.1.4 Sample utterances
      5. 2.1.5 Slots
    2. 2.2 The interaction model
      1. 2.2.1 Building the intent
      2. 2.2.2 Slots
    3. 2.3 Fulfillment
      1. 2.3.1 Hosted endpoint
      2. 2.3.2 AWS Lambda
      3. 2.3.3 Coding the fulfillment
    4. Summary
  12. Chapter 3: Designing a voice user interface
    1. 3.1 VUI fundamentals
    2. 3.2 The cooperative principle
      1. 3.2.1 Quantity
      2. 3.2.2 Quality
      3. 3.2.3 Relation
      4. 3.2.4 Manner
    3. 3.3 VUI planning
    4. 3.4 Variety
    5. Summary
  13. Chapter 4: Using entity resolution and built-in intents in Alexa skills
    1. 4.1 Alexa Skills Kit CLI
      1. 4.1.1 Creating an Alexa skill project
    2. 4.2 Entity resolution
      1. 4.2.1 Fulfillment
      2. 4.2.2 Built-in intents
      3. 4.2.3 LaunchRequest
    3. 4.3 Invoking the skill locally
    4. Summary
  14. Chapter 5 : Making a conversational Alexa skill
    1. 5.1 Creating a conversation
      1. 5.1.1 State management
      2. 5.1.2 Per-state handlers
      3. 5.1.3 Handling the unhandled
    2. 5.2 Maintaining long-term information
    3. 5.3 Putting it all together
      1. 5.3.1 New intents
      2. 5.3.2 New utterances
      3. 5.3.3 New fulfillment
      4. 5.3.4 Correcting a mistake
    4. Summary
  15. Chapter 6: VUI and conversation best practices
    1. 6.1 Conversations and context
    2. 6.2 A skill with context
      1. 6.2.1 Frame-based interactions
      2. 6.2.2 The fulfillment
      3. 6.2.3 Decaying context
    3. 6.3 Intercepting responses and requests
    4. 6.4 Unit testing
    5. Summary
  16. Chapter 7 : Using conversation tools to add meaning and usability
    1. 7.1 Discourse markers
    2. 7.2 Controlling the application’s speech with SSML
      1. 7.2.1 Breaks and pauses
      2. 7.2.2 Prosody
      3. 7.2.3 amazon:effect
      4. 7.2.4 w, say-as
      5. 7.2.5 phoneme
    3. 7.3 Embedding audio
    4. Summary
  17. Chapter 8: Directing conversation flow
    1. 8.1 Guiding user interaction
    2. 8.2 Dialog interface
      1. 8.2.1 Creating the skill
      2. 8.2.2 Setting up the dialog model
      3. 8.2.3 Slot filling
      4. 8.2.4 Intent confirmation
      5. 8.2.5 Dialog model fulfillment
    3. 8.3 Handling errors
    4. Summary
  18. Chapter 9: Building for Google Assistant
    1. 9.1 Setting up the application
    2. 9.2 Building the interaction model
      1. 9.2.1 Building an intent
      2. 9.2.2 Testing with the simulator
      3. 9.2.3 Parameters and entities
      4. 9.2.4 Adding entities
      5. 9.2.5 Using parameters in intents
    3. 9.3 Fulfillment
      1. 9.3.1 The code
      2. 9.3.2 Deployment
      3. 9.3.3 Changing the invocation name
    4. Summary
  19. Chapter 10: Going multimodal
    1. 10.1 Introducing multimodal
    2. 10.2 Multimodal in actions
      1. 10.2.1 Simple responses
      2. 10.2.2 Rich responses
      3. 10.2.3 List responses
      4. 10.2.4 Suggestion chips
    3. 10.3 Surface capabilities
    4. 10.4 Multisurface conversations
    5. Summary
  20. Chapter 11: Push interactions
    1. 11.1 Routine suggestions
      1. 11.1.1 Storing user data
      2. 11.1.2 Action suggestion for a routine
    2. 11.2 Daily updates
      1. 11.2.1 Developer control of daily updates
    3. 11.3 Push notifications
    4. 11.4 Implicit invocation
    5. Summary
  21. Chapter 12 : Building for actions on Google with the Actions SDK
    1. 12.1 Dialogflow and the Actions SDK
    2. 12.2 App planning
    3. 12.3 The action package
    4. 12.4 The fulfillment
      1. 12.4.1 Parsing input with regular expressions
      2. 12.4.2 Handling the unexpected
    5. Summary
  22. appendix A: Adding an AWS IAM profile
  23. appendix B: Connecting DynamoDB to a Lambda function
  24. Index
  25. List of Figures
  26. List of Tables
  27. List of Listings

Product information

  • Title: Voice Applications for Alexa and Google Assistant
  • Author(s): Dustin Coates
  • Release date: July 2019
  • Publisher(s): Manning Publications
  • ISBN: 9781617295317