One of the decisions every framework developer has to make is what to do with filtered actions.
For example, if someone has a routine/automation to unlock the garage cabinet which is set to run only when Michael comes home, it’s Friday, the time is between 7 am and 9 pm, and the garage light is on, which we’ll call Automation One, what should happen if that is automatically exposed to Alexa? That is, when someone says, “Alexa, turn on Automation One,” should the cabinet immediately unlock?
Should it unlock only if all the other conditions are met?
Will Alexa check the conditions or will the automation hub do so?
This is the standard home automation industry distinction between a “scene” and a “routine.” A scene is unfiltered, and therefore available to be actuated by routines or buttons or voice assistants.
A routine has filter options, and therefore typically is not exposed to voice assistants.
SmartThings was unusual in that it developed routines before it developed scenes. So back in 2016, it exposed its routines to Alexa by identifying them as scenes. Which they weren’t, because they had filters, but they didn’t have many filters and it worked OK.
Then over the years SmartThings added true scenes and in 2018 introduced the new V3 app with much more complex automations (no longer called “routines,” although I don’t know why.)
So now SmartThings matches the industry in having actionable “scenes” and filtered “routines” (which SmartThings calls “automations”) and, as is typical, exposes ALL scenes to voice assistants, but not its automations. So far, so good.
Not exposing automations avoids the question of what to do with the filters.
If SmartThings changes it up and exposes automations to the voice assistants, that introduces two major safety issues,
How will filters be handled?
At the present time, ALL ST devices and scenes are exposed to both Alexa and Google Home. As of early 2020 you can no longer selectively enable voice authorization. So what happens when someone in the home misspeaks and unintentionally triggers an ST automation normally used only in emergencies? It’s going to get messy.
The workaround for 1. Is typically similar to what SmartThings has done with the Logitech Harmony integration: have ST create virtual buttons to represent each automation and expose those to the voice assistants as devices, leaving all the filter processing on the ST side. This is the same as creating your own virtual switch, it just does it for you.
But right now there’s no workaround for 2 and, as I mentioned, it introduces a huge number of potential safety and parental control issues.
I don’t have a good design strategy to suggest. But I did just want to mention that there is a real reason why the industry generally distinguishes between IOT “scenes” and “routines.” And this distinction has become even more important with the introduction of voice assistants.
@Gwalker88 @orangebucket @jody.albritton @nathancu @GSzabados