Normal create your own voice activated stuff uses automations. Ai activated functionality uses scripts.
Im hitting all kind of issues while running tail and error.
One of them is that the varible used in the stop command needs to be in {{ {'value': output } }} for the voice automation to understand the stop output.
All functions and description needs to be set. And the script options need to be set mandatory if required.
With this last i have an issue. I feed the device_id to the script from the automation to detect what assist client is used. To get the room so ha knows where to turn on the tv or music.
But the ai does not know the device-id so i created a other input var room
Now is the LLM not always filling in the room. Unless made mandatory.
What is best practice. Only make the room mandatory. And fill in a none value in the scripts. Or combine the two functions and make a template to check if its a device id or a room?