Remember assistant name preferences in chat
CI / test (push) Successful in 1m4s
CI / test (pull_request) Successful in 59s

This commit is contained in:
m
2026-08-25 02:16:15 +03:00
parent ce07163541
commit eefd54137c
5 changed files with 114 additions and 5 deletions
+5
View File
@@ -307,6 +307,11 @@ func semanticReply(message string, result SemanticResult, previousFocus *situati
return "Фокус переключён: " + result.ActiveFocus.ProjectDisplayName + "."
}
switch result.Interpretation.SpeechAct {
case interaction.SpeechActPreference:
if name := PreferredAssistantName(message); name != "" {
return "Хорошо, зови меня " + name + "."
}
return "Хорошо, учту это дальше."
case interaction.SpeechActAssertion:
if result.Interpretation.Applicability == interaction.SemanticNeedsBroaderInterpret || result.Interpretation.Applicability == interaction.SemanticLowConfidence {
return "Смысл сообщения пока понят недостаточно надёжно. Я сохраню его и при доступности более широкого когнитивного разбора не буду притворяться, что это уже проверенный факт."