@d-id/client-sdk 1.2.2-staging.347 → 1.2.3-staging.349
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/index-GhxPstbD.js +1785 -0
- package/dist/index.js +1 -1
- package/dist/index.umd.cjs +5 -5
- package/dist/{livekit-manager-B4AOu-Gv.js → livekit-manager-DhurzaxT.js} +1 -1
- package/dist/src/services/streaming-manager/stats/av-sync.d.ts +3 -0
- package/dist/src/services/streaming-manager/stats/av-sync.test.d.ts +1 -0
- package/dist/src/services/streaming-manager/stats/report.d.ts +2 -1
- package/dist/src/types/stream/stream.d.ts +21 -0
- package/dist/src/utils/analytics.d.ts +7 -0
- package/package.json +1 -1
- package/dist/index-DYWCJccV.js +0 -1751
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as De, C as O, S as l, a as Fe, b as Ne, A as m, d as Ue, l as de, e as je, t as xe, f as v, g as U, h as Oe, i as Be, j as A, n as Je } from "./index-
|
|
1
|
+
import { c as De, C as O, S as l, a as Fe, b as Ne, A as m, d as Ue, l as de, e as je, t as xe, f as v, g as U, h as Oe, i as Be, j as A, n as Je } from "./index-GhxPstbD.js";
|
|
2
2
|
function Qe(C, L, g, i) {
|
|
3
3
|
const M = De(C, `${L}/v2/agents/${g}`, i);
|
|
4
4
|
return {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { AnalyticsRTCStatsReport, SlimRTCStatsReport } from '../../../types';
|
|
1
|
+
import { AnalyticsRTCStatsReport, AvSyncReport, SlimRTCStatsReport } from '../../../types';
|
|
2
2
|
|
|
3
3
|
export interface VideoRTCStatsReport {
|
|
4
4
|
webRTCStats: {
|
|
5
5
|
anomalies: AnalyticsRTCStatsReport[];
|
|
6
|
+
avSync: AvSyncReport | null;
|
|
6
7
|
aggregateReport: AnalyticsRTCStatsReport;
|
|
7
8
|
minRtt: number;
|
|
8
9
|
maxRtt: number;
|
|
@@ -131,6 +131,27 @@ export interface SlimRTCStatsReport {
|
|
|
131
131
|
framesPerSecond: any;
|
|
132
132
|
freezeCount: number;
|
|
133
133
|
freezeDuration: number;
|
|
134
|
+
av?: AvSyncSample;
|
|
135
|
+
}
|
|
136
|
+
export interface AvSyncSample {
|
|
137
|
+
/** Audio estimatedPlayoutTimestamp (ms, NTP) — playout time of the audio sample currently being rendered. */
|
|
138
|
+
audioPlayout: number;
|
|
139
|
+
/** Video estimatedPlayoutTimestamp (ms, NTP) — playout time of the video frame currently being rendered. */
|
|
140
|
+
videoPlayout: number;
|
|
141
|
+
/** Local timestamp of this sample (ms) — the video inbound-rtp report timestamp; the utterance time axis. */
|
|
142
|
+
localTs: number;
|
|
143
|
+
}
|
|
144
|
+
export interface AvSyncReport {
|
|
145
|
+
/** Measurable samples in this utterance (both audio and video playout present). Report is null if fewer than 2. */
|
|
146
|
+
sampleCount: number;
|
|
147
|
+
/** Measurement window in milliseconds (first to last sample). */
|
|
148
|
+
durationMs: number;
|
|
149
|
+
/** How long the A/V offset was perceptibly off (audio ahead > 45ms or behind > 100ms) — the "was there a lip-sync issue, and for how long" signal. */
|
|
150
|
+
desyncDurationMs: number;
|
|
151
|
+
/** The single worst offset (largest magnitude), signed. Positive = audio ahead of video, negative = video ahead. */
|
|
152
|
+
maxOffsetMs: number;
|
|
153
|
+
/** Settled offset after startup (signed median over the back half). ~0 = recovered; non-zero = persistent lip-sync error. */
|
|
154
|
+
residualOffsetMs: number;
|
|
134
155
|
}
|
|
135
156
|
export interface AnalyticsRTCStatsReport {
|
|
136
157
|
timestamp?: number;
|
|
@@ -35,4 +35,11 @@ export declare function getAgentInfo(agent: Agent): {
|
|
|
35
35
|
export declare const getErrorMessage: (error: unknown) => string;
|
|
36
36
|
export declare const sumFunc: (numbers: number[]) => number;
|
|
37
37
|
export declare const average: (numbers: number[]) => number;
|
|
38
|
+
export declare const min: (numbers: number[]) => number;
|
|
39
|
+
export declare const max: (numbers: number[]) => number;
|
|
40
|
+
export declare const round: (value: number, decimals?: number) => number;
|
|
41
|
+
export declare const percentile: (numbers: number[], p: number) => number;
|
|
42
|
+
export declare const median: (numbers: number[]) => number;
|
|
43
|
+
/** Run fn, returning fallback instead of throwing — so a telemetry failure can never break the caller. */
|
|
44
|
+
export declare const safe: <T>(fn: () => T, fallback: T) => T;
|
|
38
45
|
export declare function getStreamAnalyticsProps(data: any, agent: Agent, additionalProps: Record<string, any>): any;
|