fix(deepgram): keep the pooled Flux TTS websocket alive between turnsj - #7098
Open
false-vacuum wants to merge 1 commit into
Open
fix(deepgram): keep the pooled Flux TTS websocket alive between turnsj#7098false-vacuum wants to merge 1 commit into
false-vacuum wants to merge 1 commit into
Conversation
Deepgram closes a Flux TTS session that receives no client message for
60 seconds (NET-0004). TTSv2 pools its streaming websocket for up to an
hour and sends nothing on it between turns, so any pause longer than a
minute leaves the next turn on a closed socket: either the queued Error
frame ("Deepgram Flux TTS returned error") or a write to the closing
transport (APIConnectionError). Under a FallbackAdapter the turn is
spoken by the next TTS and Flux is marked unavailable until a probe
recovers it.
Pass aiohttp's `heartbeat` on the pooled ws_connect, so the client
pings the idle socket and Deepgram's timer keeps resetting. Exposed as
`keepalive_interval` on TTSv2, defaulting to 30s (half the window, the
interval stt_v2 already uses); None disables it.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Deepgram closes a Flux TTS session that receives no client message for 60 seconds (NET-0004). TTSv2 pools its streaming websocket for up to an hour and sends nothing on it between turns, so any pause longer than a minute leaves the next turn on a closed socket: either the queued Error frame ("Deepgram Flux TTS returned error") or a write to the closing transport (APIConnectionError). Under a FallbackAdapter the turn is spoken by the next TTS and Flux is marked unavailable until a probe recovers it.
Pass aiohttp's
heartbeaton the pooled ws_connect, so the client pings the idle socket and Deepgram's timer keeps resetting. Exposed askeepalive_intervalon TTSv2, defaulting to 30s (half the window, the interval stt_v2 already uses); None disables it.