From 15c717fcb0204bf4a0d4b4b4c6f0bb93e9f6c9a9 Mon Sep 17 00:00:00 2001 From: SMKRV Date: Tue, 10 Dec 2024 17:02:48 +0300 Subject: [PATCH] fix: Display only last Q&A in sensor state to prevent data truncation - Show only the latest question and answer in sensor state - Keep full conversation history in attributes - Fix truncation issues in Home Assistant UI - Maintain backwards compatibility - No configuration changes required --- custom_components/ha_text_ai/const.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/custom_components/ha_text_ai/const.py b/custom_components/ha_text_ai/const.py index add50f2..fd00e00 100644 --- a/custom_components/ha_text_ai/const.py +++ b/custom_components/ha_text_ai/const.py @@ -56,7 +56,7 @@ DEFAULT_NAME: Final = "HA Text AI" DEFAULT_NAME_PREFIX = "ha_text_ai" DEFAULT_CONTEXT_MESSAGES: Final = 5 -TRUNCATION_INDICATOR = " … " +TRUNCATION_INDICATOR = " ... " # Parameter constraints MIN_TEMPERATURE: Final = 0.0