livekit-plugins-deepgram 1.0.20__py3-none-any.whl → 1.0.22__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -565,10 +565,11 @@ class SpeechStream(stt.SpeechStream):
565
565
  asyncio.create_task(recv_task(ws)),
566
566
  asyncio.create_task(keepalive_task(ws)),
567
567
  ]
568
+ tasks_group = asyncio.gather(*tasks)
568
569
  wait_reconnect_task = asyncio.create_task(self._reconnect_event.wait())
569
570
  try:
570
571
  done, _ = await asyncio.wait(
571
- [asyncio.gather(*tasks), wait_reconnect_task],
572
+ [tasks_group, wait_reconnect_task],
572
573
  return_when=asyncio.FIRST_COMPLETED,
573
574
  ) # type: ignore
574
575
 
@@ -583,6 +584,7 @@ class SpeechStream(stt.SpeechStream):
583
584
  self._reconnect_event.clear()
584
585
  finally:
585
586
  await utils.aio.gracefully_cancel(*tasks, wait_reconnect_task)
587
+ await tasks_group
586
588
  finally:
587
589
  if ws is not None:
588
590
  await ws.close()
@@ -44,7 +44,7 @@ class TTS(tts.TTS):
44
44
  def __init__(
45
45
  self,
46
46
  *,
47
- model: str = "aura-asteria-en",
47
+ model: str = "aura-2-andromeda-en",
48
48
  encoding: str = "linear16",
49
49
  sample_rate: int = 24000,
50
50
  api_key: NotGivenOr[str] = NOT_GIVEN,
@@ -57,7 +57,7 @@ class TTS(tts.TTS):
57
57
  Create a new instance of Deepgram TTS.
58
58
 
59
59
  Args:
60
- model (str): TTS model to use. Defaults to "aura-asteria-en".
60
+ model (str): TTS model to use. Defaults to "aura-2-andromeda-en".
61
61
  encoding (str): Audio encoding to use. Defaults to "linear16".
62
62
  sample_rate (int): Sample rate of audio. Defaults to 24000.
63
63
  api_key (str): Deepgram API key. If not provided, will look for DEEPGRAM_API_KEY in environment.
@@ -221,7 +221,7 @@ class ChunkedStream(tts.ChunkedStream):
221
221
  "Content-Type": "application/json",
222
222
  },
223
223
  json={"text": self._input_text},
224
- timeout=self._conn_options.timeout,
224
+ timeout=aiohttp.ClientTimeout(connect=self._conn_options.timeout, total=30),
225
225
  ) as res:
226
226
  if res.status != 200:
227
227
  raise APIStatusError(
@@ -12,4 +12,4 @@
12
12
  # See the License for the specific language governing permissions and
13
13
  # limitations under the License.
14
14
 
15
- __version__ = "1.0.20"
15
+ __version__ = "1.0.22"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: livekit-plugins-deepgram
3
- Version: 1.0.20
3
+ Version: 1.0.22
4
4
  Summary: Agent Framework plugin for services using Deepgram's API.
5
5
  Project-URL: Documentation, https://docs.livekit.io
6
6
  Project-URL: Website, https://livekit.io/
@@ -18,7 +18,7 @@ Classifier: Topic :: Multimedia :: Sound/Audio
18
18
  Classifier: Topic :: Multimedia :: Video
19
19
  Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
20
20
  Requires-Python: >=3.9.0
21
- Requires-Dist: livekit-agents[codecs]>=1.0.20
21
+ Requires-Dist: livekit-agents[codecs]>=1.0.22
22
22
  Requires-Dist: numpy>=1.26
23
23
  Description-Content-Type: text/markdown
24
24
 
@@ -0,0 +1,11 @@
1
+ livekit/plugins/deepgram/__init__.py,sha256=7sCI3vSCelS8mjtjaIZP_tt61S8KKncEBnuf0urNejw,1358
2
+ livekit/plugins/deepgram/_utils.py,sha256=NgeR4qKZOeqs1wr8v4G2Q_KPZ5xUSFDE4f2N6WXnZH4,2041
3
+ livekit/plugins/deepgram/log.py,sha256=isjd2-ROJXiDFhRRnqRmYxv16U5H9dBV6ut2g5bU7q0,71
4
+ livekit/plugins/deepgram/models.py,sha256=dVguYc9AfjlexreN_O1C0NxX3q-ZK9k8s5B3hWsbtZ0,1236
5
+ livekit/plugins/deepgram/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
6
+ livekit/plugins/deepgram/stt.py,sha256=snDTVjK6r0QJraLL0HzyvCqcy-bAJwuMNWlbJMLFybs,32025
7
+ livekit/plugins/deepgram/tts.py,sha256=PgQfOJFcBoWzOhTJZEnipGo0hxhBzZNqZhtVW9txmUw,15415
8
+ livekit/plugins/deepgram/version.py,sha256=-8dkOE2vDSF9WN8VoBrSwU2sb5YBGFuwPnSQXQ-uaYM,601
9
+ livekit_plugins_deepgram-1.0.22.dist-info/METADATA,sha256=BQmBznN0eyqYstogbyUirMXdPNKffiWbKS9x5NA9PKc,1450
10
+ livekit_plugins_deepgram-1.0.22.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
11
+ livekit_plugins_deepgram-1.0.22.dist-info/RECORD,,
@@ -1,11 +0,0 @@
1
- livekit/plugins/deepgram/__init__.py,sha256=7sCI3vSCelS8mjtjaIZP_tt61S8KKncEBnuf0urNejw,1358
2
- livekit/plugins/deepgram/_utils.py,sha256=NgeR4qKZOeqs1wr8v4G2Q_KPZ5xUSFDE4f2N6WXnZH4,2041
3
- livekit/plugins/deepgram/log.py,sha256=isjd2-ROJXiDFhRRnqRmYxv16U5H9dBV6ut2g5bU7q0,71
4
- livekit/plugins/deepgram/models.py,sha256=dVguYc9AfjlexreN_O1C0NxX3q-ZK9k8s5B3hWsbtZ0,1236
5
- livekit/plugins/deepgram/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
6
- livekit/plugins/deepgram/stt.py,sha256=Ja2ESKoT0cquj2HXEPi1iWP_52HwQaU8jpWY4_ZlauA,31945
7
- livekit/plugins/deepgram/tts.py,sha256=Ysi6_8CGtLlTvyBorfAZW2JLyptprk_0LKFlTJhfndU,15366
8
- livekit/plugins/deepgram/version.py,sha256=t4KmPVTpEy1pOJ2GRCA-GNJfCQq_-zHNDBxGj4GKfVk,601
9
- livekit_plugins_deepgram-1.0.20.dist-info/METADATA,sha256=7aOUDoNhmbipUGlVw4Tc72iAv_etvaBFERvzEtromtM,1450
10
- livekit_plugins_deepgram-1.0.20.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
11
- livekit_plugins_deepgram-1.0.20.dist-info/RECORD,,