#1368 - More voice enhancements and prompt adjustments
This commit is contained in:
parent
d9af5da123
commit
4e7f5c182e
|
@ -38,21 +38,11 @@
|
|||
data:
|
||||
personarriving: >
|
||||
{% set person = expand('group.arriving')|map(attribute='name')|join(' and ') %}
|
||||
{% set peoplecount = expand('group.arriving') | count %}
|
||||
{% if peoplecount == 1 %}
|
||||
{% set is_are = ' is ' %}
|
||||
{% else %}
|
||||
{% set is_are = ' are ' %}
|
||||
{% endif %}
|
||||
{%- macro greeting_sentence(person, is_are) -%}
|
||||
{{ [
|
||||
"Welcome back home " ~ person,
|
||||
person ~ is_are + " home now."
|
||||
] | random }}
|
||||
[Welcome them home in a random style]
|
||||
{%- macro greeting_sentence(person) -%}
|
||||
{{ ["[Welcome " ~ person + " home]"] }}
|
||||
{%- endmacro -%}
|
||||
|
||||
{{greeting_sentence(person, is_are)}}
|
||||
{{greeting_sentence(person)}}
|
||||
call_responsibilities: 1
|
||||
call_no_announcement: 1
|
||||
call_garage_check: 1
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
to: 'rain'
|
||||
- platform: numeric_state
|
||||
entity_id: sensor.pirateweather_precip_intensity
|
||||
above: 0.2
|
||||
above: 0.5
|
||||
- platform: numeric_state
|
||||
entity_id: sensor.blitzortung_lightning_counter
|
||||
above: 1
|
||||
|
@ -30,9 +30,6 @@
|
|||
conditions:
|
||||
- condition: or
|
||||
conditions:
|
||||
# - condition: numeric_state
|
||||
# entity_id: sensor.pirateweather_cloud_coverage
|
||||
# above: 90
|
||||
- condition: numeric_state
|
||||
entity_id: sensor.pirateweather_precip_intensity
|
||||
above: 0.2
|
||||
|
@ -64,6 +61,7 @@
|
|||
- service: script.speech_engine
|
||||
data:
|
||||
value1: "Because of the {{trigger.entity_id.split('_')[2]|replace('precip','rain')|replace('counter','lightning')|replace('carlo','rain') }} {{trigger.entity_id.split('_')[3]|replace('intensity',' ')| replace('carlo','and clouds')}} outside. I will turn on some extra lights in the living room."
|
||||
call_outside_weather: 1
|
||||
call_window_check: 1
|
||||
call_garage_check: 1
|
||||
|
||||
|
|
|
@ -320,5 +320,5 @@ automation:
|
|||
|
||||
- service: script.speech_engine
|
||||
data:
|
||||
value1: "Please check the garage doors. The Small garage is {{ states('cover.small_garage_door')}} and the large garage is {{ states('cover.large_garage_door')}} [Only mention the garage door that is open]"
|
||||
value1: "Check the garage doors. The Small garage is {{ states('cover.small_garage_door')}} and the large garage is {{ states('cover.large_garage_door')}} [Only mention the garage door that is open]"
|
||||
|
||||
|
|
|
@ -17,23 +17,49 @@
|
|||
{% else %}
|
||||
Today is Paige's day to do the chores.
|
||||
{% endif %}
|
||||
[Only mention chores if today is garbage day or if this is the only information point you have]
|
||||
[Only mention chores if today is garbage day or if this is the only information you have]
|
||||
{%- endmacro -%}
|
||||
|
||||
{%- macro inside_weather() -%}
|
||||
Inside the house, it is {{ states.climate.downstairs.attributes['current_temperature'] }} degrees with {{ states('sensor.downstairs_thermostat_humidity') }} percent humidity. [Only mention humidity if it seems unusually high]
|
||||
Inside the house, it is {{ states.climate.downstairs.attributes['current_temperature'] }} degrees with {{ states('sensor.downstairs_thermostat_humidity') }} percent humidity. [Only mention humidity if it seems unusually high]
|
||||
{%- endmacro -%}
|
||||
|
||||
{%- macro outside_weather() -%}
|
||||
{%- macro outside_weather2() -%}
|
||||
Outside, it is going to be {{ states('sensor.pirateweather_temperature') }} degrees and {{ states('sensor.pirateweather_summary') }} with {{ states('sensor.pirateweather_humidity') }} % humidity. [Only mention humidity if it seems unusually high]
|
||||
{%- endmacro -%}
|
||||
|
||||
{% macro outside_weather() %}
|
||||
[Here is the current weather outside]
|
||||
{%- for entity in states.sensor if 'pirateweather' in entity.entity_id %}
|
||||
{%- set state = entity.state %}
|
||||
{%- set unit = entity.attributes.unit_of_measurement if 'unit_of_measurement' in entity.attributes else '' %}
|
||||
{%- set friendly_name = ' '.join(entity.attributes.friendly_name.split(' ')[1:]) %}
|
||||
{%- if state not in ['0', '0.0', 'none'] and 'UV Index' not in friendly_name %}
|
||||
{%- if 'Temperature' in friendly_name -%}
|
||||
{{ friendly_name }}: {{ state }} {{ unit }}
|
||||
{%- elif 'Minutely' in friendly_name -%}
|
||||
{{ friendly_name }}: {{ state }} {{ unit }}
|
||||
{%- elif 'Precip' in friendly_name -%}
|
||||
{{ friendly_name }}: {{ state }} {{ unit }}
|
||||
{%- elif 'Wind Speed' in friendly_name and state | float > 15 -%}
|
||||
{{ friendly_name }}: {{ state }} {{ unit }}
|
||||
{%- elif 'Cloud Coverage' in friendly_name and state | float > 75 -%}
|
||||
{{ friendly_name }}: {{ state }} {{ unit }}
|
||||
{%- elif 'Humidity' in friendly_name and (state | float < 50 or state | float > 85) -%}
|
||||
{{ friendly_name }}: {{ state }} {{ unit }}
|
||||
{%- elif 'Nearest Storm Distance' in friendly_name and state | float <= 10 -%}
|
||||
{{ friendly_name }}: {{ state }} {{ unit }}
|
||||
{%- endif -%}
|
||||
{%- endif %}
|
||||
{% endfor -%}
|
||||
{%- endmacro -%}
|
||||
|
||||
{%- macro lightning() -%}
|
||||
There have been {{ states('sensor.blitzortung_lightning_counter') }} lightning strikes detected within {{(states('sensor.blitzortung_lightning_distance') | int(9999)/ 1.69) | round (1, 'floor')}} Miles of our House. Please make sure everyone is inside the house.
|
||||
There have been {{ states('sensor.blitzortung_lightning_counter') }} lightning strikes detected within {{(states('sensor.blitzortung_lightning_distance') | int(9999)/ 1.69) | round (1, 'floor')}} Miles of our House. Please make sure everyone is inside the house.
|
||||
{%- endmacro -%}
|
||||
|
||||
{%- macro fridge() -%}
|
||||
The internal temperature of the refrigerator is currently {{ states('sensor.blink_blink1_temperature') }} degrees.
|
||||
The internal temperature of the refrigerator is currently {{ states('sensor.blink_blink1_temperature') }} degrees.
|
||||
{%- endmacro -%}
|
||||
|
||||
{%- macro light_check() -%}
|
||||
|
@ -175,7 +201,7 @@
|
|||
{% endmacro %}
|
||||
|
||||
{%- macro traffic_time() -%}
|
||||
Current traffic to Spectrum Offices: {{ states.sensor.waze_travel_time.state }} minutes.
|
||||
Travel Time to Spectrum: {{ states.sensor.waze_travel_time.state }} minutes.
|
||||
{%- endmacro -%}
|
||||
|
||||
{# a macro that removes all newline characters, empty spaces, and returns formatted text and replaces underscores with spaces #}
|
||||
|
|
Loading…
Reference in New Issue