realtime-avatar 0.25.0 → 0.26.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,6 +2,7 @@ import * as livekit_client from 'livekit-client';
2
2
  import { ConnectionQuality, Room, Participant, Track, DisconnectReason, SendTextOptions } from 'livekit-client';
3
3
  import { TrackReferenceOrPlaceholder, useTranscriptions, useConnectionState, LiveKitRoomProps } from '@livekit/components-react';
4
4
  import { CSSProperties, ReactNode, ReactElement } from 'react';
5
+ import { b as MicrophoneProblem } from './playout-delay-CtRZdtsj.js';
5
6
  import { z } from 'zod';
6
7
 
7
8
  declare function useAvatarCamera({ allowed, active }: {
@@ -660,7 +661,7 @@ type AvatarVideoSurfaceProps = {
660
661
  * the front (live) fully covers the back (idle) — no peek-through. */
661
662
  fit?: AvatarVideoFit;
662
663
  /**
663
- * @deprecated No-op. The surface FILLS its container (`size-full`); the CONSUMER
664
+ * @deprecated No-op. The surface FILLS its container (100% x 100%); the CONSUMER
664
665
  * owns the aspect box. Self-pinning a native ratio INSIDE the surface could not
665
666
  * survive an indefinite-height ancestor (it collapsed to zero height — the
666
667
  * black-screen bug), so aspect ownership moved out to the caller: wrap the
@@ -700,11 +701,19 @@ type AvatarVideoSurfaceProps = {
700
701
  * are not stalls and do not wait on this.
701
702
  */
702
703
  frameStallMs?: number;
703
- /** Extra className for the box (the layers fill it). */
704
+ /**
705
+ * Extra className for the box (the layers fill it). The surface's own layout is inline and
706
+ * needs no CSS build, so a class here ADDS styling; to change a property the surface sets
707
+ * (its 100% size, say), use `style`.
708
+ */
704
709
  className?: string;
705
- /** Extra inline style for the box. */
710
+ /** Extra inline style for the box, spread over the surface's own. */
706
711
  style?: CSSProperties;
707
- /** Overlay content rendered above both media layers (badges, chrome, scrims). */
712
+ /**
713
+ * Overlay content (controls, captions, scrims). Rendered in a layer that fills the box and
714
+ * stacks above both media layers and the live badge, so a positioned child places itself
715
+ * against the box and stays clickable while she is live.
716
+ */
708
717
  children?: ReactNode;
709
718
  /** Surface a small "live · WxH" badge when the live layer is shown. Default true. */
710
719
  showLiveBadge?: boolean;
@@ -730,7 +739,7 @@ type AvatarVideoSurfaceProps = {
730
739
  * desyncs by up to the whole adaptive range. Fires on change only, not per frame.
731
740
  */
732
741
  onPlayoutDelayChange?: (seconds: number) => void;
733
- /** Test id for the box. */
742
+ /** Test id for the box. Default `avatar-video-surface`. */
734
743
  "data-testid"?: string;
735
744
  };
736
745
  /**
@@ -751,7 +760,7 @@ type AvatarVideoSurfaceProps = {
751
760
  * idle loop in the SAME box. Must be rendered inside a LiveKit `RoomContext`
752
761
  * (e.g. under `RealtimeAvatarLiveKitRoom`).
753
762
  *
754
- * LAYOUT CONTRACT: the surface FILLS its container (`size-full`) — it does NOT pin
763
+ * LAYOUT CONTRACT: the surface FILLS its container (100% x 100%) — it does NOT pin
755
764
  * its own aspect. The CONSUMER owns the aspect box: wrap the surface in an element
756
765
  * with a DEFINITE size (e.g. `aspect-[9/16]` plus a height seed). Self-pinning a
757
766
  * native ratio inside the surface (`h-full w-auto`) collapsed to zero height
@@ -893,9 +902,9 @@ interface AvatarSessionClient<TLlmProvider extends LLMProvider = LLMProvider> {
893
902
  */
894
903
  releaseLiveKitSession(sessionId: string, reason?: LiveKitSessionReleaseReason, options?: RealtimeAvatarRequestOptions): Promise<boolean>;
895
904
  /**
896
- * The `pagehide` path. `sendBeacon` is the one send that outlives a closing page, and it is
897
- * synchronous-or-nothing — hence a `boolean` return and no promise, so the caller can fall
898
- * back to {@link releaseLiveKitSession} when the browser has no beacon.
905
+ * The `pagehide` path: a send that outlives a closing page (a keepalive `fetch`, or
906
+ * `sendBeacon`), dispatched synchronously — hence a `boolean` return and no promise, so the
907
+ * caller can fall back to {@link releaseLiveKitSession} when nothing could be sent.
899
908
  */
900
909
  releaseLiveKitSessionBeacon(sessionId: string, reason?: LiveKitSessionReleaseReason): boolean;
901
910
  /**
@@ -1224,6 +1233,80 @@ type BehaviorSnapshot = {
1224
1233
  prevClipId: string | null;
1225
1234
  };
1226
1235
 
1236
+ /**
1237
+ * The microphone, as a call's UI needs it.
1238
+ *
1239
+ * - `off`: this call does not listen (`listen={false}`), or it is not connected — before the
1240
+ * room joins and after it ends. Nothing is captured.
1241
+ * - `pending`: the device has been asked for and has not answered. The permission prompt may be
1242
+ * open; per the getUserMedia spec it may never settle, so this can last.
1243
+ * - `on`: published and live; she can hear the user.
1244
+ * - `muted`: published and muted on purpose (`setMicrophoneEnabled(false)`).
1245
+ * - `blocked`: refused by the browser, the operating system, or an insecure origin. The user has
1246
+ * to change a setting; `hint` names which one. Retry afterwards.
1247
+ * - `unavailable`: no device, a device another app holds, one that stopped mid-call
1248
+ * (`device-lost`), or a failure nobody classified. `message` is what the browser said.
1249
+ */
1250
+ type CallMicrophone = {
1251
+ status: "off";
1252
+ } | {
1253
+ status: "pending";
1254
+ } | {
1255
+ status: "on";
1256
+ } | {
1257
+ status: "muted";
1258
+ } | ({
1259
+ status: "blocked";
1260
+ } & MicrophoneProblem) | ({
1261
+ status: "unavailable";
1262
+ } & MicrophoneProblem);
1263
+ /** A microphone state that carries a problem: the argument of `onMicrophoneProblem`. */
1264
+ type CallMicrophoneProblem = Extract<CallMicrophone, {
1265
+ status: "blocked" | "unavailable";
1266
+ }>;
1267
+ /**
1268
+ * Whether her audio can play.
1269
+ *
1270
+ * - `unknown`: not connected yet, and no playback has been attempted.
1271
+ * - `allowed`: no playback attempt has been refused (LiveKit's `room.canPlaybackAudio`).
1272
+ * - `blocked`: the browser refused playback until a user gesture. Call `startAudio()` from one —
1273
+ * a click or tap handler — or she stays silent.
1274
+ */
1275
+ type CallAudioPlayback = "unknown" | "allowed" | "blocked";
1276
+ /** What the in-room bridge reads off LiveKit. Raw facts; {@link callMicrophoneFrom} decides. */
1277
+ type CallMicrophoneFacts = Readonly<{
1278
+ /** Whether this call publishes the microphone at all. */
1279
+ wanted: boolean;
1280
+ /** The room is connected (LiveKit acquires the microphone on its way there). */
1281
+ connected: boolean;
1282
+ /** An enable this SDK started is still in flight. */
1283
+ enabling: boolean;
1284
+ /** The local microphone publication, if one exists. */
1285
+ publication: Readonly<{
1286
+ muted: boolean;
1287
+ ended: boolean;
1288
+ }> | null;
1289
+ /**
1290
+ * `localParticipant.lastMicrophoneError`, scoped to THIS call: LiveKit keeps the last failure on
1291
+ * the participant until a capture succeeds, and a redial reuses the same Room, so an error that
1292
+ * was already there when this call's grant arrived describes an earlier call and reads as null.
1293
+ */
1294
+ deviceError: Error | null;
1295
+ }>;
1296
+ /** The two actions, registered by the bridge so the session above the room can call them. */
1297
+ type CallMediaControls = Readonly<{
1298
+ /** `room.startAudio()`, resolving whether playback is allowed afterwards. Never rejects. */
1299
+ startAudio: () => Promise<boolean>;
1300
+ /** Mute, unmute, or retry after the user fixed a blocked or unavailable microphone. */
1301
+ setMicrophoneEnabled: (enabled: boolean) => Promise<void>;
1302
+ }>;
1303
+ /** The sinks the bridge fills. All optional: a bare lifecycle simply does not observe media. */
1304
+ type CallMediaSinks = Partial<Readonly<{
1305
+ setMicrophoneFacts: (facts: CallMicrophoneFacts) => void;
1306
+ setAudioPlayback: (playback: CallAudioPlayback) => void;
1307
+ registerMediaControls: (controls: CallMediaControls | null) => void;
1308
+ }>>;
1309
+
1227
1310
  /**
1228
1311
  * Wired up by CONSUMERS, not by this package. Nothing inside the carry calls it — checked
1229
1312
  * 2026-08-26 by searching for `pendingTurn` and `replay`, which appear nowhere else here. The
@@ -1274,8 +1357,11 @@ type ReconnectPolicy = {
1274
1357
  * frees the GPU). This is the reason the idle-warning countdown is now TRUE.
1275
1358
  * - `disconnected`: a deliberate server/peer end or an exhausted auto-reconnect.
1276
1359
  * - `error`: a grant failure surfaced as a terminal phase (no lease, no retry).
1360
+ * - `user`: the app ended it ({@link SessionLifecycleApi.end}) — from any phase, queued
1361
+ * included. The held session or queue ticket is released and nothing mints again until
1362
+ * {@link SessionLifecycleApi.reconnect}.
1277
1363
  */
1278
- type SessionEndReason = "idle" | "disconnected" | "error";
1364
+ type SessionEndReason = "idle" | "disconnected" | "error" | "user";
1279
1365
  type SessionLifecyclePhase = {
1280
1366
  kind: "idle";
1281
1367
  } | {
@@ -1425,8 +1511,18 @@ type SessionLifecycleApi = {
1425
1511
  * resets the CLIENT idle clock (postpones the client-enforced end).
1426
1512
  */
1427
1513
  markActivity: () => void;
1428
- /** Manual reconnect (the Reconnect button): resets the attempt budget and re-mints. */
1514
+ /**
1515
+ * Manual reconnect (the Reconnect button): resets the attempt budget and re-mints. After
1516
+ * {@link end} it is the one way to call again.
1517
+ */
1429
1518
  reconnect: () => void;
1519
+ /**
1520
+ * End the session NOW, from any phase — queued, requesting, connecting, live or recovering.
1521
+ * Stops the queue retry and the reconnect ladder, releases the held session or queue ticket
1522
+ * (`manual`), leaves the room, and parks on `ended{reason:"user"}`. Terminal: nothing mints
1523
+ * again until {@link reconnect}; {@link reset} does not undo it. Idempotent.
1524
+ */
1525
+ end: () => void;
1430
1526
  onConnected: () => void;
1431
1527
  onDisconnected: (reason?: DisconnectReason) => void;
1432
1528
  /**
@@ -1451,7 +1547,7 @@ type SessionLifecycleApi = {
1451
1547
  * never fires. Pass null to unregister.
1452
1548
  */
1453
1549
  registerLeaveRoom: (leave: (() => void) | null) => void;
1454
- /** Reset to idle (mode/avatar change). */
1550
+ /** Reset to idle (mode/avatar change). Does not undo {@link end}: an ended call stays ended. */
1455
1551
  reset: () => void;
1456
1552
  };
1457
1553
  declare function useSessionLifecycle<T extends LLMProvider = LLMProvider>(input: UseSessionLifecycleInput<T>): SessionLifecycleApi;
@@ -1476,7 +1572,7 @@ type RealtimeSessionRoomSinks = Partial<{
1476
1572
  video: "live" | "stalled" | "connecting";
1477
1573
  audio: "flowing" | "silent";
1478
1574
  }) => void;
1479
- }>;
1575
+ }> & CallMediaSinks;
1480
1576
  type PublisherConnectionDetails = Readonly<{
1481
1577
  publisherQuality: Participant["connectionQuality"];
1482
1578
  streamState: Track["streamState"] | null;
@@ -1500,6 +1596,12 @@ type SessionLifecycleRoomBridgeProps = {
1500
1596
  * Callback failures never affect the call; no stats polling or uploads are added.
1501
1597
  */
1502
1598
  onConnectionDetailsChange?: (details: AvatarConnectionDetails | null) => void;
1599
+ /**
1600
+ * Whether the room publishes the user's microphone — pass what you passed the room's `audio`.
1601
+ * Default: the same rule {@link RealtimeAvatarLiveKitRoom} applies (server-transcribed calls).
1602
+ * Decides whether a missing microphone track is a problem or simply not wanted.
1603
+ */
1604
+ microphone?: boolean;
1503
1605
  lifecycle: Pick<SessionLifecycleApi, "onConnectionStateChange" | "setAgentPresent" | "registerLeaveRoom" | "markActivity"> & Partial<Pick<SessionLifecycleApi, "grant">> & RealtimeSessionRoomSinks;
1504
1606
  };
1505
1607
  /**
@@ -1519,7 +1621,7 @@ type SessionLifecycleRoomBridgeProps = {
1519
1621
  *
1520
1622
  * Renders nothing. Mount it once inside RealtimeAvatarLiveKitRoom.
1521
1623
  */
1522
- declare function SessionLifecycleRoomBridge({ lifecycle, onConnectionDetailsChange, onMediaModeChange, }: SessionLifecycleRoomBridgeProps): null;
1624
+ declare function SessionLifecycleRoomBridge({ lifecycle, onConnectionDetailsChange, onMediaModeChange, microphone, }: SessionLifecycleRoomBridgeProps): null;
1523
1625
 
1524
1626
  /**
1525
1627
  * The terminal, LABELED end reason surfaced to the app via `onEnded`. This is the
@@ -1729,6 +1831,28 @@ type RealtimeSessionApi = SessionLifecycleApi & {
1729
1831
  graceWindow: GraceWindowState;
1730
1832
  /** Honest media liveness from the bound agent's tracks. */
1731
1833
  media: RealtimeSessionMedia;
1834
+ /** Can she hear the user? Derived from LiveKit's microphone facts; see {@link CallMicrophone}. */
1835
+ microphone: CallMicrophone;
1836
+ /** Can the user hear her? `blocked` until `startAudio()` runs inside a user gesture. `unknown` once ended. */
1837
+ audioPlayback: CallAudioPlayback;
1838
+ /**
1839
+ * Unblock her audio (`room.startAudio()`). Call it from a click or tap handler. Never rejects:
1840
+ * resolves whether playback is allowed afterwards (`false` outside a gesture, or with no room).
1841
+ */
1842
+ startAudio: () => Promise<boolean>;
1843
+ /**
1844
+ * Mute or unmute the user's microphone. `true` after a `blocked` or `unavailable` microphone is
1845
+ * the retry, once the user has fixed what the hint names. Never rejects: a failure becomes the
1846
+ * next `microphone` state. Before the room connects it only records the choice (nothing is
1847
+ * captured); after the call ended it does nothing.
1848
+ */
1849
+ setMicrophoneEnabled: (enabled: boolean) => Promise<void>;
1850
+ /**
1851
+ * The user's mute choice, kept across the connect. If you render your own
1852
+ * `RealtimeAvatarLiveKitRoom`, pass `audio={listens && !microphoneMuted}` so a mute made before
1853
+ * the room connected is honoured when LiveKit captures at connect. `AvatarCall` does this.
1854
+ */
1855
+ microphoneMuted: boolean;
1732
1856
  /** The inner SSOT surface, for explicit access (it is also spread at top level). */
1733
1857
  lifecycle: SessionLifecycleApi;
1734
1858
  /** Speak ONE final in-character line VERBATIM, then end. Guaranteed delivered before the cut. */
@@ -1748,7 +1872,12 @@ type RealtimeSessionApi = SessionLifecycleApi & {
1748
1872
  createTranscriptSender: (opts?: TranscriptSenderOptions) => TranscriptSender;
1749
1873
  /** Re-send the last turn with its resolved provenance, a new ID, and retry_of_turn_id. */
1750
1874
  retryTurn: () => void;
1751
- /** End gracefully now (the user tapped End). */
1875
+ /**
1876
+ * End now (the user tapped End), from any phase — queued and connecting included. Tells the
1877
+ * worker (best-effort), then {@link SessionLifecycleApi.end}: releases the held session or
1878
+ * queue ticket, leaves the room, and parks on `ended`. `onEnded` fires once, with `reason`
1879
+ * (default `user_ended`). Nothing mints again until `reconnect()`.
1880
+ */
1752
1881
  end: (reason?: EndReason) => void;
1753
1882
  /** The avatar's live nonverbal behavior, or null pre-choreo (see {@link BehaviorSnapshot}). */
1754
1883
  behavior: BehaviorSnapshot | null;
@@ -1766,6 +1895,12 @@ type RealtimeSessionApi = SessionLifecycleApi & {
1766
1895
  setTurnState: (state: string | null | undefined) => void;
1767
1896
  /** Honest media liveness from the bound agent's tracks. */
1768
1897
  setMedia: (media: RealtimeSessionMedia) => void;
1898
+ /** The local microphone facts (the bridge reads them off LiveKit). */
1899
+ setMicrophoneFacts: (facts: CallMicrophoneFacts) => void;
1900
+ /** LiveKit's audio playback status. */
1901
+ setAudioPlayback: (playback: CallAudioPlayback) => void;
1902
+ /** The in-room media actions behind `startAudio` / `setMicrophoneEnabled`. */
1903
+ registerMediaControls: (controls: CallMediaControls | null) => void;
1769
1904
  };
1770
1905
  declare function useRealtimeSession<T extends LLMProvider = LLMProvider>(input: UseRealtimeSessionInput<T>): RealtimeSessionApi;
1771
1906
 
@@ -1855,8 +1990,19 @@ interface ProxyClientOptions {
1855
1990
  * ABSOLUTE url there or every request resolves against nothing.
1856
1991
  */
1857
1992
  proxyUrl: string;
1858
- /** Swap the transport — a test double, or a fetch that carries your session cookie. */
1993
+ /** Swap the transport — a test double, or a fetch that adds your own auth header. */
1859
1994
  fetch?: typeof globalThis.fetch;
1995
+ /**
1996
+ * The `credentials` mode of EVERY request this client makes, the page-hide release included.
1997
+ * Unset, the client sets none, so `fetch`'s own default (`"same-origin"`) applies, or whatever
1998
+ * your `fetch` wrapper sets.
1999
+ *
2000
+ * Set `"include"` when your route is on another origin and authorizes on a cookie — an
2001
+ * `app.example.com` page calling an `api.example.com` route. The route's CORS must then answer
2002
+ * with `Access-Control-Allow-Credentials: true` and the page's exact origin, for the preflight
2003
+ * of `connect` and of the release alike.
2004
+ */
2005
+ credentials?: RequestCredentials;
1860
2006
  /**
1861
2007
  * Per-request deadline, default 60s, `0` to disable. Keep it above your route's `timeoutMs`
1862
2008
  * (default 50s), so the route's answer arrives before the page stops listening. Running out throws a
@@ -1872,4 +2018,4 @@ interface ProxyClientOptions {
1872
2018
  }
1873
2019
  declare function createProxyClient(options: ProxyClientOptions): AvatarSessionClient;
1874
2020
 
1875
- export { type ProxyClientOptions as $, type AvatarVideoFit as A, type BehaviorSnapshot as B, type CallTranscript as C, DEFAULT_APPROACHING_END_LEAD_SECONDS as D, type EndReason as E, type FishTtsModel as F, type Governor as G, type GovernorSignal as H, type GovernorState as I, type GraceWindowClosedEvent as J, type GraceWindowOpenEvent as K, type LiveKitSessionGrant as L, type GraceWindowState as M, type IdleWarningEvent as N, type InboundRtpCursor as O, type InboundRtpReading as P, type KnownBehaviorState as Q, type LLMProvider as R, type LLMSelection as S, type LiveKitAvatarGrantState as T, type LiveKitAvatarGrantStatus as U, type LiveKitCapacityState as V, type LiveKitConnectionStatus as W, type LiveKitSessionRequest as X, type LiveKitSessionStartResult as Y, MAX_RECONNECT_ATTEMPTS as Z, MAX_SESSION_INSTRUCTIONS_CHARS as _, AdaptivePlayoutController as a, shouldReplayPendingTurn as a$, type QualityCap as a0, RECONNECT_BACKOFF_MS as a1, type RealtimeAvatarRequestOptions as a2, type RealtimeSessionApi as a3, type RealtimeSessionMedia as a4, type RealtimeSessionRoomSinks as a5, type ReconnectPolicy as a6, type ReconnectingEvent as a7, type RecoveryState as a8, type RetryStep as a9, mapTurnState as aA, readInboundRtp as aB, sessionBehaviorSchema as aC, sessionClipSchema as aD, splitCallTranscript as aE, useAvatarAdaptivePlayoutDelay as aF, useAvatarCamera as aG, useAvatarPlayoutDelay as aH, useAvatarQualityGovernor as aI, useCallTranscript as aJ, useLiveKitAvatarGrant as aK, useLiveTrackProducing as aL, useMicLease as aM, useRealtimeSession as aN, useReleaseMicLeaseOnTrackEnded as aO, useSessionLifecycle as aP, AvatarVideoSurface as aQ, type AvatarVideoSurfaceProps as aR, type LivePlaybackKeeper as aS, MIC_LEASE_ENDED_TIMEOUT_MS as aT, type MicLease as aU, NETWORK_QUALITY_POLICY as aV, type NetworkQualityStatus as aW, type PlayableVideoElement as aX, RealtimeAvatarCapacityError as aY, RealtimeAvatarLiveKitRoom as aZ, type RealtimeAvatarLiveKitRoomProps as a_, type SendTurnOptions as aa, type SessionBehavior as ab, type SessionClip as ac, type SessionClocks as ad, type SessionEndReason as ae, type SessionLifecycleApi as af, type SessionLifecyclePhase as ag, type SessionLifecyclePhaseKind as ah, SessionLifecycleRoomBridge as ai, type SessionLifecycleRoomBridgeProps as aj, type SurfaceLayers as ak, type TranscriptSender as al, type TranscriptSenderOptions as am, type TurnState as an, type TurnTimeoutEvent as ao, type UseAvatarQualityGovernorInput as ap, type UseLiveKitAvatarGrantInput as aq, type UseRealtimeSessionInput as ar, type UseSessionLifecycleInput as as, type VoiceSpec as at, type VoiceSpecInput as au, capacityErrorFromBusy as av, capacityStateFromGrant as aw, createProxyClient as ax, isNativeLiveTrackSubscribed as ay, knownBehaviorStates as az, type AdaptivePlayoutDecision as b, type AdaptivePlayoutOptions as c, type AdaptivePlayoutSample as d, type ApproachingEndEvent as e, type ApproachingEndReason as f, type AvatarConnectionDetails as g, type AvatarSessionClient as h, type CallTranscriptSegment as i, type CartesiaTtsModel as j, type ClipResult as k, type ClosingTurnResult as l, type CreditsLowEvent as m, DEFAULT_CREDITS_LOW_LEAD_SECONDS as n, DEFAULT_GOVERNOR_CONFIG as o, DEFAULT_GRACE_CEILING_SECONDS as p, DEFAULT_GRACE_WINDOW_LEAD_SECONDS as q, DEFAULT_IDLE_SECONDS as r, DEFAULT_IDLE_WARN_LEAD_SECONDS as s, DEFAULT_TURN_TIMEOUT_SECONDS as t, type DeclaredInputSource as u, type EndedEvent as v, type ExtendResult as w, type FreezeReadingFn as x, type GovernorAction as y, type GovernorConfig as z };
2021
+ export { type ProxyClientOptions as $, type AvatarVideoFit as A, type BehaviorSnapshot as B, type CallTranscript as C, DEFAULT_APPROACHING_END_LEAD_SECONDS as D, type EndReason as E, type FishTtsModel as F, type Governor as G, type GovernorSignal as H, type GovernorState as I, type GraceWindowClosedEvent as J, type GraceWindowOpenEvent as K, type LiveKitSessionGrant as L, type GraceWindowState as M, type IdleWarningEvent as N, type InboundRtpCursor as O, type InboundRtpReading as P, type KnownBehaviorState as Q, type LLMProvider as R, type LLMSelection as S, type LiveKitAvatarGrantState as T, type LiveKitAvatarGrantStatus as U, type LiveKitCapacityState as V, type LiveKitConnectionStatus as W, type LiveKitSessionRequest as X, type LiveKitSessionStartResult as Y, MAX_RECONNECT_ATTEMPTS as Z, MAX_SESSION_INSTRUCTIONS_CHARS as _, AdaptivePlayoutController as a, RealtimeAvatarCapacityError as a$, type QualityCap as a0, RECONNECT_BACKOFF_MS as a1, type RealtimeAvatarRequestOptions as a2, type RealtimeSessionApi as a3, type RealtimeSessionMedia as a4, type RealtimeSessionRoomSinks as a5, type ReconnectPolicy as a6, type ReconnectingEvent as a7, type RecoveryState as a8, type RetryStep as a9, mapTurnState as aA, readInboundRtp as aB, sessionBehaviorSchema as aC, sessionClipSchema as aD, splitCallTranscript as aE, useAvatarAdaptivePlayoutDelay as aF, useAvatarCamera as aG, useAvatarPlayoutDelay as aH, useAvatarQualityGovernor as aI, useCallTranscript as aJ, useLiveKitAvatarGrant as aK, useLiveTrackProducing as aL, useMicLease as aM, useRealtimeSession as aN, useReleaseMicLeaseOnTrackEnded as aO, useSessionLifecycle as aP, type CallMicrophone as aQ, type CallAudioPlayback as aR, type CallMicrophoneProblem as aS, AvatarVideoSurface as aT, type AvatarVideoSurfaceProps as aU, type LivePlaybackKeeper as aV, MIC_LEASE_ENDED_TIMEOUT_MS as aW, type MicLease as aX, NETWORK_QUALITY_POLICY as aY, type NetworkQualityStatus as aZ, type PlayableVideoElement as a_, type SendTurnOptions as aa, type SessionBehavior as ab, type SessionClip as ac, type SessionClocks as ad, type SessionEndReason as ae, type SessionLifecycleApi as af, type SessionLifecyclePhase as ag, type SessionLifecyclePhaseKind as ah, SessionLifecycleRoomBridge as ai, type SessionLifecycleRoomBridgeProps as aj, type SurfaceLayers as ak, type TranscriptSender as al, type TranscriptSenderOptions as am, type TurnState as an, type TurnTimeoutEvent as ao, type UseAvatarQualityGovernorInput as ap, type UseLiveKitAvatarGrantInput as aq, type UseRealtimeSessionInput as ar, type UseSessionLifecycleInput as as, type VoiceSpec as at, type VoiceSpecInput as au, capacityErrorFromBusy as av, capacityStateFromGrant as aw, createProxyClient as ax, isNativeLiveTrackSubscribed as ay, knownBehaviorStates as az, type AdaptivePlayoutDecision as b, RealtimeAvatarLiveKitRoom as b0, type RealtimeAvatarLiveKitRoomProps as b1, shouldReplayPendingTurn as b2, type AdaptivePlayoutOptions as c, type AdaptivePlayoutSample as d, type ApproachingEndEvent as e, type ApproachingEndReason as f, type AvatarConnectionDetails as g, type AvatarSessionClient as h, type CallTranscriptSegment as i, type CartesiaTtsModel as j, type ClipResult as k, type ClosingTurnResult as l, type CreditsLowEvent as m, DEFAULT_CREDITS_LOW_LEAD_SECONDS as n, DEFAULT_GOVERNOR_CONFIG as o, DEFAULT_GRACE_CEILING_SECONDS as p, DEFAULT_GRACE_WINDOW_LEAD_SECONDS as q, DEFAULT_IDLE_SECONDS as r, DEFAULT_IDLE_WARN_LEAD_SECONDS as s, DEFAULT_TURN_TIMEOUT_SECONDS as t, type DeclaredInputSource as u, type EndedEvent as v, type ExtendResult as w, type FreezeReadingFn as x, type GovernorAction as y, type GovernorConfig as z };
@@ -1,11 +1,11 @@
1
1
  import { LiveKitRoomProps } from '@livekit/react-native';
2
2
  export { AudioSession, VideoTrack, VideoTrackProps, registerGlobals } from '@livekit/react-native';
3
- import { L as LiveKitSessionGrant, A as AvatarVideoFit } from './proxy-client-O-Mu9JKt.js';
4
- export { a as AdaptivePlayoutController, b as AdaptivePlayoutDecision, c as AdaptivePlayoutOptions, d as AdaptivePlayoutSample, e as ApproachingEndEvent, f as ApproachingEndReason, g as AvatarConnectionDetails, h as AvatarSessionClient, B as BehaviorSnapshot, C as CallTranscript, i as CallTranscriptSegment, j as CartesiaTtsModel, k as ClipResult, l as ClosingTurnResult, m as CreditsLowEvent, D as DEFAULT_APPROACHING_END_LEAD_SECONDS, n as DEFAULT_CREDITS_LOW_LEAD_SECONDS, o as DEFAULT_GOVERNOR_CONFIG, p as DEFAULT_GRACE_CEILING_SECONDS, q as DEFAULT_GRACE_WINDOW_LEAD_SECONDS, r as DEFAULT_IDLE_SECONDS, s as DEFAULT_IDLE_WARN_LEAD_SECONDS, t as DEFAULT_TURN_TIMEOUT_SECONDS, u as DeclaredInputSource, E as EndReason, v as EndedEvent, w as ExtendResult, F as FishTtsModel, x as FreezeReadingFn, G as Governor, y as GovernorAction, z as GovernorConfig, H as GovernorSignal, I as GovernorState, J as GraceWindowClosedEvent, K as GraceWindowOpenEvent, M as GraceWindowState, N as IdleWarningEvent, O as InboundRtpCursor, P as InboundRtpReading, Q as KnownBehaviorState, R as LLMProvider, S as LLMSelection, T as LiveKitAvatarGrantState, U as LiveKitAvatarGrantStatus, V as LiveKitCapacityState, W as LiveKitConnectionStatus, X as LiveKitSessionRequest, Y as LiveKitSessionStartResult, Z as MAX_RECONNECT_ATTEMPTS, _ as MAX_SESSION_INSTRUCTIONS_CHARS, $ as ProxyClientOptions, a0 as QualityCap, a1 as RECONNECT_BACKOFF_MS, a2 as RealtimeAvatarRequestOptions, a3 as RealtimeSessionApi, a4 as RealtimeSessionMedia, a5 as RealtimeSessionRoomSinks, a6 as ReconnectPolicy, a7 as ReconnectingEvent, a8 as RecoveryState, a9 as RetryStep, aa as SendTurnOptions, ab as SessionBehavior, ac as SessionClip, ad as SessionClocks, ae as SessionEndReason, af as SessionLifecycleApi, ag as SessionLifecyclePhase, ah as SessionLifecyclePhaseKind, ai as SessionLifecycleRoomBridge, aj as SessionLifecycleRoomBridgeProps, ak as SurfaceLayers, al as TranscriptSender, am as TranscriptSenderOptions, an as TurnState, ao as TurnTimeoutEvent, ap as UseAvatarQualityGovernorInput, aq as UseLiveKitAvatarGrantInput, ar as UseRealtimeSessionInput, as as UseSessionLifecycleInput, at as VoiceSpec, au as VoiceSpecInput, av as capacityErrorFromBusy, aw as capacityStateFromGrant, ax as createProxyClient, ay as isNativeLiveTrackSubscribed, az as knownBehaviorStates, aA as mapTurnState, aB as readInboundRtp, aC as sessionBehaviorSchema, aD as sessionClipSchema, aE as splitCallTranscript, aF as useAvatarAdaptivePlayoutDelay, aG as useAvatarCamera, aH as useAvatarPlayoutDelay, aI as useAvatarQualityGovernor, aJ as useCallTranscript, aK as useLiveKitAvatarGrant, aL as useLiveTrackProducing, aM as useMicLease, aN as useRealtimeSession, aO as useReleaseMicLeaseOnTrackEnded, aP as useSessionLifecycle } from './proxy-client-O-Mu9JKt.js';
3
+ import { L as LiveKitSessionGrant, A as AvatarVideoFit } from './proxy-client-C8M_G_Kk.js';
4
+ export { a as AdaptivePlayoutController, b as AdaptivePlayoutDecision, c as AdaptivePlayoutOptions, d as AdaptivePlayoutSample, e as ApproachingEndEvent, f as ApproachingEndReason, g as AvatarConnectionDetails, h as AvatarSessionClient, B as BehaviorSnapshot, C as CallTranscript, i as CallTranscriptSegment, j as CartesiaTtsModel, k as ClipResult, l as ClosingTurnResult, m as CreditsLowEvent, D as DEFAULT_APPROACHING_END_LEAD_SECONDS, n as DEFAULT_CREDITS_LOW_LEAD_SECONDS, o as DEFAULT_GOVERNOR_CONFIG, p as DEFAULT_GRACE_CEILING_SECONDS, q as DEFAULT_GRACE_WINDOW_LEAD_SECONDS, r as DEFAULT_IDLE_SECONDS, s as DEFAULT_IDLE_WARN_LEAD_SECONDS, t as DEFAULT_TURN_TIMEOUT_SECONDS, u as DeclaredInputSource, E as EndReason, v as EndedEvent, w as ExtendResult, F as FishTtsModel, x as FreezeReadingFn, G as Governor, y as GovernorAction, z as GovernorConfig, H as GovernorSignal, I as GovernorState, J as GraceWindowClosedEvent, K as GraceWindowOpenEvent, M as GraceWindowState, N as IdleWarningEvent, O as InboundRtpCursor, P as InboundRtpReading, Q as KnownBehaviorState, R as LLMProvider, S as LLMSelection, T as LiveKitAvatarGrantState, U as LiveKitAvatarGrantStatus, V as LiveKitCapacityState, W as LiveKitConnectionStatus, X as LiveKitSessionRequest, Y as LiveKitSessionStartResult, Z as MAX_RECONNECT_ATTEMPTS, _ as MAX_SESSION_INSTRUCTIONS_CHARS, $ as ProxyClientOptions, a0 as QualityCap, a1 as RECONNECT_BACKOFF_MS, a2 as RealtimeAvatarRequestOptions, a3 as RealtimeSessionApi, a4 as RealtimeSessionMedia, a5 as RealtimeSessionRoomSinks, a6 as ReconnectPolicy, a7 as ReconnectingEvent, a8 as RecoveryState, a9 as RetryStep, aa as SendTurnOptions, ab as SessionBehavior, ac as SessionClip, ad as SessionClocks, ae as SessionEndReason, af as SessionLifecycleApi, ag as SessionLifecyclePhase, ah as SessionLifecyclePhaseKind, ai as SessionLifecycleRoomBridge, aj as SessionLifecycleRoomBridgeProps, ak as SurfaceLayers, al as TranscriptSender, am as TranscriptSenderOptions, an as TurnState, ao as TurnTimeoutEvent, ap as UseAvatarQualityGovernorInput, aq as UseLiveKitAvatarGrantInput, ar as UseRealtimeSessionInput, as as UseSessionLifecycleInput, at as VoiceSpec, au as VoiceSpecInput, av as capacityErrorFromBusy, aw as capacityStateFromGrant, ax as createProxyClient, ay as isNativeLiveTrackSubscribed, az as knownBehaviorStates, aA as mapTurnState, aB as readInboundRtp, aC as sessionBehaviorSchema, aD as sessionClipSchema, aE as splitCallTranscript, aF as useAvatarAdaptivePlayoutDelay, aG as useAvatarCamera, aH as useAvatarPlayoutDelay, aI as useAvatarQualityGovernor, aJ as useCallTranscript, aK as useLiveKitAvatarGrant, aL as useLiveTrackProducing, aM as useMicLease, aN as useRealtimeSession, aO as useReleaseMicLeaseOnTrackEnded, aP as useSessionLifecycle } from './proxy-client-C8M_G_Kk.js';
5
5
  import { ReactNode, ReactElement } from 'react';
6
6
  import { StyleProp, ViewStyle } from 'react-native';
7
7
  export { useChat, useConnectionState, useLocalParticipant, useRoomContext, useTrackToggle, useTranscriptions, useVoiceAssistant } from '@livekit/components-react';
8
- export { D as DEFAULT_AVATAR_PLAYOUT_DELAY_SECONDS } from './playout-delay-DWOc8iCl.js';
8
+ export { D as DEFAULT_AVATAR_PLAYOUT_DELAY_SECONDS } from './playout-delay-CtRZdtsj.js';
9
9
  export { DisconnectReason, RemoteAudioTrack, RemoteTrack, RemoteVideoTrack, Room, RoomEvent, SendTextOptions, Track } from 'livekit-client';
10
10
  import 'zod';
11
11