Skip to content

feat(examples/avatar): added animation triggers and trimmed personas#5899

Merged
tinalenguyen merged 1 commit into
livekit:mainfrom
brycedli:main
Jun 2, 2026
Merged

feat(examples/avatar): added animation triggers and trimmed personas#5899
tinalenguyen merged 1 commit into
livekit:mainfrom
brycedli:main

Conversation

@brycedli
Copy link
Copy Markdown
Contributor

Summary

  • Add wave/dance/turn tools for Leila, Jess, and Mr Fox via LemonSlice pose triggers (actions.py)
  • Auto-wave on session start and after switching to a motion-capable persona
  • Trim persona list from 15 to 9; add Leila and Jess, remove underperforming personas; default to Leila
  • Update playground dropdown and README

@CLAassistant
Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

devin-ai-integration[bot]

This comment was marked as resolved.

Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 new potential issue.

View 6 additional findings in Devin Review.

Open in Devin Review

Comment on lines +137 to +140
async def opening_wave(self) -> None:
if OPENING_WAVE_DELAY_S > 0:
await asyncio.sleep(OPENING_WAVE_DELAY_S)
await self.play("wave")
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟑 Unhandled network exceptions from trigger_pose in opening_wave prevent agent greeting

The trigger_pose function (actions.py:50-63) makes an HTTP request via aiohttp but doesn't catch network-level exceptions (e.g., aiohttp.ClientError, asyncio.TimeoutError). While it handles non-OK HTTP responses by returning False, actual connection failures raise exceptions. The play() method (actions.py:107) also doesn't catch these, so exceptions propagate through opening_wave() to the caller.

In the entrypoint (agent.py:112), if opening_wave() raises, session.generate_reply() at agent.py:114 is never reached β€” the agent silently fails to greet the user. In the set_avatar RPC handler (agent.py:166), the same failure prevents both the greeting (agent.py:168) and the RPC response (agent.py:181). A transient network error during a cosmetic wave animation should not break the core conversation flow.

Suggested change
async def opening_wave(self) -> None:
if OPENING_WAVE_DELAY_S > 0:
await asyncio.sleep(OPENING_WAVE_DELAY_S)
await self.play("wave")
async def opening_wave(self) -> None:
if OPENING_WAVE_DELAY_S > 0:
await asyncio.sleep(OPENING_WAVE_DELAY_S)
try:
await self.play("wave")
except Exception:
logger.warning("opening wave failed", exc_info=True)
Open in Devin Review

Was this helpful? React with πŸ‘ or πŸ‘Ž to provide feedback.

@tinalenguyen tinalenguyen merged commit 48e1ccb into livekit:main Jun 2, 2026
16 of 17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants