I’ve finally managed to get the Amazon’s avs package for Echo working and released an Echo assistant plugin too. It’s now possible to setup platypush also as an Amazon Echo assistant by following these steps:

  • Install Snowboy for hotword detection and my forked/patched installation of the avs both on the device where platypush runs and a device that can access a browser:
pip install snowboy
pip install git+https://github.com/BlackLight/avs
  • Authenticate to Amazon on the machine that can open a UI browser:
alexa-auth
  • Head to http://localhost:3000 and login with the Amazon account
  • Copy the generated ~/.avs.json file to the machine where platypush runs
  • Download/train an Alexa hotword model from Snowboy and save it to ~/.local/share/snowboy/Alexa.pmdl
  • Configure the assistant like this in ~/.config/platypush/config.yaml to enable it with Alexa hotword detection:
backend.assistant.snowboy:
audio_gain: 1.1
models:
alexa:
voice_model_file: ~/.local/share/snowboy/models/Alexa.pmdl
assistant_plugin: assistant.echo
assistant_language: en-US
detect_sound: ~/.local/share/sounds/wake.wav
sensitivity: 0.55
  • Restart platypush and the Alexa assistant should be up and running

It’s also possible to configure the new assistant under the Alexa app — e.g. set location, localization preferences etc. — it will appear as “User’s ReSpeaker”.

The only drawback is that the avs SDK communicates with the client application only through audio files — you send an audio file with the speech, you receive back an audio file with the spoken response. It doesn’t provide the transcript neither of the user request nor of the assistant response, so most of the event hooks that can be made for the Google assistant on speech recognized and response won’t work.

Written by

Automation, IoT, programming, machine learning, science, math, economics and more. Powered by Fabio “BlackLight” Manganiello and Sneha Divakar.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store