So you can spend a bundle on a new phone and it comes with a voice-activated digital assistant. But let’s be honest, it’s much more satisfying if you coded up this feature yourself. Here’s a guide on doing just that by combining an Asterisk server with the Wolfram Alpha API.
Asterisk is a package we are already familiar with. It’s an open source Private Branch Exchange suite that lets you build your own telephone network. Chances are, you’re not going to build one just for this project, but if you do make sure to document the process and let us know about it. With the Asterisk server in place you just need to give the assistant script an extension (in this case it’s 4747).
But then there’s the problem of translating your speech into text which can be submitted as a Wolfram query. There’s an API for that too which uses Google to do that translation. From there you can tweak abbreviations and other parameters, but all-in-all your new assistant is ready to go. Call it up and ask what to do when you have a flat tire (yeah, that commercial drives us crazy too).