Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions deepgram/transcription.py
Original file line number Diff line number Diff line change
Expand Up @@ -312,6 +312,10 @@ def configure(self, config: ToggleConfigOptions) -> None:
"processors": config
})))

def keep_alive(self) -> None:
"""Keeps the connection open when no audio data is being sent."""
self._queue.put_nowait((False, json.dumps({"type": "KeepAlive"})))

async def finish(self) -> None:
"""Closes the connection to the Deepgram endpoint,
waiting until ASR is complete on all submitted data."""
Expand Down