@absolutejs/voice 0.0.22-beta.286 → 0.0.22-beta.288
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.d.ts +2 -2
- package/dist/index.js +406 -264
- package/dist/sloCalibration.d.ts +61 -0
- package/package.json +1 -1
package/dist/sloCalibration.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Elysia } from 'elysia';
|
|
2
2
|
import type { VoiceProviderSloThresholdConfig } from './providerSlo';
|
|
3
|
+
import type { VoiceProductionReadinessRoutesOptions } from './productionReadiness';
|
|
3
4
|
import type { VoiceProofTrendReport } from './proofTrends';
|
|
4
5
|
export type VoiceSloCalibrationStatus = 'fail' | 'pass' | 'warn';
|
|
5
6
|
export type VoiceSloCalibrationMetricKey = 'interruption' | 'liveLatency' | 'monitorRun' | 'notifierDelivery' | 'provider' | 'reconnect' | 'turnLatency';
|
|
@@ -68,6 +69,18 @@ export type VoiceSloThresholdProfile = {
|
|
|
68
69
|
};
|
|
69
70
|
status: VoiceSloCalibrationStatus;
|
|
70
71
|
};
|
|
72
|
+
export type VoiceSloReadinessThresholdOptions = Pick<VoiceProductionReadinessRoutesOptions, 'liveLatencyFailAfterMs' | 'liveLatencyWarnAfterMs' | 'monitoringNotifierDeliveryFailAfterMs' | 'monitoringRunFailAfterMs' | 'reconnectResumeFailAfterMs'>;
|
|
73
|
+
export type VoiceSloReadinessThresholdReport = {
|
|
74
|
+
bargeIn: VoiceSloThresholdProfile['bargeIn'];
|
|
75
|
+
generatedAt: string;
|
|
76
|
+
issues: string[];
|
|
77
|
+
liveLatencyMaxAgeMs?: number;
|
|
78
|
+
ok: boolean;
|
|
79
|
+
providerSlo: VoiceProviderSloThresholdConfig;
|
|
80
|
+
readinessOptions: VoiceSloReadinessThresholdOptions;
|
|
81
|
+
sources: string[];
|
|
82
|
+
status: VoiceSloCalibrationStatus;
|
|
83
|
+
};
|
|
71
84
|
export type VoiceSloCalibrationOptions = {
|
|
72
85
|
headroomMultiplier?: number;
|
|
73
86
|
liveLatencyMinimumMs?: number;
|
|
@@ -88,12 +101,32 @@ export type VoiceSloCalibrationRoutesOptions = VoiceSloCalibrationOptions & {
|
|
|
88
101
|
source: (() => Promise<Array<VoiceProofTrendReport | VoiceSloCalibrationSample>> | Array<VoiceProofTrendReport | VoiceSloCalibrationSample>) | Array<VoiceProofTrendReport | VoiceSloCalibrationSample>;
|
|
89
102
|
title?: string;
|
|
90
103
|
};
|
|
104
|
+
export type VoiceSloReadinessThresholdReportOptions = VoiceSloCalibrationOptions & {
|
|
105
|
+
liveLatencyMaxAgeMs?: number;
|
|
106
|
+
};
|
|
107
|
+
export type VoiceSloReadinessThresholdRoutesOptions = VoiceSloReadinessThresholdReportOptions & {
|
|
108
|
+
headers?: HeadersInit;
|
|
109
|
+
htmlPath?: false | string;
|
|
110
|
+
markdownPath?: false | string;
|
|
111
|
+
name?: string;
|
|
112
|
+
path?: string;
|
|
113
|
+
source: (() => Promise<VoiceSloCalibrationReport | VoiceSloThresholdProfile | Array<VoiceProofTrendReport | VoiceSloCalibrationSample>> | VoiceSloCalibrationReport | VoiceSloThresholdProfile | Array<VoiceProofTrendReport | VoiceSloCalibrationSample>) | VoiceSloCalibrationReport | VoiceSloThresholdProfile | Array<VoiceProofTrendReport | VoiceSloCalibrationSample>;
|
|
114
|
+
title?: string;
|
|
115
|
+
};
|
|
91
116
|
export declare const buildVoiceSloCalibrationReport: (input: Array<VoiceProofTrendReport | VoiceSloCalibrationSample>, options?: VoiceSloCalibrationOptions) => VoiceSloCalibrationReport;
|
|
92
117
|
export declare const assertVoiceSloCalibration: (input: Array<VoiceProofTrendReport | VoiceSloCalibrationSample>, options?: VoiceSloCalibrationOptions) => VoiceSloCalibrationReport;
|
|
93
118
|
export declare const createVoiceSloThresholdProfile: (input: VoiceSloCalibrationReport | Array<VoiceProofTrendReport | VoiceSloCalibrationSample>, options?: VoiceSloCalibrationOptions) => VoiceSloThresholdProfile;
|
|
119
|
+
export declare const createVoiceSloReadinessThresholdOptions: (input: VoiceSloCalibrationReport | VoiceSloThresholdProfile | Array<VoiceProofTrendReport | VoiceSloCalibrationSample>, options?: VoiceSloCalibrationOptions) => VoiceSloReadinessThresholdOptions;
|
|
120
|
+
export declare const buildVoiceSloReadinessThresholdReport: (input: VoiceSloCalibrationReport | VoiceSloThresholdProfile | Array<VoiceProofTrendReport | VoiceSloCalibrationSample>, options?: VoiceSloReadinessThresholdReportOptions) => VoiceSloReadinessThresholdReport;
|
|
94
121
|
export declare const renderVoiceSloCalibrationMarkdown: (report: VoiceSloCalibrationReport, options?: {
|
|
95
122
|
title?: string;
|
|
96
123
|
}) => string;
|
|
124
|
+
export declare const renderVoiceSloReadinessThresholdMarkdown: (report: VoiceSloReadinessThresholdReport, options?: {
|
|
125
|
+
title?: string;
|
|
126
|
+
}) => string;
|
|
127
|
+
export declare const renderVoiceSloReadinessThresholdHTML: (report: VoiceSloReadinessThresholdReport, options?: {
|
|
128
|
+
title?: string;
|
|
129
|
+
}) => string;
|
|
97
130
|
export declare const createVoiceSloCalibrationRoutes: (options: VoiceSloCalibrationRoutesOptions) => Elysia<"", {
|
|
98
131
|
decorator: {};
|
|
99
132
|
store: {};
|
|
@@ -122,3 +155,31 @@ export declare const createVoiceSloCalibrationRoutes: (options: VoiceSloCalibrat
|
|
|
122
155
|
standaloneSchema: {};
|
|
123
156
|
response: {};
|
|
124
157
|
}>;
|
|
158
|
+
export declare const createVoiceSloReadinessThresholdRoutes: (options: VoiceSloReadinessThresholdRoutesOptions) => Elysia<"", {
|
|
159
|
+
decorator: {};
|
|
160
|
+
store: {};
|
|
161
|
+
derive: {};
|
|
162
|
+
resolve: {};
|
|
163
|
+
}, {
|
|
164
|
+
typebox: {};
|
|
165
|
+
error: {};
|
|
166
|
+
}, {
|
|
167
|
+
schema: {};
|
|
168
|
+
standaloneSchema: {};
|
|
169
|
+
macro: {};
|
|
170
|
+
macroFn: {};
|
|
171
|
+
parser: {};
|
|
172
|
+
response: {};
|
|
173
|
+
}, {}, {
|
|
174
|
+
derive: {};
|
|
175
|
+
resolve: {};
|
|
176
|
+
schema: {};
|
|
177
|
+
standaloneSchema: {};
|
|
178
|
+
response: {};
|
|
179
|
+
}, {
|
|
180
|
+
derive: {};
|
|
181
|
+
resolve: {};
|
|
182
|
+
schema: {};
|
|
183
|
+
standaloneSchema: {};
|
|
184
|
+
response: {};
|
|
185
|
+
}>;
|