Overview
This plugin allows you to use AsyncAI as a TTS provider for your voice agents.
Installation
Install the plugin from PyPI:
uv add "livekit-agents[asyncai]~=1.4"
Authentication
The AsyncAI plugin requires an AsyncAI API key.
Set ASYNCAI_API_KEY in your .env file.
Usage
Use AsyncAI 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 asyncaisession = AgentSession(tts=asyncai.TTS(model="async_flash_v1.0",)# ... llm, stt, etc.)
Parameters
This section describes some of the parameters you can set when you create an AsyncAI TTS. See the plugin reference links in the Additional resources section for a complete list of all available parameters.
str | TTSModelsOptionalDefault: async_flash_v1.0The AsyncAI TTS model to use. Defaults to "async_flash_v1.0". To learn more, see the AsyncAI documentation.
strOptionalDefault: e0f39dc4-f691-4e78-bba5-5c636692cc04Voice identifier to use for generation. See the voice library for available voice IDs.
LanguageCodeOptionalDefault: NoneLanguage code for synthesis. For supported languages, see the AsyncAI documentation.
Additional resources
The following resources provide more information about using AsyncAI with LiveKit Agents.