We are excited to announce Skill Flow Builder (SFB) 2.0, with support for ASK CLI v2 CloudFormation templates and AWS Lambda layers to speed up skill deployments. Over the past year, skills such as Cursed Painting, Defeat the Future, Survive the Gobi Desert, The Sims Stories, and MyCrush were built using SFB. One thing we’ve learned is just how much developers are willing to push the boundaries of our tools to deliver experiences that delight customers. Skill Flow Builder is now available as an open source project on GitHub, giving you full visibility into the inner workings of the framework and tools and the ability to extend them for your skill. Learn more.
Skill Flow Builder was created to help designers, writers, and developers collaborate easily and build great skills. The SFB toolchain includes an editor application for quickly iterating on your skill by writing scenes and testing them with the voice preview functionality, as well as a CLI application to make it easy for you to build and deploy skills and simulate them locally for debugging. Both the editor and CLI use the same file format and run the same SFB simulation logic.
The source code for SFB components is now available on Github, allowing you to extend the framework and tools to fit your needs. For the first time, you can add your own modifications to the editor and extend the CLI to provide specialized tools using SFB. For example, Doppio Games added extensions for APL for Audio and Alexa Web API for Games. In the repository, you can find all the latest documentation on how to use, build, and modify the SFB tools.
Skill Flow Builder now requires ASK CLI v2, so you can take advantage of all the features and bug fixes available in the latest updates to the ASK CLI. If you have already deployed a skill using SFB, the SFB CLI can automatically upgrade your project to be compatible with ASK CLI v2. Check out the migration guide in the documentation available on GitHub for more information. Note that you can link your AWS account via the ASK CLI, and the ASK CLI handles provisioning the resources into your AWS account.
A new feature available in ASK CLI v2 is the ability to deploy your skill’s infrastructure using AWS CloudFormation, which simplifies the infrastructure management for the resources and endpoints powering your Alexa skill. When you initially build a new SFB story, the CLI will generate a CloudFormation template for you, and by default this template will deploy an S3 bucket and a DynamoDB table with the necessary IAM permissions. This helps you skip a lot of setup steps you’d normally need to go through the first time you deployed your skill with SFB. For those who use SFB to deploy skills in multiple stages and locales, you can also maintain separate templates for each stage and locale combination. This allows you to share resources between stages by utilizing the configuration overrides in your project’s abcConfig.json file, or to deploy separate copies of each resource, depending on your skill’s requirements.
You can still choose to deploy your story using ASK CLI’s Lambda deployer, which will deploy both the skill metadata and Lambda back-end in the same way as before. Note that several additional resources such as IAM permissions and the skill’s S3 bucket will require manual setup. SFB projects that upgrade from ASK CLI v1 to v2 will use the Lambda deployer, so you don’t have to worry about modifying your existing infrastructure.
For example, below is a sample CloudFormation template containing the definition for the log group, DynamoDB table (with a default provisioned capacity), and S3 bucket:
Whether you use the CloudFormation or Lambda deployer to manage your skill, the SFB v2 update gives you the option to use AWS Lambda layers to speed up your deployments. By enabling the ‘use-lambda-layer’ setting in your story’s abcConfig.json file, the SFB CLI will deploy the node_modules directory in the code folder of your project as a Lambda layer, which it will then attach to your Lambda. What makes this especially helpful is that SFB will only deploy a new version of the Lambda layer if the contents of your node_modules directory have changed. For projects with a large number of dependencies, this can lead to significant increases in deployment speed.
We can’t wait to see what you do with SFB now that the full power of the framework has been unlocked, and we invite you to submit an issue or pull request with your own contributions. Learn more.