MycroftAI / skill-homeassistant

Mycroft Skill/Integration for Homeassistant
GNU Lesser General Public License v3.0
115 stars 62 forks source link

Turn on/all "all" of something in a room #116

Open Ramblurr opened 1 year ago

Ramblurr commented 1 year ago

Is your feature request related to a problem? Please describe. I'm always frustrated when I say "Turn on the living room lights" but only one of the lights in the living room turns on.

Describe the solution you'd like HA lets you assign devices to Areas (rooms) and then lets you target all the devices in those areas. I'd like for Areas to be supported with voice commands too.

Describe alternatives you've considered There are two alternatives that are already supported by this skill, but they both have drawbacks.

  1. Groups - If one light in a light group is on, the group is considered on. This is problematic, because even if one light is on and I tell mycroft to turn on the room's lights, I want all the lights to turn on.
  2. Scenes - Scenes work today and are a viable workaround, but the user experience isn't nice. I want to use natural language like "turn on the living room lights" not "Activate/trigger the scene all living room lights on"

Furthermore both of these alternatives suffer from the fact that the fuzzy entity matching often (for me at least) will pick a single light over the scene or group.

I've tried having a scene "Living room lights on" and telling mycroft to activate the scene, but it will mostly just pick a single light and turn it on.

Additional context none

Ramblurr commented 1 year ago

Poking through the code I came across the following comment:

https://github.com/MycroftAI/skill-homeassistant/blob/c8853f9e471eb629341ce6440cc436a34724c5fd/__init__.py#L142-L143

That seems like it would meet my needs too.

Tony763 commented 1 year ago

Hi, Area is not supplied trough HA websocket API. See issue #76

Tony763 commented 1 year ago

For Groups, this behaivor should be rather fixed in HA, but its there for too long and seems as no fix for now.

Ramblurr commented 1 year ago

I see..that's unfortunate. The main problem I have with groups is that if one member is on, then the whole group is on.

Scenes seem like the better option. What if it was possible to say "Turn on Living Room Bright" where Living Room Bright is a scene? Could we update the skill to support "turn on" intents for scenes?

This is primarily an issue for making non-techy folks comfortable with the system. If it was just me I wouldn't mind telling my computer to "Activate this" or "Trigger that", but my partner and other co-habitants don't find that as exciting as myself.

Tony763 commented 1 year ago

Understood Your pain, I end up creating my own group handler which handles my devices (diy) when they diconnect/reconnect (unavailable to available state).

Tony763 commented 1 year ago

Rather than adding turn on/off intent to automatin, I would add scenes and automations to "turn" action as fallback. This would avoid colisions between automation and turn actions.

This way change would be quite easy and fail proof.