Update guardrails demo to use webrtc - #248
Merged
Merged
Conversation
Co-authored-by: tadas <tadas@elevenlabs.io>
tadaspetra
marked this pull request as ready for review
August 3, 2026 18:15
Contributor
Author
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit ecf22de. Configure here.
Match setup.sh to the WebRTC-safe livekit-client override, and tighten Python lint so CI ruff check passes. Co-authored-by: Cursor <cursoragent@cursor.com>
This was referenced Aug 3, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
Automated regeneration triggered by merge of elevenlabs/skills#108 (Update skills from changelog 2026-07-27).
Generation results
Changed directories
Assessment
These changes are meaningful — they reflect updated ElevenAgents guardrails skill patterns:
conversation-tokenroute now usesgetWebrtcToken()instead ofgetSignedUrl(), and the client usesconversationTokeninstead ofsignedUrl/connectionType: websocketmodelandhistoryMessageCountfields to the investment-recommendations guardrailElevenLabsErrorwith proper status code propagationlivekit-clientoverride changed from2.19.1to2.16.1Note
Low Risk
Changes are limited to example apps, setup scripts, and a scaffold helper—no production auth or data paths—though the WebRTC migration could affect anyone copying the guardrails demo pattern.
Overview
The agents/nextjs/guardrails example moves voice sessions from WebSocket + signed URL to WebRTC: the
conversation-tokenAPI callsgetWebrtcToken()and returns{ token }, and the client starts the session withconversationTokeninstead ofsignedUrl/connectionType: "websocket". API errors now useElevenLabsErrorwith upstream status codes when available.Agent creation adds
model(gemini-2.5-flash-lite) andhistoryMessageCount: 1on the custom investment-advice guardrail.livekit-clientis pinned to 2.16.1 (down from 2.19.1) in the examplepackage.jsonand guardrailssetup.sh.Python quickstart scripts (music, sound-effects, speech-to-text, text-to-speech) write streamed audio with
writelines, catchApiError(and clearerKeyErrorfor missing API keys) instead of broadExceptionhandlers. The scaffold script usesminfor reference picking and drops an unused slug binding.Reviewed by Cursor Bugbot for commit 23383db. Bugbot is set up for automated code reviews on this repo. Configure here.