I have several Alexa skills that I have created over the years to "Tell the house" or "Tell the thermostat", that execute intent scripts to do things in Home Assistant.
I'm trying to convert those to work locally with HA using Assist and Intents, but keep running into a couple of issues on the first (and probably easiest) of the intents.
First, I keep getting "no_intent_match" for one of my sentences (I want to watch TV) - even after copying/pasting the sentence directly from the Debug Assistant Speech-to-text output. But the other sentence for the same intent is working. Any ideas on how to resolve this?
custom_sentences/en/WatchTV.yaml:
language: en
intents:
WatchTv:
data:
- sentences:
- I want to watch TV # this doesn't work
- (I'm | I am) going to watch TV # this does work
Second, I'm trying to reuse the Alexa intent scripts for the local intents (the actions are working for both), but Alexa requires the "type:ssml" and that the text be wrapped in <speak></speak> tags. Is there any way to use the same intent script for both Alexa and HA intents and get the text to work for both?
intent script output that works for Alexa:
WatchTv:
action:
- service: ... stuf happens here...
speech:
type: ssml
text: >
{%- if (not area is defined) or (area == '') -%}
{%- set where = 'living room' -%}
{%- else -%}
{%- set where = area -%}
{%- endif %}
<speak>Powering up the home theater in the {{where}}</speak>