Deepgram TTS integration guide

How to use the Deepgram TTS plugin for LiveKit Agents.

Overview

Deepgram provides responsive, human-like text-to-speech technology for voice AI. With LiveKit's Deepgram integration and the Agents framework, you can build voice AI agents that sound realistic.

Quick reference

This section provides a quick reference for the Deepgram TTS plugin. For more information, see Additional resources.

Installation

Install the plugin from PyPI:

pip install "livekit-agents[deepgram]~=1.0rc"

Authentication

The Deepgram plugin requires a Deepgram API key.

Set DEEPGRAM_API_KEY in your .env file.

Usage

Use Deepgram TTS within an AgentSession or as a standalone speech generator. For example, you can use this TTS in the Voice AI quickstart.

from livekit.plugins import deepgram
session = AgentSession(
tts=deepgram.TTS(
model="aura-asteria-en",
)
# ... llm, stt, etc.
)

Parameters

This section describes some of the available parameters. See the plugin reference for a complete list of all available parameters.

modelstringOptionalDefault: aura-asteria-en

ID of the model to use for generation. To learn more, see supported models.

Prompting

Deepgram supports filler words and natural pauses through prompting. To learn more, see Text to Speech Prompting.

Additional resources

The following resources provide more information about using Deepgram with LiveKit Agents.