Skip to content

Commit 04d00cb

Browse files
Feat/anam support ai disclosure (#6695)
Co-authored-by: devin-ai-integration[bot] <158243242+devin-ai-integration[bot]@users.noreply.github.com>
1 parent 1f16498 commit 04d00cb

2 files changed

Lines changed: 11 additions & 0 deletions

File tree

  • livekit-plugins/livekit-plugins-anam/livekit/plugins/anam

livekit-plugins/livekit-plugins-anam/livekit/plugins/anam/api.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,13 @@ async def create_session_token(
122122
"videoHeight": session_options.video_height,
123123
}
124124

125+
if session_options is not None and session_options.show_ai_avatar_disclosure is not None:
126+
if "sessionOptions" not in payload:
127+
payload["sessionOptions"] = {}
128+
payload["sessionOptions"]["showAIAvatarDisclosure"] = (
129+
session_options.show_ai_avatar_disclosure
130+
)
131+
125132
headers = {
126133
"Authorization": f"Bearer {self._api_key}", # Use API Key here
127134
"Content-Type": "application/json",

livekit-plugins/livekit-plugins-anam/livekit/plugins/anam/types.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,11 @@ class SessionOptions:
5656
validated by Anam; an unsupported pair is rejected with an HTTP 400
5757
rather than silently downgraded.
5858
video_height: Output video frame height in pixels. See ``video_width``.
59+
show_ai_avatar_disclosure: Anam's default is not to render an AI avatar
60+
disclosure watermark. Set to ``True`` to have Anam disclose that the
61+
video contains an AI avatar via a watermark.
5962
"""
6063

6164
video_width: int | None = None
6265
video_height: int | None = None
66+
show_ai_avatar_disclosure: bool | None = None

0 commit comments

Comments
 (0)