Amazon Echo Skill EchoToEventGhost

If you have a question or need help, this is the place to be.
Post Reply
phairplay
Posts: 12
Joined: Wed Jan 18, 2017 12:02 pm

Re: Amazon Echo Skill EchoToEventGhost

Post by phairplay » Wed Jan 18, 2017 12:10 pm

hi,
this looks like a great idea and something I'm looking for.
I've just purchased my first echo installed event ghost and have ifttt trigger my scripts

"echo trigger clean plex" she response with "sending that to if"
What I would like to do is use this as it allows basic auth my first question is;
what is the trigger work to launch this can I say "echo clean plex"

clean plex is a script created by a plex user that deletes all shows in a set folder after being watched and moves the ones I keep to my server.

Surio89
Posts: 10
Joined: Sat May 14, 2011 8:57 am

Re: Amazon Echo Skill EchoToEventGhost

Post by Surio89 » Thu Jan 19, 2017 2:30 pm

After a few problems it works now but it would be nice to say "alexa, turn on projector" instead of using an additional invocation name.

Did somebody manage to setup a Smart Home Skill where you dont have to use an invocation name?
https://developer.amazon.com/public/sol ... -skill-api

I setup a Smart Home Skill using AWS Auth0 following this Blogger but it got to complex for me in later steps...
https://developer.amazon.com/blogs/post ... home-skill
https://developer.amazon.com/blogs/auth ... el+Palermo

maybe somebody with some more experience in amazon aws could manage this and give us some advice.

SDeGonge
Posts: 10
Joined: Thu Aug 09, 2012 10:01 pm

Amazon Echo Skill EchoToEventGhost - Help Request

Post by SDeGonge » Thu Jan 19, 2017 7:04 pm

<deleted>
Last edited by SDeGonge on Fri Jan 20, 2017 8:06 pm, edited 1 time in total.

millsx2
Posts: 10
Joined: Thu Aug 15, 2013 5:56 am

Re: Amazon Echo Skill EchoToEventGhost

Post by millsx2 » Thu Jan 19, 2017 10:42 pm

@phairplay and @Surio89

This eventghost plugin is for an Echo/Alexa Skill. Whenever using an Alexa Skill an invocation name is required. If you want to use Alexa without an invocation name, I believe you will need to use some kind of hue bridge like the one below.

https://github.com/IndigoDomotics/alexa-hue-bridge

I found a bridge program that would allow you to create virtual devices with http addresses and then you could connect them to eventghost with the webserver plugin. I cannot find the link for it right now. There appears to be a lot of these on github.

phairplay
Posts: 12
Joined: Wed Jan 18, 2017 12:02 pm

Re: Amazon Echo Skill EchoToEventGhost

Post by phairplay » Fri Jan 27, 2017 8:48 am

millsx2 wrote:@phairplay and @Surio89

This eventghost plugin is for an Echo/Alexa Skill. Whenever using an Alexa Skill an invocation name is required. If you want to use Alexa without an invocation name, I believe you will need to use some kind of hue bridge like the one below.

https://github.com/IndigoDomotics/alexa-hue-bridge

I found a bridge program that would allow you to create virtual devices with http addresses and then you could connect them to eventghost with the webserver plugin. I cannot find the link for it right now. There appears to be a lot of these on github.
thank you this was very helpful

phairplay
Posts: 12
Joined: Wed Jan 18, 2017 12:02 pm

Re: Amazon Echo Skill EchoToEventGhost

Post by phairplay » Sat Jan 28, 2017 11:45 am

Hi guys,

I was able to get the skill working and talking to event ghost. Can someone help me with the responses at the moment all I get is 404 error


also the words she sends to eventghost are some times away off. why is this?

therealbiglou
Experienced User
Posts: 127
Joined: Sat May 19, 2012 4:33 am

Re: Amazon Echo Skill EchoToEventGhost

Post by therealbiglou » Sat Jan 28, 2017 2:34 pm

phairplay wrote:Hi guys,

I was able to get the skill working and talking to event ghost. Can someone help me with the responses at the moment all I get is 404 error


also the words she sends to eventghost are some times away off. why is this?
I can't help you with the 404, but I've noticed she sometimes gets words wrong and sometimes doesn't. I got around this by saying the same phrase several times at different volumes, different inflections, and from different locations to got a variety of word combos. I then used every possible translation as triggers for the same macros. That way, no matter what she outputs, she triggers the macro I want.

phairplay
Posts: 12
Joined: Wed Jan 18, 2017 12:02 pm

Re: Amazon Echo Skill EchoToEventGhost

Post by phairplay » Sat Jan 28, 2017 2:42 pm

therealbiglou wrote: I can't help you with the 404, but I've noticed she sometimes gets words wrong and sometimes doesn't. I got around this by saying the same phrase several times at different volumes, different inflections, and from different locations to got a variety of word combos. I then used every possible translation as triggers for the same macros. That way, no matter what she outputs, she triggers the macro I want.
Thank you for the assist
I think I've now linked the index.html from the OP's zip file correctly as she now response with "okay got it working on command blah blah"
how can I get her to respond with something else?

phairplay
Posts: 12
Joined: Wed Jan 18, 2017 12:02 pm

Re: Amazon Echo Skill EchoToEventGhost

Post by phairplay » Tue Jan 31, 2017 2:54 pm

okay,
I now have everything set up.
if the command sent to evenghost is correct then I can get alexa to repeat a custom response, if she sends the wrong command word she response tell me so.

now she does seem to send the wrong command a lot.

how do you guys capture these mistakes and turn them into the correct trigger...or do you keep repeating until she send it correctly?

therealbiglou
Experienced User
Posts: 127
Joined: Sat May 19, 2012 4:33 am

Re: Amazon Echo Skill EchoToEventGhost

