Assist - Custom responses

I need your help cause I don’t understand how to fix my prob. I tried many things…

/config/configuration.yaml :

# Loads default set of integrations. Do not remove.
default_config:

cloud:
conversation:
intent_script:
persistent_notification:
logger:

# Load frontend themes from the themes folder
frontend:
  themes: !include_dir_merge_named themes

# Text-to-speech
tts:
  - platform: google_translate

automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml

/config/custom_sentences/fr/climate_HassClimateGetTemperature.yaml :
cf. intents/sentences/fr/climate_HassClimateGetTemperature.yaml at a792e9c0ae90d5edea056ad4bc3641190903afcd · home-assistant/intents · GitHub

language: fr
intents:
  HassClimateGetTemperature:
    data:
      - sentences:
          - "[il fait] combien [fait-il|il fait] dans [la|le] <area>"
          - "quelle [est la] température [fait-il|il fait] [de|dans|du] [la|le] <area>"
          - "[donnes-moi|c'est quoi] la température [de|dans|du] [la|le] <area>"

/config/custom_sentences/fr/HassClimateGetTemperature.yaml :
cf. intents/responses/fr/HassClimateGetTemperature.yaml at a792e9c0ae90d5edea056ad4bc3641190903afcd · home-assistant/intents · GitHub

language: fr
responses:
  intents:
    HassClimateGetTemperature:
      default: "{{ state.state_with_unit }}"

all looks ok but…

and on homeassistant.log :

Jun 24 19:30:01 nabaztag homeassistant[761]: #033[31m2023-06-24 19:30:01.995 ERROR (MainThread) [homeassistant.components.assist_pipeline.pipeline] Unexpected error during intent recognition
Jun 24 19:30:01 nabaztag homeassistant[761]: Traceback (most recent call last):
Jun 24 19:30:01 nabaztag homeassistant[761]:   File "/usr/src/homeassistant/homeassistant/components/assist_pipeline/pipeline.py", line 520, in recognize_intent
Jun 24 19:30:01 nabaztag homeassistant[761]:     conversation_result = await conversation.async_converse(
Jun 24 19:30:01 nabaztag homeassistant[761]:                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Jun 24 19:30:01 nabaztag homeassistant[761]:   File "/usr/src/homeassistant/homeassistant/components/conversation/__init__.py", line 373, in async_converse
Jun 24 19:30:01 nabaztag homeassistant[761]:     result = await agent.async_process(
Jun 24 19:30:01 nabaztag homeassistant[761]:              ^^^^^^^^^^^^^^^^^^^^^^^^^^
Jun 24 19:30:02 nabaztag homeassistant[761]:   File "/usr/src/homeassistant/homeassistant/components/conversation/default_agent.py", line 187, in async_process
Jun 24 19:30:02 nabaztag homeassistant[761]:     intent_response = await intent.async_handle(
Jun 24 19:30:02 nabaztag homeassistant[761]:                       ^^^^^^^^^^^^^^^^^^^^^^^^^^
Jun 24 19:30:02 nabaztag homeassistant[761]:   File "/usr/src/homeassistant/homeassistant/helpers/intent.py", line 75, in async_handle
Jun 24 19:30:02 nabaztag homeassistant[761]:     raise UnknownIntent(f"Unknown intent {intent_type}")
Jun 24 19:30:02 nabaztag homeassistant[761]: homeassistant.helpers.intent.UnknownIntent: Unknown intent HassClimateGetTemperature#033[0m

thanks for you help

I did that before on configuration.yaml :

conversation:
  intents:
    CustomGetTemperatureRoom:
      - "[il fait] combien [fait-il|il fait] dans [la|le] {area}"
      - "quelle [est la] température [fait-il|il fait] [de|dans|du] [la|le] {area}"
      - "[donnes-moi|c'est quoi] la température [de|dans|du] [la|le] {area}"
intent_script:
  CustomGetTemperatureRoom:
    speech: 
      text: "La température dans la chambre de Gabriel est de {{ states('sensor.esp_32_d1_mini_temperature_2') }}"

it was ok but with an entity fixed. I wanted the entity with the assist alias “température” on the area. I have 5 areas with that.

(…)

after few hours I did that on configuration.yaml :

persistent_notification:
conversation:
  intents:
    CustomGetTemperatureRoom:
      - "[il fait] combien [fait-il|il fait] dans [la|le] {area}"
      - "quelle [est la] température [fait-il|il fait] [de|dans|du] [la|le] {area}"
      - "[donnes-moi|c'est quoi] la température [de|dans|du] [la|le] {area}"
intent_script:
  CustomGetTemperatureRoom:
    speech: 
      text: >
        {% for entity in area_entities(area) if entity is match(".*temperature.*") %}
          {{ states(entity) }} °C
        {% endfor %}
    action:
      - event: debug_notification
        event_data_template:
          message: >
            # AREA = {{ area }}
            {% for entity in area_entities(area) if entity is match(".*temperature.*") %}
              {{ entity }}={{ states(entity) }}
            {% endfor %}

about the debug I add that on automatisations.yaml :

# DEBUG SYSTEM 
- alias: "Debug Notification"
  trigger:
    platform: event
    event_type: debug_notification
  action:
    service: persistent_notification.create
    data_template:
      message: "{{ trigger.event.data.message }}"
      title: "Debug Info"

but…

if the native system catch something, it reply (here : “Température est 24.3 °C”)

Edit :

Ok great, I have no sensor in the garden (jardin)…
this assistant is not very functional…