'This Isn't AI' (shkspr.mobi)
The Amazon Echo, a 'smart' speaker developed by Amazon.com, gets many things right. You can ask it to for weather updates, check news, and to play music, and Alexa, the AI powering the device, won't disappoint. But how smart is Alexa? Programmer Terence Eden put it to a simple test to find out. From a blog post: I can now query my solar panels via my Alexa Amazon Dot Echo. I flatter myself as a reasonably competent techie and programmer, but fuck me AWS Lambdas and Alexa skills are a right pile of shite! I wanted something simple. When I say "Solar Panels", call this API, then say this phrase. That's the kind of thing which should take 5 minutes in something like IFTTT . Instead, it took around two hours of following out-of-date official tutorials, and whinging on Twitter, before I got my basic service up and running. [...] It's not so bad, but it does reveal Amazon's contempt for developers. Several of the steps contained errors, it involves multiple logins, random clicks, and a bunch of copy & pasting. Dull and complex. A frustrating and ultimately unsatisfying experience. I ended up using StackOverflow to correct errors in my code because the documentation was so woefully lacking. I kinda thought that Amazon would hear "solar panels" and work out the rest of the query using fancy neural network magic. Nothing could be further from the truth. The developer has to manually code every single possible permutation of the phrase that they expect to hear. This isn't AI. Voice interfaces are the command line. But you don't get tab-to-complete. Amazon allows you to test your code by typing rather than speaking. I spent a frustrating 10 minutes trying to work out why my example code didn't work. Want to know why? I was typing "favourite" rather than the American spelling. Big Data my shiny metal arse.
As I waited for the Echo Dot that I ordered "for my wife" for Christmas, I researched custom code, came to the conclusion that expecting Alexa to go to the cloud for a simple "pause my TV" command was really stupid, so I coded around it, because I am a programmer and that is what we do.
I learned in my research that the Echo can talk to several different kinds of "smart" things without going to the cloud. The "Phillips Hue" being one of them... so that was my back door.
Like 10 minutes of googling told me that there is an open-source implementation of the phillips hue protocol: https://github.com/bwssytems/h...
it didn't work for me right out of the box, but I fiddled with it for a few minutes then it was fine.
From there I wrote in a few minutes a rest endpoint that could take commands from the Hue bridge, and run (locally on my computer) the code of my choice.
All told about an hour after my device arrived at my house, it can control the Roku boxes attached to both of my TVs, and it can run specific movies off of my media server with no round-trip to "the cloud" needed
it is a simple use-case, and required a little bit of "non-amazon" thinking, but it was really easy. Any self-respecting developer could do it.