Amazon Lets Us All Use Lex To Build A Bot
Amazon Lets Us All Use Lex To Build A Bot
Written by Lucy Black   
Tuesday, 25 April 2017

 Lex is the voice-to-text and text-to-voice service that powers Alexa. Now we can all use it to add voice capabilities to our apps and devices without restriction. But there is a cost.

alexa

Lex is ASR Automatic Speech Recognition and NLU Nature Language understanding as a service. 

"Thousands of machine learning and deep learning experts across Amazon have been developing AI technologies for years, and Amazon Alexa includes some of the most sophisticated and powerful deep learning technologies in existence," said Raju Gulabani, Vice President, Databases, Analytics, and AI, AWS. 

Lex is an AWS service that integrates with AWS Lambda. It isn't a general free form voice-to-text and text-to-voice system. It is organized as a system for building chatbots. The system uses the same approach that you would take to creating an Alexa app. You define intents slots and utterances. Utterances are typed or spoken phrases that invoke your intents and slots define data that the intent needs to complete them. 

You can send up to 15 seconds of speech input to Lex and you need to make sure the microphone you are using is up to the job. Amazon has made the seven-microphone array that is used in Alexa available only to invited manufacturers so unless you are lucky you will have to create your own input hardware. Supported input formats are LPCM and Opus. Supported output audio formats: MPEG, OGG, PCM. The speech output can't use Alexa's voice but you can choose from seven other voices.

Another job that you are going to have to do is to find a replacement for a wake word - the system doesn't start when you say Alexa or anything else. It is up to you to figure out when the microphone is triggered. 

There are SDKs for iOS and Android and these support voice and text input. The interaction is essentially via REST with just two actions - PostContent and PostText. The response is determined by the bot that you have built  - its slots and utterances. 

 

lex1

At first sight this looks a lot like just being able to use Alexa, but there are some important differences. The first is that Amazon doesn't have to certify your app. You can develop what you like and, as one of the possible intents is to return parsed intent and slot values, you can implement the action locally. This gives you more flexibility than Alexa allows. However, it is worth knowing that Amazon has access to all of your data and keeps the voice input recording with the aim of using them to improve the voice recognition. 

Finally the biggest difference between using Alexa and using Lex is that Alexa's service is free but Lex is a paid-for service:

You are charged based on the number of text or voice requests processed by your bot, at $0.004 per voice request, and $.00075 per text request. For example, the cost for 1,000 speech requests would be $4.00, and 1,000 text requests would cost $0.75. 

You can also process 10,000 text requests and 5000 speech requests per month for free for the first year. 

This also allows us to estimate the cost to Amazon of running Alexa for free. There are at least 10 million Alexa devices in use. If we assume that they each make 10 voice requests per day on average - if you don't agree with the guestimate then make your own - that means that by Amazon's measure this is worth $12 million per month in AWS computing power. 

More Information

Amazon Lex

Related Articles

Alexa Skill Builder Beta

Chatbots Explored

Google Home Voice Ad Causes A Reaction 

Amazon Offering More Incentives For Alexa Skills 

New Amazon Alexa Skills Contest 

The State Of Voice As UI

What Makes A Bot?

 

To be informed about new articles on I Programmer, sign up for our weekly newsletter, subscribe to the RSS feed and follow us on, Twitter, FacebookGoogle+ or Linkedin.

 

Banner


Sinatra 2.0 Released
08/05/2017

The second major release of the domain specific language for creating Ruby applications has been released. Sinatra is an alternative to Rails and other Ruby frameworks but with a different approach an [ ... ]



Amazon Echo Show - Voice Done Right
09/05/2017

Amazon has just announced another device in its Alexa range. This one has an interesting extras that could make voice interaction far more useful than just a clock radio.


More News

 
 

 

blog comments powered by Disqus

Last Updated ( Tuesday, 25 April 2017 )
 
 

   
Banner
RSS feed of news items only
I Programmer News
Copyright © 2017 i-programmer.info. All Rights Reserved.
Joomla! is Free Software released under the GNU/GPL License.