realtime-avatar 0.18.0 → 0.20.0
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.
- package/dist/{chunk-27XNZHSF.js → chunk-PKOWNCDT.js} +5 -1
- package/dist/{chunk-RKIEGOGJ.js → chunk-QT5UTARL.js} +1 -1
- package/dist/express.d.ts +2 -2
- package/dist/express.js +2 -2
- package/dist/hono.d.ts +2 -2
- package/dist/hono.js +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +1 -1
- package/dist/nextjs.d.ts +2 -2
- package/dist/nextjs.js +2 -2
- package/dist/{proxy-client-w6prrzGW.d.ts → proxy-client-DpMcj6fI.d.ts} +20 -3
- package/dist/react-native.d.ts +2 -2
- package/dist/react-native.js +151 -7
- package/dist/react.d.ts +3 -3
- package/dist/react.js +150 -6
- package/dist/recording.d.ts +2 -2
- package/dist/server.d.ts +1 -1
- package/dist/server.js +1 -1
- package/dist/tanstack-start.d.ts +2 -2
- package/dist/tanstack-start.js +2 -2
- package/dist/{types-CxkszIDK.d.ts → types-D76SpA3g.d.ts} +3 -0
- package/dist/{types-Bzn5PJ0g.d.ts → types-TaQCvMPh.d.ts} +1 -1
- package/package.json +5 -6
|
@@ -437,6 +437,7 @@ z.object({
|
|
|
437
437
|
source_kind: avatarSourceKindSchema.default("portrait"),
|
|
438
438
|
source_video_url: nullableUrlSchema.optional(),
|
|
439
439
|
stt_mode: liveKitSttModeSchema.default("server"),
|
|
440
|
+
camera: z.boolean().optional(),
|
|
440
441
|
video_cache_id: z.string().min(1).max(240).nullable().optional(),
|
|
441
442
|
voice: voiceSpecSchema.nullable().optional(),
|
|
442
443
|
voice_id: z.string().min(1).max(240).nullable().optional(),
|
|
@@ -509,6 +510,7 @@ z.object({
|
|
|
509
510
|
queueTicketId: z.string().min(1).max(160).optional(),
|
|
510
511
|
roomName: z.string().min(1).max(160).optional(),
|
|
511
512
|
sttMode: liveKitSttModeSchema.default("server"),
|
|
513
|
+
camera: z.boolean().optional(),
|
|
512
514
|
voice: voiceSpecSchema.nullable().optional(),
|
|
513
515
|
voiceId: z.string().min(1).max(240).nullable().optional(),
|
|
514
516
|
// Unbounded, for the same reason as `clip_library` on the wire schema above.
|
|
@@ -531,6 +533,7 @@ var liveKitSessionGrantSchema = z.object({
|
|
|
531
533
|
participant_identity: z.string().min(1),
|
|
532
534
|
reservation_expires_at: z.string().datetime({ offset: true }),
|
|
533
535
|
stt_mode: liveKitSttModeSchema.default("server"),
|
|
536
|
+
camera: z.boolean().optional(),
|
|
534
537
|
room_created: z.boolean().default(false),
|
|
535
538
|
dispatch_created: z.boolean().default(false),
|
|
536
539
|
join_timeout_seconds: z.number().int().nonnegative().default(0),
|
|
@@ -618,7 +621,7 @@ z.enum([
|
|
|
618
621
|
|
|
619
622
|
// ../http-client/src/client.ts
|
|
620
623
|
var DEFAULT_BASE_URL = "https://realtimeavatar.ai/api/v1";
|
|
621
|
-
var SDK_VERSION = "0.
|
|
624
|
+
var SDK_VERSION = "0.20.0";
|
|
622
625
|
var RealtimeAvatar = class {
|
|
623
626
|
#apiKey;
|
|
624
627
|
#baseUrl;
|
|
@@ -657,6 +660,7 @@ var RealtimeAvatar = class {
|
|
|
657
660
|
stt_mode: options.listen === false ? "off" : "server"
|
|
658
661
|
};
|
|
659
662
|
if (options.instructions !== void 0) body.instructions = options.instructions;
|
|
663
|
+
if (options.camera !== void 0) body.camera = options.camera;
|
|
660
664
|
if (options.context !== void 0) {
|
|
661
665
|
body.initial_context = options.context.map((m) => ({ role: m.role, content: m.content }));
|
|
662
666
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { RealtimeAvatar, isQueued, RealtimeAvatarHttpError } from './chunk-
|
|
1
|
+
import { RealtimeAvatar, isQueued, RealtimeAvatarHttpError } from './chunk-PKOWNCDT.js';
|
|
2
2
|
|
|
3
3
|
// ../proxy/src/config.ts
|
|
4
4
|
var json = (body, status = 200) => new Response(JSON.stringify(body), {
|
package/dist/express.d.ts
CHANGED
package/dist/express.js
CHANGED
package/dist/hono.d.ts
CHANGED
package/dist/hono.js
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { a as CallPolicy, C as CallMode, S as StartCallResult, E as EndCallOptions, A as Avatar, b as AvatarUpdate, c as AvatarSourceSwap, d as ClipLibraryDeclaration, e as ClipLibraryUpdate, L as LoopRedirect, f as ClipLibrary, g as AssetKind, h as Asset, i as ListSessionsOptions, U as UsageSessionPage, j as UsageSession, k as ListRecordingsQuery, l as ListRecordingsResponse, R as RecordingArtifact, m as RecordingAccessResponse, n as CreditBalance, T as TranscriptPayload } from './types-
|
|
2
|
-
export { o as AvatarClip, p as CallConnection, q as CallQueued, r as ClipDeclaration, s as ClipLibraryPlan, t as ClipSource, u as ContextMessage, v as EndCallReason, w as RecordingArtifactStatus, x as RecordingMode, V as VideoPolicy, y as isQueued, z as listRecordingsResponseSchema, B as recordingAccessResponseSchema, D as recordingArtifactSchema, F as recordingModeSchema } from './types-
|
|
1
|
+
import { a as CallPolicy, C as CallMode, S as StartCallResult, E as EndCallOptions, A as Avatar, b as AvatarUpdate, c as AvatarSourceSwap, d as ClipLibraryDeclaration, e as ClipLibraryUpdate, L as LoopRedirect, f as ClipLibrary, g as AssetKind, h as Asset, i as ListSessionsOptions, U as UsageSessionPage, j as UsageSession, k as ListRecordingsQuery, l as ListRecordingsResponse, R as RecordingArtifact, m as RecordingAccessResponse, n as CreditBalance, T as TranscriptPayload } from './types-D76SpA3g.js';
|
|
2
|
+
export { o as AvatarClip, p as CallConnection, q as CallQueued, r as ClipDeclaration, s as ClipLibraryPlan, t as ClipSource, u as ContextMessage, v as EndCallReason, w as RecordingArtifactStatus, x as RecordingMode, V as VideoPolicy, y as isQueued, z as listRecordingsResponseSchema, B as recordingAccessResponseSchema, D as recordingArtifactSchema, F as recordingModeSchema } from './types-D76SpA3g.js';
|
|
3
3
|
import { ConnectionHistoryResponse } from './connection-history.js';
|
|
4
4
|
import { z } from 'zod';
|
|
5
5
|
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { RealtimeAvatar, RealtimeAvatarError, RealtimeAvatarHttpError, clipLibraryDeclarationSchema, isQueued, listRecordingsResponseSchema, recordingAccessResponseSchema, recordingArtifactSchema, recordingModeSchema, verifyTranscript } from './chunk-
|
|
1
|
+
export { RealtimeAvatar, RealtimeAvatarError, RealtimeAvatarHttpError, clipLibraryDeclarationSchema, isQueued, listRecordingsResponseSchema, recordingAccessResponseSchema, recordingArtifactSchema, recordingModeSchema, verifyTranscript } from './chunk-PKOWNCDT.js';
|
|
2
2
|
import './chunk-MCIXU6XP.js';
|
package/dist/nextjs.d.ts
CHANGED
package/dist/nextjs.js
CHANGED
|
@@ -1,8 +1,23 @@
|
|
|
1
|
+
import * as livekit_client from 'livekit-client';
|
|
2
|
+
import { ConnectionQuality, Room, Participant, Track, DisconnectReason, SendTextOptions } from 'livekit-client';
|
|
1
3
|
import { TrackReferenceOrPlaceholder, useTranscriptions, useConnectionState, LiveKitRoomProps } from '@livekit/components-react';
|
|
2
4
|
import { CSSProperties, ReactNode, ReactElement } from 'react';
|
|
3
|
-
import { ConnectionQuality, Room, Participant, Track, DisconnectReason, SendTextOptions } from 'livekit-client';
|
|
4
5
|
import { z } from 'zod';
|
|
5
6
|
|
|
7
|
+
declare function useAvatarCamera({ allowed, active }: {
|
|
8
|
+
allowed: boolean;
|
|
9
|
+
active?: boolean;
|
|
10
|
+
}): {
|
|
11
|
+
enabled: boolean;
|
|
12
|
+
pending: boolean;
|
|
13
|
+
error: "permission_denied" | "unavailable" | null;
|
|
14
|
+
available: boolean;
|
|
15
|
+
toggle: () => Promise<void>;
|
|
16
|
+
setEnabled: (enabled: boolean) => Promise<void>;
|
|
17
|
+
publication: livekit_client.TrackPublication | undefined;
|
|
18
|
+
participant: livekit_client.LocalParticipant;
|
|
19
|
+
};
|
|
20
|
+
|
|
6
21
|
/**
|
|
7
22
|
* Wire schemas for the public Realtime Avatar API.
|
|
8
23
|
*
|
|
@@ -144,6 +159,7 @@ declare const liveKitSessionRequestSchema: z.ZodObject<{
|
|
|
144
159
|
off: "off";
|
|
145
160
|
server: "server";
|
|
146
161
|
}>>;
|
|
162
|
+
camera: z.ZodOptional<z.ZodBoolean>;
|
|
147
163
|
voice: z.ZodOptional<z.ZodNullable<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
148
164
|
provider: z.ZodLiteral<"cartesia">;
|
|
149
165
|
model: z.ZodDefault<z.ZodEnum<{
|
|
@@ -268,8 +284,8 @@ declare const liveKitSessionGrantSchema: z.ZodObject<{
|
|
|
268
284
|
retainedUntil: z.ZodString;
|
|
269
285
|
status: z.ZodLiteral<"failed">;
|
|
270
286
|
errorCode: z.ZodEnum<{
|
|
271
|
-
recording_unavailable: "recording_unavailable";
|
|
272
287
|
recording_failed: "recording_failed";
|
|
288
|
+
recording_unavailable: "recording_unavailable";
|
|
273
289
|
}>;
|
|
274
290
|
}, z.core.$strict>], "status">>;
|
|
275
291
|
connection_history: z.ZodOptional<z.ZodObject<{
|
|
@@ -288,6 +304,7 @@ declare const liveKitSessionGrantSchema: z.ZodObject<{
|
|
|
288
304
|
off: "off";
|
|
289
305
|
server: "server";
|
|
290
306
|
}>>;
|
|
307
|
+
camera: z.ZodOptional<z.ZodBoolean>;
|
|
291
308
|
room_created: z.ZodDefault<z.ZodBoolean>;
|
|
292
309
|
dispatch_created: z.ZodDefault<z.ZodBoolean>;
|
|
293
310
|
join_timeout_seconds: z.ZodDefault<z.ZodNumber>;
|
|
@@ -1717,4 +1734,4 @@ interface ProxyClientOptions {
|
|
|
1717
1734
|
}
|
|
1718
1735
|
declare function createProxyClient(options: ProxyClientOptions): AvatarSessionClient;
|
|
1719
1736
|
|
|
1720
|
-
export { type QualityCap 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 GovernorState as H, type GraceWindowClosedEvent as I, type GraceWindowOpenEvent as J, type GraceWindowState as K, type LiveKitSessionGrant as L, type IdleWarningEvent as M, type InboundRtpCursor as N, type InboundRtpReading as O, type KnownBehaviorState as P, type LLMProvider as Q, type LLMSelection as R, type LiveKitAvatarGrantState as S, type LiveKitAvatarGrantStatus as T, type LiveKitCapacityState as U, type LiveKitConnectionStatus as V, type LiveKitSessionRequest as W, type LiveKitSessionStartResult as X, MAX_RECONNECT_ATTEMPTS as Y, MAX_SESSION_INSTRUCTIONS_CHARS as Z, type ProxyClientOptions as _, AdaptivePlayoutController as a, RECONNECT_BACKOFF_MS as a0, type RealtimeAvatarRequestOptions as a1, type RealtimeSessionApi as a2, type RealtimeSessionMedia as a3, type RealtimeSessionRoomSinks as a4, type ReconnectPolicy as a5, type ReconnectingEvent as a6, type RecoveryState as a7, type RetryStep as a8, type SessionBehavior as a9, splitCallTranscript as aA, useAvatarAdaptivePlayoutDelay as aB,
|
|
1737
|
+
export { type QualityCap 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 GovernorState as H, type GraceWindowClosedEvent as I, type GraceWindowOpenEvent as J, type GraceWindowState as K, type LiveKitSessionGrant as L, type IdleWarningEvent as M, type InboundRtpCursor as N, type InboundRtpReading as O, type KnownBehaviorState as P, type LLMProvider as Q, type LLMSelection as R, type LiveKitAvatarGrantState as S, type LiveKitAvatarGrantStatus as T, type LiveKitCapacityState as U, type LiveKitConnectionStatus as V, type LiveKitSessionRequest as W, type LiveKitSessionStartResult as X, MAX_RECONNECT_ATTEMPTS as Y, MAX_SESSION_INSTRUCTIONS_CHARS as Z, type ProxyClientOptions as _, AdaptivePlayoutController as a, RECONNECT_BACKOFF_MS as a0, type RealtimeAvatarRequestOptions as a1, type RealtimeSessionApi as a2, type RealtimeSessionMedia as a3, type RealtimeSessionRoomSinks as a4, type ReconnectPolicy as a5, type ReconnectingEvent as a6, type RecoveryState as a7, type RetryStep as a8, type SessionBehavior as a9, splitCallTranscript as aA, useAvatarAdaptivePlayoutDelay as aB, useAvatarCamera as aC, useAvatarPlayoutDelay as aD, useAvatarQualityGovernor as aE, useCallTranscript as aF, useLiveKitAvatarGrant as aG, useLiveTrackProducing as aH, useMicLease as aI, useRealtimeSession as aJ, useReleaseMicLeaseOnTrackEnded as aK, useSessionLifecycle as aL, AvatarVideoSurface as aM, type AvatarVideoSurfaceProps as aN, type LivePlaybackKeeper as aO, MIC_LEASE_ENDED_TIMEOUT_MS as aP, type MicLease as aQ, NETWORK_QUALITY_POLICY as aR, type NetworkQualityStatus as aS, type PlayableVideoElement as aT, RealtimeAvatarCapacityError as aU, RealtimeAvatarLiveKitRoom as aV, type RealtimeAvatarLiveKitRoomProps as aW, shouldReplayPendingTurn as aX, type SessionClip as aa, type SessionClocks as ab, type SessionEndReason as ac, type SessionLifecycleApi as ad, type SessionLifecyclePhase as ae, type SessionLifecyclePhaseKind as af, SessionLifecycleRoomBridge as ag, type SessionLifecycleRoomBridgeProps as ah, type SurfaceLayers as ai, type TurnState as aj, type TurnTimeoutEvent as ak, type UseAvatarQualityGovernorInput as al, type UseLiveKitAvatarGrantInput as am, type UseRealtimeSessionInput as an, type UseSessionLifecycleInput as ao, type VoiceSpec as ap, type VoiceSpecInput as aq, capacityErrorFromBusy as ar, capacityStateFromGrant as as, createProxyClient as at, isNativeLiveTrackSubscribed as au, knownBehaviorStates as av, mapTurnState as aw, readInboundRtp as ax, sessionBehaviorSchema as ay, sessionClipSchema 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 EndedEvent as u, type ExtendResult as v, type FreezeReadingFn as w, type GovernorAction as x, type GovernorConfig as y, type GovernorSignal as z };
|
package/dist/react-native.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
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-DpMcj6fI.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, E as EndReason, u as EndedEvent, v as ExtendResult, F as FishTtsModel, w as FreezeReadingFn, G as Governor, x as GovernorAction, y as GovernorConfig, z as GovernorSignal, H as GovernorState, I as GraceWindowClosedEvent, J as GraceWindowOpenEvent, K as GraceWindowState, M as IdleWarningEvent, N as InboundRtpCursor, O as InboundRtpReading, P as KnownBehaviorState, Q as LLMProvider, R as LLMSelection, S as LiveKitAvatarGrantState, T as LiveKitAvatarGrantStatus, U as LiveKitCapacityState, V as LiveKitConnectionStatus, W as LiveKitSessionRequest, X as LiveKitSessionStartResult, Y as MAX_RECONNECT_ATTEMPTS, Z as MAX_SESSION_INSTRUCTIONS_CHARS, _ as ProxyClientOptions, $ as QualityCap, a0 as RECONNECT_BACKOFF_MS, a1 as RealtimeAvatarRequestOptions, a2 as RealtimeSessionApi, a3 as RealtimeSessionMedia, a4 as RealtimeSessionRoomSinks, a5 as ReconnectPolicy, a6 as ReconnectingEvent, a7 as RecoveryState, a8 as RetryStep, a9 as SessionBehavior, aa as SessionClip, ab as SessionClocks, ac as SessionEndReason, ad as SessionLifecycleApi, ae as SessionLifecyclePhase, af as SessionLifecyclePhaseKind, ag as SessionLifecycleRoomBridge, ah as SessionLifecycleRoomBridgeProps, ai as SurfaceLayers, aj as TurnState, ak as TurnTimeoutEvent, al as UseAvatarQualityGovernorInput, am as UseLiveKitAvatarGrantInput, an as UseRealtimeSessionInput, ao as UseSessionLifecycleInput, ap as VoiceSpec, aq as VoiceSpecInput, ar as capacityErrorFromBusy, as as capacityStateFromGrant, at as createProxyClient, au as isNativeLiveTrackSubscribed, av as knownBehaviorStates, aw as mapTurnState, ax as readInboundRtp, ay as sessionBehaviorSchema, az as sessionClipSchema, aA as splitCallTranscript, aB as useAvatarAdaptivePlayoutDelay, aC as useAvatarCamera, aD as useAvatarPlayoutDelay, aE as useAvatarQualityGovernor, aF as useCallTranscript, aG as useLiveKitAvatarGrant, aH as useLiveTrackProducing, aI as useMicLease, aJ as useRealtimeSession, aK as useReleaseMicLeaseOnTrackEnded, aL as useSessionLifecycle } from './proxy-client-DpMcj6fI.js';
|
|
3
5
|
import { ReactNode, ReactElement } from 'react';
|
|
4
|
-
import { L as LiveKitSessionGrant, A as AvatarVideoFit } from './proxy-client-w6prrzGW.js';
|
|
5
|
-
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, E as EndReason, u as EndedEvent, v as ExtendResult, F as FishTtsModel, w as FreezeReadingFn, G as Governor, x as GovernorAction, y as GovernorConfig, z as GovernorSignal, H as GovernorState, I as GraceWindowClosedEvent, J as GraceWindowOpenEvent, K as GraceWindowState, M as IdleWarningEvent, N as InboundRtpCursor, O as InboundRtpReading, P as KnownBehaviorState, Q as LLMProvider, R as LLMSelection, S as LiveKitAvatarGrantState, T as LiveKitAvatarGrantStatus, U as LiveKitCapacityState, V as LiveKitConnectionStatus, W as LiveKitSessionRequest, X as LiveKitSessionStartResult, Y as MAX_RECONNECT_ATTEMPTS, Z as MAX_SESSION_INSTRUCTIONS_CHARS, _ as ProxyClientOptions, $ as QualityCap, a0 as RECONNECT_BACKOFF_MS, a1 as RealtimeAvatarRequestOptions, a2 as RealtimeSessionApi, a3 as RealtimeSessionMedia, a4 as RealtimeSessionRoomSinks, a5 as ReconnectPolicy, a6 as ReconnectingEvent, a7 as RecoveryState, a8 as RetryStep, a9 as SessionBehavior, aa as SessionClip, ab as SessionClocks, ac as SessionEndReason, ad as SessionLifecycleApi, ae as SessionLifecyclePhase, af as SessionLifecyclePhaseKind, ag as SessionLifecycleRoomBridge, ah as SessionLifecycleRoomBridgeProps, ai as SurfaceLayers, aj as TurnState, ak as TurnTimeoutEvent, al as UseAvatarQualityGovernorInput, am as UseLiveKitAvatarGrantInput, an as UseRealtimeSessionInput, ao as UseSessionLifecycleInput, ap as VoiceSpec, aq as VoiceSpecInput, ar as capacityErrorFromBusy, as as capacityStateFromGrant, at as createProxyClient, au as isNativeLiveTrackSubscribed, av as knownBehaviorStates, aw as mapTurnState, ax as readInboundRtp, ay as sessionBehaviorSchema, az as sessionClipSchema, aA as splitCallTranscript, aB as useAvatarAdaptivePlayoutDelay, aC as useAvatarPlayoutDelay, aD as useAvatarQualityGovernor, aE as useCallTranscript, aF as useLiveKitAvatarGrant, aG as useLiveTrackProducing, aH as useMicLease, aI as useRealtimeSession, aJ as useReleaseMicLeaseOnTrackEnded, aK as useSessionLifecycle } from './proxy-client-w6prrzGW.js';
|
|
6
6
|
import { StyleProp, ViewStyle } from 'react-native';
|
|
7
7
|
export { useChat, useConnectionState, useLocalParticipant, useRoomContext, useTrackToggle, useTranscriptions, useVoiceAssistant } from '@livekit/components-react';
|
|
8
8
|
export { D as DEFAULT_AVATAR_PLAYOUT_DELAY_SECONDS } from './playout-delay-DWOc8iCl.js';
|
package/dist/react-native.js
CHANGED
|
@@ -1,14 +1,155 @@
|
|
|
1
1
|
import { AudioSession, LiveKitRoom, VideoTrack } from '@livekit/react-native';
|
|
2
2
|
export { AudioSession, VideoTrack, registerGlobals } from '@livekit/react-native';
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
3
|
+
import { useState, useRef, useEffect, useCallback, createElement, useMemo } from 'react';
|
|
4
|
+
import { useLocalParticipant, useConnectionState, useTranscriptions, useMaybeRoomContext, useVoiceAssistant, isTrackReference, useRoomContext, useChat } from '@livekit/components-react';
|
|
5
5
|
export { useChat, useConnectionState, useLocalParticipant, useRoomContext, useTrackToggle, useTranscriptions, useVoiceAssistant } from '@livekit/components-react';
|
|
6
|
-
import { isRemoteTrack, VideoQuality, ConnectionQuality, RoomEvent, TrackEvent,
|
|
6
|
+
import { ConnectionState, isRemoteTrack, VideoQuality, ConnectionQuality, RoomEvent, TrackEvent, Track, ConnectionError, ConnectionErrorReason, DisconnectReason, createLocalVideoTrack, Room } from 'livekit-client';
|
|
7
7
|
export { DisconnectReason, Room, RoomEvent, Track } from 'livekit-client';
|
|
8
8
|
import { Platform, StyleSheet, Animated, Image, View, Text } from 'react-native';
|
|
9
9
|
import { z } from 'zod';
|
|
10
10
|
|
|
11
11
|
// ../client/src/react-native/index.ts
|
|
12
|
+
|
|
13
|
+
// ../client/src/camera.ts
|
|
14
|
+
function defaultCameraCaptureOptions() {
|
|
15
|
+
return { resolution: { width: 640, height: 360, frameRate: 5 }, facingMode: "user" };
|
|
16
|
+
}
|
|
17
|
+
function cameraPublishOptions(grant, video) {
|
|
18
|
+
if (grant?.camera !== true) return false;
|
|
19
|
+
return video === true ? defaultCameraCaptureOptions() : video;
|
|
20
|
+
}
|
|
21
|
+
function createCameraControl(driver) {
|
|
22
|
+
let desired = false;
|
|
23
|
+
let disposed = false;
|
|
24
|
+
let generation = 0;
|
|
25
|
+
let current = null;
|
|
26
|
+
let opening = null;
|
|
27
|
+
let closing = Promise.resolve();
|
|
28
|
+
const retire = (track) => {
|
|
29
|
+
let stopFailure;
|
|
30
|
+
try {
|
|
31
|
+
track.stop();
|
|
32
|
+
} catch (cause) {
|
|
33
|
+
stopFailure = new Error("Camera capture could not stop", { cause });
|
|
34
|
+
}
|
|
35
|
+
const operation = closing.then(async () => {
|
|
36
|
+
await driver.unpublish(track);
|
|
37
|
+
if (stopFailure) throw stopFailure;
|
|
38
|
+
});
|
|
39
|
+
closing = operation.catch(() => {
|
|
40
|
+
});
|
|
41
|
+
return operation;
|
|
42
|
+
};
|
|
43
|
+
async function setEnabled(enabled) {
|
|
44
|
+
desired = enabled && !disposed;
|
|
45
|
+
if (!desired) {
|
|
46
|
+
generation += 1;
|
|
47
|
+
const track = current;
|
|
48
|
+
current = null;
|
|
49
|
+
if (track) await retire(track);
|
|
50
|
+
return;
|
|
51
|
+
}
|
|
52
|
+
if (opening) {
|
|
53
|
+
await opening;
|
|
54
|
+
if (desired && !disposed && !current) await setEnabled(true);
|
|
55
|
+
return;
|
|
56
|
+
}
|
|
57
|
+
if (current) return;
|
|
58
|
+
const attempt = generation;
|
|
59
|
+
driver.onPending(true);
|
|
60
|
+
opening = Promise.resolve().then(async () => {
|
|
61
|
+
await closing;
|
|
62
|
+
if (!desired || disposed || attempt !== generation) return;
|
|
63
|
+
const track = await driver.capture(defaultCameraCaptureOptions());
|
|
64
|
+
if (!desired || disposed || attempt !== generation) {
|
|
65
|
+
track.stop();
|
|
66
|
+
return;
|
|
67
|
+
}
|
|
68
|
+
current = track;
|
|
69
|
+
try {
|
|
70
|
+
await driver.publish(track);
|
|
71
|
+
} catch (error) {
|
|
72
|
+
if (current === track) current = null;
|
|
73
|
+
await retire(track);
|
|
74
|
+
throw error;
|
|
75
|
+
}
|
|
76
|
+
if (!desired || disposed || attempt !== generation) {
|
|
77
|
+
if (current === track) current = null;
|
|
78
|
+
await retire(track);
|
|
79
|
+
}
|
|
80
|
+
}).finally(() => {
|
|
81
|
+
opening = null;
|
|
82
|
+
driver.onPending(false);
|
|
83
|
+
});
|
|
84
|
+
return opening;
|
|
85
|
+
}
|
|
86
|
+
return {
|
|
87
|
+
get pending() {
|
|
88
|
+
return opening !== null;
|
|
89
|
+
},
|
|
90
|
+
setEnabled,
|
|
91
|
+
async close() {
|
|
92
|
+
disposed = true;
|
|
93
|
+
await setEnabled(false);
|
|
94
|
+
}
|
|
95
|
+
};
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
// ../client/src/react/use-avatar-camera.ts
|
|
99
|
+
function useAvatarCamera({ allowed, active = true }) {
|
|
100
|
+
const { localParticipant, cameraTrack, isCameraEnabled } = useLocalParticipant();
|
|
101
|
+
const connection = useConnectionState();
|
|
102
|
+
const [pending, setPending] = useState(false);
|
|
103
|
+
const [error, setError] = useState(null);
|
|
104
|
+
const control = useRef(null);
|
|
105
|
+
const available = allowed && active && connection === ConnectionState.Connected;
|
|
106
|
+
useEffect(() => {
|
|
107
|
+
let alive = true;
|
|
108
|
+
const current = createCameraControl({
|
|
109
|
+
capture: createLocalVideoTrack,
|
|
110
|
+
publish: (track) => localParticipant.publishTrack(track, { source: Track.Source.Camera }),
|
|
111
|
+
unpublish: (track) => localParticipant.unpublishTrack(track, true),
|
|
112
|
+
onPending: (value) => {
|
|
113
|
+
if (alive) setPending(value);
|
|
114
|
+
}
|
|
115
|
+
});
|
|
116
|
+
control.current = current;
|
|
117
|
+
return () => {
|
|
118
|
+
alive = false;
|
|
119
|
+
control.current = null;
|
|
120
|
+
void current.close().catch(() => {
|
|
121
|
+
});
|
|
122
|
+
};
|
|
123
|
+
}, [localParticipant]);
|
|
124
|
+
const setEnabled = useCallback(async (enabled) => {
|
|
125
|
+
const current = control.current;
|
|
126
|
+
if (!current) return;
|
|
127
|
+
setError(null);
|
|
128
|
+
try {
|
|
129
|
+
await current.setEnabled(enabled && available);
|
|
130
|
+
} catch (failure) {
|
|
131
|
+
if (control.current !== current) return;
|
|
132
|
+
setError(failure instanceof Error && failure.name === "NotAllowedError" ? "permission_denied" : "unavailable");
|
|
133
|
+
}
|
|
134
|
+
}, [available]);
|
|
135
|
+
useEffect(() => {
|
|
136
|
+
if (!available) void setEnabled(false);
|
|
137
|
+
}, [available, setEnabled]);
|
|
138
|
+
const toggle = useCallback(
|
|
139
|
+
() => setEnabled(!isCameraEnabled && !control.current?.pending),
|
|
140
|
+
[isCameraEnabled, setEnabled]
|
|
141
|
+
);
|
|
142
|
+
return {
|
|
143
|
+
enabled: isCameraEnabled,
|
|
144
|
+
pending,
|
|
145
|
+
error,
|
|
146
|
+
available,
|
|
147
|
+
toggle,
|
|
148
|
+
setEnabled,
|
|
149
|
+
publication: cameraTrack,
|
|
150
|
+
participant: localParticipant
|
|
151
|
+
};
|
|
152
|
+
}
|
|
12
153
|
function useRealtimeAvatarAudioSession(enabled) {
|
|
13
154
|
useEffect(() => {
|
|
14
155
|
if (!enabled) return;
|
|
@@ -40,7 +181,7 @@ function RealtimeAvatarLiveKitRoom(props) {
|
|
|
40
181
|
token: grant?.participant_token,
|
|
41
182
|
connect: shouldConnect,
|
|
42
183
|
audio: audio ?? grant?.stt_mode === "server",
|
|
43
|
-
video,
|
|
184
|
+
video: cameraPublishOptions(grant, video),
|
|
44
185
|
options: roomOptions
|
|
45
186
|
},
|
|
46
187
|
children
|
|
@@ -1482,7 +1623,7 @@ z.object({
|
|
|
1482
1623
|
expiresAt: z.string().datetime({ offset: true })
|
|
1483
1624
|
}).strict();
|
|
1484
1625
|
var ConnectionQuality2 = { Excellent: "excellent", Good: "good", Poor: "poor", Lost: "lost", Unknown: "unknown" };
|
|
1485
|
-
var
|
|
1626
|
+
var ConnectionState5 = { Disconnected: "disconnected", Connecting: "connecting", Connected: "connected", Reconnecting: "reconnecting", SignalReconnecting: "signalReconnecting" };
|
|
1486
1627
|
var MAX_CONNECTION_HISTORY_OBSERVATIONS = 240;
|
|
1487
1628
|
var MAX_CONNECTION_HISTORY_BATCH = 32;
|
|
1488
1629
|
var quality = z.enum(ConnectionQuality2);
|
|
@@ -1490,7 +1631,7 @@ var connectionHistoryObservationSchema = z.object({
|
|
|
1490
1631
|
sequence: z.number().int().min(1).max(MAX_CONNECTION_HISTORY_OBSERVATIONS),
|
|
1491
1632
|
elapsedMs: z.number().int().min(0).max(864e5),
|
|
1492
1633
|
clientObservedAt: z.string().datetime({ offset: true }).nullable(),
|
|
1493
|
-
connectionState: z.enum(
|
|
1634
|
+
connectionState: z.enum(ConnectionState5),
|
|
1494
1635
|
localQuality: quality,
|
|
1495
1636
|
audioQuality: quality.nullable(),
|
|
1496
1637
|
videoQuality: quality.nullable()
|
|
@@ -1657,6 +1798,7 @@ z.object({
|
|
|
1657
1798
|
source_kind: avatarSourceKindSchema.default("portrait"),
|
|
1658
1799
|
source_video_url: nullableUrlSchema.optional(),
|
|
1659
1800
|
stt_mode: liveKitSttModeSchema.default("server"),
|
|
1801
|
+
camera: z.boolean().optional(),
|
|
1660
1802
|
video_cache_id: z.string().min(1).max(240).nullable().optional(),
|
|
1661
1803
|
voice: voiceSpecSchema.nullable().optional(),
|
|
1662
1804
|
voice_id: z.string().min(1).max(240).nullable().optional(),
|
|
@@ -1729,6 +1871,7 @@ z.object({
|
|
|
1729
1871
|
queueTicketId: z.string().min(1).max(160).optional(),
|
|
1730
1872
|
roomName: z.string().min(1).max(160).optional(),
|
|
1731
1873
|
sttMode: liveKitSttModeSchema.default("server"),
|
|
1874
|
+
camera: z.boolean().optional(),
|
|
1732
1875
|
voice: voiceSpecSchema.nullable().optional(),
|
|
1733
1876
|
voiceId: z.string().min(1).max(240).nullable().optional(),
|
|
1734
1877
|
// Unbounded, for the same reason as `clip_library` on the wire schema above.
|
|
@@ -1751,6 +1894,7 @@ z.object({
|
|
|
1751
1894
|
participant_identity: z.string().min(1),
|
|
1752
1895
|
reservation_expires_at: z.string().datetime({ offset: true }),
|
|
1753
1896
|
stt_mode: liveKitSttModeSchema.default("server"),
|
|
1897
|
+
camera: z.boolean().optional(),
|
|
1754
1898
|
room_created: z.boolean().default(false),
|
|
1755
1899
|
dispatch_created: z.boolean().default(false),
|
|
1756
1900
|
join_timeout_seconds: z.number().int().nonnegative().default(0),
|
|
@@ -3105,4 +3249,4 @@ function createProxyClient(options) {
|
|
|
3105
3249
|
};
|
|
3106
3250
|
}
|
|
3107
3251
|
|
|
3108
|
-
export { AdaptivePlayoutController, AvatarVideoSurface, DEFAULT_APPROACHING_END_LEAD_SECONDS, DEFAULT_AVATAR_PLAYOUT_DELAY_SECONDS, DEFAULT_CREDITS_LOW_LEAD_SECONDS, DEFAULT_GOVERNOR_CONFIG, DEFAULT_GRACE_CEILING_SECONDS, DEFAULT_GRACE_WINDOW_LEAD_SECONDS, DEFAULT_IDLE_SECONDS, DEFAULT_IDLE_WARN_LEAD_SECONDS, DEFAULT_TURN_TIMEOUT_SECONDS, MAX_RECONNECT_ATTEMPTS, MAX_SESSION_INSTRUCTIONS_CHARS, RECONNECT_BACKOFF_MS, RealtimeAvatarLiveKitRoom, SessionLifecycleRoomBridge, capacityErrorFromBusy, capacityStateFromGrant, createProxyClient, isNativeLiveTrackSubscribed, knownBehaviorStates, mapTurnState, readInboundRtp, sessionBehaviorSchema, sessionClipSchema, splitCallTranscript, useAvatarAdaptivePlayoutDelay, useAvatarPlayoutDelay, useAvatarQualityGovernor, useCallTranscript, useLiveKitAvatarGrant, useLiveTrackProducing, useMicLease, useRealtimeAvatarAudioSession, useRealtimeSession, useReleaseMicLeaseOnTrackEnded, useSessionLifecycle };
|
|
3252
|
+
export { AdaptivePlayoutController, AvatarVideoSurface, DEFAULT_APPROACHING_END_LEAD_SECONDS, DEFAULT_AVATAR_PLAYOUT_DELAY_SECONDS, DEFAULT_CREDITS_LOW_LEAD_SECONDS, DEFAULT_GOVERNOR_CONFIG, DEFAULT_GRACE_CEILING_SECONDS, DEFAULT_GRACE_WINDOW_LEAD_SECONDS, DEFAULT_IDLE_SECONDS, DEFAULT_IDLE_WARN_LEAD_SECONDS, DEFAULT_TURN_TIMEOUT_SECONDS, MAX_RECONNECT_ATTEMPTS, MAX_SESSION_INSTRUCTIONS_CHARS, RECONNECT_BACKOFF_MS, RealtimeAvatarLiveKitRoom, SessionLifecycleRoomBridge, capacityErrorFromBusy, capacityStateFromGrant, createProxyClient, isNativeLiveTrackSubscribed, knownBehaviorStates, mapTurnState, readInboundRtp, sessionBehaviorSchema, sessionClipSchema, splitCallTranscript, useAvatarAdaptivePlayoutDelay, useAvatarCamera, useAvatarPlayoutDelay, useAvatarQualityGovernor, useCallTranscript, useLiveKitAvatarGrant, useLiveTrackProducing, useMicLease, useRealtimeAvatarAudioSession, useRealtimeSession, useReleaseMicLeaseOnTrackEnded, useSessionLifecycle };
|
package/dist/react.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { RegisteredTool, ToolRegistration } from './tools.js';
|
|
2
|
+
import { ah as SessionLifecycleRoomBridgeProps, h as AvatarSessionClient, A as AvatarVideoFit } from './proxy-client-DpMcj6fI.js';
|
|
3
|
+
export { a as AdaptivePlayoutController, b as AdaptivePlayoutDecision, c as AdaptivePlayoutOptions, d as AdaptivePlayoutSample, e as ApproachingEndEvent, f as ApproachingEndReason, g as AvatarConnectionDetails, aM as AvatarVideoSurface, aN as AvatarVideoSurfaceProps, 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, E as EndReason, u as EndedEvent, v as ExtendResult, F as FishTtsModel, w as FreezeReadingFn, G as Governor, x as GovernorAction, y as GovernorConfig, z as GovernorSignal, H as GovernorState, I as GraceWindowClosedEvent, J as GraceWindowOpenEvent, K as GraceWindowState, M as IdleWarningEvent, N as InboundRtpCursor, O as InboundRtpReading, P as KnownBehaviorState, Q as LLMProvider, R as LLMSelection, S as LiveKitAvatarGrantState, T as LiveKitAvatarGrantStatus, U as LiveKitCapacityState, V as LiveKitConnectionStatus, W as LiveKitSessionRequest, X as LiveKitSessionStartResult, aO as LivePlaybackKeeper, Y as MAX_RECONNECT_ATTEMPTS, Z as MAX_SESSION_INSTRUCTIONS_CHARS, aP as MIC_LEASE_ENDED_TIMEOUT_MS, aQ as MicLease, aR as NETWORK_QUALITY_POLICY, aS as NetworkQualityStatus, aT as PlayableVideoElement, _ as ProxyClientOptions, $ as QualityCap, a0 as RECONNECT_BACKOFF_MS, aU as RealtimeAvatarCapacityError, aV as RealtimeAvatarLiveKitRoom, aW as RealtimeAvatarLiveKitRoomProps, a1 as RealtimeAvatarRequestOptions, a2 as RealtimeSessionApi, a3 as RealtimeSessionMedia, a4 as RealtimeSessionRoomSinks, a5 as ReconnectPolicy, a6 as ReconnectingEvent, a7 as RecoveryState, a8 as RetryStep, a9 as SessionBehavior, aa as SessionClip, ab as SessionClocks, ac as SessionEndReason, ad as SessionLifecycleApi, ae as SessionLifecyclePhase, af as SessionLifecyclePhaseKind, ag as SessionLifecycleRoomBridge, ai as SurfaceLayers, aj as TurnState, ak as TurnTimeoutEvent, al as UseAvatarQualityGovernorInput, am as UseLiveKitAvatarGrantInput, an as UseRealtimeSessionInput, ao as UseSessionLifecycleInput, ap as VoiceSpec, aq as VoiceSpecInput, ar as capacityErrorFromBusy, as as capacityStateFromGrant, at as createProxyClient, av as knownBehaviorStates, aw as mapTurnState, ax as readInboundRtp, ay as sessionBehaviorSchema, az as sessionClipSchema, aX as shouldReplayPendingTurn, aA as splitCallTranscript, aB as useAvatarAdaptivePlayoutDelay, aC as useAvatarCamera, aD as useAvatarPlayoutDelay, aE as useAvatarQualityGovernor, aF as useCallTranscript, aG as useLiveKitAvatarGrant, aI as useMicLease, aJ as useRealtimeSession, aK as useReleaseMicLeaseOnTrackEnded, aL as useSessionLifecycle } from './proxy-client-DpMcj6fI.js';
|
|
2
4
|
import { ReactNode } from 'react';
|
|
3
|
-
import { ah as SessionLifecycleRoomBridgeProps, h as AvatarSessionClient, A as AvatarVideoFit } from './proxy-client-w6prrzGW.js';
|
|
4
|
-
export { a as AdaptivePlayoutController, b as AdaptivePlayoutDecision, c as AdaptivePlayoutOptions, d as AdaptivePlayoutSample, e as ApproachingEndEvent, f as ApproachingEndReason, g as AvatarConnectionDetails, aL as AvatarVideoSurface, aM as AvatarVideoSurfaceProps, 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, E as EndReason, u as EndedEvent, v as ExtendResult, F as FishTtsModel, w as FreezeReadingFn, G as Governor, x as GovernorAction, y as GovernorConfig, z as GovernorSignal, H as GovernorState, I as GraceWindowClosedEvent, J as GraceWindowOpenEvent, K as GraceWindowState, M as IdleWarningEvent, N as InboundRtpCursor, O as InboundRtpReading, P as KnownBehaviorState, Q as LLMProvider, R as LLMSelection, S as LiveKitAvatarGrantState, T as LiveKitAvatarGrantStatus, U as LiveKitCapacityState, V as LiveKitConnectionStatus, W as LiveKitSessionRequest, X as LiveKitSessionStartResult, aN as LivePlaybackKeeper, Y as MAX_RECONNECT_ATTEMPTS, Z as MAX_SESSION_INSTRUCTIONS_CHARS, aO as MIC_LEASE_ENDED_TIMEOUT_MS, aP as MicLease, aQ as NETWORK_QUALITY_POLICY, aR as NetworkQualityStatus, aS as PlayableVideoElement, _ as ProxyClientOptions, $ as QualityCap, a0 as RECONNECT_BACKOFF_MS, aT as RealtimeAvatarCapacityError, aU as RealtimeAvatarLiveKitRoom, aV as RealtimeAvatarLiveKitRoomProps, a1 as RealtimeAvatarRequestOptions, a2 as RealtimeSessionApi, a3 as RealtimeSessionMedia, a4 as RealtimeSessionRoomSinks, a5 as ReconnectPolicy, a6 as ReconnectingEvent, a7 as RecoveryState, a8 as RetryStep, a9 as SessionBehavior, aa as SessionClip, ab as SessionClocks, ac as SessionEndReason, ad as SessionLifecycleApi, ae as SessionLifecyclePhase, af as SessionLifecyclePhaseKind, ag as SessionLifecycleRoomBridge, ai as SurfaceLayers, aj as TurnState, ak as TurnTimeoutEvent, al as UseAvatarQualityGovernorInput, am as UseLiveKitAvatarGrantInput, an as UseRealtimeSessionInput, ao as UseSessionLifecycleInput, ap as VoiceSpec, aq as VoiceSpecInput, ar as capacityErrorFromBusy, as as capacityStateFromGrant, at as createProxyClient, av as knownBehaviorStates, aw as mapTurnState, ax as readInboundRtp, ay as sessionBehaviorSchema, az as sessionClipSchema, aW as shouldReplayPendingTurn, aA as splitCallTranscript, aB as useAvatarAdaptivePlayoutDelay, aC as useAvatarPlayoutDelay, aD as useAvatarQualityGovernor, aE as useCallTranscript, aF as useLiveKitAvatarGrant, aH as useMicLease, aI as useRealtimeSession, aJ as useReleaseMicLeaseOnTrackEnded, aK as useSessionLifecycle } from './proxy-client-w6prrzGW.js';
|
|
5
5
|
export { D as DEFAULT_AVATAR_PLAYOUT_DELAY_SECONDS } from './playout-delay-DWOc8iCl.js';
|
|
6
6
|
import 'zod';
|
|
7
|
-
import '@livekit/components-react';
|
|
8
7
|
import 'livekit-client';
|
|
8
|
+
import '@livekit/components-react';
|
|
9
9
|
|
|
10
10
|
/**
|
|
11
11
|
* Once a link has proven unstable, hold the frozen live frame this long before
|
package/dist/react.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { useRef, useState, useEffect, useCallback, useMemo, createElement, Fragment } from 'react';
|
|
3
|
-
import { useRoomContext, useConnectionState,
|
|
4
|
-
import { ConnectionState, isRemoteTrack, VideoQuality, ConnectionQuality, RoomEvent, TrackEvent, Track, ConnectionError, ConnectionErrorReason, DisconnectReason, Room } from 'livekit-client';
|
|
3
|
+
import { useRoomContext, useConnectionState, useLocalParticipant, useTranscriptions, RoomAudioRenderer, LiveKitRoom, useMaybeRoomContext, useVoiceAssistant, VideoTrack, useChat } from '@livekit/components-react';
|
|
4
|
+
import { ConnectionState, isRemoteTrack, VideoQuality, ConnectionQuality, RoomEvent, TrackEvent, Track, ConnectionError, ConnectionErrorReason, DisconnectReason, createLocalVideoTrack, Room } from 'livekit-client';
|
|
5
5
|
import { z } from 'zod';
|
|
6
6
|
|
|
7
7
|
// ../client/src/react/use-character-tools.ts
|
|
@@ -199,6 +199,147 @@ function useCharacterTools(tools, options = {}) {
|
|
|
199
199
|
}, [room, tools, connection]);
|
|
200
200
|
return state;
|
|
201
201
|
}
|
|
202
|
+
|
|
203
|
+
// ../client/src/camera.ts
|
|
204
|
+
function defaultCameraCaptureOptions() {
|
|
205
|
+
return { resolution: { width: 640, height: 360, frameRate: 5 }, facingMode: "user" };
|
|
206
|
+
}
|
|
207
|
+
function cameraPublishOptions(grant, video) {
|
|
208
|
+
if (grant?.camera !== true) return false;
|
|
209
|
+
return video === true ? defaultCameraCaptureOptions() : video;
|
|
210
|
+
}
|
|
211
|
+
function createCameraControl(driver) {
|
|
212
|
+
let desired = false;
|
|
213
|
+
let disposed = false;
|
|
214
|
+
let generation = 0;
|
|
215
|
+
let current = null;
|
|
216
|
+
let opening = null;
|
|
217
|
+
let closing = Promise.resolve();
|
|
218
|
+
const retire = (track) => {
|
|
219
|
+
let stopFailure;
|
|
220
|
+
try {
|
|
221
|
+
track.stop();
|
|
222
|
+
} catch (cause) {
|
|
223
|
+
stopFailure = new Error("Camera capture could not stop", { cause });
|
|
224
|
+
}
|
|
225
|
+
const operation = closing.then(async () => {
|
|
226
|
+
await driver.unpublish(track);
|
|
227
|
+
if (stopFailure) throw stopFailure;
|
|
228
|
+
});
|
|
229
|
+
closing = operation.catch(() => {
|
|
230
|
+
});
|
|
231
|
+
return operation;
|
|
232
|
+
};
|
|
233
|
+
async function setEnabled(enabled) {
|
|
234
|
+
desired = enabled && !disposed;
|
|
235
|
+
if (!desired) {
|
|
236
|
+
generation += 1;
|
|
237
|
+
const track = current;
|
|
238
|
+
current = null;
|
|
239
|
+
if (track) await retire(track);
|
|
240
|
+
return;
|
|
241
|
+
}
|
|
242
|
+
if (opening) {
|
|
243
|
+
await opening;
|
|
244
|
+
if (desired && !disposed && !current) await setEnabled(true);
|
|
245
|
+
return;
|
|
246
|
+
}
|
|
247
|
+
if (current) return;
|
|
248
|
+
const attempt = generation;
|
|
249
|
+
driver.onPending(true);
|
|
250
|
+
opening = Promise.resolve().then(async () => {
|
|
251
|
+
await closing;
|
|
252
|
+
if (!desired || disposed || attempt !== generation) return;
|
|
253
|
+
const track = await driver.capture(defaultCameraCaptureOptions());
|
|
254
|
+
if (!desired || disposed || attempt !== generation) {
|
|
255
|
+
track.stop();
|
|
256
|
+
return;
|
|
257
|
+
}
|
|
258
|
+
current = track;
|
|
259
|
+
try {
|
|
260
|
+
await driver.publish(track);
|
|
261
|
+
} catch (error) {
|
|
262
|
+
if (current === track) current = null;
|
|
263
|
+
await retire(track);
|
|
264
|
+
throw error;
|
|
265
|
+
}
|
|
266
|
+
if (!desired || disposed || attempt !== generation) {
|
|
267
|
+
if (current === track) current = null;
|
|
268
|
+
await retire(track);
|
|
269
|
+
}
|
|
270
|
+
}).finally(() => {
|
|
271
|
+
opening = null;
|
|
272
|
+
driver.onPending(false);
|
|
273
|
+
});
|
|
274
|
+
return opening;
|
|
275
|
+
}
|
|
276
|
+
return {
|
|
277
|
+
get pending() {
|
|
278
|
+
return opening !== null;
|
|
279
|
+
},
|
|
280
|
+
setEnabled,
|
|
281
|
+
async close() {
|
|
282
|
+
disposed = true;
|
|
283
|
+
await setEnabled(false);
|
|
284
|
+
}
|
|
285
|
+
};
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
// ../client/src/react/use-avatar-camera.ts
|
|
289
|
+
function useAvatarCamera({ allowed, active = true }) {
|
|
290
|
+
const { localParticipant, cameraTrack, isCameraEnabled } = useLocalParticipant();
|
|
291
|
+
const connection = useConnectionState();
|
|
292
|
+
const [pending, setPending] = useState(false);
|
|
293
|
+
const [error, setError] = useState(null);
|
|
294
|
+
const control = useRef(null);
|
|
295
|
+
const available = allowed && active && connection === ConnectionState.Connected;
|
|
296
|
+
useEffect(() => {
|
|
297
|
+
let alive = true;
|
|
298
|
+
const current = createCameraControl({
|
|
299
|
+
capture: createLocalVideoTrack,
|
|
300
|
+
publish: (track) => localParticipant.publishTrack(track, { source: Track.Source.Camera }),
|
|
301
|
+
unpublish: (track) => localParticipant.unpublishTrack(track, true),
|
|
302
|
+
onPending: (value) => {
|
|
303
|
+
if (alive) setPending(value);
|
|
304
|
+
}
|
|
305
|
+
});
|
|
306
|
+
control.current = current;
|
|
307
|
+
return () => {
|
|
308
|
+
alive = false;
|
|
309
|
+
control.current = null;
|
|
310
|
+
void current.close().catch(() => {
|
|
311
|
+
});
|
|
312
|
+
};
|
|
313
|
+
}, [localParticipant]);
|
|
314
|
+
const setEnabled = useCallback(async (enabled) => {
|
|
315
|
+
const current = control.current;
|
|
316
|
+
if (!current) return;
|
|
317
|
+
setError(null);
|
|
318
|
+
try {
|
|
319
|
+
await current.setEnabled(enabled && available);
|
|
320
|
+
} catch (failure) {
|
|
321
|
+
if (control.current !== current) return;
|
|
322
|
+
setError(failure instanceof Error && failure.name === "NotAllowedError" ? "permission_denied" : "unavailable");
|
|
323
|
+
}
|
|
324
|
+
}, [available]);
|
|
325
|
+
useEffect(() => {
|
|
326
|
+
if (!available) void setEnabled(false);
|
|
327
|
+
}, [available, setEnabled]);
|
|
328
|
+
const toggle = useCallback(
|
|
329
|
+
() => setEnabled(!isCameraEnabled && !control.current?.pending),
|
|
330
|
+
[isCameraEnabled, setEnabled]
|
|
331
|
+
);
|
|
332
|
+
return {
|
|
333
|
+
enabled: isCameraEnabled,
|
|
334
|
+
pending,
|
|
335
|
+
error,
|
|
336
|
+
available,
|
|
337
|
+
toggle,
|
|
338
|
+
setEnabled,
|
|
339
|
+
publication: cameraTrack,
|
|
340
|
+
participant: localParticipant
|
|
341
|
+
};
|
|
342
|
+
}
|
|
202
343
|
var holder = null;
|
|
203
344
|
var queue = [];
|
|
204
345
|
var pendingEnded = null;
|
|
@@ -846,7 +987,7 @@ function RealtimeAvatarLiveKitRoom(props) {
|
|
|
846
987
|
token: grant?.participant_token,
|
|
847
988
|
connect: shouldConnect,
|
|
848
989
|
audio: audio ?? grant?.stt_mode === "server",
|
|
849
|
-
video,
|
|
990
|
+
video: cameraPublishOptions(grant, video),
|
|
850
991
|
options: roomOptions
|
|
851
992
|
},
|
|
852
993
|
createElement(Fragment, null, cushion, children, roomAudio)
|
|
@@ -2016,7 +2157,7 @@ z.object({
|
|
|
2016
2157
|
expiresAt: z.string().datetime({ offset: true })
|
|
2017
2158
|
}).strict();
|
|
2018
2159
|
var ConnectionQuality2 = { Excellent: "excellent", Good: "good", Poor: "poor", Lost: "lost", Unknown: "unknown" };
|
|
2019
|
-
var
|
|
2160
|
+
var ConnectionState5 = { Disconnected: "disconnected", Connecting: "connecting", Connected: "connected", Reconnecting: "reconnecting", SignalReconnecting: "signalReconnecting" };
|
|
2020
2161
|
var MAX_CONNECTION_HISTORY_OBSERVATIONS = 240;
|
|
2021
2162
|
var MAX_CONNECTION_HISTORY_BATCH = 32;
|
|
2022
2163
|
var quality = z.enum(ConnectionQuality2);
|
|
@@ -2024,7 +2165,7 @@ var connectionHistoryObservationSchema = z.object({
|
|
|
2024
2165
|
sequence: z.number().int().min(1).max(MAX_CONNECTION_HISTORY_OBSERVATIONS),
|
|
2025
2166
|
elapsedMs: z.number().int().min(0).max(864e5),
|
|
2026
2167
|
clientObservedAt: z.string().datetime({ offset: true }).nullable(),
|
|
2027
|
-
connectionState: z.enum(
|
|
2168
|
+
connectionState: z.enum(ConnectionState5),
|
|
2028
2169
|
localQuality: quality,
|
|
2029
2170
|
audioQuality: quality.nullable(),
|
|
2030
2171
|
videoQuality: quality.nullable()
|
|
@@ -2191,6 +2332,7 @@ z.object({
|
|
|
2191
2332
|
source_kind: avatarSourceKindSchema.default("portrait"),
|
|
2192
2333
|
source_video_url: nullableUrlSchema.optional(),
|
|
2193
2334
|
stt_mode: liveKitSttModeSchema.default("server"),
|
|
2335
|
+
camera: z.boolean().optional(),
|
|
2194
2336
|
video_cache_id: z.string().min(1).max(240).nullable().optional(),
|
|
2195
2337
|
voice: voiceSpecSchema.nullable().optional(),
|
|
2196
2338
|
voice_id: z.string().min(1).max(240).nullable().optional(),
|
|
@@ -2263,6 +2405,7 @@ z.object({
|
|
|
2263
2405
|
queueTicketId: z.string().min(1).max(160).optional(),
|
|
2264
2406
|
roomName: z.string().min(1).max(160).optional(),
|
|
2265
2407
|
sttMode: liveKitSttModeSchema.default("server"),
|
|
2408
|
+
camera: z.boolean().optional(),
|
|
2266
2409
|
voice: voiceSpecSchema.nullable().optional(),
|
|
2267
2410
|
voiceId: z.string().min(1).max(240).nullable().optional(),
|
|
2268
2411
|
// Unbounded, for the same reason as `clip_library` on the wire schema above.
|
|
@@ -2285,6 +2428,7 @@ z.object({
|
|
|
2285
2428
|
participant_identity: z.string().min(1),
|
|
2286
2429
|
reservation_expires_at: z.string().datetime({ offset: true }),
|
|
2287
2430
|
stt_mode: liveKitSttModeSchema.default("server"),
|
|
2431
|
+
camera: z.boolean().optional(),
|
|
2288
2432
|
room_created: z.boolean().default(false),
|
|
2289
2433
|
dispatch_created: z.boolean().default(false),
|
|
2290
2434
|
join_timeout_seconds: z.number().int().nonnegative().default(0),
|
|
@@ -3730,4 +3874,4 @@ function createProxyClient(options) {
|
|
|
3730
3874
|
};
|
|
3731
3875
|
}
|
|
3732
3876
|
|
|
3733
|
-
export { AdaptivePlayoutController, AvatarCall, AvatarVideoSurface, DEFAULT_APPROACHING_END_LEAD_SECONDS, DEFAULT_AVATAR_PLAYOUT_DELAY_SECONDS, DEFAULT_AVATAR_UNSTABLE_STALL_MS, DEFAULT_CREDITS_LOW_LEAD_SECONDS, DEFAULT_GOVERNOR_CONFIG, DEFAULT_GRACE_CEILING_SECONDS, DEFAULT_GRACE_WINDOW_LEAD_SECONDS, DEFAULT_IDLE_SECONDS, DEFAULT_IDLE_WARN_LEAD_SECONDS, DEFAULT_TURN_TIMEOUT_SECONDS, MAX_RECONNECT_ATTEMPTS, MAX_SESSION_INSTRUCTIONS_CHARS, MIC_LEASE_ENDED_TIMEOUT_MS, NETWORK_QUALITY_POLICY, RECONNECT_BACKOFF_MS, RealtimeAvatarCapacityError, RealtimeAvatarLiveKitRoom, SessionLifecycleRoomBridge, capacityErrorFromBusy, capacityStateFromGrant, createProxyClient, knownBehaviorStates, mapTurnState, readInboundRtp, sessionBehaviorSchema, sessionClipSchema, shouldReplayPendingTurn, splitCallTranscript, useAvatarAdaptivePlayoutDelay, useAvatarCall, useAvatarPlayoutDelay, useAvatarQualityGovernor, useCallTranscript, useCharacterTools, useLiveKitAvatarGrant, useMicLease, useRealtimeSession, useReleaseMicLeaseOnTrackEnded, useSessionLifecycle };
|
|
3877
|
+
export { AdaptivePlayoutController, AvatarCall, AvatarVideoSurface, DEFAULT_APPROACHING_END_LEAD_SECONDS, DEFAULT_AVATAR_PLAYOUT_DELAY_SECONDS, DEFAULT_AVATAR_UNSTABLE_STALL_MS, DEFAULT_CREDITS_LOW_LEAD_SECONDS, DEFAULT_GOVERNOR_CONFIG, DEFAULT_GRACE_CEILING_SECONDS, DEFAULT_GRACE_WINDOW_LEAD_SECONDS, DEFAULT_IDLE_SECONDS, DEFAULT_IDLE_WARN_LEAD_SECONDS, DEFAULT_TURN_TIMEOUT_SECONDS, MAX_RECONNECT_ATTEMPTS, MAX_SESSION_INSTRUCTIONS_CHARS, MIC_LEASE_ENDED_TIMEOUT_MS, NETWORK_QUALITY_POLICY, RECONNECT_BACKOFF_MS, RealtimeAvatarCapacityError, RealtimeAvatarLiveKitRoom, SessionLifecycleRoomBridge, capacityErrorFromBusy, capacityStateFromGrant, createProxyClient, knownBehaviorStates, mapTurnState, readInboundRtp, sessionBehaviorSchema, sessionClipSchema, shouldReplayPendingTurn, splitCallTranscript, useAvatarAdaptivePlayoutDelay, useAvatarCall, useAvatarCamera, useAvatarPlayoutDelay, useAvatarQualityGovernor, useCallTranscript, useCharacterTools, useLiveKitAvatarGrant, useMicLease, useRealtimeSession, useReleaseMicLeaseOnTrackEnded, useSessionLifecycle };
|
package/dist/recording.d.ts
CHANGED
|
@@ -61,8 +61,8 @@ declare const recordingArtifactSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
61
61
|
retainedUntil: z.ZodString;
|
|
62
62
|
status: z.ZodLiteral<"failed">;
|
|
63
63
|
errorCode: z.ZodEnum<{
|
|
64
|
-
recording_unavailable: "recording_unavailable";
|
|
65
64
|
recording_failed: "recording_failed";
|
|
65
|
+
recording_unavailable: "recording_unavailable";
|
|
66
66
|
}>;
|
|
67
67
|
}, z.core.$strict>], "status">;
|
|
68
68
|
type RecordingArtifact = z.infer<typeof recordingArtifactSchema>;
|
|
@@ -118,8 +118,8 @@ declare const listRecordingsResponseSchema: z.ZodObject<{
|
|
|
118
118
|
retainedUntil: z.ZodString;
|
|
119
119
|
status: z.ZodLiteral<"failed">;
|
|
120
120
|
errorCode: z.ZodEnum<{
|
|
121
|
-
recording_unavailable: "recording_unavailable";
|
|
122
121
|
recording_failed: "recording_failed";
|
|
122
|
+
recording_unavailable: "recording_unavailable";
|
|
123
123
|
}>;
|
|
124
124
|
}, z.core.$strict>], "status">>;
|
|
125
125
|
nextCursor: z.ZodNullable<z.ZodString>;
|
package/dist/server.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export { RealtimeAvatar, RealtimeAvatarError, RealtimeAvatarHttpError, RealtimeAvatarOptions, StartCallOptions, clipLibraryDeclarationSchema, verifyTranscript } from './index.js';
|
|
2
|
-
export { h as Asset, g as AssetKind, A as Avatar, o as AvatarClip, c as AvatarSourceSwap, b as AvatarUpdate, p as CallConnection, C as CallMode, a as CallPolicy, q as CallQueued, r as ClipDeclaration, f as ClipLibrary, d as ClipLibraryDeclaration, s as ClipLibraryPlan, e as ClipLibraryUpdate, t as ClipSource, u as ContextMessage, n as CreditBalance, E as EndCallOptions, v as EndCallReason, k as ListRecordingsQuery, l as ListRecordingsResponse, i as ListSessionsOptions, L as LoopRedirect, m as RecordingAccessResponse, R as RecordingArtifact, w as RecordingArtifactStatus, x as RecordingMode, S as StartCallResult, T as TranscriptPayload, j as UsageSession, U as UsageSessionPage, V as VideoPolicy, y as isQueued, z as listRecordingsResponseSchema, B as recordingAccessResponseSchema, D as recordingArtifactSchema, F as recordingModeSchema } from './types-
|
|
2
|
+
export { h as Asset, g as AssetKind, A as Avatar, o as AvatarClip, c as AvatarSourceSwap, b as AvatarUpdate, p as CallConnection, C as CallMode, a as CallPolicy, q as CallQueued, r as ClipDeclaration, f as ClipLibrary, d as ClipLibraryDeclaration, s as ClipLibraryPlan, e as ClipLibraryUpdate, t as ClipSource, u as ContextMessage, n as CreditBalance, E as EndCallOptions, v as EndCallReason, k as ListRecordingsQuery, l as ListRecordingsResponse, i as ListSessionsOptions, L as LoopRedirect, m as RecordingAccessResponse, R as RecordingArtifact, w as RecordingArtifactStatus, x as RecordingMode, S as StartCallResult, T as TranscriptPayload, j as UsageSession, U as UsageSessionPage, V as VideoPolicy, y as isQueued, z as listRecordingsResponseSchema, B as recordingAccessResponseSchema, D as recordingArtifactSchema, F as recordingModeSchema } from './types-D76SpA3g.js';
|
|
3
3
|
import './connection-history.js';
|
|
4
4
|
import 'zod';
|
package/dist/server.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { RealtimeAvatar, RealtimeAvatarError, RealtimeAvatarHttpError, clipLibraryDeclarationSchema, isQueued, listRecordingsResponseSchema, recordingAccessResponseSchema, recordingArtifactSchema, recordingModeSchema, verifyTranscript } from './chunk-
|
|
1
|
+
export { RealtimeAvatar, RealtimeAvatarError, RealtimeAvatarHttpError, clipLibraryDeclarationSchema, isQueued, listRecordingsResponseSchema, recordingAccessResponseSchema, recordingArtifactSchema, recordingModeSchema, verifyTranscript } from './chunk-PKOWNCDT.js';
|
|
2
2
|
import './chunk-MCIXU6XP.js';
|
package/dist/tanstack-start.d.ts
CHANGED
package/dist/tanstack-start.js
CHANGED
|
@@ -173,6 +173,7 @@ interface components {
|
|
|
173
173
|
/** @description DEPRECATED, no-op. Accepted and ignored. The faster hesitation ceiling this requested is now the default for every session, so sending it changes nothing. Safe to stop sending; the field is retained only so existing callers do not break. */
|
|
174
174
|
fast_endpointing?: boolean;
|
|
175
175
|
require_ready_clip_library?: boolean;
|
|
176
|
+
camera?: boolean;
|
|
176
177
|
};
|
|
177
178
|
LiveKitSessionGrant: {
|
|
178
179
|
/** @description Returned only for X-RTA-Release-Evidence: 1. Omitted by default for strict SDK compatibility. Missing deployment or worker evidence remains null. */
|
|
@@ -265,6 +266,7 @@ interface components {
|
|
|
265
266
|
/** Format: date-time */
|
|
266
267
|
expiresAt: string;
|
|
267
268
|
};
|
|
269
|
+
camera?: boolean;
|
|
268
270
|
};
|
|
269
271
|
LiveKitCapacitySnapshot: {
|
|
270
272
|
capacity_pool: string;
|
|
@@ -1162,6 +1164,7 @@ interface CallPolicy {
|
|
|
1162
1164
|
maxSeconds?: number;
|
|
1163
1165
|
/** Speech recognition. `server` for a spoken conversation, `off` if you drive turns. */
|
|
1164
1166
|
listen?: boolean;
|
|
1167
|
+
camera?: Wire["LiveKitSessionRequest"]["camera"];
|
|
1165
1168
|
/** How she is rendered. */
|
|
1166
1169
|
video?: VideoPolicy;
|
|
1167
1170
|
/** Voice override for this call; omit to use the avatar's default. */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as CallMode, a as CallPolicy } from './types-
|
|
1
|
+
import { C as CallMode, a as CallPolicy } from './types-D76SpA3g.js';
|
|
2
2
|
|
|
3
3
|
/** The three things a caller can ask the proxy to do. Gate on these, not on URLs. */
|
|
4
4
|
type ProxyOperation = "connect" | "end" | "avatars" | "credits";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "realtime-avatar",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.20.0",
|
|
4
4
|
"description": "Realtime Avatar SDK. `realtime-avatar` and the route adapters hold your API key and are server-only; `realtime-avatar/react`, `/browser` and `/tools` never can — importing a server entry into a browser build throws at bundle time.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "The Influence Company",
|
|
@@ -122,7 +122,8 @@
|
|
|
122
122
|
"@types/react": "19.2.7",
|
|
123
123
|
"react": "19.2.7",
|
|
124
124
|
"react-dom": "19.2.7",
|
|
125
|
-
"react-native": "0.81.5"
|
|
125
|
+
"react-native": "0.81.5",
|
|
126
|
+
"zod": "4.4.3"
|
|
126
127
|
},
|
|
127
128
|
"peerDependencies": {
|
|
128
129
|
"@livekit/components-react": "^2.9.0",
|
|
@@ -130,7 +131,8 @@
|
|
|
130
131
|
"react": ">=18",
|
|
131
132
|
"react-dom": ">=18",
|
|
132
133
|
"react-native": ">=0.78",
|
|
133
|
-
"livekit-client": "^2.9.0"
|
|
134
|
+
"livekit-client": "^2.9.0",
|
|
135
|
+
"zod": "^4.4.3"
|
|
134
136
|
},
|
|
135
137
|
"peerDependenciesMeta": {
|
|
136
138
|
"@livekit/components-react": {
|
|
@@ -151,8 +153,5 @@
|
|
|
151
153
|
"livekit-client": {
|
|
152
154
|
"optional": true
|
|
153
155
|
}
|
|
154
|
-
},
|
|
155
|
-
"dependencies": {
|
|
156
|
-
"zod": "^4.4.3"
|
|
157
156
|
}
|
|
158
157
|
}
|