realtime-avatar 0.3.0 → 0.4.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/express.d.ts +2 -2
- package/dist/express.js +1 -1
- package/dist/hono.d.ts +2 -2
- package/dist/hono.js +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js +1 -1
- package/dist/nextjs.d.ts +2 -2
- package/dist/nextjs.js +1 -1
- package/dist/{proxy-client-cZyX50-O.d.ts → proxy-client-Dm-O0jNn.d.ts} +0 -32
- package/dist/react-native.d.ts +2 -2
- package/dist/react-native.js +1 -31
- package/dist/react.d.ts +2 -2
- package/dist/react.js +1 -31
- 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 +1 -1
- package/dist/{types-E8SrD6sv.d.ts → types-9leGOgVv.d.ts} +1 -1
- package/dist/{types-C_EMPwN7.d.ts → types-C5zypiVY.d.ts} +0 -33
- package/package.json +2 -2
package/dist/express.d.ts
CHANGED
package/dist/express.js
CHANGED
|
@@ -43,7 +43,7 @@ var RealtimeAvatarHttpError = class extends RealtimeAvatarError {
|
|
|
43
43
|
|
|
44
44
|
// ../http-client/src/client.ts
|
|
45
45
|
var DEFAULT_BASE_URL = "https://realtimeavatar.ai/api/v1";
|
|
46
|
-
var SDK_VERSION = "0.
|
|
46
|
+
var SDK_VERSION = "0.4.0";
|
|
47
47
|
var RealtimeAvatar = class {
|
|
48
48
|
#apiKey;
|
|
49
49
|
#baseUrl;
|
package/dist/hono.d.ts
CHANGED
package/dist/hono.js
CHANGED
|
@@ -43,7 +43,7 @@ var RealtimeAvatarHttpError = class extends RealtimeAvatarError {
|
|
|
43
43
|
|
|
44
44
|
// ../http-client/src/client.ts
|
|
45
45
|
var DEFAULT_BASE_URL = "https://realtimeavatar.ai/api/v1";
|
|
46
|
-
var SDK_VERSION = "0.
|
|
46
|
+
var SDK_VERSION = "0.4.0";
|
|
47
47
|
var RealtimeAvatar = class {
|
|
48
48
|
#apiKey;
|
|
49
49
|
#baseUrl;
|
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 ClipSyncResult, d as AssetKind, e as Asset, L as ListSessionsOptions, U as UsageSessionPage, f as UsageSession, g as CreditBalance, T as TranscriptPayload } from './types-
|
|
2
|
-
export { h as CallConnection, i as CallQueued, j as ContextMessage, k as EndCallReason, V as VideoPolicy, l as VideoState, m as isQueued } from './types-
|
|
1
|
+
import { a as CallPolicy, C as CallMode, S as StartCallResult, E as EndCallOptions, A as Avatar, b as AvatarUpdate, c as ClipSyncResult, d as AssetKind, e as Asset, L as ListSessionsOptions, U as UsageSessionPage, f as UsageSession, g as CreditBalance, T as TranscriptPayload } from './types-C5zypiVY.js';
|
|
2
|
+
export { h as CallConnection, i as CallQueued, j as ContextMessage, k as EndCallReason, V as VideoPolicy, l as VideoState, m as isQueued } from './types-C5zypiVY.js';
|
|
3
3
|
|
|
4
4
|
interface RealtimeAvatarOptions {
|
|
5
5
|
/** `tic_live_…` or `tic_test_…`. Server-side only — never ship this to a browser. */
|
package/dist/index.js
CHANGED
|
@@ -43,7 +43,7 @@ var RealtimeAvatarHttpError = class extends RealtimeAvatarError {
|
|
|
43
43
|
|
|
44
44
|
// ../http-client/src/client.ts
|
|
45
45
|
var DEFAULT_BASE_URL = "https://realtimeavatar.ai/api/v1";
|
|
46
|
-
var SDK_VERSION = "0.
|
|
46
|
+
var SDK_VERSION = "0.4.0";
|
|
47
47
|
var RealtimeAvatar = class {
|
|
48
48
|
#apiKey;
|
|
49
49
|
#baseUrl;
|
package/dist/nextjs.d.ts
CHANGED
package/dist/nextjs.js
CHANGED
|
@@ -43,7 +43,7 @@ var RealtimeAvatarHttpError = class extends RealtimeAvatarError {
|
|
|
43
43
|
|
|
44
44
|
// ../http-client/src/client.ts
|
|
45
45
|
var DEFAULT_BASE_URL = "https://realtimeavatar.ai/api/v1";
|
|
46
|
-
var SDK_VERSION = "0.
|
|
46
|
+
var SDK_VERSION = "0.4.0";
|
|
47
47
|
var RealtimeAvatar = class {
|
|
48
48
|
#apiKey;
|
|
49
49
|
#baseUrl;
|
|
@@ -204,38 +204,6 @@ declare const liveKitSessionRequestSchema: z.ZodObject<{
|
|
|
204
204
|
when: z.ZodOptional<z.ZodString>;
|
|
205
205
|
hint: z.ZodOptional<z.ZodString>;
|
|
206
206
|
}, z.core.$strict>>>;
|
|
207
|
-
sceneGraph: z.ZodOptional<z.ZodObject<{
|
|
208
|
-
scenes: z.ZodArray<z.ZodObject<{
|
|
209
|
-
scene_id: z.ZodString;
|
|
210
|
-
hub_clip_id: z.ZodString;
|
|
211
|
-
clips: z.ZodArray<z.ZodObject<{
|
|
212
|
-
clip_id: z.ZodString;
|
|
213
|
-
source_video_url: z.ZodOptional<z.ZodString>;
|
|
214
|
-
video_cache_id: z.ZodOptional<z.ZodString>;
|
|
215
|
-
max_seconds: z.ZodOptional<z.ZodNumber>;
|
|
216
|
-
trigger: z.ZodOptional<z.ZodEnum<{
|
|
217
|
-
idle: "idle";
|
|
218
|
-
listen: "listen";
|
|
219
|
-
think: "think";
|
|
220
|
-
directive: "directive";
|
|
221
|
-
}>>;
|
|
222
|
-
loop: z.ZodOptional<z.ZodBoolean>;
|
|
223
|
-
weight: z.ZodOptional<z.ZodNumber>;
|
|
224
|
-
crossfade_ms: z.ZodOptional<z.ZodNumber>;
|
|
225
|
-
trim_start_ms: z.ZodOptional<z.ZodNumber>;
|
|
226
|
-
trim_end_ms: z.ZodOptional<z.ZodNumber>;
|
|
227
|
-
when: z.ZodOptional<z.ZodString>;
|
|
228
|
-
hint: z.ZodOptional<z.ZodString>;
|
|
229
|
-
}, z.core.$strict>>;
|
|
230
|
-
}, z.core.$strict>>;
|
|
231
|
-
transitions: z.ZodArray<z.ZodObject<{
|
|
232
|
-
clip_id: z.ZodString;
|
|
233
|
-
source_video_url: z.ZodString;
|
|
234
|
-
from_scene: z.ZodString;
|
|
235
|
-
to_scene: z.ZodString;
|
|
236
|
-
max_seconds: z.ZodOptional<z.ZodNumber>;
|
|
237
|
-
}, z.core.$strict>>;
|
|
238
|
-
}, z.core.$strict>>;
|
|
239
207
|
behavior: z.ZodOptional<z.ZodObject<{
|
|
240
208
|
gestures_enabled: z.ZodOptional<z.ZodBoolean>;
|
|
241
209
|
gesture_freq: z.ZodOptional<z.ZodEnum<{
|
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
3
|
import { ReactNode, ReactElement } from 'react';
|
|
4
|
-
import { aK as LiveKitSessionGrant, a as AvatarVideoFit } from './proxy-client-
|
|
5
|
-
export { b as ApproachingEndEvent, c as ApproachingEndReason, A as AvatarSessionClient, B as BehaviorSnapshot, C as CallTranscript, f as CallTranscriptSegment, g as CartesiaTtsModel, h as ClipResult, i as ClosingTurnResult, j as CreditsLowEvent, D as DEFAULT_APPROACHING_END_LEAD_SECONDS, k as DEFAULT_AVATAR_PLAYOUT_DELAY_SECONDS, l as DEFAULT_CREDITS_LOW_LEAD_SECONDS, m as DEFAULT_GOVERNOR_CONFIG, n as DEFAULT_GRACE_CEILING_SECONDS, o as DEFAULT_GRACE_WINDOW_LEAD_SECONDS, p as DEFAULT_IDLE_SECONDS, q as DEFAULT_IDLE_WARN_LEAD_SECONDS, r as DEFAULT_TURN_TIMEOUT_SECONDS, E as EndReason, s as EndedEvent, t as ExtendResult, F as FishTtsModel, u as FreezeReadingFn, G as Governor, v as GovernorAction, w as GovernorConfig, x as GovernorSignal, y as GovernorState, z as GraceWindowClosedEvent, H as GraceWindowOpenEvent, I as GraceWindowState, J as IdleWarningEvent, K as KnownBehaviorState, L as LLMProvider, M as LLMSelection, N as LiveKitAvatarGrantState, O as LiveKitAvatarGrantStatus, P as LiveKitCapacityState, Q as LiveKitConnectionStatus, R as LiveKitSessionRequest, S as LiveKitSessionStartResult, U as MAX_RECONNECT_ATTEMPTS, V as MAX_SESSION_INSTRUCTIONS_CHARS, Z as ProxyClientOptions, _ as QualityCap, $ as RECONNECT_BACKOFF_MS, a3 as RealtimeAvatarRequestOptions, a4 as RealtimeSessionApi, a5 as RealtimeSessionMedia, a6 as RealtimeSessionRoomSinks, a7 as ReconnectPolicy, a8 as ReconnectingEvent, a9 as RecoveryState, aa as RetryStep, 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 TurnState, am as TurnTimeoutEvent, an as UseAvatarQualityGovernorInput, ao as UseLiveKitAvatarGrantInput, ap as UseRealtimeSessionInput, aq as UseSessionLifecycleInput, ar as VoiceSpec, as as VoiceSpecInput, at as capacityErrorFromBusy, au as capacityStateFromGrant, av as createProxyClient, aL as isNativeLiveTrackSubscribed, aw as knownBehaviorStates, ax as mapTurnState, ay as sessionBehaviorSchema, az as sessionClipSchema, aB as splitCallTranscript, aC as useAvatarPlayoutDelay, aD as useAvatarQualityGovernor, aE as useCallTranscript, aF as useLiveKitAvatarGrant, aM as useLiveTrackProducing, aG as useMicLease, aH as useRealtimeSession, aI as useReleaseMicLeaseOnTrackEnded, aJ as useSessionLifecycle } from './proxy-client-
|
|
4
|
+
import { aK as LiveKitSessionGrant, a as AvatarVideoFit } from './proxy-client-Dm-O0jNn.js';
|
|
5
|
+
export { b as ApproachingEndEvent, c as ApproachingEndReason, A as AvatarSessionClient, B as BehaviorSnapshot, C as CallTranscript, f as CallTranscriptSegment, g as CartesiaTtsModel, h as ClipResult, i as ClosingTurnResult, j as CreditsLowEvent, D as DEFAULT_APPROACHING_END_LEAD_SECONDS, k as DEFAULT_AVATAR_PLAYOUT_DELAY_SECONDS, l as DEFAULT_CREDITS_LOW_LEAD_SECONDS, m as DEFAULT_GOVERNOR_CONFIG, n as DEFAULT_GRACE_CEILING_SECONDS, o as DEFAULT_GRACE_WINDOW_LEAD_SECONDS, p as DEFAULT_IDLE_SECONDS, q as DEFAULT_IDLE_WARN_LEAD_SECONDS, r as DEFAULT_TURN_TIMEOUT_SECONDS, E as EndReason, s as EndedEvent, t as ExtendResult, F as FishTtsModel, u as FreezeReadingFn, G as Governor, v as GovernorAction, w as GovernorConfig, x as GovernorSignal, y as GovernorState, z as GraceWindowClosedEvent, H as GraceWindowOpenEvent, I as GraceWindowState, J as IdleWarningEvent, K as KnownBehaviorState, L as LLMProvider, M as LLMSelection, N as LiveKitAvatarGrantState, O as LiveKitAvatarGrantStatus, P as LiveKitCapacityState, Q as LiveKitConnectionStatus, R as LiveKitSessionRequest, S as LiveKitSessionStartResult, U as MAX_RECONNECT_ATTEMPTS, V as MAX_SESSION_INSTRUCTIONS_CHARS, Z as ProxyClientOptions, _ as QualityCap, $ as RECONNECT_BACKOFF_MS, a3 as RealtimeAvatarRequestOptions, a4 as RealtimeSessionApi, a5 as RealtimeSessionMedia, a6 as RealtimeSessionRoomSinks, a7 as ReconnectPolicy, a8 as ReconnectingEvent, a9 as RecoveryState, aa as RetryStep, 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 TurnState, am as TurnTimeoutEvent, an as UseAvatarQualityGovernorInput, ao as UseLiveKitAvatarGrantInput, ap as UseRealtimeSessionInput, aq as UseSessionLifecycleInput, ar as VoiceSpec, as as VoiceSpecInput, at as capacityErrorFromBusy, au as capacityStateFromGrant, av as createProxyClient, aL as isNativeLiveTrackSubscribed, aw as knownBehaviorStates, ax as mapTurnState, ay as sessionBehaviorSchema, az as sessionClipSchema, aB as splitCallTranscript, aC as useAvatarPlayoutDelay, aD as useAvatarQualityGovernor, aE as useCallTranscript, aF as useLiveKitAvatarGrant, aM as useLiveTrackProducing, aG as useMicLease, aH as useRealtimeSession, aI as useReleaseMicLeaseOnTrackEnded, aJ as useSessionLifecycle } from './proxy-client-Dm-O0jNn.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 { DisconnectReason, RemoteAudioTrack, RemoteTrack, RemoteVideoTrack, Room, RoomEvent, SendTextOptions, Track } from 'livekit-client';
|
package/dist/react-native.js
CHANGED
|
@@ -1018,28 +1018,6 @@ var sessionBehaviorSchema = z.object({
|
|
|
1018
1018
|
gestures_enabled: z.boolean().optional(),
|
|
1019
1019
|
gesture_freq: z.enum(["sparse", "balanced", "lively"]).optional()
|
|
1020
1020
|
}).strict();
|
|
1021
|
-
var _SCENE_CLIP_ID_RE = /^[A-Za-z0-9_-]{1,64}$/;
|
|
1022
|
-
var sceneIdSchema = z.string().regex(/^[a-z0-9_]{1,40}$/, "scene_id must be a lowercase slug");
|
|
1023
|
-
var sceneTransitionSchema = z.object({
|
|
1024
|
-
clip_id: z.string().regex(_SCENE_CLIP_ID_RE, "clip_id must be a slug"),
|
|
1025
|
-
source_video_url: z.string().url(),
|
|
1026
|
-
from_scene: sceneIdSchema,
|
|
1027
|
-
to_scene: sceneIdSchema,
|
|
1028
|
-
max_seconds: z.number().min(1).max(10).optional()
|
|
1029
|
-
}).strict().superRefine((v, ctx) => {
|
|
1030
|
-
if (v.from_scene === v.to_scene) {
|
|
1031
|
-
ctx.addIssue({ code: "custom", message: "a transition's from_scene must differ from to_scene", path: ["to_scene"] });
|
|
1032
|
-
}
|
|
1033
|
-
});
|
|
1034
|
-
var sceneClusterSchema = z.object({
|
|
1035
|
-
scene_id: sceneIdSchema,
|
|
1036
|
-
hub_clip_id: z.string().regex(_SCENE_CLIP_ID_RE, "hub_clip_id must be a slug"),
|
|
1037
|
-
clips: z.array(sessionClipSchema).min(1).max(4)
|
|
1038
|
-
}).strict();
|
|
1039
|
-
var sceneGraphSchema = z.object({
|
|
1040
|
-
scenes: z.array(sceneClusterSchema).min(1).max(4),
|
|
1041
|
-
transitions: z.array(sceneTransitionSchema).min(2).max(12)
|
|
1042
|
-
}).strict();
|
|
1043
1021
|
var transcriptWebhookSchema = z.object({
|
|
1044
1022
|
url: z.string().url().max(500),
|
|
1045
1023
|
secret: z.string().min(16).max(200)
|
|
@@ -1076,7 +1054,6 @@ z.object({
|
|
|
1076
1054
|
// fewer is always safe — so the wire must not hold a number too.
|
|
1077
1055
|
clip_library: z.array(sessionClipSchema).optional(),
|
|
1078
1056
|
choreography: sessionChoreographySchema.optional(),
|
|
1079
|
-
scene_graph: sceneGraphSchema.optional(),
|
|
1080
1057
|
behavior: sessionBehaviorSchema.optional(),
|
|
1081
1058
|
expression_profile: z.string().min(1).max(40).optional(),
|
|
1082
1059
|
render_backend: renderBackendSchema.optional(),
|
|
@@ -1143,7 +1120,6 @@ z.object({
|
|
|
1143
1120
|
voiceId: z.string().min(1).max(240).nullable().optional(),
|
|
1144
1121
|
// Unbounded, for the same reason as `clip_library` on the wire schema above.
|
|
1145
1122
|
clipLibrary: z.array(sessionClipSchema).optional(),
|
|
1146
|
-
sceneGraph: sceneGraphSchema.optional(),
|
|
1147
1123
|
behavior: sessionBehaviorSchema.optional(),
|
|
1148
1124
|
renderBackend: renderBackendSchema.optional(),
|
|
1149
1125
|
supportEdits: sessionSupportEditsSchema.optional(),
|
|
@@ -1195,13 +1171,7 @@ var behaviorStateFrameSchema = z.object({
|
|
|
1195
1171
|
clip_id: z.string().min(1).max(64).optional(),
|
|
1196
1172
|
trigger: clipTriggerSchema.optional(),
|
|
1197
1173
|
loop: z.boolean().optional(),
|
|
1198
|
-
prev_clip_id: z.string().min(1).max(64).optional()
|
|
1199
|
-
scene: z.string().min(1).max(40).optional(),
|
|
1200
|
-
scene_transition: z.object({
|
|
1201
|
-
clip_id: z.string().min(1).max(64),
|
|
1202
|
-
from_scene: z.string().min(1).max(40),
|
|
1203
|
-
to_scene: z.string().min(1).max(40)
|
|
1204
|
-
}).optional()
|
|
1174
|
+
prev_clip_id: z.string().min(1).max(64).optional()
|
|
1205
1175
|
}).strip();
|
|
1206
1176
|
var clipAckFrameSchema = z.object({
|
|
1207
1177
|
kind: z.literal("clip_ack"),
|
package/dist/react.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import { A as AvatarSessionClient, a as AvatarVideoFit } from './proxy-client-
|
|
3
|
-
export { b as ApproachingEndEvent, c as ApproachingEndReason, d as AvatarVideoSurface, e as AvatarVideoSurfaceProps, B as BehaviorSnapshot, C as CallTranscript, f as CallTranscriptSegment, g as CartesiaTtsModel, h as ClipResult, i as ClosingTurnResult, j as CreditsLowEvent, D as DEFAULT_APPROACHING_END_LEAD_SECONDS, k as DEFAULT_AVATAR_PLAYOUT_DELAY_SECONDS, l as DEFAULT_CREDITS_LOW_LEAD_SECONDS, m as DEFAULT_GOVERNOR_CONFIG, n as DEFAULT_GRACE_CEILING_SECONDS, o as DEFAULT_GRACE_WINDOW_LEAD_SECONDS, p as DEFAULT_IDLE_SECONDS, q as DEFAULT_IDLE_WARN_LEAD_SECONDS, r as DEFAULT_TURN_TIMEOUT_SECONDS, E as EndReason, s as EndedEvent, t as ExtendResult, F as FishTtsModel, u as FreezeReadingFn, G as Governor, v as GovernorAction, w as GovernorConfig, x as GovernorSignal, y as GovernorState, z as GraceWindowClosedEvent, H as GraceWindowOpenEvent, I as GraceWindowState, J as IdleWarningEvent, K as KnownBehaviorState, L as LLMProvider, M as LLMSelection, N as LiveKitAvatarGrantState, O as LiveKitAvatarGrantStatus, P as LiveKitCapacityState, Q as LiveKitConnectionStatus, R as LiveKitSessionRequest, S as LiveKitSessionStartResult, T as LivePlaybackKeeper, U as MAX_RECONNECT_ATTEMPTS, V as MAX_SESSION_INSTRUCTIONS_CHARS, W as MIC_LEASE_ENDED_TIMEOUT_MS, X as MicLease, Y as PlayableVideoElement, Z as ProxyClientOptions, _ as QualityCap, $ as RECONNECT_BACKOFF_MS, a0 as RealtimeAvatarCapacityError, a1 as RealtimeAvatarLiveKitRoom, a2 as RealtimeAvatarLiveKitRoomProps, a3 as RealtimeAvatarRequestOptions, a4 as RealtimeSessionApi, a5 as RealtimeSessionMedia, a6 as RealtimeSessionRoomSinks, a7 as ReconnectPolicy, a8 as ReconnectingEvent, a9 as RecoveryState, aa as RetryStep, 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 TurnState, am as TurnTimeoutEvent, an as UseAvatarQualityGovernorInput, ao as UseLiveKitAvatarGrantInput, ap as UseRealtimeSessionInput, aq as UseSessionLifecycleInput, ar as VoiceSpec, as as VoiceSpecInput, at as capacityErrorFromBusy, au as capacityStateFromGrant, av as createProxyClient, aw as knownBehaviorStates, ax as mapTurnState, ay as sessionBehaviorSchema, az as sessionClipSchema, aA as shouldReplayPendingTurn, aB as splitCallTranscript, aC as useAvatarPlayoutDelay, aD as useAvatarQualityGovernor, aE as useCallTranscript, aF as useLiveKitAvatarGrant, aG as useMicLease, aH as useRealtimeSession, aI as useReleaseMicLeaseOnTrackEnded, aJ as useSessionLifecycle } from './proxy-client-
|
|
2
|
+
import { A as AvatarSessionClient, a as AvatarVideoFit } from './proxy-client-Dm-O0jNn.js';
|
|
3
|
+
export { b as ApproachingEndEvent, c as ApproachingEndReason, d as AvatarVideoSurface, e as AvatarVideoSurfaceProps, B as BehaviorSnapshot, C as CallTranscript, f as CallTranscriptSegment, g as CartesiaTtsModel, h as ClipResult, i as ClosingTurnResult, j as CreditsLowEvent, D as DEFAULT_APPROACHING_END_LEAD_SECONDS, k as DEFAULT_AVATAR_PLAYOUT_DELAY_SECONDS, l as DEFAULT_CREDITS_LOW_LEAD_SECONDS, m as DEFAULT_GOVERNOR_CONFIG, n as DEFAULT_GRACE_CEILING_SECONDS, o as DEFAULT_GRACE_WINDOW_LEAD_SECONDS, p as DEFAULT_IDLE_SECONDS, q as DEFAULT_IDLE_WARN_LEAD_SECONDS, r as DEFAULT_TURN_TIMEOUT_SECONDS, E as EndReason, s as EndedEvent, t as ExtendResult, F as FishTtsModel, u as FreezeReadingFn, G as Governor, v as GovernorAction, w as GovernorConfig, x as GovernorSignal, y as GovernorState, z as GraceWindowClosedEvent, H as GraceWindowOpenEvent, I as GraceWindowState, J as IdleWarningEvent, K as KnownBehaviorState, L as LLMProvider, M as LLMSelection, N as LiveKitAvatarGrantState, O as LiveKitAvatarGrantStatus, P as LiveKitCapacityState, Q as LiveKitConnectionStatus, R as LiveKitSessionRequest, S as LiveKitSessionStartResult, T as LivePlaybackKeeper, U as MAX_RECONNECT_ATTEMPTS, V as MAX_SESSION_INSTRUCTIONS_CHARS, W as MIC_LEASE_ENDED_TIMEOUT_MS, X as MicLease, Y as PlayableVideoElement, Z as ProxyClientOptions, _ as QualityCap, $ as RECONNECT_BACKOFF_MS, a0 as RealtimeAvatarCapacityError, a1 as RealtimeAvatarLiveKitRoom, a2 as RealtimeAvatarLiveKitRoomProps, a3 as RealtimeAvatarRequestOptions, a4 as RealtimeSessionApi, a5 as RealtimeSessionMedia, a6 as RealtimeSessionRoomSinks, a7 as ReconnectPolicy, a8 as ReconnectingEvent, a9 as RecoveryState, aa as RetryStep, 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 TurnState, am as TurnTimeoutEvent, an as UseAvatarQualityGovernorInput, ao as UseLiveKitAvatarGrantInput, ap as UseRealtimeSessionInput, aq as UseSessionLifecycleInput, ar as VoiceSpec, as as VoiceSpecInput, at as capacityErrorFromBusy, au as capacityStateFromGrant, av as createProxyClient, aw as knownBehaviorStates, ax as mapTurnState, ay as sessionBehaviorSchema, az as sessionClipSchema, aA as shouldReplayPendingTurn, aB as splitCallTranscript, aC as useAvatarPlayoutDelay, aD as useAvatarQualityGovernor, aE as useCallTranscript, aF as useLiveKitAvatarGrant, aG as useMicLease, aH as useRealtimeSession, aI as useReleaseMicLeaseOnTrackEnded, aJ as useSessionLifecycle } from './proxy-client-Dm-O0jNn.js';
|
|
4
4
|
import '@livekit/components-react';
|
|
5
5
|
import 'livekit-client';
|
|
6
6
|
import 'zod';
|
package/dist/react.js
CHANGED
|
@@ -1236,28 +1236,6 @@ var sessionBehaviorSchema = z.object({
|
|
|
1236
1236
|
gestures_enabled: z.boolean().optional(),
|
|
1237
1237
|
gesture_freq: z.enum(["sparse", "balanced", "lively"]).optional()
|
|
1238
1238
|
}).strict();
|
|
1239
|
-
var _SCENE_CLIP_ID_RE = /^[A-Za-z0-9_-]{1,64}$/;
|
|
1240
|
-
var sceneIdSchema = z.string().regex(/^[a-z0-9_]{1,40}$/, "scene_id must be a lowercase slug");
|
|
1241
|
-
var sceneTransitionSchema = z.object({
|
|
1242
|
-
clip_id: z.string().regex(_SCENE_CLIP_ID_RE, "clip_id must be a slug"),
|
|
1243
|
-
source_video_url: z.string().url(),
|
|
1244
|
-
from_scene: sceneIdSchema,
|
|
1245
|
-
to_scene: sceneIdSchema,
|
|
1246
|
-
max_seconds: z.number().min(1).max(10).optional()
|
|
1247
|
-
}).strict().superRefine((v, ctx) => {
|
|
1248
|
-
if (v.from_scene === v.to_scene) {
|
|
1249
|
-
ctx.addIssue({ code: "custom", message: "a transition's from_scene must differ from to_scene", path: ["to_scene"] });
|
|
1250
|
-
}
|
|
1251
|
-
});
|
|
1252
|
-
var sceneClusterSchema = z.object({
|
|
1253
|
-
scene_id: sceneIdSchema,
|
|
1254
|
-
hub_clip_id: z.string().regex(_SCENE_CLIP_ID_RE, "hub_clip_id must be a slug"),
|
|
1255
|
-
clips: z.array(sessionClipSchema).min(1).max(4)
|
|
1256
|
-
}).strict();
|
|
1257
|
-
var sceneGraphSchema = z.object({
|
|
1258
|
-
scenes: z.array(sceneClusterSchema).min(1).max(4),
|
|
1259
|
-
transitions: z.array(sceneTransitionSchema).min(2).max(12)
|
|
1260
|
-
}).strict();
|
|
1261
1239
|
var transcriptWebhookSchema = z.object({
|
|
1262
1240
|
url: z.string().url().max(500),
|
|
1263
1241
|
secret: z.string().min(16).max(200)
|
|
@@ -1294,7 +1272,6 @@ z.object({
|
|
|
1294
1272
|
// fewer is always safe — so the wire must not hold a number too.
|
|
1295
1273
|
clip_library: z.array(sessionClipSchema).optional(),
|
|
1296
1274
|
choreography: sessionChoreographySchema.optional(),
|
|
1297
|
-
scene_graph: sceneGraphSchema.optional(),
|
|
1298
1275
|
behavior: sessionBehaviorSchema.optional(),
|
|
1299
1276
|
expression_profile: z.string().min(1).max(40).optional(),
|
|
1300
1277
|
render_backend: renderBackendSchema.optional(),
|
|
@@ -1361,7 +1338,6 @@ z.object({
|
|
|
1361
1338
|
voiceId: z.string().min(1).max(240).nullable().optional(),
|
|
1362
1339
|
// Unbounded, for the same reason as `clip_library` on the wire schema above.
|
|
1363
1340
|
clipLibrary: z.array(sessionClipSchema).optional(),
|
|
1364
|
-
sceneGraph: sceneGraphSchema.optional(),
|
|
1365
1341
|
behavior: sessionBehaviorSchema.optional(),
|
|
1366
1342
|
renderBackend: renderBackendSchema.optional(),
|
|
1367
1343
|
supportEdits: sessionSupportEditsSchema.optional(),
|
|
@@ -1413,13 +1389,7 @@ var behaviorStateFrameSchema = z.object({
|
|
|
1413
1389
|
clip_id: z.string().min(1).max(64).optional(),
|
|
1414
1390
|
trigger: clipTriggerSchema.optional(),
|
|
1415
1391
|
loop: z.boolean().optional(),
|
|
1416
|
-
prev_clip_id: z.string().min(1).max(64).optional()
|
|
1417
|
-
scene: z.string().min(1).max(40).optional(),
|
|
1418
|
-
scene_transition: z.object({
|
|
1419
|
-
clip_id: z.string().min(1).max(64),
|
|
1420
|
-
from_scene: z.string().min(1).max(40),
|
|
1421
|
-
to_scene: z.string().min(1).max(40)
|
|
1422
|
-
}).optional()
|
|
1392
|
+
prev_clip_id: z.string().min(1).max(64).optional()
|
|
1423
1393
|
}).strip();
|
|
1424
1394
|
var clipAckFrameSchema = z.object({
|
|
1425
1395
|
kind: z.literal("clip_ack"),
|
package/dist/server.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export { RealtimeAvatar, RealtimeAvatarError, RealtimeAvatarHttpError, RealtimeAvatarOptions, StartCallOptions, verifyTranscript } from './index.js';
|
|
2
|
-
export { e as Asset, d as AssetKind, A as Avatar, b as AvatarUpdate, h as CallConnection, C as CallMode, a as CallPolicy, i as CallQueued, c as ClipSyncResult, j as ContextMessage, g as CreditBalance, E as EndCallOptions, k as EndCallReason, L as ListSessionsOptions, S as StartCallResult, T as TranscriptPayload, f as UsageSession, U as UsageSessionPage, V as VideoPolicy, l as VideoState, m as isQueued } from './types-
|
|
2
|
+
export { e as Asset, d as AssetKind, A as Avatar, b as AvatarUpdate, h as CallConnection, C as CallMode, a as CallPolicy, i as CallQueued, c as ClipSyncResult, j as ContextMessage, g as CreditBalance, E as EndCallOptions, k as EndCallReason, L as ListSessionsOptions, S as StartCallResult, T as TranscriptPayload, f as UsageSession, U as UsageSessionPage, V as VideoPolicy, l as VideoState, m as isQueued } from './types-C5zypiVY.js';
|
package/dist/server.js
CHANGED
|
@@ -43,7 +43,7 @@ var RealtimeAvatarHttpError = class extends RealtimeAvatarError {
|
|
|
43
43
|
|
|
44
44
|
// ../http-client/src/client.ts
|
|
45
45
|
var DEFAULT_BASE_URL = "https://realtimeavatar.ai/api/v1";
|
|
46
|
-
var SDK_VERSION = "0.
|
|
46
|
+
var SDK_VERSION = "0.4.0";
|
|
47
47
|
var RealtimeAvatar = class {
|
|
48
48
|
#apiKey;
|
|
49
49
|
#baseUrl;
|
package/dist/tanstack-start.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { P as ProxyConfig } from './types-
|
|
2
|
-
import './types-
|
|
1
|
+
import { P as ProxyConfig } from './types-9leGOgVv.js';
|
|
2
|
+
import './types-C5zypiVY.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* TanStack Start. Mount at `routes/api/realtime-avatar/$.ts` — the trailing `$` is Start's
|
package/dist/tanstack-start.js
CHANGED
|
@@ -43,7 +43,7 @@ var RealtimeAvatarHttpError = class extends RealtimeAvatarError {
|
|
|
43
43
|
|
|
44
44
|
// ../http-client/src/client.ts
|
|
45
45
|
var DEFAULT_BASE_URL = "https://realtimeavatar.ai/api/v1";
|
|
46
|
-
var SDK_VERSION = "0.
|
|
46
|
+
var SDK_VERSION = "0.4.0";
|
|
47
47
|
var RealtimeAvatar = class {
|
|
48
48
|
#apiKey;
|
|
49
49
|
#baseUrl;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as CallMode, a as CallPolicy } from './types-
|
|
1
|
+
import { C as CallMode, a as CallPolicy } from './types-C5zypiVY.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";
|
|
@@ -114,39 +114,6 @@ interface components {
|
|
|
114
114
|
crossfade_easing?: "linear" | "smooth" | "ease_out";
|
|
115
115
|
wrap_crossfade_ms?: number;
|
|
116
116
|
};
|
|
117
|
-
scene_graph?: {
|
|
118
|
-
scenes: {
|
|
119
|
-
scene_id: string;
|
|
120
|
-
hub_clip_id: string;
|
|
121
|
-
clips: {
|
|
122
|
-
clip_id: string;
|
|
123
|
-
/**
|
|
124
|
-
* Format: uri
|
|
125
|
-
* @description The clip's video URL — for a platform-generated library this is the generated clip's hosted URL, filled in server-side at hydration.
|
|
126
|
-
*/
|
|
127
|
-
source_video_url?: string;
|
|
128
|
-
video_cache_id?: string;
|
|
129
|
-
max_seconds?: number;
|
|
130
|
-
/** @enum {string} */
|
|
131
|
-
trigger?: "idle" | "listen" | "think" | "directive";
|
|
132
|
-
loop?: boolean;
|
|
133
|
-
weight?: number;
|
|
134
|
-
crossfade_ms?: number;
|
|
135
|
-
trim_start_ms?: number;
|
|
136
|
-
trim_end_ms?: number;
|
|
137
|
-
when?: string;
|
|
138
|
-
hint?: string;
|
|
139
|
-
}[];
|
|
140
|
-
}[];
|
|
141
|
-
transitions: {
|
|
142
|
-
clip_id: string;
|
|
143
|
-
/** Format: uri */
|
|
144
|
-
source_video_url: string;
|
|
145
|
-
from_scene: string;
|
|
146
|
-
to_scene: string;
|
|
147
|
-
max_seconds?: number;
|
|
148
|
-
}[];
|
|
149
|
-
};
|
|
150
117
|
behavior?: {
|
|
151
118
|
gestures_enabled?: boolean;
|
|
152
119
|
/** @enum {string} */
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "realtime-avatar",
|
|
3
|
-
"version": "0.
|
|
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
|
|
3
|
+
"version": "0.4.0",
|
|
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",
|
|
7
7
|
"homepage": "https://realtimeavatar.ai/docs",
|