"off" triggers intent "name: HassTurnOff" which turns off all lights 💡

When simply saying “on” or “off” (to be precise: my local language version of those) all lights are turned on or off.

sentence parser output:

intent:
  name: HassTurnOff
slots:
  domain: light
details:
  domain:
    name: domain
    value: light
    text: ''
targets:
[ list of all my lights ]

Is this a global bug or a specific one with my HA version or
?

Why does it affect the light domain at all? Complete miracle to me.

I know there’s some kind of magic word to be used in the light.turn_off service to catch ALL lights. But that’s not the case here, it’s just one single word. Creates a bit of issues


What do you expect it to do when you say "<Wake Word> Off"?

long answer:
Ahm, better nothing than selecting a random (OK it’s always lights) domain.
Why not using the switch domain, that’d be a bit more funny wouldn’t it :smiley:

short answer: nothing.

I suspect it has been set up that way on purpose. What is the most common thing you turn on or off?

Lights.

What should HA do if no light is specified?

Select all lights in the area would be logical.

You can always create a custom intent to do what you would prefer.

You’re probably right, “lights” is the most interesting use-case for voice, perhaps/likely.

But why not “[turn]off all [lights]” as minimal intent setup?
I consider the current “a single word without any context” implementation a bit dangerous tbh. Real-life example: if your baby would talk to you “on”, what do you think it wants from you? :wink:

But I’m completely new in the voice assistant game. Is it possible to create a custom intent to block/fix this behavior on my own? So that “on” and “off” don’t do anything?

I’m not sure. I don’t actually use the voice assistant. Docs are here: Conversation - Home Assistant

I have no idea. Or baby. So I guess I would be quite shocked more than anything.

Check this out, just posted: NLP/LLM Request Elucidator Assistant

Seems to match the point here:

A big problem with existing AI assistants is having to formulate specific enough queries from the get-go, making it frustrating to use them.

We naturally have a context in our mind that is often different from the context of the AI. For example, I may want to turn all lights off in the room, and ask “Turn all lights off” but the AI would turn all the lights off in the house.

But I still believe HA can fix this very "on|off equals ‘ALL in light domain’ " issue on its own (without additional LLM hardware power, instead by just fixing the code). Just not sure where to raise awareness for that.

This is an error (or the personal decision of the contributor) in the template for your language. You can check the intents and fix it yourself or contact the language leader.
The “turn on/off” is a mandatory part of sentence in most languages

Thanks for that helpful hint.

Maybe it’s because the default HassTurnOn and HassTurnOff intents don’t exclude the light domain?

But that’s not just the case for German, same for English. Either it’s not the reason for this bug or it’s actually intended to behave strangely like this.

No idea who’s “my” language leader, there’s no list or sth. similar at Language leaders | Home Assistant Developer Docs.

So following up at

The leaders are listed in languages.yaml. Or you can find them on the progress page Home Assistant Intents It’s not entirely obvious :sweat_smile:.
In any case, the commands for managing the entire domain are in this file intents/sentences/de/light_HassTurnOff.yaml at 9ebd76e1f4e41d76c21f22b87ad6aad5168e54ef · home-assistant/intents · GitHub
But I don’t see any options that trigger on “off”
Don’t you have your own custom sentence?

No I don’t. I was asking on how to build one in the earlier posts to “fix” this behaviour for myself.

What does your response look like? In my local language that still has not changed:

  1. Go to /developer-tools/assist
  2. Enter “off” or “on” (in your local/configured language) and see what it triggers

the turn off (ĐČыĐșĐ»ŃŽŃ‡ĐžŃ‚ŃŒ) command is not defined in Russian

It seems to me that the problem in your language arises from complex extended rules. pronouncing only the article already triggers the execution of one of the variants of the intent
You need to run more tests to verify this assumption.

I don’t think I need more tests. I need the right, experienced and much more qualified person (than me) to finally pass this information to.

Update: seems to be fixed somewhere between HA Core 2023.8 and 2024.2. I don’t see this behaviour anymore currently.