Post by therealbiglou » Tue Jan 31, 2017 3:06 pm

how can I get her to respond with something else?
In the code you pasted into the Alexa developer site, search for the words she responds with. This will bring you to a string that is hard coded. Simply change this to whatever you want. I just have her say "Got it" as a response.
how do you guys capture these mistakes and turn them into the correct trigger...
As I said earlier, I say the same phrase at different volumes, from different locations, and with different inflections. This produces a variety of slightly different phrases. For instance, when I want her to make Windows Media Center tune to NBC, I would say, "Alexa, tell the TV to watch NBC."

However, she has heard:
  • watch N.B.C.
  • watch NBC
  • watch embassy
  • etc.
So, I simply drag these events into the same macro which tells WMC to tune to channel 705 (NBC). Every once in a while I'll give the command and she still hears me incorrectly and generates a brand new event. So, over time I train eventghost by continuing to add the misheard events into their appropriate macros.

phairplay
Posts: 12
Joined: Wed Jan 18, 2017 12:02 pm

Re: Amazon Echo Skill EchoToEventGhost

Post by phairplay » Tue Jan 31, 2017 4:14 pm

therealbiglou wrote: In the code you pasted into the Alexa developer site, search for the words she responds with. This will bring you to a string that is hard coded. Simply change this to whatever you want. I just have her say "Got it" as a response.
Hi thank you for the reponse,
After a lot of playing about and going over the entire thread a dozen times I'm now able to get alexa return a custom response to every custom action
Capture.PNG
if what was sent to eventghost doesn't match an action she she will respond with "Sorry can you say that again"
therealbiglou wrote: As I said earlier, I say the same phrase at different volumes, from different locations, and with different inflections. This produces a variety of slightly different phrases. For instance, when I want her to make Windows Media Center tune to NBC, I would say, "Alexa, tell the TV to watch NBC."

However, she has heard:
  • watch N.B.C.
  • watch NBC
  • watch embassy
  • etc.
So, I simply drag these events into the same macro which tells WMC to tune to channel 705 (NBC). Every once in a while I'll give the command and she still hears me incorrectly and generates a brand new event. So, over time I train eventghost by continuing to add the misheard events into their appropriate macros.
I thought this might be the case i was hoping there was another way other than keep adding triggers. I did notice a poster created a csv file but I don't really know how to set it up.

thanks again

therealbiglou
Experienced User
Posts: 127
Joined: Sat May 19, 2012 4:33 am

Re: Amazon Echo Skill EchoToEventGhost

Post by therealbiglou » Tue Jan 31, 2017 5:01 pm

The problem with the CSV is that it still requires you to update it based on things Alexa heard. You may have typed 10 different words to mean a master word, but if she heard something that's not on the list, it's not going to run the correct macro. I prefer to just add events to macros as she mishears my commands.

phairplay
Posts: 12
Joined: Wed Jan 18, 2017 12:02 pm

Re: Amazon Echo Skill EchoToEventGhost

Post by phairplay » Wed Feb 01, 2017 1:01 pm

therealbiglou wrote:The problem with the CSV is that it still requires you to update it based on things Alexa heard. You may have typed 10 different words to mean a master word, but if she heard something that's not on the list, it's not going to run the correct macro. I prefer to just add events to macros as she mishears my commands.
valid point
thanks for the assist

SDeGonge
Posts: 10
Joined: Thu Aug 09, 2012 10:01 pm

Amazon Echo Skill EchoToEventGhost - Keep Connection Open

Post by SDeGonge » Fri Feb 03, 2017 2:51 pm

Is there a way to make the skill stay connected (with a timeout) so multiple commands can be send without having to say "Alexa ask <skill name> to..." each time?
I'm using this to mimic my SageTV remote so navigation becomes a real pain (ie: up up right enter).

Great skill by the way!

therealbiglou
Experienced User
Posts: 127
Joined: Sat May 19, 2012 4:33 am

Re: Amazon Echo Skill EchoToEventGhost - Keep Connection Ope

Post by therealbiglou » Fri Feb 03, 2017 4:07 pm

SDeGonge wrote:Is there a way to make the skill stay connected (with a timeout) so multiple commands can be send without having to say "Alexa ask <skill name> to..." each time?
I'm using this to mimic my SageTV remote so navigation becomes a real pain (ie: up up right enter).

Great skill by the way!
Yes there is! I recently asked about this myself and kgschlosser came up with a great solution.

Create a new Python Script action and paste the following:

Code: Select all

suffixes= eg.event.payload[0].split(' and ')

for suffix in suffixes:
    # the 2 options below will give you a "pretty" event suffix this is if you 
    # are not using the actual suffix for anything other then just triggering
    # an event

    # remove the # before the next line if you would like all the first letters
    # in the suffix to be capital but not to mess with anything that might be
    # like NBC it will stay the same

    #suffix = ' '.join(list(word[0].upper() + word[1:] for word in suffix.split(' ')))

    # remove the # from the next line if you would like to remove all of the 
    # spaces from the suffix

    #suffix = suffix.replace(' ', '')

    # swap the # between these 2 depending if you want to have the "Main."
    # in your event

    eg.TriggerEvent(prefrix='EchoToEG', suffix=suffix)
    #eg.TriggerEvent(suffix='EchoToEG.' + suffix)
You can change EchoToEG to whatever you have for the events coming in from the Echo. What this script does is take your spoken command and split it into multiple events based on the word "and". So, you can say, "Alexa, tell the TV to watch NBC and turn the volume up. What you'll end up with in the EG log is:
  • main.EchoToEG.watch NBC
  • main.EchoToEG.turn the volume up
You can compound as many requests into one statement by just adding multiple ands. Then, just simply use the multiple events to start multiple macros.

Post Reply