future-stone-69754
07/30/2025, 10:27 AMtall-airline-16756
07/30/2025, 10:29 AMtall-airline-16756
07/30/2025, 10:30 AMfuture-stone-69754
07/30/2025, 10:31 AMtall-airline-16756
07/30/2025, 10:32 AMpip install "livekit-agents[aws]~=1.0"
2. Set Up AWS Credentials:
Add the following to your .env file:
AWS_ACCESS_KEY_ID=<aws-access-key-id>
AWS_SECRET_ACCESS_KEY=<aws-secret-access-key>
AWS_DEFAULT_REGION=<aws-deployment-region>
3. Configure Amazon Polly TTS:
Here's a friendly code snippet to get your Cantonese TTS up and running:
from livekit.plugins import aws
session = AgentSession(
tts=aws.TTS(
voice="Ruth", # or another compatible voice
speech_engine="generative",
language="yue-CN", # Yue (Cantonese) language code
),
# ... llm, stt, etc.
)
4. Key Parameters:
⦠language: Set to "yue-CN" for Yue (Cantonese).
⦠voice: Choose a compatible voice that supports Cantonese.
⦠speech_engine: Options include "standard", "neural", "long-form", or "generative".
Pro tip: Make sure you pick a voice that really understands Cantonese ā this'll help you get the most natural-sounding speech possible! š£ļøš
Sources: Amazon Polly TTS integration guide | LiveKit Docs | livekit-plugins/livekit-plugins-aws/livekit/plugins/aws/__init__.pyfuture-stone-69754
07/30/2025, 11:48 AMtall-airline-16756
07/30/2025, 11:49 AMfuture-stone-69754
07/31/2025, 11:50 AM