Getting this error even though I downloaded all de...
# ask-ai
f
Getting this error even though I downloaded all depndencies: Traceback (most recent call last): File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/venv/lib/python3.11/site-packages/livekit/plugins/aws/__init__.py", line 32, in getattr from .experimental import realtime File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/venv/lib/python3.11/site-packages/livekit/plugins/aws/experimental/realtime/__init__.py", line 1, in <module> from .realtime_model import RealtimeModel, RealtimeSession File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/venv/lib/python3.11/site-packages/livekit/plugins/aws/experimental/realtime/realtime_model.py", line 19, in <module> from aws_sdk_bedrock_runtime.client import ( ModuleNotFoundError: No module named 'aws_sdk_bedrock_runtime' The above exception was the direct cause of the following exception: Traceback (most recent call last): File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/agent.py", line 1533, in entrypoint llm=aws.realtime.RealtimeModel( ^^^^^^^^^^^^ File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/venv/lib/python3.11/site-packages/livekit/plugins/aws/__init__.py", line 34, in getattr raise ImportError( ImportError: The 'realtime' module requires optional dependencies. Please install them with: pip install 'livekit-plugins-aws[realtime]' 164649 livekit.agents ERROR unhandled exception while running the job task Traceback (most recent call last): File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/venv/lib/python3.11/site-packages/livekit/plugins/aws/__init__.py", line 32, in getattr from .experimental import realtime File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/venv/lib/python3.11/site-packages/livekit/plugins/aws/experimental/realtime/__init__.py", line 1, in <module> from .realtime_model import RealtimeModel, RealtimeSession File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/venv/lib/python3.11/site-packages/livekit/plugins/aws/experimental/realtime/realtime_model.py", line 19, in <module> from aws_sdk_bedrock_runtime.client import ( ModuleNotFoundError: No module named 'aws_sdk_bedrock_runtime' The above exception was the direct cause of the following exception: Traceback (most recent call last): File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/agent.py", line 1533, in entrypoint llm=aws.realtime.RealtimeModel( ^^^^^^^^^^^^ File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/venv/lib/python3.11/site-packages/livekit/plugins/aws/__init__.py", line 34, in getattr raise ImportError( ImportError: The 'realtime' module requires optional dependencies. Please install them with: pip install 'livekit-plugins-aws[realtime]' 2025-07-10 164649,364 - ERROR livekit.agents - unhandled exception while running the job task Traceback (most recent call last): File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/venv/lib/python3.11/site-packages/livekit/plugins/aws/__init__.py", line 32, in getattr from .experimental import realtime File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/venv/lib/python3.11/site-packages/livekit/plugins/aws/experimental/realtime/__init__.py", line 1, in <module> from .realtime_model import RealtimeModel, RealtimeSession File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/venv/lib/python3.11/site-packages/livekit/plugins/aws/experimental/realtime/realtime_model.py", line 19, in <module> from aws_sdk_bedrock_runtime.client import ( ModuleNotFoundError: No module named 'aws_sdk_bedrock_runtime' The above exception was the direct cause of the following exception: Traceback (most recent call last): File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/agent.py", line 1533, in entrypoint llm=aws.realtime.RealtimeModel( ^^^^^^^^^^^^ File "/Users/muthanaalhadrab/dev/BytesAI/voice-agent/venv/lib/python3.11/site-packages/livekit/plugins/aws/__init__.py", line 34, in getattr raise ImportError( ImportError: The 'realtime' module requires optional dependencies. Please install them with: pip install 'livekit-plugins-aws[realtime]' {"session_id": "-", "pid": 4680, "job_id": "AJ_YNBDjmdnNfyV"}
t
Thanks for reaching out, Muthana. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
The error you're seeing occurs because the
realtime
module in
livekit.plugins.aws
requires optional dependencies that are not installed by default. Here’s how to resolve the issue: • Python Version Requirement: The
aws-sdk-bedrock-runtime
package is only available for Python 3.12 and above. If you are using Python 3.11 or below, you will need to upgrade your environment to Python 3.12 or later. • Install Optional Dependencies: After confirming your Python version, install the necessary extras with:
pip install 'livekit-plugins-aws[realtime]'
Verify Installation: Check that both
aws-sdk-bedrock-runtime==0.0.2
and
boto3>1.35.10
are installed. If you continue to have issues, try clearing your pip cache and installing in a clean virtual environment. If you have already upgraded Python and installed with the
[realtime]
extra but still see the error, please provide the output of:
Copy code
python --version
pip show livekit-plugins-aws
pip show aws-sdk-bedrock-runtime
This will help to diagnose if there are any version mismatches or missing packages. Sources: livekit-plugins/livekit-plugins-aws/livekit/plugins/aws/log.py | Amazon Nova Sonic integration guide | LiveKit Docs