Dustin Coates in Alexa

AWS re:Invent Day 5 Notes

Here it is, the final day of AWS re:Invent. Today had half the sessions and seemingly 10% of the attendees. Nonetheless, the one session I attended was nearly full.

Building Alexa Analytics Using AWS

This was presented by a four-pack of Nick Schwab, Franklin Lobb, Andrea Muttoni, and Max Amorde and answered the question: how can developers track the ways their users are interacting with their skills?

Small-time developers will be satisfied with services like Voice Labs or Bespoken. Developers with more popular skills will want something more custom. This isn’t so different from the way it works with websites. Small websites use Google Analytics. Fortune 500 websites have a data warehouse. The key is understanding what users are doing, and where the skill isn’t serving them.

Developers who need more information than one of the off-the-shelf services can provide, the presenters outlined a flow that combines Lambda, DynamoDB, Firehose, S3, Athena, and QuickSight. Lambda is used for the Skill and for taking the data from DynamoDB to send it to Firehose, which consolidates all of the data. The assembled data is sent to S3 for storage, then to Athena (which provides a “serverless query service” using SQL syntax) for analysis. Finally, QuickSight displays data in a visual way without having to create the queries.

Some useful information to store:

  • Request ID, which will be the primary key
  • User ID
  • API execution time (where applicable)
  • Canonical slot value, actual slot value, and whether it’s in the interaction model

Logging this is important, because you may find that a popular slot value isn’t something you support. One developer has these mismatches sent to Slack, where he can monitor and adjust his skill accordingly.

Additionally, skill developer Schwab tracks how often users come in, when they arrive, when and how many hints about skill functionality he provides, and how often he encourages users to review a skill. He found that once he started asking for reviews, he got seven times as many as he did before.

Because most hobbyist skills are hosted on AWS Lambda and integrating with DynamoDB from there is easy, there’s no reason not to track information about the skill usage.