mirror of
https://github.com/CCOSTAN/Home-AssistantConfig.git
synced 2025-12-03 11:31:42 +00:00
- Updated home_stats.yaml with detailed descriptions for home status automation. - Expanded vacuum.yaml to include new input helpers and automation scripts for managing vacuum cleaning schedules and states. - Refined speech_engine.yaml to clarify usage and functionality for sending notifications. - Modified briefing.yaml to include a new macro for reporting cleaned rooms by the vacuum. These changes aim to improve clarity, usability, and functionality across the automation scripts and configurations.
62 lines
2.6 KiB
YAML
Executable File
62 lines
2.6 KiB
YAML
Executable File
######################################################################
|
|
# @CCOSTAN - Follow Me on X
|
|
# For more info visit https://www.vcloudinfo.com/click-here
|
|
# Original Repo : https://github.com/CCOSTAN/Home-AssistantConfig
|
|
# -------------------------------------------------------------------
|
|
# Speech Engine Script - queued announcements to Chromecast targets
|
|
# Sends templated speech briefings to media players when family/guests are home.
|
|
# -------------------------------------------------------------------
|
|
# Notes: Optional call_* flags control sections (dark_outside, window/garage checks, garbage day, inside/outside weather). Defaults to living room Chromecast if no media_player is provided.
|
|
######################################################################
|
|
# Usage example:
|
|
# service: script.speech_engine
|
|
# data:
|
|
# call_no_announcement: 1
|
|
# call_dark_outside: 1
|
|
# call_window_check: 1
|
|
# call_garage_check: 1
|
|
# call_garbage_day: 1
|
|
# call_inside_weather: 1
|
|
# call_outside_weather: 1
|
|
|
|
# Define the "speech_engine" script
|
|
speech_engine:
|
|
# Set the mode to "queued"
|
|
mode: queued
|
|
# Define the sequence of actions to be performed
|
|
sequence:
|
|
# If the state of the "group.family" entity is "home" or the state of the "input_boolean.guest_mode" entity is "on", proceed with the script
|
|
- condition: or
|
|
conditions:
|
|
- condition: state
|
|
entity_id: group.family
|
|
state: 'home'
|
|
- condition: state
|
|
entity_id: input_boolean.guest_mode
|
|
state: 'on'
|
|
|
|
# Run the "script.speech_processing" service with the specified media player and speech message
|
|
- service: script.speech_processing
|
|
data:
|
|
# Set the entity ID for the media players to be controlled
|
|
# If the "media_player" variable is not defined, set it to a list of media player entities
|
|
# If the "media_player" variable is a list, convert it to a comma-separated string
|
|
media_player: >-
|
|
{% if media_player | length == 0 %}
|
|
{% set media_player = [
|
|
'media_player.livingroomcc'
|
|
] %}
|
|
{% endif %}
|
|
{% if media_player is not string and media_player is sequence %}
|
|
{% set media_player = media_player|join(', ') %}
|
|
{% endif %}
|
|
{{ media_player }}
|
|
# Include the speech message from the "speech/briefing.yaml" template file
|
|
speech_message: !include ../templates/speech/briefing.yaml
|
|
|
|
# Turn off the "input_boolean.home_stats"
|
|
- service: input_boolean.turn_off
|
|
data:
|
|
entity_id:
|
|
- input_boolean.home_stats
|