@roarkanalytics/sdk 0.333.0 → 2.1.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 +25 -0
- package/core.d.ts +2 -2
- package/core.d.ts.map +1 -1
- package/core.js +4 -2
- package/core.js.map +1 -1
- package/core.mjs +4 -2
- package/core.mjs.map +1 -1
- package/index.d.mts +2 -2
- package/index.d.ts +2 -2
- package/index.d.ts.map +1 -1
- package/index.js.map +1 -1
- package/index.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/call.d.ts +194 -0
- package/resources/call.d.ts.map +1 -1
- package/resources/call.js +13 -0
- package/resources/call.js.map +1 -1
- package/resources/call.mjs +13 -0
- package/resources/call.mjs.map +1 -1
- package/resources/evaluation.d.ts +130 -45
- package/resources/evaluation.d.ts.map +1 -1
- package/resources/index.d.ts +1 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs.map +1 -1
- package/src/core.ts +5 -3
- package/src/index.ts +6 -2
- package/src/resources/call.ts +246 -1
- package/src/resources/evaluation.ts +142 -47
- package/src/resources/index.ts +1 -1
- package/src/version.ts +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
package/resources/call.d.ts
CHANGED
|
@@ -1,4 +1,198 @@
|
|
|
1
1
|
import { APIResource } from "../resource.js";
|
|
2
|
+
import * as Core from "../core.js";
|
|
2
3
|
export declare class Call extends APIResource {
|
|
4
|
+
/**
|
|
5
|
+
* Fetch evaluation run results for a specific call.
|
|
6
|
+
*/
|
|
7
|
+
getEvaluationRun(id: string, options?: Core.RequestOptions): Core.APIPromise<CallGetEvaluationRunResponse>;
|
|
8
|
+
/**
|
|
9
|
+
* Fetch detailed sentiment analysis results for a specific call, including
|
|
10
|
+
* emotional tone, key phrases, and sentiment scores.
|
|
11
|
+
*/
|
|
12
|
+
getSentimentRun(id: string, options?: Core.RequestOptions): Core.APIPromise<CallGetSentimentRunResponse>;
|
|
13
|
+
}
|
|
14
|
+
export interface CallGetEvaluationRunResponse {
|
|
15
|
+
/**
|
|
16
|
+
* Evaluation run response payload
|
|
17
|
+
*/
|
|
18
|
+
data: Array<CallGetEvaluationRunResponse.Data>;
|
|
19
|
+
}
|
|
20
|
+
export declare namespace CallGetEvaluationRunResponse {
|
|
21
|
+
interface Data {
|
|
22
|
+
/**
|
|
23
|
+
* All block runs for this evaluator, including skipped ones
|
|
24
|
+
*/
|
|
25
|
+
blockRuns: Array<Data.BlockRun>;
|
|
26
|
+
evaluator: Data.Evaluator;
|
|
27
|
+
evidence: Array<Data.Evidence>;
|
|
28
|
+
metrics: Array<Data.Metric>;
|
|
29
|
+
/**
|
|
30
|
+
* Status of the evaluator run
|
|
31
|
+
*/
|
|
32
|
+
status: 'PENDING' | 'IN_PROGRESS' | 'COMPLETED' | 'FAILED';
|
|
33
|
+
/**
|
|
34
|
+
* ID of the evaluator run
|
|
35
|
+
*/
|
|
36
|
+
id?: string;
|
|
37
|
+
/**
|
|
38
|
+
* When the evaluator run completed
|
|
39
|
+
*/
|
|
40
|
+
completedAt?: string | null;
|
|
41
|
+
/**
|
|
42
|
+
* Score of the evaluation run (0-1)
|
|
43
|
+
*/
|
|
44
|
+
score?: number | null;
|
|
45
|
+
/**
|
|
46
|
+
* Score classification of the evaluator run based on score threshold (IRRELEVANT
|
|
47
|
+
* is mapped to SKIPPED)
|
|
48
|
+
*/
|
|
49
|
+
scoreClassification?: 'SUCCESS' | 'FAILURE' | 'SKIPPED' | null;
|
|
50
|
+
/**
|
|
51
|
+
* When the evaluator run started
|
|
52
|
+
*/
|
|
53
|
+
startedAt?: string | null;
|
|
54
|
+
/**
|
|
55
|
+
* Summary of the evaluation run
|
|
56
|
+
*/
|
|
57
|
+
summary?: string | null;
|
|
58
|
+
}
|
|
59
|
+
namespace Data {
|
|
60
|
+
interface BlockRun {
|
|
61
|
+
/**
|
|
62
|
+
* ID of the block definition
|
|
63
|
+
*/
|
|
64
|
+
blockDefinitionId: string;
|
|
65
|
+
/**
|
|
66
|
+
* Name of the evaluation block
|
|
67
|
+
*/
|
|
68
|
+
blockName: string;
|
|
69
|
+
/**
|
|
70
|
+
* ID of the block run instance
|
|
71
|
+
*/
|
|
72
|
+
blockRunId: string;
|
|
73
|
+
/**
|
|
74
|
+
* When the block run was created
|
|
75
|
+
*/
|
|
76
|
+
createdAt: string;
|
|
77
|
+
/**
|
|
78
|
+
* Reason for the outcome (pass/fail explanation or skip reason)
|
|
79
|
+
*/
|
|
80
|
+
reason: string | null;
|
|
81
|
+
/**
|
|
82
|
+
* Result of the block run
|
|
83
|
+
*/
|
|
84
|
+
result: 'PASSED' | 'FAILED' | 'SKIPPED' | null;
|
|
85
|
+
/**
|
|
86
|
+
* Score of the block run (0-1)
|
|
87
|
+
*/
|
|
88
|
+
score: number | null;
|
|
89
|
+
/**
|
|
90
|
+
* Status of the block run
|
|
91
|
+
*/
|
|
92
|
+
status: 'PENDING' | 'RUNNING' | 'COMPLETED' | 'FAILED';
|
|
93
|
+
}
|
|
94
|
+
interface Evaluator {
|
|
95
|
+
/**
|
|
96
|
+
* ID of the evaluator
|
|
97
|
+
*/
|
|
98
|
+
id: string;
|
|
99
|
+
/**
|
|
100
|
+
* Name of the evaluator
|
|
101
|
+
*/
|
|
102
|
+
name: string;
|
|
103
|
+
/**
|
|
104
|
+
* Weight of the evaluator
|
|
105
|
+
*/
|
|
106
|
+
weight?: number;
|
|
107
|
+
}
|
|
108
|
+
interface Evidence {
|
|
109
|
+
/**
|
|
110
|
+
* Comment text of the evidence
|
|
111
|
+
*/
|
|
112
|
+
commentText: string | null;
|
|
113
|
+
/**
|
|
114
|
+
* Created at of the evidence
|
|
115
|
+
*/
|
|
116
|
+
createdAt: string;
|
|
117
|
+
/**
|
|
118
|
+
* Is positive of the evidence
|
|
119
|
+
*/
|
|
120
|
+
isPositive: boolean;
|
|
121
|
+
/**
|
|
122
|
+
* Snippet text of the evidence
|
|
123
|
+
*/
|
|
124
|
+
snippetText: string;
|
|
125
|
+
}
|
|
126
|
+
interface Metric {
|
|
127
|
+
/**
|
|
128
|
+
* Boolean value of the metric
|
|
129
|
+
*/
|
|
130
|
+
booleanValue: boolean | null;
|
|
131
|
+
/**
|
|
132
|
+
* Confidence level of the metric (0-1)
|
|
133
|
+
*/
|
|
134
|
+
confidence: number | null;
|
|
135
|
+
/**
|
|
136
|
+
* Created at of the metric
|
|
137
|
+
*/
|
|
138
|
+
createdAt: string;
|
|
139
|
+
/**
|
|
140
|
+
* Name of the metric
|
|
141
|
+
*/
|
|
142
|
+
name: string;
|
|
143
|
+
/**
|
|
144
|
+
* Numeric value of the metric
|
|
145
|
+
*/
|
|
146
|
+
numericValue: number | null;
|
|
147
|
+
/**
|
|
148
|
+
* Reasoning of the metric
|
|
149
|
+
*/
|
|
150
|
+
reasoning: string | null;
|
|
151
|
+
/**
|
|
152
|
+
* Role of the metric
|
|
153
|
+
*/
|
|
154
|
+
role: string;
|
|
155
|
+
/**
|
|
156
|
+
* Text value of the metric
|
|
157
|
+
*/
|
|
158
|
+
textValue: string | null;
|
|
159
|
+
/**
|
|
160
|
+
* Value type of the metric
|
|
161
|
+
*/
|
|
162
|
+
valueType: string;
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
export interface CallGetSentimentRunResponse {
|
|
167
|
+
/**
|
|
168
|
+
* Sentiment run response payload
|
|
169
|
+
*/
|
|
170
|
+
data: CallGetSentimentRunResponse.Data;
|
|
171
|
+
}
|
|
172
|
+
export declare namespace CallGetSentimentRunResponse {
|
|
173
|
+
/**
|
|
174
|
+
* Sentiment run response payload
|
|
175
|
+
*/
|
|
176
|
+
interface Data {
|
|
177
|
+
/**
|
|
178
|
+
* Status of the sentiment run
|
|
179
|
+
*/
|
|
180
|
+
status: string;
|
|
181
|
+
/**
|
|
182
|
+
* NEUTRAL / NEGATIVE / POSITIVE
|
|
183
|
+
*/
|
|
184
|
+
averageCategoricalSentiment?: string;
|
|
185
|
+
/**
|
|
186
|
+
* Average sentiment score between 0-1 of the call
|
|
187
|
+
*/
|
|
188
|
+
averageSentiment?: number;
|
|
189
|
+
/**
|
|
190
|
+
* Common emotion of the call
|
|
191
|
+
*/
|
|
192
|
+
commonEmotion?: string;
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
export declare namespace Call {
|
|
196
|
+
export { type CallGetEvaluationRunResponse as CallGetEvaluationRunResponse, type CallGetSentimentRunResponse as CallGetSentimentRunResponse, };
|
|
3
197
|
}
|
|
4
198
|
//# sourceMappingURL=call.d.ts.map
|
package/resources/call.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"call.d.ts","sourceRoot":"","sources":["../src/resources/call.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"call.d.ts","sourceRoot":"","sources":["../src/resources/call.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,KAAK,IAAI,MAAM,SAAS,CAAC;AAEhC,qBAAa,IAAK,SAAQ,WAAW;IACnC;;OAEG;IACH,gBAAgB,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,4BAA4B,CAAC;IAI1G;;;OAGG;IACH,eAAe,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,UAAU,CAAC,2BAA2B,CAAC;CAGzG;AAED,MAAM,WAAW,4BAA4B;IAC3C;;OAEG;IACH,IAAI,EAAE,KAAK,CAAC,4BAA4B,CAAC,IAAI,CAAC,CAAC;CAChD;AAED,yBAAiB,4BAA4B,CAAC;IAC5C,UAAiB,IAAI;QACn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4BAA4B,IAAI,4BAA4B,EACjE,KAAK,2BAA2B,IAAI,2BAA2B,GAChE,CAAC;CACH"}
|
package/resources/call.js
CHANGED
|
@@ -4,6 +4,19 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.Call = void 0;
|
|
5
5
|
const resource_1 = require("../resource.js");
|
|
6
6
|
class Call extends resource_1.APIResource {
|
|
7
|
+
/**
|
|
8
|
+
* Fetch evaluation run results for a specific call.
|
|
9
|
+
*/
|
|
10
|
+
getEvaluationRun(id, options) {
|
|
11
|
+
return this._client.get(`/v1/call/${id}/evaluation-run`, options);
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Fetch detailed sentiment analysis results for a specific call, including
|
|
15
|
+
* emotional tone, key phrases, and sentiment scores.
|
|
16
|
+
*/
|
|
17
|
+
getSentimentRun(id, options) {
|
|
18
|
+
return this._client.get(`/v1/call/${id}/sentiment-run`, options);
|
|
19
|
+
}
|
|
7
20
|
}
|
|
8
21
|
exports.Call = Call;
|
|
9
22
|
//# sourceMappingURL=call.js.map
|
package/resources/call.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"call.js","sourceRoot":"","sources":["../src/resources/call.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,6CAA0C;
|
|
1
|
+
{"version":3,"file":"call.js","sourceRoot":"","sources":["../src/resources/call.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,6CAA0C;AAG1C,MAAa,IAAK,SAAQ,sBAAW;IACnC;;OAEG;IACH,gBAAgB,CAAC,EAAU,EAAE,OAA6B;QACxD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,EAAE,iBAAiB,EAAE,OAAO,CAAC,CAAC;IACpE,CAAC;IAED;;;OAGG;IACH,eAAe,CAAC,EAAU,EAAE,OAA6B;QACvD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,EAAE,gBAAgB,EAAE,OAAO,CAAC,CAAC;IACnE,CAAC;CACF;AAfD,oBAeC"}
|
package/resources/call.mjs
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
import { APIResource } from "../resource.mjs";
|
|
3
3
|
export class Call extends APIResource {
|
|
4
|
+
/**
|
|
5
|
+
* Fetch evaluation run results for a specific call.
|
|
6
|
+
*/
|
|
7
|
+
getEvaluationRun(id, options) {
|
|
8
|
+
return this._client.get(`/v1/call/${id}/evaluation-run`, options);
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Fetch detailed sentiment analysis results for a specific call, including
|
|
12
|
+
* emotional tone, key phrases, and sentiment scores.
|
|
13
|
+
*/
|
|
14
|
+
getSentimentRun(id, options) {
|
|
15
|
+
return this._client.get(`/v1/call/${id}/sentiment-run`, options);
|
|
16
|
+
}
|
|
4
17
|
}
|
|
5
18
|
//# sourceMappingURL=call.mjs.map
|
package/resources/call.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"call.mjs","sourceRoot":"","sources":["../src/resources/call.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;
|
|
1
|
+
{"version":3,"file":"call.mjs","sourceRoot":"","sources":["../src/resources/call.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAGtB,MAAM,OAAO,IAAK,SAAQ,WAAW;IACnC;;OAEG;IACH,gBAAgB,CAAC,EAAU,EAAE,OAA6B;QACxD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,EAAE,iBAAiB,EAAE,OAAO,CAAC,CAAC;IACpE,CAAC;IAED;;;OAGG;IACH,eAAe,CAAC,EAAU,EAAE,OAA6B;QACvD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,EAAE,gBAAgB,EAAE,OAAO,CAAC,CAAC;IACnE,CAAC;CACF"}
|
|
@@ -79,6 +79,9 @@ export declare namespace EvaluationGetEvaluatorByIDResponse {
|
|
|
79
79
|
* Unique identifier for the block
|
|
80
80
|
*/
|
|
81
81
|
id: string;
|
|
82
|
+
/**
|
|
83
|
+
* Block type identifier
|
|
84
|
+
*/
|
|
82
85
|
blockType: 'CUSTOM_PROMPT';
|
|
83
86
|
/**
|
|
84
87
|
* Optional description of what this block evaluates
|
|
@@ -114,6 +117,9 @@ export declare namespace EvaluationGetEvaluatorByIDResponse {
|
|
|
114
117
|
* Unique identifier for the block
|
|
115
118
|
*/
|
|
116
119
|
id: string;
|
|
120
|
+
/**
|
|
121
|
+
* Block type identifier
|
|
122
|
+
*/
|
|
117
123
|
blockType: 'DATAFIELD_CHECK';
|
|
118
124
|
/**
|
|
119
125
|
* Optional description of what this block evaluates
|
|
@@ -157,6 +163,9 @@ export declare namespace EvaluationGetEvaluatorByIDResponse {
|
|
|
157
163
|
* Unique identifier for the block
|
|
158
164
|
*/
|
|
159
165
|
id: string;
|
|
166
|
+
/**
|
|
167
|
+
* Block type identifier
|
|
168
|
+
*/
|
|
160
169
|
blockType: 'EMOTION';
|
|
161
170
|
/**
|
|
162
171
|
* Optional description of what this block evaluates
|
|
@@ -188,6 +197,9 @@ export declare namespace EvaluationGetEvaluatorByIDResponse {
|
|
|
188
197
|
* Unique identifier for the block
|
|
189
198
|
*/
|
|
190
199
|
id: string;
|
|
200
|
+
/**
|
|
201
|
+
* Block type identifier
|
|
202
|
+
*/
|
|
191
203
|
blockType: 'LATENCY';
|
|
192
204
|
/**
|
|
193
205
|
* Optional description of what this block evaluates
|
|
@@ -223,6 +235,9 @@ export declare namespace EvaluationGetEvaluatorByIDResponse {
|
|
|
223
235
|
* Unique identifier for the block
|
|
224
236
|
*/
|
|
225
237
|
id: string;
|
|
238
|
+
/**
|
|
239
|
+
* Block type identifier
|
|
240
|
+
*/
|
|
226
241
|
blockType: 'POLITENESS';
|
|
227
242
|
/**
|
|
228
243
|
* Optional description of what this block evaluates
|
|
@@ -250,6 +265,9 @@ export declare namespace EvaluationGetEvaluatorByIDResponse {
|
|
|
250
265
|
* Unique identifier for the block
|
|
251
266
|
*/
|
|
252
267
|
id: string;
|
|
268
|
+
/**
|
|
269
|
+
* Block type identifier
|
|
270
|
+
*/
|
|
253
271
|
blockType: 'SENTIMENT';
|
|
254
272
|
/**
|
|
255
273
|
* Optional description of what this block evaluates
|
|
@@ -277,6 +295,9 @@ export declare namespace EvaluationGetEvaluatorByIDResponse {
|
|
|
277
295
|
* Unique identifier for the block
|
|
278
296
|
*/
|
|
279
297
|
id: string;
|
|
298
|
+
/**
|
|
299
|
+
* Block type identifier
|
|
300
|
+
*/
|
|
280
301
|
blockType: 'TOOL_CALLS';
|
|
281
302
|
/**
|
|
282
303
|
* Optional description of what this block evaluates
|
|
@@ -316,6 +337,9 @@ export declare namespace EvaluationGetEvaluatorByIDResponse {
|
|
|
316
337
|
* Unique identifier for the block
|
|
317
338
|
*/
|
|
318
339
|
id: string;
|
|
340
|
+
/**
|
|
341
|
+
* Block type identifier
|
|
342
|
+
*/
|
|
319
343
|
blockType: 'TOXICITY';
|
|
320
344
|
/**
|
|
321
345
|
* Optional description of what this block evaluates
|
|
@@ -343,6 +367,9 @@ export declare namespace EvaluationGetEvaluatorByIDResponse {
|
|
|
343
367
|
* Unique identifier for the block
|
|
344
368
|
*/
|
|
345
369
|
id: string;
|
|
370
|
+
/**
|
|
371
|
+
* Block type identifier
|
|
372
|
+
*/
|
|
346
373
|
blockType: 'VOCAL_CUE';
|
|
347
374
|
/**
|
|
348
375
|
* Optional description of what this block evaluates
|
|
@@ -423,6 +450,9 @@ export declare namespace EvaluationGetEvaluatorsResponse {
|
|
|
423
450
|
* Unique identifier for the block
|
|
424
451
|
*/
|
|
425
452
|
id: string;
|
|
453
|
+
/**
|
|
454
|
+
* Block type identifier
|
|
455
|
+
*/
|
|
426
456
|
blockType: 'CUSTOM_PROMPT';
|
|
427
457
|
/**
|
|
428
458
|
* Optional description of what this block evaluates
|
|
@@ -458,6 +488,9 @@ export declare namespace EvaluationGetEvaluatorsResponse {
|
|
|
458
488
|
* Unique identifier for the block
|
|
459
489
|
*/
|
|
460
490
|
id: string;
|
|
491
|
+
/**
|
|
492
|
+
* Block type identifier
|
|
493
|
+
*/
|
|
461
494
|
blockType: 'DATAFIELD_CHECK';
|
|
462
495
|
/**
|
|
463
496
|
* Optional description of what this block evaluates
|
|
@@ -501,6 +534,9 @@ export declare namespace EvaluationGetEvaluatorsResponse {
|
|
|
501
534
|
* Unique identifier for the block
|
|
502
535
|
*/
|
|
503
536
|
id: string;
|
|
537
|
+
/**
|
|
538
|
+
* Block type identifier
|
|
539
|
+
*/
|
|
504
540
|
blockType: 'EMOTION';
|
|
505
541
|
/**
|
|
506
542
|
* Optional description of what this block evaluates
|
|
@@ -532,6 +568,9 @@ export declare namespace EvaluationGetEvaluatorsResponse {
|
|
|
532
568
|
* Unique identifier for the block
|
|
533
569
|
*/
|
|
534
570
|
id: string;
|
|
571
|
+
/**
|
|
572
|
+
* Block type identifier
|
|
573
|
+
*/
|
|
535
574
|
blockType: 'LATENCY';
|
|
536
575
|
/**
|
|
537
576
|
* Optional description of what this block evaluates
|
|
@@ -567,6 +606,9 @@ export declare namespace EvaluationGetEvaluatorsResponse {
|
|
|
567
606
|
* Unique identifier for the block
|
|
568
607
|
*/
|
|
569
608
|
id: string;
|
|
609
|
+
/**
|
|
610
|
+
* Block type identifier
|
|
611
|
+
*/
|
|
570
612
|
blockType: 'POLITENESS';
|
|
571
613
|
/**
|
|
572
614
|
* Optional description of what this block evaluates
|
|
@@ -594,6 +636,9 @@ export declare namespace EvaluationGetEvaluatorsResponse {
|
|
|
594
636
|
* Unique identifier for the block
|
|
595
637
|
*/
|
|
596
638
|
id: string;
|
|
639
|
+
/**
|
|
640
|
+
* Block type identifier
|
|
641
|
+
*/
|
|
597
642
|
blockType: 'SENTIMENT';
|
|
598
643
|
/**
|
|
599
644
|
* Optional description of what this block evaluates
|
|
@@ -621,6 +666,9 @@ export declare namespace EvaluationGetEvaluatorsResponse {
|
|
|
621
666
|
* Unique identifier for the block
|
|
622
667
|
*/
|
|
623
668
|
id: string;
|
|
669
|
+
/**
|
|
670
|
+
* Block type identifier
|
|
671
|
+
*/
|
|
624
672
|
blockType: 'TOOL_CALLS';
|
|
625
673
|
/**
|
|
626
674
|
* Optional description of what this block evaluates
|
|
@@ -660,6 +708,9 @@ export declare namespace EvaluationGetEvaluatorsResponse {
|
|
|
660
708
|
* Unique identifier for the block
|
|
661
709
|
*/
|
|
662
710
|
id: string;
|
|
711
|
+
/**
|
|
712
|
+
* Block type identifier
|
|
713
|
+
*/
|
|
663
714
|
blockType: 'TOXICITY';
|
|
664
715
|
/**
|
|
665
716
|
* Optional description of what this block evaluates
|
|
@@ -687,6 +738,9 @@ export declare namespace EvaluationGetEvaluatorsResponse {
|
|
|
687
738
|
* Unique identifier for the block
|
|
688
739
|
*/
|
|
689
740
|
id: string;
|
|
741
|
+
/**
|
|
742
|
+
* Block type identifier
|
|
743
|
+
*/
|
|
690
744
|
blockType: 'VOCAL_CUE';
|
|
691
745
|
/**
|
|
692
746
|
* Optional description of what this block evaluates
|
|
@@ -816,107 +870,138 @@ export declare namespace EvaluationGetJobRunsResponse {
|
|
|
816
870
|
namespace Data {
|
|
817
871
|
interface Data {
|
|
818
872
|
/**
|
|
819
|
-
*
|
|
820
|
-
*/
|
|
821
|
-
id: string;
|
|
822
|
-
/**
|
|
823
|
-
* When the evaluator run completed
|
|
873
|
+
* All block runs for this evaluator, including skipped ones
|
|
824
874
|
*/
|
|
825
|
-
|
|
875
|
+
blockRuns: Array<Data.BlockRun>;
|
|
876
|
+
evaluator: Data.Evaluator;
|
|
877
|
+
evidence: Array<Data.Evidence>;
|
|
878
|
+
metrics: Array<Data.Metric>;
|
|
826
879
|
/**
|
|
827
|
-
*
|
|
880
|
+
* Status of the evaluator run
|
|
828
881
|
*/
|
|
829
|
-
|
|
882
|
+
status: 'PENDING' | 'IN_PROGRESS' | 'COMPLETED' | 'FAILED';
|
|
830
883
|
/**
|
|
831
|
-
*
|
|
884
|
+
* ID of the evaluator run
|
|
832
885
|
*/
|
|
833
|
-
|
|
886
|
+
id?: string;
|
|
834
887
|
/**
|
|
835
|
-
*
|
|
888
|
+
* When the evaluator run completed
|
|
836
889
|
*/
|
|
837
|
-
|
|
890
|
+
completedAt?: string | null;
|
|
838
891
|
/**
|
|
839
|
-
* Score of the
|
|
892
|
+
* Score of the evaluation run (0-1)
|
|
840
893
|
*/
|
|
841
|
-
score
|
|
894
|
+
score?: number | null;
|
|
842
895
|
/**
|
|
843
|
-
* Score classification of the evaluator run
|
|
896
|
+
* Score classification of the evaluator run based on score threshold (IRRELEVANT
|
|
897
|
+
* is mapped to SKIPPED)
|
|
844
898
|
*/
|
|
845
|
-
scoreClassification
|
|
899
|
+
scoreClassification?: 'SUCCESS' | 'FAILURE' | 'SKIPPED' | null;
|
|
846
900
|
/**
|
|
847
901
|
* When the evaluator run started
|
|
848
902
|
*/
|
|
849
|
-
startedAt
|
|
850
|
-
/**
|
|
851
|
-
* Status of the evaluator run
|
|
852
|
-
*/
|
|
853
|
-
status: 'PENDING' | 'IN_PROGRESS' | 'COMPLETED' | 'FAILED';
|
|
903
|
+
startedAt?: string | null;
|
|
854
904
|
/**
|
|
855
|
-
* Summary of the
|
|
905
|
+
* Summary of the evaluation run
|
|
856
906
|
*/
|
|
857
|
-
summary
|
|
907
|
+
summary?: string | null;
|
|
858
908
|
}
|
|
859
909
|
namespace Data {
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
910
|
+
interface BlockRun {
|
|
911
|
+
/**
|
|
912
|
+
* ID of the block definition
|
|
913
|
+
*/
|
|
914
|
+
blockDefinitionId: string;
|
|
915
|
+
/**
|
|
916
|
+
* Name of the evaluation block
|
|
917
|
+
*/
|
|
918
|
+
blockName: string;
|
|
919
|
+
/**
|
|
920
|
+
* ID of the block run instance
|
|
921
|
+
*/
|
|
922
|
+
blockRunId: string;
|
|
923
|
+
/**
|
|
924
|
+
* When the block run was created
|
|
925
|
+
*/
|
|
926
|
+
createdAt: string;
|
|
927
|
+
/**
|
|
928
|
+
* Reason for the outcome (pass/fail explanation or skip reason)
|
|
929
|
+
*/
|
|
930
|
+
reason: string | null;
|
|
931
|
+
/**
|
|
932
|
+
* Result of the block run
|
|
933
|
+
*/
|
|
934
|
+
result: 'PASSED' | 'FAILED' | 'SKIPPED' | null;
|
|
935
|
+
/**
|
|
936
|
+
* Score of the block run (0-1)
|
|
937
|
+
*/
|
|
938
|
+
score: number | null;
|
|
939
|
+
/**
|
|
940
|
+
* Status of the block run
|
|
941
|
+
*/
|
|
942
|
+
status: 'PENDING' | 'RUNNING' | 'COMPLETED' | 'FAILED';
|
|
943
|
+
}
|
|
863
944
|
interface Evaluator {
|
|
864
945
|
/**
|
|
865
946
|
* ID of the evaluator
|
|
866
947
|
*/
|
|
867
|
-
id: string
|
|
948
|
+
id: string;
|
|
868
949
|
/**
|
|
869
950
|
* Name of the evaluator
|
|
870
951
|
*/
|
|
871
|
-
name: string
|
|
952
|
+
name: string;
|
|
953
|
+
/**
|
|
954
|
+
* Weight of the evaluator
|
|
955
|
+
*/
|
|
956
|
+
weight?: number;
|
|
872
957
|
}
|
|
873
958
|
interface Evidence {
|
|
874
959
|
/**
|
|
875
|
-
*
|
|
960
|
+
* Comment text of the evidence
|
|
876
961
|
*/
|
|
877
|
-
|
|
962
|
+
commentText: string | null;
|
|
878
963
|
/**
|
|
879
|
-
*
|
|
964
|
+
* Created at of the evidence
|
|
880
965
|
*/
|
|
881
|
-
|
|
966
|
+
createdAt: string;
|
|
882
967
|
/**
|
|
883
|
-
*
|
|
968
|
+
* Is positive of the evidence
|
|
884
969
|
*/
|
|
885
|
-
isPositive: boolean
|
|
970
|
+
isPositive: boolean;
|
|
886
971
|
/**
|
|
887
|
-
* Snippet of the evidence
|
|
972
|
+
* Snippet text of the evidence
|
|
888
973
|
*/
|
|
889
|
-
snippetText: string
|
|
974
|
+
snippetText: string;
|
|
890
975
|
}
|
|
891
976
|
interface Metric {
|
|
892
|
-
/**
|
|
893
|
-
* ID of the metric
|
|
894
|
-
*/
|
|
895
|
-
id: string | null;
|
|
896
977
|
/**
|
|
897
978
|
* Boolean value of the metric
|
|
898
979
|
*/
|
|
899
980
|
booleanValue: boolean | null;
|
|
900
981
|
/**
|
|
901
|
-
* Confidence of the metric
|
|
982
|
+
* Confidence level of the metric (0-1)
|
|
902
983
|
*/
|
|
903
984
|
confidence: number | null;
|
|
985
|
+
/**
|
|
986
|
+
* Created at of the metric
|
|
987
|
+
*/
|
|
988
|
+
createdAt: string;
|
|
904
989
|
/**
|
|
905
990
|
* Name of the metric
|
|
906
991
|
*/
|
|
907
|
-
name: string
|
|
992
|
+
name: string;
|
|
908
993
|
/**
|
|
909
994
|
* Numeric value of the metric
|
|
910
995
|
*/
|
|
911
996
|
numericValue: number | null;
|
|
912
997
|
/**
|
|
913
|
-
* Reasoning
|
|
998
|
+
* Reasoning of the metric
|
|
914
999
|
*/
|
|
915
1000
|
reasoning: string | null;
|
|
916
1001
|
/**
|
|
917
1002
|
* Role of the metric
|
|
918
1003
|
*/
|
|
919
|
-
role:
|
|
1004
|
+
role: string;
|
|
920
1005
|
/**
|
|
921
1006
|
* Text value of the metric
|
|
922
1007
|
*/
|
|
@@ -924,7 +1009,7 @@ export declare namespace EvaluationGetJobRunsResponse {
|
|
|
924
1009
|
/**
|
|
925
1010
|
* Value type of the metric
|
|
926
1011
|
*/
|
|
927
|
-
valueType:
|
|
1012
|
+
valueType: string;
|
|
928
1013
|
}
|
|
929
1014
|
}
|
|
930
1015
|
/**
|