to be honest, I am still a newbie in using Snips, that’s also one of the reasons for this topic.
I like to know something regarding best practices for: SNIPS <-> Home Assistant
I started with Snips and Home Assistant - on different Pis - with connectivity to an IP/KNX Router using KNX / XKNX for my Smarthome environment.
I need to say, I have quite a huge KNX environment running incl. Gira Homeserver, visualization, komplex logics etc and the intention for Snips is, to control most of the different entities (lights, cover, heating, cooling, ventilation, media, electronic consumers, etc.) in the near future.
I know, it will be quite a lot of stuff and this is the reason for my upcomming questions. I would like to avoid reengineering and restructuring as much as I can.
So the current status is, the Pis (Snips, HASS etc.) are all running and I am able to control light via Snips->HASS->KNX/XKNX. So, before starting, now the real challenge will be, to create sustainable Snips-Apps and structured entities within HASS.
My questions are: Are there any best-practices for
- Definitions of Intents, Slots, Slot Types (in Snips)
- Contents of the objects above
- Sustainable Structures of “namings” of entities within XKNS in HASS
- Based on the namings of the entities, conceptional structures of the HASS Templates
The reasons for my questions are also based on some of the typical but also unusual properties/characteristics of the german language, especially the characteristic in connecting nouns.
- Hey Snips, switch on the light over the desk in the office.
(Hey Snips, schalte das Licht im Büro über dem Schreibtisch an.)
- Hey Snips, switch on the “desklight” in the office.
(Hey Snips, schalte das Schreibtischlicht im Büro an.)
- Hey Snips, switch on the “desklight”.
(Hey Snips, schalte das Schreibtischlicht.)
- Hey Snips, dim the light at the wall over the desk to 50%.
(Hey Snips, dimme das Licht an der Wand über dem Schreibtisch auf 50%)
So my intention for the Slots in Snips:
- location (rooms): office (Büro)
- locationtype (objects within a room): desk, TV, Couch, wall, window, … (Schreibtisch, Fernseher, Sofa, Wand, Fenster)
- entity (control units): light, “desklight”, “wall-light” (Licht, Schreibtischlicht, Wandlampe, etc)
- command: on, off, next, previous, … (an, aus, vor, zurück, …)
- value: 50%, …
The challenge is, that in locationtype and entity you somehow have parts of the same objects, based on the characteristics of the german language.
If now you are going to HASS looking to JSONs objects you need to create the entity names within HASS based on the entities and value, that were delivered, to control the individual objects e.g. light.office_desk_light.
Based on the structure above it will be a huge challenge to realize a template for a number of lights, covers etc.
So, therefore my questions regarding best-practices or any “lessons-learned”.
Any comment is really appreciated.
PS: I have worked out a “concept/structure” wich - looking to the existing snips-apps - seems really quite strange and completely different of how existing apps are realized. Therefore I would like to know, if there are any best practices, because probably my concept doesn’t make sense.