Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

agents 0.12.6 AttributeError: 'RealtimeModel' object has no attribute 'capabilities' #1329

Closed
gianpaj opened this issue Jan 2, 2025 · 3 comments
Labels
bug Something isn't working

Comments

@gianpaj
Copy link

gianpaj commented Jan 2, 2025

The latest version throws these errors:

2025-01-02 17:56:23,429 - ERROR livekit.agents - Error in _main_task
Traceback (most recent call last):
  File ".venv/lib/python3.11/site-packages/livekit/agents/utils/log.py", line 16, in async_fn_logs
    return await fn(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File ".venv/lib/python3.11/site-packages/livekit/agents/multimodal/multimodal_agent.py", line 440, in _main_task
    self._session._push_audio(f)
    ^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'RealtimeSession' object has no attribute '_push_audio' {"pid": 70605, "job_id": "AJ_XKj9HCV3ev3q"}

...

025-01-02 17:56:44,426 - ERROR livekit - failed to emit event playout_stopped
Traceback (most recent call last):
  File ".venv/lib/python3.11/site-packages/livekit/rtc/event_emitter.py", line 58, in emit
    callback(*callback_args)
  File ".venv/lib/python3.11/site-packages/livekit/agents/multimodal/multimodal_agent.py", line 403, in _on_playout_stopped
    if self._model.capabilities.supports_truncate:
       ^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'RealtimeModel' object has no attribute 'capabilities' {"pid": 70605, "job_id": "AJ_XKj9HCV3ev3q"}

I'm using the same code as in main.py in the playground
https://github.com/livekit-examples/realtime-playground/blob/main/agent/main.py#L107-L118

The effect is that the AI voice comes through but the user's voice is not sent to OpenAI

This doesn't occur with 0.12.5

$ uv pip list | grep livekit
livekit                0.18.3
livekit-agents         0.12.6
livekit-api            0.8.1
livekit-plugins-openai 0.10.11
livekit-protocol       0.8.0

Also, not sure if it is related, but there's a type error now
SCR-20250102-pupq

@gianpaj gianpaj added the bug Something isn't working label Jan 2, 2025
@gianpaj
Copy link
Author

gianpaj commented Jan 2, 2025

Copy link
Member

this is an issue with incompatible versions of the openai plugin. can you update the plugin to 0.10.13 ?

@gianpaj
Copy link
Author

gianpaj commented Jan 3, 2025

@davidzhao the issue i get with 0.10.13 is about WeakSet (#1326)

but with livekit-plugins-openai 0.10.14, now it works. Thanks 🙏

$ uv pip list | grep livekit
livekit                0.18.3
livekit-agents         0.12.7
livekit-api            0.8.1
livekit-plugins-openai 0.10.14

@gianpaj gianpaj closed this as completed Jan 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants