[NO LONGER SUPPORTED] Ask Alexa

But askAlexa cant run the routines we have created without ST.

I can see a time Alexa will do the things that ST does now without the need for the ST hub. Amazon has been increasing its usefulness.

What do you mean? You mean non-ST things? Good point.

Alexa can’t run routines on its own. It needs ST to have the routines then Alexa controls them. To run askAlexa exclusively would mean no ST needed, at least that’s how I read it.

Ah
I should have added to the end of my sentence 
to control my ST environment!

Well that changes everything. I use askAlexa when I can but her responses and non-compliance lately is making it hard.

1 Like

Is this the problem everyone is seeing?

if so I had this same problem on and off for weeks, I finally figured out that she was hearing “Smartthings” as “Smart Things” half the time.
So I have now changed the command for ask Alexa to “Smart Things” and have had no more issues.

1 Like

For this Friday’s posting I will give everyone a sneak preview to the newest Ask Alexa extension, “Schedules”, the additional features of the Message Queue that are coming, and a new Partner.

First, Ask Alexa Schedules extension: Unlike the rest of Ask Alexa, this is less voice-based (for at least setting up the schedules) but is one of the most powerful scheduling/reminder applications for SmartThings.

When I began building this I asked a good number of my users what they wanted with scheduling in SmartThings. As you can imagine, for 100 people you get 101 answers! In this case, most fell into 4 categories:

  • Items that occur once, but you still want to be reminded of them (like a doctor’s appointment)
  • Simple recurrences, like annual birthdays, or monthly tasks (like paying bills)
  • Complex recurrences. Think of the simple recurrences above, but with more control (i.e weekly reminders, but starting and ending at specific times, or run on a specific date, but only schedule 3 future reminders, don’t remind me on Saturdays, etc)
  • And, ironically, some folks wanted complete control by giving cron expressions to set the schedule.

In addition, folks want to schedule all kinds of thing. While the most popular are birthday and verbal reminders, some want to run CoRE pistons/macros at a specific interval. Some want to run a weather or voice report; some only wanted hourly weather advisories (but only during bad weather). And some simply want to purge their message queues at midnight.

While on the surface these are rather simple to conceptualize, when you throw in the additional requests for reminders (i.e. “Alert me 3 days before the event, and then do it daily until the event”) it adds a level of complication. Finally, and unfortunately, SmartThings has no programmic way to determine what schedules are already set. Therefore, the program has to remember what it scheduled, how often, when it stops, etc. Another SmartThings limitation that other programs regularly run into
.there is a fixed number of schedules a single smartapp can set. This used to be 4, but has recently been set to 6
but still not enough for a full featured schedules and reminders.

It is ironic that I have spent more time coding this particular extension than any other except the main program itself. However, the results are fantastic! First, I get around the limitations of SmartThings allowing you to set up multiple schedules. And, to keep clutter down, you have the option to have schedules auto-delete when they are done. Finally, for those that have large remote families, not only can you be reminder of birthday/anniversary events, you can be alerted up to a WEEK before the event so you can get little Billy’s present in the mail (instead of waiting until the day of his birthday). You can have progressive reminders (1 week, 1 day, 1 hour and then 15 minutes before the event), and finally, for those power users that really understand the nuances (and the power) of Cron scheduling, there is a custom option that allows you to set up these types of schedules so you never have an excuse to miss anything every again.

With the addition of the scheduler, the app uses new features of the message queue that other developers have already begun implementing:

  • Expire notifications-SmartApps that send notifications to the message queue can set an expiration time. This is useful for time specific alerts like weather alerts. So, you can set up a schedule to alert you on an hourly basis to adverse weather (and only alert when those advisories are available), but put a 2 hour expiration date on them. So, if you get an alert at 1pm but don’t listen to it, the message will go away at 3pm as it is no longer relevant.
  • Overwrite notifications-Some apps, like Device Manager, will send you an alert when a device is non-responsive. However, if you have a fluctuating device, you don’t want 100 alerts of ‘device unavailable’ in your queue. Another example is Big Talker and a door open/closing

only the last event (specifically, when) may be the most relevant. Normally, a SmartApp would have to delete its old messages, then send a new one. I have optimized this and allow developers to set an ‘overwrite’ flag that will overwrite any of their older messages, leaving only the last one in place.
  • Notify only-Sometimes, you want to be verbally alerted to events, but not store them at all in the queues. With the “Notify only” flag, you can do this. It will simply send to the queue of your choosing, and if you have text, lights or verbal notification, those items will activate but the message will not store in your queue. This will be important for future extensions like device to device messaging and the recently announced notification system (https://www.cnet.com/news/alexa-what-did-i-miss-amazon-introduces-voice-notifications/)
  • Suppress Time/Date - Some smartapp partners (see below) put in the time and date to their reports. Developers publishing to Ask Alexa’s Message Queue have the ability to suppress the initial time and date during playback of the messages via Alexa. The users will also have this ability globally per message queue

Overall, beta tester are saying this is the BEST extension so far for Ask Alexa, and some have even ventured to say it is the best scheduling application for SmartThings overall.

Finally, Barry Burke (the person responsible for most aspects of the weather reporting extension) has released Spruce Status which uses the latest features of the Message Queue
The message queue allows ALL partner developers to have alerting when Amazon releases their ‘notification’ process as mentioned above
In his own words:

5 Likes

Ooops - “in my own words” I included the link for my Ecobee DTH instead of the Spruce Status app.

The proper link for the Spruce integration is here (it’s a direct link to the raw SmartApp code):

https://raw.githubusercontent.com/SANdood/Custom-ST-Devices/master/spruce-status-for-ask-alexa.groovy

Great work Michael!
The range of things the “schedules” can accommodate is limitless! With every increasing hectic lifestyles, and obligations, this can help ANYONE! Literally elderly (memory retention issues), to young children you are teaching chores and those in between who are managing themselves and sometimes those around them too. Your design, allowing for maximum flexibility for the user is amazing! Things can be simple or really deep dive and have every nuance covered.

Thank you for your dedication to making our smart home’s yet again “smarter”.

1 Like

Thank you! This fixed my issue as well. Was driving me nuts!

2 Likes

Where do you change the command to ask Alexa from “Smartthings” to “Smart Things”?

That would be on the skill information page of developer.amazon.com:

1 Like

Thank you for the screenshot. Updated mine and it works beautifully now. As with everyone else, my Ask Alexa recently stopped working. Updating the Invocation Name from smartthings to smart things fixed it.

I actually don’t think the renaming of the skill is required. When this happened to me I disabled the native skill and my skill, then re-enabled them and they both work fine. Probably a good idea nevertheless
however, not 100% sure it is required.

You are ON POINT ! ! ! I always knew how impressive Ask Alexa is - but here something for our fellow ST users.

Kudo’s Michael! Thank you again for Ask Alexa - and the million other things you have contributed.

2 Likes

Wow
This is the first conversation outside of this forum I have seen mention of the apps I have produced. I was actually more impressed they mentioned my Talking Alarm Clock app, which I wrote two years ago and was published by SmartThings.

It wasn’t hard to notice the work of @tonesto7 and @rayzurbock (also partners in the Ask Alexa world) are also mentioned
Great work to all!

5 Likes

I hope everyone gets to enjoy a 3 days weekend that is coming up!

While not as exciting of a week as last few with all of the great announcements from Amazon, Google and even Apple, I was more surprised when I was alerted to an article NOT written by SmartThings that not only called out Ask Alexa, but one of the first apps I wrote, Talking Alarm Clock. Based on the latest stats, The Talking Alarm Clock has a larger install base than even Ask Alexa! While this was (admittedly) a nice ego boost, the thing I am most excited about is that two other apps that are partners to Ask Alexa, Big Talker and NST Manager, were also in the list of the top recommended apps for SmartThings. I was a little disappointed that things like CoRE/webCoRE were not listed. @ady624 has done something for me that no other developer has done
allowed me to migrate away from my OWN CODE to something that is more universally usable. Anyway, I don’t know if the author of this article frequents the forums, but if he is reading this I appreciate the props. If you want to reach out to me I can give you a sneak preview to some of the new extensions coming out for Ask Alexa.

The article is here:

Within the article above there is even a nice video someone produced that I was totally unaware of until I saw this article. While I have a training video being produced this summer, this is a nice demonstration of how multiple commands and natural voice commands can make a smart home even smarter. Notice that once you invoke the skill you can continue ‘talking’ and commanding Alexa. Ironically, most people are unaware of this, which is one of the reasons I need to get a training video out there!

I was also surprised to find yet another article written (and a related video) from February that totally went under my radar:

Bottom line, there is a need for online training or demonstration of ALL of the functionality of Ask Alexa. Until I get a training video out there, I am going to dedicate any Fridays that do not code updates to going through training on Ask Alexa as there are hidden gems that people just assume can’t be done that are rather simple. This week I will focus on a question about ‘areas’ or ‘rooms’.

One of the decisions I had to make when designing Ask Alexa was the overall structure of the app. Would I design it like SmartThings (and Amazon’s own native integration) from a ‘one’ concept (i.e. one account controls many things), or an ‘area’ or ‘context’ concept (“Turn on the lights in the living room”, “turn on the lights in the bathroom”, etc). At the end of the day, looking back, I made a great choice to keep the core concept the same as SmartThings in allowing you to not have to remember multiple invocation names, but use “Alexa, tell SmartThings
” as your portal to opening the app and then controlling your home (and having continued conversations with the home like in the video).

However, there are times where you might simply not remember the devices in the living room and just want an overall status of that ‘area’. SmartThings uses this concept in their ‘rooms’ organization and I get asked a lot if Ask Alexa can do this. You have to be creative, but the answer is YES!

For a ‘room report’, simple create a voice report called “Living Room” (Ensuring that you don’t have any other devices or extensions with that name), then build a voice report that gives you what you want. I built one for “Outside” that averages the front door and back door motion sensors to give me a ‘temperature’ reading, and one for the “Kitchen” to give me the status of various doors and lights. So when I say “Alexa, ask SmartThings about the Kitchen” it gives me a report about the items I have listed.

This is all fine for status reports, but what about control of the items in a room? Well, you can do that too
.using a Group Macro. In the above example, I have a macro called “Kitchen Lights” that is has all of the lights in that room in it. I simply say “Alexa, turn off the Kitchen Lights” and all of them go off. Again, you have the room or area concept without having to create an overly complicated setup.

Finally, I got a lot of positive responses from the Schedules extension I previewed here last week. Based on feedback from the testers, I FINALLY feel it is getting ready for release
I plan to release it the next couple weeks or so. Surprisingly, schedules are difficult to manager in SmartThings, especially if you want to have reminders PRIOR to the events. But I think I finally cracked the code :slight_smile:

I have started on the documentation for the Schedules extension for those of you that want to see how it works. Have a look at the installation wiki (http://thingsthataresmart.wiki/index.php?title=Ask_Alexa). I have a few use cases here, and some screenshots documenting everything. Consider all of these information beta and can (and probably will) change before the release.

Everyone have a great weekend!

9 Likes

Hello Everyone, I could really use some help if anyone is kind enough to help me figure out whats wrong here or point me in the right direction. I followed the installation instructions and I went through the whole process again. I can’t pin point whats wrong. I am attaching a few screenshots hopefully they help.

Oh, and by the way I ould also appreciate if anyone can send me an invitation to the slack channel app.

Thank you guys for any and all help.

This looks rather simple
was this an ‘upgrade’ where you had this working before or a brand new installation from scratch? The area you are having issues with is the ‘getAverage’ method where two (or more) get averaged together. Unfortunately, some sensors (or DTHs) do not send the correct numeric values to Ask Alexa. I have only seen this once before.

Let me know about your installation, and then look in Settings->Text Field Variables to see what is in this area. It is safe to put a screenshot of that on this page.

1 Like