skill-homeassistant 0.1.0__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.
Files changed (41) hide show
  1. skill_homeassistant-0.1.0/LICENSE +201 -0
  2. skill_homeassistant-0.1.0/PKG-INFO +197 -0
  3. skill_homeassistant-0.1.0/README.md +169 -0
  4. skill_homeassistant-0.1.0/pyproject.toml +88 -0
  5. skill_homeassistant-0.1.0/skill_homeassistant/__init__.py +342 -0
  6. skill_homeassistant-0.1.0/skill_homeassistant/ha_client/__init__.py +427 -0
  7. skill_homeassistant-0.1.0/skill_homeassistant/ha_client/constants.py +30 -0
  8. skill_homeassistant-0.1.0/skill_homeassistant/ha_client/logic/__init__.py +0 -0
  9. skill_homeassistant-0.1.0/skill_homeassistant/ha_client/logic/connector.py +330 -0
  10. skill_homeassistant-0.1.0/skill_homeassistant/ha_client/logic/device.py +731 -0
  11. skill_homeassistant-0.1.0/skill_homeassistant/ha_client/logic/utils.py +56 -0
  12. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/acknowledge.dialog +5 -0
  13. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/assist.dialog +3 -0
  14. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/assist.error.dialog +1 -0
  15. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/assist.not.understood.dialog +2 -0
  16. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/device.not.found.dialog +3 -0
  17. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/device.status.dialog +3 -0
  18. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/device.turned.off.dialog +3 -0
  19. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/device.turned.on.dialog +3 -0
  20. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/disable.dialog +2 -0
  21. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/enable.dialog +2 -0
  22. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/lights.current.brightness.dialog +2 -0
  23. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/lights.current.color.dialog +2 -0
  24. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/lights.status.not.available.dialog +1 -0
  25. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/no.parsed.device.dialog +2 -0
  26. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/dialog/vacuum.action.not.found.dialog +2 -0
  27. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/assist.intent +1 -0
  28. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/disable.intent +2 -0
  29. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/enable.intent +2 -0
  30. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/get.all.devices.intent +1 -0
  31. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/lights.decrease.brightness.intent +3 -0
  32. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/lights.get.brightness.intent +2 -0
  33. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/lights.get.color.intent +2 -0
  34. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/lights.increase.brightness.intent +3 -0
  35. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/lights.set.brightness.intent +2 -0
  36. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/lights.set.color.intent +2 -0
  37. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/sensor.intent +3 -0
  38. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/stop.intent +4 -0
  39. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/turn.off.intent +5 -0
  40. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/intents/turn.on.intent +5 -0
  41. skill_homeassistant-0.1.0/skill_homeassistant/locale/en-us/skill.json +30 -0
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright [yyyy] [name of copyright owner]
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.
@@ -0,0 +1,197 @@
1
+ Metadata-Version: 2.3
2
+ Name: skill-homeassistant
3
+ Version: 0.1.0
4
+ Summary: A unified OVOS/Neon.AI Skill for Home Assistant.
5
+ License: Apache-2.0
6
+ Keywords: ovos,neon,home,assistant,voice,interface,skill,plugin
7
+ Author: Mike Gray
8
+ Author-email: mike@oscillatelabs.net
9
+ Requires-Python: >=3.9,<4.0
10
+ Classifier: License :: OSI Approved :: Apache Software License
11
+ Classifier: Programming Language :: Python :: 3
12
+ Classifier: Programming Language :: Python :: 3.9
13
+ Classifier: Programming Language :: Python :: 3.10
14
+ Classifier: Programming Language :: Python :: 3.11
15
+ Classifier: Programming Language :: Python :: 3.12
16
+ Classifier: Programming Language :: Python :: 3.13
17
+ Provides-Extra: test
18
+ Requires-Dist: nested-lookup (>=0.2,<1.0)
19
+ Requires-Dist: ovos-bus-client (>=0.0.8)
20
+ Requires-Dist: ovos-config (>=0.0.5)
21
+ Requires-Dist: ovos-phal-plugin-oauth (>=0.0.3)
22
+ Requires-Dist: ovos-plugin-manager (>=0.0.23)
23
+ Requires-Dist: ovos-utils (>=0.0.27)
24
+ Requires-Dist: ovos-workshop (>=0.0.15)
25
+ Requires-Dist: setuptools (>=75.0.0,<76.0.0)
26
+ Description-Content-Type: text/markdown
27
+
28
+ # Home Assistant Skill
29
+
30
+ Control your Home Assistant smart home devices through OVOS or Neon.AI voice assistants.
31
+
32
+ This unified skill is a replacement for the `neon-homeassistant-skill` and `ovos-PHAL-plugin-homeassistant` skill/plugin. Most features are supported, but please report any issues you encounter. **_Note: Do not install both this skill and the previous skills/plugins._**
33
+
34
+ ## Features
35
+
36
+ - Control lights (on/off, brightness, color)
37
+ - Control switches and outlets
38
+ - Monitor sensors
39
+ - Control covers (open/close, position)
40
+ - Silent mode for specific devices
41
+ - Support for Home Assistant Assist API
42
+
43
+ ## Installation on Neon
44
+
45
+ You can `pip install neon-homeassistant-skill`, or handle the installation from the `~/.config/neon/neon.yaml` file if you prefer:
46
+
47
+ ```yaml
48
+ skills:
49
+ default_skills:
50
+ - skill-homeassistant # Optionally with a version, such as skill-homeassistant==0.1.0
51
+ ```
52
+
53
+ ## Configuration
54
+
55
+ ### Authentication Using a Long-lived Token
56
+
57
+ We recommend using a [long-lived token for Home Assistant](https://developers.home-assistant.io/docs/auth_api/#long-lived-access-token). This provides persistent access without requiring re-authentication. Configure it in your skill settings file:
58
+
59
+ - OVOS: `~/.config/mycroft/skills/skill-homeassistant/settings.json`
60
+ - Neon: `~/.config/neon/skills/neon_homeassistant_skill/settings.json`
61
+
62
+ ```json
63
+ {
64
+ "api_key": "<HA_LONG_LIVED_TOKEN>",
65
+ "host": "<HA_IP_OR_HOSTNAME>"
66
+ }
67
+ ```
68
+
69
+ ### Configuration Options
70
+
71
+ All available settings with their defaults:
72
+
73
+ ```jsonc
74
+ {
75
+ "host": "", // Home Assistant instance URL - required, no default
76
+ "api_key": "", // Long-lived access token - required, no default
77
+ "disable_intents": false, // Disable all Home Assistant intents. In most cases, you should just uninstall the skill instead of setting this to true.
78
+ "silent_entities": [], // List of entities to control without voice confirmation
79
+ "brightness_increment": 10, // Percentage to change brightness by
80
+ "search_confidence_threshold": 0.5, // Minimum confidence for entity matching, from 0 to 1 (correlates to a percentage)
81
+ "assist_only": true, // Only pull entities exposed to Home Assistant Assist
82
+ "timeout": 5, // Timeout for Home Assistant API requests in seconds
83
+ "log_level": "INFO" // Logging level (DEBUG, INFO, WARNING, ERROR)
84
+ }
85
+ ```
86
+
87
+ ### Legacy Configuration Support
88
+
89
+ If you're migrating from the previous neon-homeassistant-skill with ovos-PHAL-plugin-homeassistant, the skill will automatically detect and use configuration from your `mycroft.conf` or `neon.yaml`. However, we recommend migrating to the new settings.json location.
90
+
91
+ ### Hostname Considerations
92
+
93
+ Mycroft Mark II may not support `.local` hostnames (e.g., `homeassistant.local`). Options include:
94
+
95
+ 1. Use the IP address of your Home Assistant instance (recommended for local access)
96
+ 2. Use your Nabu Casa DNS if you have a subscription (requires internet connectivity)
97
+ 3. Use a local DNS server that resolves to your Home Assistant instance
98
+
99
+ ## Usage
100
+
101
+ ### Voice Commands
102
+
103
+ #### Lights
104
+
105
+ - "Turn on/off [device name]"
106
+ - "Set [device name] brightness to [X] percent"
107
+ - "Increase/decrease [device name] brightness"
108
+ - "What color is [device name]?"
109
+ - "Set [device name] color to [color]"
110
+ - "What's the brightness of [device name]?"
111
+
112
+ #### Switches
113
+
114
+ - "Turn on/off [device name]"
115
+ - "Toggle [device name]"
116
+
117
+ #### Covers
118
+
119
+ - "Open/Close [device name]"
120
+ - "Set [device name] position to [X] percent"
121
+ - "Stop [device name]"
122
+
123
+ #### Sensors
124
+
125
+ - "What's the temperature in [sensor name]?"
126
+ - "What's the status of [sensor name]?"
127
+
128
+ #### Home Assistant Assist
129
+
130
+ - "Ask Home Assistant [command]" (passes command directly to HA Assist API)
131
+
132
+ ### Silent Mode
133
+
134
+ Add devices to the `silent_entities` list to control them without voice feedback:
135
+
136
+ ```json
137
+ {
138
+ "silent_entities": ["light.kitchen", "switch.office"]
139
+ }
140
+ ```
141
+
142
+ ### Disabling Intents
143
+
144
+ If you don't want the skill's intents enabled (e.g., when shipping in a voice assistant image), set `disable_intents` to true:
145
+
146
+ ```json
147
+ {
148
+ "disable_intents": true
149
+ }
150
+ ```
151
+
152
+ ## Troubleshooting
153
+
154
+ ### Common Issues
155
+
156
+ 1. **Connection Failures**
157
+
158
+ - Verify your Home Assistant instance is reachable
159
+ - Check the host URL format (should include protocol, e.g., `https://`)
160
+ - Ensure your token has the required permissions
161
+
162
+ 2. **Entity Not Found**
163
+
164
+ - Check if the entity is exposed to Home Assistant Assist
165
+ - Verify the entity name matches exactly
166
+ - Try using the entity's friendly name
167
+
168
+ 3. **Authentication Issues**
169
+ - For long-lived tokens: Verify the token is valid and not expired
170
+ - For OAuth: Try re-authenticating with "connect to home assistant"
171
+
172
+ ### Debug Mode
173
+
174
+ Enable debug logging for more detailed information:
175
+
176
+ ```json
177
+ {
178
+ "debug": true,
179
+ "log_level": "DEBUG"
180
+ }
181
+ ```
182
+
183
+ ## Upcoming Features
184
+
185
+ - Vacuum functions
186
+ - HVAC functions
187
+ - Media player control
188
+ - Camera integration
189
+
190
+ ## Contributing
191
+
192
+ Contributions are very welcome! Please read our contributing guidelines and submit pull requests to our GitHub repository.
193
+
194
+ ## License
195
+
196
+ Apache License 2.0
197
+
@@ -0,0 +1,169 @@
1
+ # Home Assistant Skill
2
+
3
+ Control your Home Assistant smart home devices through OVOS or Neon.AI voice assistants.
4
+
5
+ This unified skill is a replacement for the `neon-homeassistant-skill` and `ovos-PHAL-plugin-homeassistant` skill/plugin. Most features are supported, but please report any issues you encounter. **_Note: Do not install both this skill and the previous skills/plugins._**
6
+
7
+ ## Features
8
+
9
+ - Control lights (on/off, brightness, color)
10
+ - Control switches and outlets
11
+ - Monitor sensors
12
+ - Control covers (open/close, position)
13
+ - Silent mode for specific devices
14
+ - Support for Home Assistant Assist API
15
+
16
+ ## Installation on Neon
17
+
18
+ You can `pip install neon-homeassistant-skill`, or handle the installation from the `~/.config/neon/neon.yaml` file if you prefer:
19
+
20
+ ```yaml
21
+ skills:
22
+ default_skills:
23
+ - skill-homeassistant # Optionally with a version, such as skill-homeassistant==0.1.0
24
+ ```
25
+
26
+ ## Configuration
27
+
28
+ ### Authentication Using a Long-lived Token
29
+
30
+ We recommend using a [long-lived token for Home Assistant](https://developers.home-assistant.io/docs/auth_api/#long-lived-access-token). This provides persistent access without requiring re-authentication. Configure it in your skill settings file:
31
+
32
+ - OVOS: `~/.config/mycroft/skills/skill-homeassistant/settings.json`
33
+ - Neon: `~/.config/neon/skills/neon_homeassistant_skill/settings.json`
34
+
35
+ ```json
36
+ {
37
+ "api_key": "<HA_LONG_LIVED_TOKEN>",
38
+ "host": "<HA_IP_OR_HOSTNAME>"
39
+ }
40
+ ```
41
+
42
+ ### Configuration Options
43
+
44
+ All available settings with their defaults:
45
+
46
+ ```jsonc
47
+ {
48
+ "host": "", // Home Assistant instance URL - required, no default
49
+ "api_key": "", // Long-lived access token - required, no default
50
+ "disable_intents": false, // Disable all Home Assistant intents. In most cases, you should just uninstall the skill instead of setting this to true.
51
+ "silent_entities": [], // List of entities to control without voice confirmation
52
+ "brightness_increment": 10, // Percentage to change brightness by
53
+ "search_confidence_threshold": 0.5, // Minimum confidence for entity matching, from 0 to 1 (correlates to a percentage)
54
+ "assist_only": true, // Only pull entities exposed to Home Assistant Assist
55
+ "timeout": 5, // Timeout for Home Assistant API requests in seconds
56
+ "log_level": "INFO" // Logging level (DEBUG, INFO, WARNING, ERROR)
57
+ }
58
+ ```
59
+
60
+ ### Legacy Configuration Support
61
+
62
+ If you're migrating from the previous neon-homeassistant-skill with ovos-PHAL-plugin-homeassistant, the skill will automatically detect and use configuration from your `mycroft.conf` or `neon.yaml`. However, we recommend migrating to the new settings.json location.
63
+
64
+ ### Hostname Considerations
65
+
66
+ Mycroft Mark II may not support `.local` hostnames (e.g., `homeassistant.local`). Options include:
67
+
68
+ 1. Use the IP address of your Home Assistant instance (recommended for local access)
69
+ 2. Use your Nabu Casa DNS if you have a subscription (requires internet connectivity)
70
+ 3. Use a local DNS server that resolves to your Home Assistant instance
71
+
72
+ ## Usage
73
+
74
+ ### Voice Commands
75
+
76
+ #### Lights
77
+
78
+ - "Turn on/off [device name]"
79
+ - "Set [device name] brightness to [X] percent"
80
+ - "Increase/decrease [device name] brightness"
81
+ - "What color is [device name]?"
82
+ - "Set [device name] color to [color]"
83
+ - "What's the brightness of [device name]?"
84
+
85
+ #### Switches
86
+
87
+ - "Turn on/off [device name]"
88
+ - "Toggle [device name]"
89
+
90
+ #### Covers
91
+
92
+ - "Open/Close [device name]"
93
+ - "Set [device name] position to [X] percent"
94
+ - "Stop [device name]"
95
+
96
+ #### Sensors
97
+
98
+ - "What's the temperature in [sensor name]?"
99
+ - "What's the status of [sensor name]?"
100
+
101
+ #### Home Assistant Assist
102
+
103
+ - "Ask Home Assistant [command]" (passes command directly to HA Assist API)
104
+
105
+ ### Silent Mode
106
+
107
+ Add devices to the `silent_entities` list to control them without voice feedback:
108
+
109
+ ```json
110
+ {
111
+ "silent_entities": ["light.kitchen", "switch.office"]
112
+ }
113
+ ```
114
+
115
+ ### Disabling Intents
116
+
117
+ If you don't want the skill's intents enabled (e.g., when shipping in a voice assistant image), set `disable_intents` to true:
118
+
119
+ ```json
120
+ {
121
+ "disable_intents": true
122
+ }
123
+ ```
124
+
125
+ ## Troubleshooting
126
+
127
+ ### Common Issues
128
+
129
+ 1. **Connection Failures**
130
+
131
+ - Verify your Home Assistant instance is reachable
132
+ - Check the host URL format (should include protocol, e.g., `https://`)
133
+ - Ensure your token has the required permissions
134
+
135
+ 2. **Entity Not Found**
136
+
137
+ - Check if the entity is exposed to Home Assistant Assist
138
+ - Verify the entity name matches exactly
139
+ - Try using the entity's friendly name
140
+
141
+ 3. **Authentication Issues**
142
+ - For long-lived tokens: Verify the token is valid and not expired
143
+ - For OAuth: Try re-authenticating with "connect to home assistant"
144
+
145
+ ### Debug Mode
146
+
147
+ Enable debug logging for more detailed information:
148
+
149
+ ```json
150
+ {
151
+ "debug": true,
152
+ "log_level": "DEBUG"
153
+ }
154
+ ```
155
+
156
+ ## Upcoming Features
157
+
158
+ - Vacuum functions
159
+ - HVAC functions
160
+ - Media player control
161
+ - Camera integration
162
+
163
+ ## Contributing
164
+
165
+ Contributions are very welcome! Please read our contributing guidelines and submit pull requests to our GitHub repository.
166
+
167
+ ## License
168
+
169
+ Apache License 2.0
@@ -0,0 +1,88 @@
1
+ [build-system]
2
+ requires = ["poetry_core>=1.0.0"]
3
+ build-backend = "poetry.core.masonry.api"
4
+
5
+ [tool.poetry]
6
+ name = "skill-homeassistant"
7
+ version = "0.1.0"
8
+ description = "A unified OVOS/Neon.AI Skill for Home Assistant."
9
+ authors = ["Mike Gray <mike@oscillatelabs.net>"]
10
+ readme = "README.md"
11
+ license = "Apache-2.0"
12
+ include = ["skill_homeassistant/locale/*"]
13
+ keywords = [
14
+ "ovos",
15
+ "neon",
16
+ "home",
17
+ "assistant",
18
+ "voice",
19
+ "interface",
20
+ "skill",
21
+ "plugin",
22
+ ]
23
+
24
+ [tool.poetry.extras]
25
+ test = ["neon-minerva"]
26
+
27
+ [tool.poetry.dependencies]
28
+ python = "^3.9"
29
+ ovos-bus-client = ">=0.0.8"
30
+ ovos-workshop = ">=0.0.15"
31
+ setuptools = "^75.0.0"
32
+ ovos-plugin-manager = ">=0.0.23"
33
+ ovos-utils = ">=0.0.27"
34
+ ovos-config = ">=0.0.5"
35
+ ovos-phal-plugin-oauth = ">=0.0.3"
36
+ nested-lookup = ">=0.2,<1.0"
37
+
38
+ [tool.poetry.group.dev.dependencies]
39
+ pytest = "*"
40
+ pylint = "*"
41
+ flake8 = "*"
42
+ pydocstyle = "*"
43
+ pycodestyle = "*"
44
+ black = "*"
45
+ mypy = "*"
46
+ bandit = "*"
47
+ types-pyyaml = "*"
48
+ ovos-utils = { version = "*", allow-prereleases = true }
49
+ padacioso = { version = "*", allow-prereleases = true }
50
+ adapt-parser = { git = "https://github.com/mycroftai/adapt" }
51
+ ovos-core = ">=0.0.7"
52
+ poethepoet = "^0.32.1"
53
+ pytest-cov = "^6.0.0"
54
+ toml = "^0.10.2"
55
+ neon-minerva = { version = "~=0.2.0", allow-prereleases = true }
56
+ mock = "^5.1.0"
57
+
58
+ [tool.ruff]
59
+ line-length = 119
60
+
61
+ [tool.black]
62
+ line-length = 119
63
+
64
+ [tool.mypy]
65
+ exclude = ["test"]
66
+
67
+ [tool.isort]
68
+ profile = "black"
69
+
70
+ [tool.poe.tasks.test]
71
+ help = "Run the test suite"
72
+ cmd = "pytest --cov=skill_homeassistant --cov-report term-missing -vv test/"
73
+
74
+ [tool.poe.tasks.format]
75
+ help = "Run code formatters"
76
+ shell = "black --line-length=119 skill_homeassistant && isort --overwrite-in-place skill_homeassistant"
77
+
78
+ [tool.poetry.scripts]
79
+ "neon-homeassistant-skill" = "skill_homeassistant:HomeAssistantSkill"
80
+
81
+ [tool.poetry.plugins."ovos.plugin.skill"]
82
+ "skill_homeassistant.oscillatelabsllc" = "skill_homeassistant:HomeAssistantSkill"
83
+
84
+ [tool.pylint.messages_control]
85
+ disable = [
86
+ "W0718", # broad-except
87
+ "C0415", # import-outside-toplevel
88
+ ]