@roarkanalytics/sdk 3.11.0 → 3.12.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/CHANGELOG.md +24 -0
- package/client.d.mts +7 -4
- package/client.d.mts.map +1 -1
- package/client.d.ts +7 -4
- package/client.d.ts.map +1 -1
- package/client.js +3 -0
- package/client.js.map +1 -1
- package/client.mjs +3 -0
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/agent-prompt.d.mts +129 -0
- package/resources/agent-prompt.d.mts.map +1 -0
- package/resources/agent-prompt.d.ts +129 -0
- package/resources/agent-prompt.d.ts.map +1 -0
- package/resources/agent-prompt.js +58 -0
- package/resources/agent-prompt.js.map +1 -0
- package/resources/agent-prompt.mjs +54 -0
- package/resources/agent-prompt.mjs.map +1 -0
- package/resources/call.d.mts +1 -1
- package/resources/call.d.mts.map +1 -1
- package/resources/call.d.ts +1 -1
- package/resources/call.d.ts.map +1 -1
- package/resources/config.d.mts +166 -18
- package/resources/config.d.mts.map +1 -1
- package/resources/config.d.ts +166 -18
- package/resources/config.d.ts.map +1 -1
- package/resources/customer-flow-edge-case.d.mts +72 -9
- package/resources/customer-flow-edge-case.d.mts.map +1 -1
- package/resources/customer-flow-edge-case.d.ts +72 -9
- package/resources/customer-flow-edge-case.d.ts.map +1 -1
- package/resources/customer-flow.d.mts +2005 -78
- package/resources/customer-flow.d.mts.map +1 -1
- package/resources/customer-flow.d.ts +2005 -78
- package/resources/customer-flow.d.ts.map +1 -1
- package/resources/customer-flow.js +18 -0
- package/resources/customer-flow.js.map +1 -1
- package/resources/customer-flow.mjs +18 -0
- package/resources/customer-flow.mjs.map +1 -1
- package/resources/index.d.mts +3 -2
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +3 -2
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +3 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +1 -0
- package/resources/index.mjs.map +1 -1
- package/resources/simulation-environment.d.mts +163 -1
- package/resources/simulation-environment.d.mts.map +1 -1
- package/resources/simulation-environment.d.ts +163 -1
- package/resources/simulation-environment.d.ts.map +1 -1
- package/resources/simulation-environment.js +51 -0
- package/resources/simulation-environment.js.map +1 -1
- package/resources/simulation-environment.mjs +51 -0
- package/resources/simulation-environment.mjs.map +1 -1
- package/resources/simulation-job.d.mts +62 -2
- package/resources/simulation-job.d.mts.map +1 -1
- package/resources/simulation-job.d.ts +62 -2
- package/resources/simulation-job.d.ts.map +1 -1
- package/resources/simulation-persona.d.mts +42 -6
- package/resources/simulation-persona.d.mts.map +1 -1
- package/resources/simulation-persona.d.ts +42 -6
- package/resources/simulation-persona.d.ts.map +1 -1
- package/resources/simulation-run-plan-job.d.mts +31 -1
- package/resources/simulation-run-plan-job.d.mts.map +1 -1
- package/resources/simulation-run-plan-job.d.ts +31 -1
- package/resources/simulation-run-plan-job.d.ts.map +1 -1
- package/resources/simulation-run-plan.d.mts +64 -0
- package/resources/simulation-run-plan.d.mts.map +1 -1
- package/resources/simulation-run-plan.d.ts +64 -0
- package/resources/simulation-run-plan.d.ts.map +1 -1
- package/resources/simulation-template.d.mts +10 -0
- package/resources/simulation-template.d.mts.map +1 -1
- package/resources/simulation-template.d.ts +10 -0
- package/resources/simulation-template.d.ts.map +1 -1
- package/resources/simulation.d.mts +17 -1
- package/resources/simulation.d.mts.map +1 -1
- package/resources/simulation.d.ts +17 -1
- package/resources/simulation.d.ts.map +1 -1
- package/src/client.ts +33 -0
- package/src/resources/agent-prompt.ts +183 -0
- package/src/resources/call.ts +1 -1
- package/src/resources/config.ts +310 -20
- package/src/resources/customer-flow-edge-case.ts +180 -9
- package/src/resources/customer-flow.ts +3091 -63
- package/src/resources/index.ts +15 -0
- package/src/resources/simulation-environment.ts +244 -0
- package/src/resources/simulation-job.ts +92 -2
- package/src/resources/simulation-persona.ts +108 -6
- package/src/resources/simulation-run-plan-job.ts +39 -1
- package/src/resources/simulation-run-plan.ts +74 -0
- package/src/resources/simulation-template.ts +11 -0
- package/src/resources/simulation.ts +18 -1
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -216,6 +216,12 @@ export namespace SimulationRunPlanJobGetByIDResponse {
|
|
|
216
216
|
*/
|
|
217
217
|
createdAt: string;
|
|
218
218
|
|
|
219
|
+
/**
|
|
220
|
+
* Present when the run was invalidated: it keeps its transcript and recording, but
|
|
221
|
+
* nothing scored it and it is excluded from every run total.
|
|
222
|
+
*/
|
|
223
|
+
invalidation: SimulationJob.Invalidation | null;
|
|
224
|
+
|
|
219
225
|
persona: SimulationJob.Persona;
|
|
220
226
|
|
|
221
227
|
/**
|
|
@@ -313,6 +319,28 @@ export namespace SimulationRunPlanJobGetByIDResponse {
|
|
|
313
319
|
| 'DAILY';
|
|
314
320
|
}
|
|
315
321
|
|
|
322
|
+
/**
|
|
323
|
+
* Present when the run was invalidated: it keeps its transcript and recording, but
|
|
324
|
+
* nothing scored it and it is excluded from every run total.
|
|
325
|
+
*/
|
|
326
|
+
export interface Invalidation {
|
|
327
|
+
/**
|
|
328
|
+
* When the run was invalidated.
|
|
329
|
+
*/
|
|
330
|
+
invalidatedAt: string;
|
|
331
|
+
|
|
332
|
+
/**
|
|
333
|
+
* Why the result does not count. `SCRIPT_DIVERGED`: a strict flow went off script
|
|
334
|
+
* at a step whose off-script policy is HANG_UP_INVALIDATE.
|
|
335
|
+
*/
|
|
336
|
+
reason: 'SCRIPT_DIVERGED';
|
|
337
|
+
|
|
338
|
+
/**
|
|
339
|
+
* One sentence: where the script was left and what your agent did instead.
|
|
340
|
+
*/
|
|
341
|
+
detail?: string | null;
|
|
342
|
+
}
|
|
343
|
+
|
|
316
344
|
export interface Persona {
|
|
317
345
|
/**
|
|
318
346
|
* Unique identifier of the persona
|
|
@@ -377,7 +405,10 @@ export namespace SimulationRunPlanJobGetByIDResponse {
|
|
|
377
405
|
| 'FRUSTRATED'
|
|
378
406
|
| 'SKEPTICAL'
|
|
379
407
|
| 'RUSHED'
|
|
380
|
-
| 'DISTRACTED'
|
|
408
|
+
| 'DISTRACTED'
|
|
409
|
+
| 'ANGRY'
|
|
410
|
+
| 'ANXIOUS'
|
|
411
|
+
| 'SAD';
|
|
381
412
|
|
|
382
413
|
/**
|
|
383
414
|
* How the persona confirms information
|
|
@@ -519,6 +550,13 @@ export namespace SimulationRunPlanJobGetByIDResponse {
|
|
|
519
550
|
*/
|
|
520
551
|
description?: string | null;
|
|
521
552
|
|
|
553
|
+
/**
|
|
554
|
+
* Label shown in place of the name across the dashboard (e.g. a short descriptor
|
|
555
|
+
* like "Irate Escalator"). The persona still identifies as `name` on calls. Omit
|
|
556
|
+
* or set null to display the name itself.
|
|
557
|
+
*/
|
|
558
|
+
displayName?: string | null;
|
|
559
|
+
|
|
522
560
|
/**
|
|
523
561
|
* Secondary language ISO 639-1 code for code-switching (e.g., Hinglish, Spanglish)
|
|
524
562
|
*/
|
|
@@ -179,12 +179,25 @@ export namespace SimulationRunPlanCreateResponse {
|
|
|
179
179
|
*/
|
|
180
180
|
flows: Array<RunPlan.Flow>;
|
|
181
181
|
|
|
182
|
+
/**
|
|
183
|
+
* Whether this plan lets a run add metrics by itself off the attached flows, on
|
|
184
|
+
* top of its own list. False means the `metrics` list is the whole answer.
|
|
185
|
+
*/
|
|
186
|
+
includeAutomaticMetrics: boolean;
|
|
187
|
+
|
|
182
188
|
/**
|
|
183
189
|
* Whether this plan also collects each attached flow's own metrics, on top of its
|
|
184
190
|
* own list.
|
|
185
191
|
*/
|
|
186
192
|
includeFlowMetrics: boolean;
|
|
187
193
|
|
|
194
|
+
/**
|
|
195
|
+
* Whether this plan is managed by config as code. A managed plan is reconciled
|
|
196
|
+
* from your config: PUT and DELETE on it return 409, and changes belong in the
|
|
197
|
+
* config file.
|
|
198
|
+
*/
|
|
199
|
+
isConfigManaged: boolean;
|
|
200
|
+
|
|
188
201
|
/**
|
|
189
202
|
* Number of iterations to run for each test case
|
|
190
203
|
*/
|
|
@@ -448,12 +461,25 @@ export namespace SimulationRunPlanUpdateResponse {
|
|
|
448
461
|
*/
|
|
449
462
|
flows: Array<Data.Flow>;
|
|
450
463
|
|
|
464
|
+
/**
|
|
465
|
+
* Whether this plan lets a run add metrics by itself off the attached flows, on
|
|
466
|
+
* top of its own list. False means the `metrics` list is the whole answer.
|
|
467
|
+
*/
|
|
468
|
+
includeAutomaticMetrics: boolean;
|
|
469
|
+
|
|
451
470
|
/**
|
|
452
471
|
* Whether this plan also collects each attached flow's own metrics, on top of its
|
|
453
472
|
* own list.
|
|
454
473
|
*/
|
|
455
474
|
includeFlowMetrics: boolean;
|
|
456
475
|
|
|
476
|
+
/**
|
|
477
|
+
* Whether this plan is managed by config as code. A managed plan is reconciled
|
|
478
|
+
* from your config: PUT and DELETE on it return 409, and changes belong in the
|
|
479
|
+
* config file.
|
|
480
|
+
*/
|
|
481
|
+
isConfigManaged: boolean;
|
|
482
|
+
|
|
457
483
|
/**
|
|
458
484
|
* Number of iterations to run for each test case
|
|
459
485
|
*/
|
|
@@ -681,12 +707,25 @@ export namespace SimulationRunPlanListResponse {
|
|
|
681
707
|
*/
|
|
682
708
|
flows: Array<Data.Flow>;
|
|
683
709
|
|
|
710
|
+
/**
|
|
711
|
+
* Whether this plan lets a run add metrics by itself off the attached flows, on
|
|
712
|
+
* top of its own list. False means the `metrics` list is the whole answer.
|
|
713
|
+
*/
|
|
714
|
+
includeAutomaticMetrics: boolean;
|
|
715
|
+
|
|
684
716
|
/**
|
|
685
717
|
* Whether this plan also collects each attached flow's own metrics, on top of its
|
|
686
718
|
* own list.
|
|
687
719
|
*/
|
|
688
720
|
includeFlowMetrics: boolean;
|
|
689
721
|
|
|
722
|
+
/**
|
|
723
|
+
* Whether this plan is managed by config as code. A managed plan is reconciled
|
|
724
|
+
* from your config: PUT and DELETE on it return 409, and changes belong in the
|
|
725
|
+
* config file.
|
|
726
|
+
*/
|
|
727
|
+
isConfigManaged: boolean;
|
|
728
|
+
|
|
690
729
|
/**
|
|
691
730
|
* Number of iterations to run for each test case
|
|
692
731
|
*/
|
|
@@ -942,12 +981,25 @@ export namespace SimulationRunPlanGetByIDResponse {
|
|
|
942
981
|
*/
|
|
943
982
|
flows: Array<Data.Flow>;
|
|
944
983
|
|
|
984
|
+
/**
|
|
985
|
+
* Whether this plan lets a run add metrics by itself off the attached flows, on
|
|
986
|
+
* top of its own list. False means the `metrics` list is the whole answer.
|
|
987
|
+
*/
|
|
988
|
+
includeAutomaticMetrics: boolean;
|
|
989
|
+
|
|
945
990
|
/**
|
|
946
991
|
* Whether this plan also collects each attached flow's own metrics, on top of its
|
|
947
992
|
* own list.
|
|
948
993
|
*/
|
|
949
994
|
includeFlowMetrics: boolean;
|
|
950
995
|
|
|
996
|
+
/**
|
|
997
|
+
* Whether this plan is managed by config as code. A managed plan is reconciled
|
|
998
|
+
* from your config: PUT and DELETE on it return 409, and changes belong in the
|
|
999
|
+
* config file.
|
|
1000
|
+
*/
|
|
1001
|
+
isConfigManaged: boolean;
|
|
1002
|
+
|
|
951
1003
|
/**
|
|
952
1004
|
* Number of iterations to run for each test case
|
|
953
1005
|
*/
|
|
@@ -1187,6 +1239,22 @@ export interface SimulationRunPlanCreateParams {
|
|
|
1187
1239
|
*/
|
|
1188
1240
|
flows?: Array<SimulationRunPlanCreateParams.Flow>;
|
|
1189
1241
|
|
|
1242
|
+
/**
|
|
1243
|
+
* Let the run add metrics by itself off the attached flows, on top of the
|
|
1244
|
+
* `metrics` named here.
|
|
1245
|
+
*
|
|
1246
|
+
* Two attach this way today: Agent Expectations wherever an attached flow has
|
|
1247
|
+
* agent expectations written on it, and Keypad Entry wherever one has steps where
|
|
1248
|
+
* the agent is expected to press keys. Both grade something authored on the flow
|
|
1249
|
+
* that nothing else measures, which is why it is on by default.
|
|
1250
|
+
*
|
|
1251
|
+
* Set false when the `metrics` list is meant to be exhaustive: a plan testing only
|
|
1252
|
+
* whether the caller can complete the flow may not want the agent graded on its
|
|
1253
|
+
* expectations as well. False also pins the plan against any automatic metric
|
|
1254
|
+
* Roark adds later.
|
|
1255
|
+
*/
|
|
1256
|
+
includeAutomaticMetrics?: boolean;
|
|
1257
|
+
|
|
1190
1258
|
/**
|
|
1191
1259
|
* Also collect each attached flow's own metrics, on top of the `metrics` named
|
|
1192
1260
|
* here.
|
|
@@ -1397,6 +1465,12 @@ export interface SimulationRunPlanUpdateParams {
|
|
|
1397
1465
|
*/
|
|
1398
1466
|
flows?: Array<SimulationRunPlanUpdateParams.Flow>;
|
|
1399
1467
|
|
|
1468
|
+
/**
|
|
1469
|
+
* Whether to let the run add metrics by itself off the attached flows. See
|
|
1470
|
+
* `POST /v1/simulation/plan`.
|
|
1471
|
+
*/
|
|
1472
|
+
includeAutomaticMetrics?: boolean;
|
|
1473
|
+
|
|
1400
1474
|
/**
|
|
1401
1475
|
* Whether to also collect each attached flow's own metrics, on top of this plan's
|
|
1402
1476
|
* list.
|
|
@@ -47,6 +47,17 @@ export namespace SimulationTemplateListResponse {
|
|
|
47
47
|
*/
|
|
48
48
|
category: string;
|
|
49
49
|
|
|
50
|
+
/**
|
|
51
|
+
* The end-call conditions a run from this template uses unless the request sets
|
|
52
|
+
* its own.
|
|
53
|
+
*
|
|
54
|
+
* Empty for templates whose calls end when the agent says goodbye. Non-empty where
|
|
55
|
+
* the template runs scripted flows that finish on a verdict: the simulated caller
|
|
56
|
+
* hangs up on an end-call phrase or one of these, so a run that discards them
|
|
57
|
+
* would stay on the line until the duration cap.
|
|
58
|
+
*/
|
|
59
|
+
defaultEndCallReasons: Array<string>;
|
|
60
|
+
|
|
50
61
|
/**
|
|
51
62
|
* The per-simulation cap a run from this template uses unless the request sets its
|
|
52
63
|
* own.
|
|
@@ -219,6 +219,22 @@ export declare namespace SimulationRunParams {
|
|
|
219
219
|
*/
|
|
220
220
|
flows?: Array<Plan.Flow>;
|
|
221
221
|
|
|
222
|
+
/**
|
|
223
|
+
* Let the run add metrics by itself off the attached flows, on top of the
|
|
224
|
+
* `metrics` named here.
|
|
225
|
+
*
|
|
226
|
+
* Two attach this way today: Agent Expectations wherever an attached flow has
|
|
227
|
+
* agent expectations written on it, and Keypad Entry wherever one has steps where
|
|
228
|
+
* the agent is expected to press keys. Both grade something authored on the flow
|
|
229
|
+
* that nothing else measures, which is why it is on by default.
|
|
230
|
+
*
|
|
231
|
+
* Set false when the `metrics` list is meant to be exhaustive: a plan testing only
|
|
232
|
+
* whether the caller can complete the flow may not want the agent graded on its
|
|
233
|
+
* expectations as well. False also pins the plan against any automatic metric
|
|
234
|
+
* Roark adds later.
|
|
235
|
+
*/
|
|
236
|
+
includeAutomaticMetrics?: boolean;
|
|
237
|
+
|
|
222
238
|
/**
|
|
223
239
|
* Also collect each attached flow's own metrics, on top of the `metrics` named
|
|
224
240
|
* here.
|
|
@@ -523,7 +539,8 @@ export declare namespace SimulationRunParams {
|
|
|
523
539
|
|
|
524
540
|
/**
|
|
525
541
|
* Semantic conditions that trigger end of call. The LLM evaluates the conversation
|
|
526
|
-
* against these conditions.
|
|
542
|
+
* against these conditions. Defaults to the template's `defaultEndCallReasons`, as
|
|
543
|
+
* returned by GET /v1/simulation/template. Pass an empty array to run with none.
|
|
527
544
|
*/
|
|
528
545
|
endCallReasons?: Array<string>;
|
|
529
546
|
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '3.
|
|
1
|
+
export const VERSION = '3.12.0'; // x-release-please-version
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "3.
|
|
1
|
+
export declare const VERSION = "3.12.0";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "3.
|
|
1
|
+
export declare const VERSION = "3.12.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '3.
|
|
1
|
+
export const VERSION = '3.12.0'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|