-
Notifications
You must be signed in to change notification settings - Fork 216
Add Hedra Avatar Plugin #957
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
Conversation
🦋 Changeset detectedLatest commit: 7779d32 The changes in this PR will be included in the next version bump. This PR includes changesets to release 18 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
@codex review |
davidzhao
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lg, just a couple of nits
|
Codex Review: Didn't find any major issues. Nice work! ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
Caution Review failedThe pull request is closed. 📝 WalkthroughWalkthroughA new Hedra avatar plugin is introduced for LiveKit agents, featuring core implementation with avatar session management, API integration with retry logic, complete package configuration, documentation, and example usage demonstrating integration across the agent framework. Changes
Sequence Diagram(s)sequenceDiagram
actor Agent as Agent/User
participant AvatarSession as AvatarSession
participant LiveKit as LiveKit<br/>(Access Token)
participant HedraAPI as Hedra API
participant AudioOutput as Audio Output<br/>Stream
Agent->>AvatarSession: start(agentSession, room, options)
AvatarSession->>LiveKit: create AccessToken<br/>(avatar identity, room, publish-on-behalf)
LiveKit-->>AvatarSession: token
AvatarSession->>HedraAPI: POST /agents/start<br/>(multipart: livekit_url, livekit_token, avatar_id/image)
alt Retry Loop
HedraAPI-->>AvatarSession: error or timeout
AvatarSession->>AvatarSession: wait exponential backoff
AvatarSession->>HedraAPI: retry POST request
end
HedraAPI-->>AvatarSession: success
AvatarSession->>AudioOutput: configure DataStreamAudioOutput<br/>(sample_rate, waitRemoteTrack)
AvatarSession->>agentSession: route audio to avatar
agentSession-->>Agent: avatar active
Estimated code review effort🎯 4 (Complex) | ⏱️ ~60 minutes Poem
✨ Finishing touches
📜 Recent review detailsConfiguration used: Organization UI Review profile: CHILL Plan: Pro ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (14)
✏️ Tip: You can disable this entire section by setting Comment |
Plugin has been fully tested with both using avatar_id mode and uploading image mode.
Summary by CodeRabbit
Release Notes
New Features
Documentation
✏️ Tip: You can customize this high-level summary in your review settings.