Skip to main content

Amazon Nova Sonic integration guide

How to use the Amazon Nova Sonic model with LiveKit Agents.

Available in
Python

Overview

Amazon Nova Sonic is a state of the art speech-to-speech model with a bidirectional audio streaming API. Nova Sonic processes and responds to realtime speech as it occurs, enabling natural, human-like conversational experiences. LiveKit's AWS plugin includes support for Nova Sonic on AWS Bedrock, allowing you to use this model to create true realtime conversational agents.

Quick reference

This section includes a basic usage example and some reference material. For links to more detailed documentation, see Additional resources.

Installation

Install the AWS plugin from PyPI with the realtime extra:

pip install "livekit-plugins-aws[realtime]"

Authentication

The AWS plugin requires AWS credentials. Set the following environment variables in your .env file:

AWS_ACCESS_KEY_ID=<your-aws-access-key-id>
AWS_SECRET_ACCESS_KEY=<your-aws-secret-access-key>

Usage

Use the Nova Sonic API within an AgentSession. For example, you can use it in the Voice AI quickstart.

from livekit.plugins import aws
session = AgentSession(
llm=aws.realtime.RealtimeModel(),
)

Parameters

This section describes some of the available parameters. For a complete reference of all available parameters, see the plugin reference.

voicestringOptional

Name of the Nova Sonic API voice. For a full list, see Voices.

regionstringOptional

AWS region of the Bedrock runtime endpoint.

Turn detection

The Nova Sonic API includes built-in VAD-based turn detection, which is currently the only supported turn detection method.

Additional resources

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