ha-voice-label-sync 0.2.0.dev0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 flimo44
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,246 @@
1
+ Metadata-Version: 2.4
2
+ Name: ha-voice-label-sync
3
+ Version: 0.2.0.dev0
4
+ Summary: Generate voice assistant configuration from Home Assistant labels.
5
+ Author: Philippe Le Bonhomme
6
+ License-Expression: MIT
7
+ Project-URL: Homepage, https://github.com/flimo44/ha-voice-label-sync
8
+ Project-URL: Documentation, https://github.com/flimo44/ha-voice-label-sync#readme
9
+ Project-URL: Issues, https://github.com/flimo44/ha-voice-label-sync/issues
10
+ Project-URL: Source, https://github.com/flimo44/ha-voice-label-sync
11
+ Keywords: home-assistant,google-assistant,voice-assistant,automation,yaml
12
+ Classifier: Development Status :: 3 - Alpha
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: Programming Language :: Python :: 3.11
15
+ Classifier: Programming Language :: Python :: 3.12
16
+ Classifier: Topic :: Home Automation
17
+ Requires-Python: >=3.11
18
+ Description-Content-Type: text/markdown
19
+ License-File: LICENSE
20
+ Dynamic: license-file
21
+
22
+ <img width="1024" height="559" alt="image" src="https://github.com/user-attachments/assets/6918c5ae-b95b-4d81-9108-7b2cd8acd0fd" />
23
+
24
+ ### Automatically generate your voice assistant configuration from Home Assistant labels.
25
+
26
+ [![Python checks](https://github.com/flimo44/ha-voice-label-sync/actions/workflows/python-check.yml/badge.svg?branch=main)](https://github.com/flimo44/ha-voice-label-sync/actions/workflows/python-check.yml)
27
+
28
+
29
+ > 🚧 Early development project
30
+ >
31
+ > Feedback and ideas are welcome.
32
+
33
+ ## Why?
34
+
35
+ Do you maintain dozens of Google Assistant entities manually?
36
+
37
+ Managing voice assistant configurations manually quickly becomes difficult.
38
+
39
+ HA Voice Label Sync automatically generates the required configuration from Home Assistant labels, making your labels the single source of truth.
40
+
41
+ With the current release you can:
42
+
43
+ Stop maintaining large YAML files manually.
44
+ Avoid duplicated configuration.
45
+ Keep Home Assistant as the only place where entities are managed.
46
+ Generate your configuration in seconds.
47
+
48
+ ## Current Status
49
+
50
+ ## Project status
51
+
52
+ HVLS is currently under active development.
53
+
54
+ Latest stable release: `v0.1.2`
55
+
56
+ Current development version: `0.2.0.dev0`
57
+
58
+ Current capabilities:
59
+
60
+ - Standalone CLI
61
+ - Reusable Python core
62
+ - Google Assistant YAML generation
63
+ - Dry-run support
64
+ - Safe atomic file writing
65
+ - Automatic backups and retention
66
+ - Initial Home Assistant integration skeleton
67
+
68
+ Not yet available:
69
+
70
+ - Full Home Assistant configuration UI
71
+ - Home Assistant actions and buttons
72
+ - Backup restoration from the UI
73
+ - HACS installation
74
+
75
+ HA Voice Label Sync has been designed to support multiple voice assistants.
76
+
77
+ - Currently supported :
78
+
79
+
80
+ ✅ Google Assistant
81
+
82
+ - Planned :
83
+
84
+ Amazon Alexa
85
+ Apple HomeKit
86
+
87
+ Instead of maintaining a long list of exposed entities manually, simply assign a label in Home Assistant, run the script, and let HA Voice Label Sync generate the configuration for you.
88
+
89
+
90
+ ## Features
91
+
92
+ - Select entities using a Home Assistant label
93
+ - Generate `entity_config` for Google Assistant
94
+ - Use Home Assistant friendly names
95
+ - Use Home Assistant areas as Google rooms
96
+ - Ignore disabled or hidden entities
97
+ - Dry-run mode before writing the file
98
+
99
+ ## How it works
100
+
101
+
102
+ ```
103
+ Home Assistant
104
+
105
+
106
+ Labels
107
+
108
+
109
+ Voice Assistant Sync
110
+
111
+ ┌──────┴───────┐
112
+ │ │
113
+ Google Assistant Amazon Alexa
114
+
115
+ ```
116
+
117
+ ## Generated entity_config
118
+
119
+ ```yaml
120
+ switch.prise_pompe:
121
+ expose: true
122
+ name: Pompe piscine
123
+ room: Piscine
124
+ ```
125
+
126
+
127
+ Home Assistant configuration
128
+
129
+ ```yaml
130
+ google_assistant:
131
+ project_id: YOUR_PROJECT_ID
132
+ service_account: !include google_key.json
133
+ report_state: true
134
+ expose_by_default: false
135
+ entity_config: !include google_assistant_entities.yaml
136
+ ```
137
+
138
+ ## Quick start
139
+
140
+ Installation
141
+
142
+ Option 1 – Download the script
143
+
144
+ Download the latest version of ga_label_sync.py from the repository.
145
+
146
+ Copy it to your Home Assistant scripts directory.
147
+
148
+ Typical locations are:
149
+
150
+ ```text
151
+ /config/scripts/
152
+
153
+ or
154
+
155
+ <home-assistant-config>/scripts/
156
+ ```
157
+
158
+ depending on your Home Assistant installation.
159
+
160
+ Option 2 – Clone the repository
161
+ ```bash
162
+ git clone https://github.com/flimo44/ha-voice-label-sync.git
163
+ ```
164
+ The script is located in:
165
+ ```text
166
+ scripts/ga_label_sync.py
167
+ ```
168
+
169
+ ```Tip
170
+
171
+ If you simply want to use the script, downloading scripts/ga_label_sync.py is enough.
172
+
173
+ Cloning the repository is recommended only if you plan to follow development or contribute to the project.
174
+ ```
175
+
176
+ Usage :
177
+
178
+ ### Step 1 — Add the label
179
+
180
+ <img width="455" height="375" alt="Capture d&#39;écran 2026-06-26 201643" src="https://github.com/user-attachments/assets/a262942a-5fb1-4a84-b88e-5db12eb67be8" />
181
+
182
+
183
+ ### Step 2 — Preview the generated configuration
184
+
185
+
186
+ <img width="555" height="172" alt="Capture d&#39;écran 2026-06-26 203136" src="https://github.com/user-attachments/assets/66ea6d63-983b-467b-9870-198d64b027bd" />
187
+
188
+ ```bash
189
+ python3 /config/scripts/ga_label_sync.py --label "google_assistant" --dry-run
190
+ ```
191
+
192
+ ```
193
+ # --- Couloir ---
194
+ lock.serrure_maison:
195
+ expose: true
196
+ name: Serrure porte entrée
197
+ room: Couloir
198
+
199
+ # --- Jardin ---
200
+ switch.portail:
201
+ expose: true
202
+ name: Portail
203
+ room: Jardin
204
+
205
+ # --- Piscine ---
206
+ input_select.piscine_mode_gestion:
207
+ expose: true
208
+ name: "Piscine - Mode Gestion"
209
+ room: Piscine
210
+
211
+ switch.piscine_chauffage:
212
+ expose: true
213
+ name: Pac Piscine
214
+ room: Piscine
215
+
216
+ switch.prise_pompe2:
217
+ expose: true
218
+ name: Pompe piscine
219
+ room: Piscine
220
+ ```
221
+
222
+
223
+ ### Step 3 — Generate the file
224
+ ```bash
225
+ python3 /config/scripts/ga_label_sync.py --label "google_assistant"
226
+ ```
227
+ <img width="454" height="446" alt="Capture d&#39;écran 2026-06-26 200340" src="https://github.com/user-attachments/assets/6f0938ae-13e9-4856-9b4f-7db5e8290171" />
228
+
229
+
230
+ ### Step 4 — Restart Home Assistant
231
+
232
+
233
+
234
+ ### Step 5 — Synchronize Google Home
235
+
236
+
237
+ Google Home before synchronization
238
+
239
+ <img width="1080" height="2400" alt="Screenshot_2026-06-26-19-44-33-60_2d2bd67b5e15ae98c151ac739cd6881e" src="https://github.com/user-attachments/assets/a03d1005-fde8-4186-b8ea-da2f426c5a84" />
240
+
241
+ Google Home after synchronization
242
+
243
+ <img width="1080" height="2400" alt="Screenshot_2026-06-26-19-45-48-86_2d2bd67b5e15ae98c151ac739cd6881e" src="https://github.com/user-attachments/assets/5b4d96cc-9da9-4419-9d1f-f5eac4fbec8c" />
244
+
245
+ License
246
+ MIT
@@ -0,0 +1,225 @@
1
+ <img width="1024" height="559" alt="image" src="https://github.com/user-attachments/assets/6918c5ae-b95b-4d81-9108-7b2cd8acd0fd" />
2
+
3
+ ### Automatically generate your voice assistant configuration from Home Assistant labels.
4
+
5
+ [![Python checks](https://github.com/flimo44/ha-voice-label-sync/actions/workflows/python-check.yml/badge.svg?branch=main)](https://github.com/flimo44/ha-voice-label-sync/actions/workflows/python-check.yml)
6
+
7
+
8
+ > 🚧 Early development project
9
+ >
10
+ > Feedback and ideas are welcome.
11
+
12
+ ## Why?
13
+
14
+ Do you maintain dozens of Google Assistant entities manually?
15
+
16
+ Managing voice assistant configurations manually quickly becomes difficult.
17
+
18
+ HA Voice Label Sync automatically generates the required configuration from Home Assistant labels, making your labels the single source of truth.
19
+
20
+ With the current release you can:
21
+
22
+ Stop maintaining large YAML files manually.
23
+ Avoid duplicated configuration.
24
+ Keep Home Assistant as the only place where entities are managed.
25
+ Generate your configuration in seconds.
26
+
27
+ ## Current Status
28
+
29
+ ## Project status
30
+
31
+ HVLS is currently under active development.
32
+
33
+ Latest stable release: `v0.1.2`
34
+
35
+ Current development version: `0.2.0.dev0`
36
+
37
+ Current capabilities:
38
+
39
+ - Standalone CLI
40
+ - Reusable Python core
41
+ - Google Assistant YAML generation
42
+ - Dry-run support
43
+ - Safe atomic file writing
44
+ - Automatic backups and retention
45
+ - Initial Home Assistant integration skeleton
46
+
47
+ Not yet available:
48
+
49
+ - Full Home Assistant configuration UI
50
+ - Home Assistant actions and buttons
51
+ - Backup restoration from the UI
52
+ - HACS installation
53
+
54
+ HA Voice Label Sync has been designed to support multiple voice assistants.
55
+
56
+ - Currently supported :
57
+
58
+
59
+ ✅ Google Assistant
60
+
61
+ - Planned :
62
+
63
+ Amazon Alexa
64
+ Apple HomeKit
65
+
66
+ Instead of maintaining a long list of exposed entities manually, simply assign a label in Home Assistant, run the script, and let HA Voice Label Sync generate the configuration for you.
67
+
68
+
69
+ ## Features
70
+
71
+ - Select entities using a Home Assistant label
72
+ - Generate `entity_config` for Google Assistant
73
+ - Use Home Assistant friendly names
74
+ - Use Home Assistant areas as Google rooms
75
+ - Ignore disabled or hidden entities
76
+ - Dry-run mode before writing the file
77
+
78
+ ## How it works
79
+
80
+
81
+ ```
82
+ Home Assistant
83
+
84
+
85
+ Labels
86
+
87
+
88
+ Voice Assistant Sync
89
+
90
+ ┌──────┴───────┐
91
+ │ │
92
+ Google Assistant Amazon Alexa
93
+
94
+ ```
95
+
96
+ ## Generated entity_config
97
+
98
+ ```yaml
99
+ switch.prise_pompe:
100
+ expose: true
101
+ name: Pompe piscine
102
+ room: Piscine
103
+ ```
104
+
105
+
106
+ Home Assistant configuration
107
+
108
+ ```yaml
109
+ google_assistant:
110
+ project_id: YOUR_PROJECT_ID
111
+ service_account: !include google_key.json
112
+ report_state: true
113
+ expose_by_default: false
114
+ entity_config: !include google_assistant_entities.yaml
115
+ ```
116
+
117
+ ## Quick start
118
+
119
+ Installation
120
+
121
+ Option 1 – Download the script
122
+
123
+ Download the latest version of ga_label_sync.py from the repository.
124
+
125
+ Copy it to your Home Assistant scripts directory.
126
+
127
+ Typical locations are:
128
+
129
+ ```text
130
+ /config/scripts/
131
+
132
+ or
133
+
134
+ <home-assistant-config>/scripts/
135
+ ```
136
+
137
+ depending on your Home Assistant installation.
138
+
139
+ Option 2 – Clone the repository
140
+ ```bash
141
+ git clone https://github.com/flimo44/ha-voice-label-sync.git
142
+ ```
143
+ The script is located in:
144
+ ```text
145
+ scripts/ga_label_sync.py
146
+ ```
147
+
148
+ ```Tip
149
+
150
+ If you simply want to use the script, downloading scripts/ga_label_sync.py is enough.
151
+
152
+ Cloning the repository is recommended only if you plan to follow development or contribute to the project.
153
+ ```
154
+
155
+ Usage :
156
+
157
+ ### Step 1 — Add the label
158
+
159
+ <img width="455" height="375" alt="Capture d&#39;écran 2026-06-26 201643" src="https://github.com/user-attachments/assets/a262942a-5fb1-4a84-b88e-5db12eb67be8" />
160
+
161
+
162
+ ### Step 2 — Preview the generated configuration
163
+
164
+
165
+ <img width="555" height="172" alt="Capture d&#39;écran 2026-06-26 203136" src="https://github.com/user-attachments/assets/66ea6d63-983b-467b-9870-198d64b027bd" />
166
+
167
+ ```bash
168
+ python3 /config/scripts/ga_label_sync.py --label "google_assistant" --dry-run
169
+ ```
170
+
171
+ ```
172
+ # --- Couloir ---
173
+ lock.serrure_maison:
174
+ expose: true
175
+ name: Serrure porte entrée
176
+ room: Couloir
177
+
178
+ # --- Jardin ---
179
+ switch.portail:
180
+ expose: true
181
+ name: Portail
182
+ room: Jardin
183
+
184
+ # --- Piscine ---
185
+ input_select.piscine_mode_gestion:
186
+ expose: true
187
+ name: "Piscine - Mode Gestion"
188
+ room: Piscine
189
+
190
+ switch.piscine_chauffage:
191
+ expose: true
192
+ name: Pac Piscine
193
+ room: Piscine
194
+
195
+ switch.prise_pompe2:
196
+ expose: true
197
+ name: Pompe piscine
198
+ room: Piscine
199
+ ```
200
+
201
+
202
+ ### Step 3 — Generate the file
203
+ ```bash
204
+ python3 /config/scripts/ga_label_sync.py --label "google_assistant"
205
+ ```
206
+ <img width="454" height="446" alt="Capture d&#39;écran 2026-06-26 200340" src="https://github.com/user-attachments/assets/6f0938ae-13e9-4856-9b4f-7db5e8290171" />
207
+
208
+
209
+ ### Step 4 — Restart Home Assistant
210
+
211
+
212
+
213
+ ### Step 5 — Synchronize Google Home
214
+
215
+
216
+ Google Home before synchronization
217
+
218
+ <img width="1080" height="2400" alt="Screenshot_2026-06-26-19-44-33-60_2d2bd67b5e15ae98c151ac739cd6881e" src="https://github.com/user-attachments/assets/a03d1005-fde8-4186-b8ea-da2f426c5a84" />
219
+
220
+ Google Home after synchronization
221
+
222
+ <img width="1080" height="2400" alt="Screenshot_2026-06-26-19-45-48-86_2d2bd67b5e15ae98c151ac739cd6881e" src="https://github.com/user-attachments/assets/5b4d96cc-9da9-4419-9d1f-f5eac4fbec8c" />
223
+
224
+ License
225
+ MIT
@@ -0,0 +1,49 @@
1
+ [build-system]
2
+ requires = ["setuptools>=77"]
3
+ build-backend = "setuptools.build_meta"
4
+
5
+ [project]
6
+ name = "ha-voice-label-sync"
7
+ version = "0.2.0.dev0"
8
+ description = "Generate voice assistant configuration from Home Assistant labels."
9
+ readme = "README.md"
10
+ requires-python = ">=3.11"
11
+ license = "MIT"
12
+ license-files = ["LICENSE"]
13
+ authors = [
14
+ { name = "Philippe Le Bonhomme" }
15
+ ]
16
+ keywords = [
17
+ "home-assistant",
18
+ "google-assistant",
19
+ "voice-assistant",
20
+ "automation",
21
+ "yaml"
22
+ ]
23
+ classifiers = [
24
+ "Development Status :: 3 - Alpha",
25
+ "Programming Language :: Python :: 3",
26
+ "Programming Language :: Python :: 3.11",
27
+ "Programming Language :: Python :: 3.12",
28
+ "Topic :: Home Automation"
29
+ ]
30
+ dependencies = []
31
+
32
+ [project.urls]
33
+ Homepage = "https://github.com/flimo44/ha-voice-label-sync"
34
+ Documentation = "https://github.com/flimo44/ha-voice-label-sync#readme"
35
+ Issues = "https://github.com/flimo44/ha-voice-label-sync/issues"
36
+ Source = "https://github.com/flimo44/ha-voice-label-sync"
37
+
38
+ [project.scripts]
39
+ hvls = "hvls.cli:main"
40
+
41
+ [tool.setuptools.packages.find]
42
+ where = ["src"]
43
+
44
+ [tool.ruff]
45
+ target-version = "py311"
46
+ line-length = 88
47
+
48
+ [tool.ruff.lint]
49
+ select = ["E", "F", "I", "UP"]
@@ -0,0 +1,4 @@
1
+ [egg_info]
2
+ tag_build =
3
+ tag_date = 0
4
+