Ask Yes/No Question Blueprint Update (#39804)

This commit is contained in:
JLo 2025-07-02 10:37:57 +02:00 committed by GitHub
parent 5ab8edfa2d
commit 6b32853f6a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -7,25 +7,11 @@ blueprint:
homeassistant:
min_version: 2025.6.99
input:
voice_assistant:
name: Voice assistant
description: The voice assistant that will be used for that conversation.
selector:
entity:
multiple: false
filter:
- domain: assist_satellite
question:
name: Question
description: The question that will be asked by the voice assistant.
selector:
text:
preannounce:
name: Preannounce
description: Play a sound before the question is asked.
default: true
selector:
boolean:
yes_section:
name: Confirmation ('Yes', 'Of course', ...)
@ -200,6 +186,24 @@ variables:
- Let's skip that
- I'm not comfortable with that
fields:
voice_assistant:
name: Voice assistant
description: The voice assistant that will be used for that conversation.
required: true
selector:
entity:
multiple: false
filter:
- domain: assist_satellite
preannounce:
name: Preannounce
description: Play a sound before the question is asked.
required: true
default: true
selector:
boolean:
sequence:
- variables:
number_of_retries: !input number_of_retries
@ -209,8 +213,8 @@ sequence:
continue_on_error: true
data:
question: !input question
preannounce: !input preannounce
entity_id: !input voice_assistant
preannounce: "{{preannounce}}"
entity_id: "{{voice_assistant}}"
answers:
- id: "yes"
sentences: "{{yes_sentences}}"
@ -229,7 +233,7 @@ sequence:
message: !input yes_answer
preannounce: false
target:
entity_id: !input voice_assistant
entity_id: "{{voice_assistant}}"
- conditions:
- condition: template
value_template: "{{response.id == 'no'}}"
@ -241,7 +245,7 @@ sequence:
message: !input no_answer
preannounce: false
target:
entity_id: !input voice_assistant
entity_id: "{{voice_assistant}}"
default:
- sequence: !input other_actions
- action: assist_satellite.announce
@ -250,7 +254,7 @@ sequence:
message: !input other_answer
preannounce: false
target:
entity_id: !input voice_assistant
entity_id: "{{voice_assistant}}"
until:
- condition: template
value_template: "{{ (response is defined and response.id in ['yes','no']) or repeat.index > number_of_retries}}"