fix: should work now

Also added trimming to Windows transcription.

ref: N25B-452
This commit is contained in:
2026-01-19 15:03:59 +01:00
parent c0789e82a9
commit 1cd5b46f97
2 changed files with 5 additions and 3 deletions

View File

@@ -90,7 +90,7 @@ class LLMAgent(BaseAgent):
full_message = ""
async for chunk in self._query_llm(message.text, message.norms, message.goals):
if self._interrupted:
self._interrupted_message = message
self._interrupted_message = message.text
self.logger.debug("Interrupted processing of previous message.")
break
await self._send_reply(chunk)
@@ -173,7 +173,7 @@ class LLMAgent(BaseAgent):
full_message += token
current_chunk += token
self.logger.debug(
self.logger.llm(
"Received token: %s",
full_message,
extra={"reference": message_id}, # Used in the UI to update old logs

View File

@@ -145,4 +145,6 @@ class OpenAIWhisperSpeechRecognizer(SpeechRecognizer):
def recognize_speech(self, audio: np.ndarray) -> str:
self.load_model()
return whisper.transcribe(self.model, audio, **self._get_decode_options(audio))["text"]
return whisper.transcribe(self.model, audio, **self._get_decode_options(audio))[
"text"
].strip()