Skip to main content

LMNT TTS integration guide

How to use the LMNT TTS plugin for LiveKit Agents.

Overview

LMNT provides a fast text-to-speech service optimized for realtime voice AI. With LiveKit's LMNT integration and the Agents framework, you can build high-performance and lifelike voice AI at scale.

Quick reference

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

Installation

Install the plugin from PyPI:

pip install "livekit-agents[lmnt]~=1.0"

Authentication

The LMNT plugin requires an LMNT API key.

Set LMNT_API_KEY in your .env file.

Usage

Use LMNT 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 lmnt
session = AgentSession(
tts=lmnt.TTS(
voice="leah",
)
# ... llm, stt, etc.
)

Parameters

This section describes some of the parameters you can set when you create an LMNT TTS. See the plugin reference for a complete list of all available parameters.

modelstringOptionalDefault: blizzard

The model to use for synthesis. Refer to the LMNT models guide for possible values.

voicestringOptionalDefault: leah

The voice ID to use. Find or create new voices in the LMNT voice library.

languagestringOptional

Two-letter ISO 639-1 language code. See the LMNT API documentation for supported languages.

temperaturefloatOptional

Influences how expressive and emotionally varied the speech becomes. Lower values (like 0.3) create more neutral, consistent speaking styles. Higher values (like 1.0) allow for more dynamic emotional range and speaking styles.

top_pfloatOptional

Controls the stability of the generated speech. A lower value (like 0.3) produces more consistent, reliable speech. A higher value (like 0.9) gives more flexibility in how words are spoken, but might occasionally produce unusual intonations or speech patterns.

Additional resources

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

Voice AI quickstart

Get started with LiveKit Agents and LMNT TTS.