Add audio flushing after sending text in RimeNonJsonTTSService
This update ensures that audio is flushed immediately after sending bare text to the WebSocket, improving the responsiveness of the Text-to-Speech service.
This commit is contained in:
@@ -833,6 +833,7 @@ class RimeNonJsonTTSService(InterruptibleTTSService):
|
||||
# Send bare text (not JSON)
|
||||
await self._get_websocket().send(text)
|
||||
await self.start_tts_usage_metrics(text)
|
||||
await self.flush_audio()
|
||||
|
||||
except Exception as e:
|
||||
logger.error(f"{self} exception: {e}")
|
||||
|
||||
Reference in New Issue
Block a user