Master your spelling with “Spell Master”. A simple Alexa Skill to help you practice for your spelling tests.
To allow 6 year-olds and up to study independently for their school's spelling tests using a device connected to Amazon's Alexa Voice Service (e.g. Amazon Echo).
- Recognizes more than 24,000 kid-safe words
- Edit your spelling list by adding and deleting words
- Practice your spellings with a spelling test
To use the published Spell Master skill you need to enable it from the Alexa app/website. If the link does not work you can seach for it with the search term "Spell Master".
- Create an
auth.json
file inside thesrc
folder. It should look like the below. Remember to replace the APP_ID value with your own Application Id when you have created one.
{
"SKILL_NAME": "Spell Master",
"APP_ID": "amzn1.echo-sdk-ams....",
"TABLE_NAME": "SpellMasterData"
}
- Run
npm install
inside thesrc
folder to download the Alexa Skills Kit SDK for Node.js - Create a Lambda function and Amazon Resource Name (ARN) by following Step 1 on Amazon's Node.js quick start guide for Alexa Skills
- Note: There is no need to select a blue print as suggested (see Step 1.f), you can press next and configure the trigger with Alexa Skill Kit. Once you have done this you can press next again to configure the function. Here you will have the option to select the Code entry type, select Upload a .ZIP file. You will want to .ZIP up all the files in the
src
folder. Make sure to .ZIP the files and not the directory.
- Note: There is no need to select a blue print as suggested (see Step 1.f), you can press next and configure the trigger with Alexa Skill Kit. Once you have done this you can press next again to configure the function. Here you will have the option to select the Code entry type, select Upload a .ZIP file. You will want to .ZIP up all the files in the
- Add DynamoDB support:
- Go to the AWS Console and click on DynamoDB. Make sure you are in the same region as your Lambda
- Click on CreateTable and set "SpellMasterData" as the table name and "userId" for the primary key type.
- Continue the steps with the default settings to finish the setup.
- Note: You can create the table manually as outlined or let the Alexa Skill Kit SDK do it for you by giving your Lambda function DynamoDB create table permissions.
- Extending role permissions to allow the skill to use DynamoDB (I am sure there is a better way):
- Go to the AWS Console and click on IAM, then:
- Click on Roles
- Click on the role you created. Mine was named "lambda-dynamodb-execution-role" (see Step 1.i on role creation)
- Under Inline Policies click on Create Role Policy
- Select Policy Generator then click on the Select button
- Effect should be set to Allow
- For AWS Service select Amazon DynamoDb
- For Actions select
GetItem
andPutItem
- Add your Amazon Resource Name (ARN) - you can find this on settings page of the Lambda function you created
- Click on Add Statement
- Create an Alexa Skill by following Step 2 on Amazon's Node.js quick start guide for Alexa Skills
- The Intent Schema is inside the
speechAssets
folder (speechAssets/IntentSchema.json
). - Sample Utterances are inside the
speechAssets
folder (speechAssets/SampleUtterances.txt
). - This skill has one Custom Slot Type:
LIST_OF_SPELLINGS
. This is where you can edit the words that Spell Master supports. For example if you wanted to add support for the wordshin
you would include it ass.h.i.n.
. All words in LIST_OF_SPELLINGS can be found here:speechAssets/customSlotTypes/LIST_OF_SPELLINGS
- The Intent Schema is inside the
- Test out your skill by following Step 3 on Amazon's Node.js quick start guide for Alexa Skills
- To add extra functionality edit the
index.js
file in the./src
folder.- Spell Master uses state based intent handling (thanks to the Alexa Skills Kit SDK for Node.js). This means you can set intent handlers to only work when the skill is in a specific state. Currently Spell Master supports the following states:
MENUMODE
,ADDWORDMODE
,DELETEWORDMODE
,DELETELISTMODE
,READLISTMODE
, andSPELLTESTMODE
. Descriptions of these states can be found in the source code.
- Spell Master uses state based intent handling (thanks to the Alexa Skills Kit SDK for Node.js). This means you can set intent handlers to only work when the skill is in a specific state. Currently Spell Master supports the following states:
- To edit the dialog of this skill edit the
dialog.json
file in the./src
folder. - To support more words edit the
LIST_OF_SPELLINGS
Custom Slot Type. I created the initial list of 24,000 words by combining a few of the dictionaries compiled by Dr. Phillip M. Feldman.
User: "Alexa, open Spell Master"
Spell Master: "Welcome to Spell Master. You have added 0 words to your spelling list. To get started you will need to add words to it. To do this, say, add word."
User: "Add word"
Spell Master: "Please spell the word you would like to add."
User: "C L I M B I N G"
Spell Master: "Do you want me to add the word, climbing?"
User: "Yes"
Spell Master: "Climbing, has been added. Please spell another word you would like to add or say cancel."
User: "Cancel"
Spell Master: "You have added 1 word to your spelling list. You can say, start spelling test, add word, delete word, read spelling list, or delete spelling list. What would you like to do?
User: "Start spelling test"
...
- AWS Lambda to run Alexa Skill function
- Amazon DynamoDB to store the spelling test data
- Alexa Skills Kit makes it easy to add skills to Alexa
- Alexa Voice Service helps to voice-enable any connected product
- Raspberry Pi for setting up with Alexa Voice Service (e.g. creating an Echo) so you can use as a use Alexa Skill testing tool
- Node.js for building the skill
- Alexa Skills Kit SDK for Node.js
- Intent Schema & Sample Utterances
- Custom Interaction Model Reference
- Alexa Skills Kit Voice Design Handbook
- Alexa Skills Kit Voice Design Best Practices
- Skills Kit Samples
- Awesome Amazon Echo - collection of resources
- AWS-SDK-JS
- SSML Reference
- Echosim.io if you don't have a Raspberry Pi or Echo use this for testing your Alexa Skill.
- Add support for Cards