Generate expanded Amazon Alexa utterances from template strings to improve voice recognition coverage.
Alexa Utterances is a Node.js library that generates expanded sample utterances for Amazon Alexa skills from template strings. It solves the tedious problem of manually writing hundreds of voice command variations by allowing developers to define concise templates that auto-expand into comprehensive utterance lists, improving a skill's voice recognition coverage.
Alexa skill developers and teams building voice applications who need to efficiently define large sets of sample utterances for their interaction models.
Developers choose Alexa Utterances because it drastically reduces the manual effort of utterance creation with a clean, expressive template syntax, supports all Alexa slot types, and integrates seamlessly with custom slot definitions, making it a standard tool in the Alexa JS ecosystem.
generate expanded utterances for Amazon Alexa from a template string
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Uses a concise syntax with pipes and braces to define utterance variations, such as '{what is the|what's the|check the} status', enabling rapid generation of multiple phrasings from a single template.
Allows defining reusable word lists in a dictionary object, promoting DRY principles across intents—for example, a 'colors' list can be referenced in multiple templates to avoid repetition.
Supports Amazon's built-in slots (LITERAL, NUMBER, etc.) and custom slots with a special syntax ({-|Fruit}), ensuring seamless compatibility with Alexa interaction models without manual tweaking.
Auto-generates utterances for numeric ranges with step increments, like 'buy {5-20 by 5|NUMBER} items', expanding to word-based numbers to improve recognition for quantity-based commands.
The library operates offline to produce utterances during development; it cannot dynamically generate or adapt utterances at runtime, limiting use for skills with personalized or context-aware voice commands.
Available only as a Node.js package, so developers using other backend languages (e.g., Python for AWS Lambda) cannot leverage it directly without porting or workarounds.
When the exhaustiveUtterances parameter is set to true, it generates a full cartesian product of all options, which can produce an overwhelming number of utterances and potentially bloat the skill model if not carefully managed.