@coval/sdk 0.4.3 → 0.4.5
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/generated/apis/MetricsApi.d.ts +4 -4
- package/dist/generated/apis/MetricsApi.js +2 -2
- package/dist/generated/apis/SimulationsApi.d.ts +4 -4
- package/dist/generated/apis/SimulationsApi.js +2 -2
- package/dist/generated/models/CovalAgentsAPICreateAgentRequest.d.ts +4 -10
- package/dist/generated/models/CovalAgentsAPICreateAgentRequest.d.ts.map +1 -1
- package/dist/generated/models/CovalAgentsAPICreateAgentRequest.js.map +1 -1
- package/dist/generated/models/CovalMetricsAPICreateMetricRequest.d.ts +62 -3
- package/dist/generated/models/CovalMetricsAPICreateMetricRequest.d.ts.map +1 -1
- package/dist/generated/models/CovalMetricsAPICreateMetricRequest.js +26 -0
- package/dist/generated/models/CovalMetricsAPICreateMetricRequest.js.map +1 -1
- package/dist/generated/models/CovalMetricsAPIMetricResource.d.ts +51 -3
- package/dist/generated/models/CovalMetricsAPIMetricResource.d.ts.map +1 -1
- package/dist/generated/models/CovalMetricsAPIMetricResource.js +26 -0
- package/dist/generated/models/CovalMetricsAPIMetricResource.js.map +1 -1
- package/dist/generated/models/CovalMetricsAPIMetricType.d.ts +3 -0
- package/dist/generated/models/CovalMetricsAPIMetricType.d.ts.map +1 -1
- package/dist/generated/models/CovalMetricsAPIMetricType.js +4 -1
- package/dist/generated/models/CovalMetricsAPIMetricType.js.map +1 -1
- package/dist/generated/models/CovalMetricsAPITestMetricBatchItemResult.d.ts +52 -0
- package/dist/generated/models/CovalMetricsAPITestMetricBatchItemResult.d.ts.map +1 -0
- package/dist/generated/models/CovalMetricsAPITestMetricBatchItemResult.js +53 -0
- package/dist/generated/models/CovalMetricsAPITestMetricBatchItemResult.js.map +1 -0
- package/dist/generated/models/CovalMetricsAPITestMetricItemStatus.d.ts +34 -0
- package/dist/generated/models/CovalMetricsAPITestMetricItemStatus.d.ts.map +1 -0
- package/dist/generated/models/CovalMetricsAPITestMetricItemStatus.js +52 -0
- package/dist/generated/models/CovalMetricsAPITestMetricItemStatus.js.map +1 -0
- package/dist/generated/models/CovalMetricsAPITestMetricRequest.d.ts +10 -3
- package/dist/generated/models/CovalMetricsAPITestMetricRequest.d.ts.map +1 -1
- package/dist/generated/models/CovalMetricsAPITestMetricRequest.js +3 -3
- package/dist/generated/models/CovalMetricsAPITestMetricRequest.js.map +1 -1
- package/dist/generated/models/CovalMetricsAPITestMetricResponse.d.ts +10 -2
- package/dist/generated/models/CovalMetricsAPITestMetricResponse.d.ts.map +1 -1
- package/dist/generated/models/CovalMetricsAPITestMetricResponse.js +5 -0
- package/dist/generated/models/CovalMetricsAPITestMetricResponse.js.map +1 -1
- package/dist/generated/models/CovalMetricsAPIUpdateMetricRequest.d.ts +51 -1
- package/dist/generated/models/CovalMetricsAPIUpdateMetricRequest.d.ts.map +1 -1
- package/dist/generated/models/CovalMetricsAPIUpdateMetricRequest.js +26 -0
- package/dist/generated/models/CovalMetricsAPIUpdateMetricRequest.js.map +1 -1
- package/dist/generated/models/CovalReviewsAPICreateReviewProjectRequest.d.ts +6 -0
- package/dist/generated/models/CovalReviewsAPICreateReviewProjectRequest.d.ts.map +1 -1
- package/dist/generated/models/CovalReviewsAPICreateReviewProjectRequest.js +2 -0
- package/dist/generated/models/CovalReviewsAPICreateReviewProjectRequest.js.map +1 -1
- package/dist/generated/models/CovalReviewsAPIReviewProjectResource.d.ts +6 -0
- package/dist/generated/models/CovalReviewsAPIReviewProjectResource.d.ts.map +1 -1
- package/dist/generated/models/CovalReviewsAPIReviewProjectResource.js +2 -0
- package/dist/generated/models/CovalReviewsAPIReviewProjectResource.js.map +1 -1
- package/dist/generated/models/CovalReviewsAPIUpdateReviewProjectRequest.d.ts +20 -0
- package/dist/generated/models/CovalReviewsAPIUpdateReviewProjectRequest.d.ts.map +1 -1
- package/dist/generated/models/CovalReviewsAPIUpdateReviewProjectRequest.js +11 -0
- package/dist/generated/models/CovalReviewsAPIUpdateReviewProjectRequest.js.map +1 -1
- package/dist/generated/models/CovalRunsAPIRunResults.d.ts +8 -0
- package/dist/generated/models/CovalRunsAPIRunResults.d.ts.map +1 -1
- package/dist/generated/models/CovalRunsAPIRunResults.js +2 -0
- package/dist/generated/models/CovalRunsAPIRunResults.js.map +1 -1
- package/dist/generated/models/CovalSimulationsAPISimulationResourceFull.d.ts +6 -0
- package/dist/generated/models/CovalSimulationsAPISimulationResourceFull.d.ts.map +1 -1
- package/dist/generated/models/CovalSimulationsAPISimulationResourceFull.js +2 -0
- package/dist/generated/models/CovalSimulationsAPISimulationResourceFull.js.map +1 -1
- package/dist/generated/models/index.d.ts +2 -0
- package/dist/generated/models/index.d.ts.map +1 -1
- package/dist/generated/models/index.js +2 -0
- package/dist/generated/models/index.js.map +1 -1
- package/package.json +1 -1
- package/src/generated/apis/MetricsApi.ts +4 -4
- package/src/generated/apis/SimulationsApi.ts +4 -4
- package/src/generated/models/CovalAgentsAPICreateAgentRequest.ts +4 -10
- package/src/generated/models/CovalMetricsAPICreateMetricRequest.ts +74 -3
- package/src/generated/models/CovalMetricsAPIMetricResource.ts +63 -3
- package/src/generated/models/CovalMetricsAPIMetricType.ts +4 -1
- package/src/generated/models/CovalMetricsAPITestMetricBatchItemResult.ts +101 -0
- package/src/generated/models/CovalMetricsAPITestMetricItemStatus.ts +61 -0
- package/src/generated/models/CovalMetricsAPITestMetricRequest.ts +13 -5
- package/src/generated/models/CovalMetricsAPITestMetricResponse.ts +20 -2
- package/src/generated/models/CovalMetricsAPIUpdateMetricRequest.ts +63 -1
- package/src/generated/models/CovalReviewsAPICreateReviewProjectRequest.ts +8 -0
- package/src/generated/models/CovalReviewsAPIReviewProjectResource.ts +8 -0
- package/src/generated/models/CovalReviewsAPIUpdateReviewProjectRequest.ts +27 -0
- package/src/generated/models/CovalRunsAPIRunResults.ts +8 -0
- package/src/generated/models/CovalSimulationsAPISimulationResourceFull.ts +8 -0
- package/src/generated/models/index.ts +2 -0
|
@@ -131,11 +131,52 @@ export interface CovalMetricsAPICreateMetricRequest {
|
|
|
131
131
|
* @memberof CovalMetricsAPICreateMetricRequest
|
|
132
132
|
*/
|
|
133
133
|
sql_query?: string;
|
|
134
|
+
/**
|
|
135
|
+
* Where the metric reads its criteria from. Required for METRIC_COMPOSITE_EVALUATION.
|
|
136
|
+
* `test_case` reads a field off each test case (most commonly its expected behaviors),
|
|
137
|
+
* `test_case_attribute` reads from the test case's attributes, and `metric_metadata`
|
|
138
|
+
* uses the fixed list in `criteria`.
|
|
139
|
+
*
|
|
140
|
+
* @type {CovalMetricsAPICreateMetricRequestCriteriaSourceEnum}
|
|
141
|
+
* @memberof CovalMetricsAPICreateMetricRequest
|
|
142
|
+
*/
|
|
143
|
+
criteria_source?: CovalMetricsAPICreateMetricRequestCriteriaSourceEnum;
|
|
144
|
+
/**
|
|
145
|
+
* Path to the criteria on the source. Required when `criteria_source` is `test_case`
|
|
146
|
+
* or `test_case_attribute`.
|
|
147
|
+
*
|
|
148
|
+
* @type {string}
|
|
149
|
+
* @memberof CovalMetricsAPICreateMetricRequest
|
|
150
|
+
*/
|
|
151
|
+
criteria_path?: string;
|
|
152
|
+
/**
|
|
153
|
+
* Literal list of criteria. Required when `criteria_source` is `metric_metadata`.
|
|
154
|
+
* @type {Array<string>}
|
|
155
|
+
* @memberof CovalMetricsAPICreateMetricRequest
|
|
156
|
+
*/
|
|
157
|
+
criteria?: Array<string>;
|
|
158
|
+
/**
|
|
159
|
+
* How per-criterion verdicts aggregate into the metric's value. Each criterion is judged
|
|
160
|
+
* independently as met or not met; `percentage_of_criteria_met` scores the fraction met
|
|
161
|
+
* among the criteria the judge could evaluate.
|
|
162
|
+
*
|
|
163
|
+
* @type {CovalMetricsAPICreateMetricRequestReportingMethodEnum}
|
|
164
|
+
* @memberof CovalMetricsAPICreateMetricRequest
|
|
165
|
+
*/
|
|
166
|
+
reporting_method?: CovalMetricsAPICreateMetricRequestReportingMethodEnum;
|
|
167
|
+
/**
|
|
168
|
+
* Custom prompt template used to evaluate each criterion. Include a `{criterion}`
|
|
169
|
+
* placeholder; if it is omitted the criterion is appended to the prompt.
|
|
170
|
+
*
|
|
171
|
+
* @type {string}
|
|
172
|
+
* @memberof CovalMetricsAPICreateMetricRequest
|
|
173
|
+
*/
|
|
174
|
+
base_prompt_template?: string;
|
|
134
175
|
/**
|
|
135
176
|
* Inject OTel trace context into the LLM judge prompt during evaluation.
|
|
136
|
-
* Supported for LLM judge metric types
|
|
137
|
-
* `
|
|
138
|
-
* `METRIC_AUDIO_LLM_NUMERICAL`).
|
|
177
|
+
* Supported for LLM judge metric types and `METRIC_COMPOSITE_EVALUATION` (`METRIC_LLM_BINARY`,
|
|
178
|
+
* `METRIC_CATEGORICAL`, `METRIC_NUMERICAL_LLM_JUDGE`, `METRIC_AUDIO_LLM_BINARY`,
|
|
179
|
+
* `METRIC_AUDIO_LLM_CATEGORICAL`, `METRIC_AUDIO_LLM_NUMERICAL`, `METRIC_COMPOSITE_EVALUATION`).
|
|
139
180
|
*
|
|
140
181
|
* @type {boolean}
|
|
141
182
|
* @memberof CovalMetricsAPICreateMetricRequest
|
|
@@ -176,6 +217,26 @@ export const CovalMetricsAPICreateMetricRequestRoleEnum = {
|
|
|
176
217
|
} as const;
|
|
177
218
|
export type CovalMetricsAPICreateMetricRequestRoleEnum = typeof CovalMetricsAPICreateMetricRequestRoleEnum[keyof typeof CovalMetricsAPICreateMetricRequestRoleEnum];
|
|
178
219
|
|
|
220
|
+
/**
|
|
221
|
+
* @export
|
|
222
|
+
*/
|
|
223
|
+
export const CovalMetricsAPICreateMetricRequestCriteriaSourceEnum = {
|
|
224
|
+
TestCase: 'test_case',
|
|
225
|
+
TestCaseAttribute: 'test_case_attribute',
|
|
226
|
+
MetricMetadata: 'metric_metadata'
|
|
227
|
+
} as const;
|
|
228
|
+
export type CovalMetricsAPICreateMetricRequestCriteriaSourceEnum = typeof CovalMetricsAPICreateMetricRequestCriteriaSourceEnum[keyof typeof CovalMetricsAPICreateMetricRequestCriteriaSourceEnum];
|
|
229
|
+
|
|
230
|
+
/**
|
|
231
|
+
* @export
|
|
232
|
+
*/
|
|
233
|
+
export const CovalMetricsAPICreateMetricRequestReportingMethodEnum = {
|
|
234
|
+
PercentageOfCriteriaMet: 'percentage_of_criteria_met',
|
|
235
|
+
CountOfCriteriaMet: 'count_of_criteria_met',
|
|
236
|
+
AllCriteriaMet: 'all_criteria_met'
|
|
237
|
+
} as const;
|
|
238
|
+
export type CovalMetricsAPICreateMetricRequestReportingMethodEnum = typeof CovalMetricsAPICreateMetricRequestReportingMethodEnum[keyof typeof CovalMetricsAPICreateMetricRequestReportingMethodEnum];
|
|
239
|
+
|
|
179
240
|
|
|
180
241
|
/**
|
|
181
242
|
* Check if a given object implements the CovalMetricsAPICreateMetricRequest interface.
|
|
@@ -210,6 +271,11 @@ export function CovalMetricsAPICreateMetricRequestFromJSONTyped(json: any, ignor
|
|
|
210
271
|
'role': json['role'] == null ? undefined : json['role'],
|
|
211
272
|
'min_pause_duration_seconds': json['min_pause_duration_seconds'] == null ? undefined : json['min_pause_duration_seconds'],
|
|
212
273
|
'sql_query': json['sql_query'] == null ? undefined : json['sql_query'],
|
|
274
|
+
'criteria_source': json['criteria_source'] == null ? undefined : json['criteria_source'],
|
|
275
|
+
'criteria_path': json['criteria_path'] == null ? undefined : json['criteria_path'],
|
|
276
|
+
'criteria': json['criteria'] == null ? undefined : json['criteria'],
|
|
277
|
+
'reporting_method': json['reporting_method'] == null ? undefined : json['reporting_method'],
|
|
278
|
+
'base_prompt_template': json['base_prompt_template'] == null ? undefined : json['base_prompt_template'],
|
|
213
279
|
'include_traces': json['include_traces'] == null ? undefined : json['include_traces'],
|
|
214
280
|
'runtime_config': json['runtime_config'] == null ? undefined : CovalMetricsAPIMetricRuntimeConfigFromJSON(json['runtime_config']),
|
|
215
281
|
'target_condition': json['target_condition'] == null ? undefined : CovalMetricsAPITargetConditionFromJSON(json['target_condition']),
|
|
@@ -241,6 +307,11 @@ export function CovalMetricsAPICreateMetricRequestToJSONTyped(value?: CovalMetri
|
|
|
241
307
|
'role': value['role'],
|
|
242
308
|
'min_pause_duration_seconds': value['min_pause_duration_seconds'],
|
|
243
309
|
'sql_query': value['sql_query'],
|
|
310
|
+
'criteria_source': value['criteria_source'],
|
|
311
|
+
'criteria_path': value['criteria_path'],
|
|
312
|
+
'criteria': value['criteria'],
|
|
313
|
+
'reporting_method': value['reporting_method'],
|
|
314
|
+
'base_prompt_template': value['base_prompt_template'],
|
|
244
315
|
'include_traces': value['include_traces'],
|
|
245
316
|
'runtime_config': CovalMetricsAPIMetricRuntimeConfigToJSON(value['runtime_config']),
|
|
246
317
|
'target_condition': CovalMetricsAPITargetConditionToJSON(value['target_condition']),
|
|
@@ -145,11 +145,41 @@ export interface CovalMetricsAPIMetricResource {
|
|
|
145
145
|
* @memberof CovalMetricsAPIMetricResource
|
|
146
146
|
*/
|
|
147
147
|
sql_query?: string | null;
|
|
148
|
+
/**
|
|
149
|
+
* Where a METRIC_COMPOSITE_EVALUATION metric reads its criteria from.
|
|
150
|
+
* @type {CovalMetricsAPIMetricResourceCriteriaSourceEnum}
|
|
151
|
+
* @memberof CovalMetricsAPIMetricResource
|
|
152
|
+
*/
|
|
153
|
+
criteria_source?: CovalMetricsAPIMetricResourceCriteriaSourceEnum | null;
|
|
154
|
+
/**
|
|
155
|
+
* Path to the criteria on the source, when `criteria_source` is `test_case` or `test_case_attribute`.
|
|
156
|
+
* @type {string}
|
|
157
|
+
* @memberof CovalMetricsAPIMetricResource
|
|
158
|
+
*/
|
|
159
|
+
criteria_path?: string | null;
|
|
160
|
+
/**
|
|
161
|
+
* Literal criteria, when `criteria_source` is `metric_metadata`.
|
|
162
|
+
* @type {Array<string>}
|
|
163
|
+
* @memberof CovalMetricsAPIMetricResource
|
|
164
|
+
*/
|
|
165
|
+
criteria?: Array<string> | null;
|
|
166
|
+
/**
|
|
167
|
+
* How the per-criterion verdicts are aggregated into the metric's value.
|
|
168
|
+
* @type {CovalMetricsAPIMetricResourceReportingMethodEnum}
|
|
169
|
+
* @memberof CovalMetricsAPIMetricResource
|
|
170
|
+
*/
|
|
171
|
+
reporting_method?: CovalMetricsAPIMetricResourceReportingMethodEnum | null;
|
|
172
|
+
/**
|
|
173
|
+
* Custom prompt template used to evaluate each criterion.
|
|
174
|
+
* @type {string}
|
|
175
|
+
* @memberof CovalMetricsAPIMetricResource
|
|
176
|
+
*/
|
|
177
|
+
base_prompt_template?: string | null;
|
|
148
178
|
/**
|
|
149
179
|
* Whether OTel trace context is injected into the LLM judge prompt during evaluation.
|
|
150
|
-
* Supported for LLM judge metric types
|
|
151
|
-
* `
|
|
152
|
-
* `METRIC_AUDIO_LLM_NUMERICAL`).
|
|
180
|
+
* Supported for LLM judge metric types and `METRIC_COMPOSITE_EVALUATION` (`METRIC_LLM_BINARY`,
|
|
181
|
+
* `METRIC_CATEGORICAL`, `METRIC_NUMERICAL_LLM_JUDGE`, `METRIC_AUDIO_LLM_BINARY`,
|
|
182
|
+
* `METRIC_AUDIO_LLM_CATEGORICAL`, `METRIC_AUDIO_LLM_NUMERICAL`, `METRIC_COMPOSITE_EVALUATION`).
|
|
153
183
|
*
|
|
154
184
|
* @type {boolean}
|
|
155
185
|
* @memberof CovalMetricsAPIMetricResource
|
|
@@ -213,6 +243,26 @@ export const CovalMetricsAPIMetricResourceRoleEnum = {
|
|
|
213
243
|
} as const;
|
|
214
244
|
export type CovalMetricsAPIMetricResourceRoleEnum = typeof CovalMetricsAPIMetricResourceRoleEnum[keyof typeof CovalMetricsAPIMetricResourceRoleEnum];
|
|
215
245
|
|
|
246
|
+
/**
|
|
247
|
+
* @export
|
|
248
|
+
*/
|
|
249
|
+
export const CovalMetricsAPIMetricResourceCriteriaSourceEnum = {
|
|
250
|
+
TestCase: 'test_case',
|
|
251
|
+
TestCaseAttribute: 'test_case_attribute',
|
|
252
|
+
MetricMetadata: 'metric_metadata'
|
|
253
|
+
} as const;
|
|
254
|
+
export type CovalMetricsAPIMetricResourceCriteriaSourceEnum = typeof CovalMetricsAPIMetricResourceCriteriaSourceEnum[keyof typeof CovalMetricsAPIMetricResourceCriteriaSourceEnum];
|
|
255
|
+
|
|
256
|
+
/**
|
|
257
|
+
* @export
|
|
258
|
+
*/
|
|
259
|
+
export const CovalMetricsAPIMetricResourceReportingMethodEnum = {
|
|
260
|
+
PercentageOfCriteriaMet: 'percentage_of_criteria_met',
|
|
261
|
+
CountOfCriteriaMet: 'count_of_criteria_met',
|
|
262
|
+
AllCriteriaMet: 'all_criteria_met'
|
|
263
|
+
} as const;
|
|
264
|
+
export type CovalMetricsAPIMetricResourceReportingMethodEnum = typeof CovalMetricsAPIMetricResourceReportingMethodEnum[keyof typeof CovalMetricsAPIMetricResourceReportingMethodEnum];
|
|
265
|
+
|
|
216
266
|
|
|
217
267
|
/**
|
|
218
268
|
* Check if a given object implements the CovalMetricsAPIMetricResource interface.
|
|
@@ -246,6 +296,11 @@ export function CovalMetricsAPIMetricResourceFromJSONTyped(json: any, ignoreDisc
|
|
|
246
296
|
'role': json['role'] == null ? undefined : json['role'],
|
|
247
297
|
'min_pause_duration_seconds': json['min_pause_duration_seconds'] == null ? undefined : json['min_pause_duration_seconds'],
|
|
248
298
|
'sql_query': json['sql_query'] == null ? undefined : json['sql_query'],
|
|
299
|
+
'criteria_source': json['criteria_source'] == null ? undefined : json['criteria_source'],
|
|
300
|
+
'criteria_path': json['criteria_path'] == null ? undefined : json['criteria_path'],
|
|
301
|
+
'criteria': json['criteria'] == null ? undefined : json['criteria'],
|
|
302
|
+
'reporting_method': json['reporting_method'] == null ? undefined : json['reporting_method'],
|
|
303
|
+
'base_prompt_template': json['base_prompt_template'] == null ? undefined : json['base_prompt_template'],
|
|
249
304
|
'include_traces': json['include_traces'] == null ? undefined : json['include_traces'],
|
|
250
305
|
'runtime_config': json['runtime_config'] == null ? undefined : CovalMetricsAPIMetricRuntimeConfigFromJSON(json['runtime_config']),
|
|
251
306
|
'target_condition': json['target_condition'] == null ? undefined : CovalMetricsAPITargetConditionFromJSON(json['target_condition']),
|
|
@@ -283,6 +338,11 @@ export function CovalMetricsAPIMetricResourceToJSONTyped(value?: CovalMetricsAPI
|
|
|
283
338
|
'role': value['role'],
|
|
284
339
|
'min_pause_duration_seconds': value['min_pause_duration_seconds'],
|
|
285
340
|
'sql_query': value['sql_query'],
|
|
341
|
+
'criteria_source': value['criteria_source'],
|
|
342
|
+
'criteria_path': value['criteria_path'],
|
|
343
|
+
'criteria': value['criteria'],
|
|
344
|
+
'reporting_method': value['reporting_method'],
|
|
345
|
+
'base_prompt_template': value['base_prompt_template'],
|
|
286
346
|
'include_traces': value['include_traces'],
|
|
287
347
|
'runtime_config': CovalMetricsAPIMetricRuntimeConfigToJSON(value['runtime_config']),
|
|
288
348
|
'target_condition': CovalMetricsAPITargetConditionToJSON(value['target_condition']),
|
|
@@ -27,6 +27,8 @@
|
|
|
27
27
|
* - `METRIC_TRANSCRIPT_REGEX` - Regex pattern matching
|
|
28
28
|
* - `METRIC_PAUSE_ANALYSIS` - Speech pause detection
|
|
29
29
|
* - `METRIC_SQL_FLOAT` - Custom SQL query over the simulation's data (set `sql_query`)
|
|
30
|
+
* - `METRIC_COMPOSITE_EVALUATION` - Judges a list of criteria independently and reports how
|
|
31
|
+
* many were met (set `criteria_source`, and `criteria_path` or `criteria` to match)
|
|
30
32
|
*
|
|
31
33
|
* @export
|
|
32
34
|
*/
|
|
@@ -41,7 +43,8 @@ export const CovalMetricsAPIMetricType = {
|
|
|
41
43
|
MetricMetadataField: 'METRIC_METADATA_FIELD',
|
|
42
44
|
MetricTranscriptRegex: 'METRIC_TRANSCRIPT_REGEX',
|
|
43
45
|
MetricPauseAnalysis: 'METRIC_PAUSE_ANALYSIS',
|
|
44
|
-
MetricSqlFloat: 'METRIC_SQL_FLOAT'
|
|
46
|
+
MetricSqlFloat: 'METRIC_SQL_FLOAT',
|
|
47
|
+
MetricCompositeEvaluation: 'METRIC_COMPOSITE_EVALUATION'
|
|
45
48
|
} as const;
|
|
46
49
|
export type CovalMetricsAPIMetricType = typeof CovalMetricsAPIMetricType[keyof typeof CovalMetricsAPIMetricType];
|
|
47
50
|
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Coval Agents API
|
|
5
|
+
* Manage configurations for simulations and evaluations.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
* Contact: support@coval.dev
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime.js';
|
|
16
|
+
import type { CovalMetricsAPITestMetricItemStatus } from './CovalMetricsAPITestMetricItemStatus.js';
|
|
17
|
+
import {
|
|
18
|
+
CovalMetricsAPITestMetricItemStatusFromJSON,
|
|
19
|
+
CovalMetricsAPITestMetricItemStatusFromJSONTyped,
|
|
20
|
+
CovalMetricsAPITestMetricItemStatusToJSON,
|
|
21
|
+
CovalMetricsAPITestMetricItemStatusToJSONTyped,
|
|
22
|
+
} from './CovalMetricsAPITestMetricItemStatus.js';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Result for one simulation output in a test-metric request.
|
|
26
|
+
* @export
|
|
27
|
+
* @interface CovalMetricsAPITestMetricBatchItemResult
|
|
28
|
+
*/
|
|
29
|
+
export interface CovalMetricsAPITestMetricBatchItemResult {
|
|
30
|
+
/**
|
|
31
|
+
* The simulation output ID this result applies to.
|
|
32
|
+
* @type {string}
|
|
33
|
+
* @memberof CovalMetricsAPITestMetricBatchItemResult
|
|
34
|
+
*/
|
|
35
|
+
simulation_output_id: string;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {CovalMetricsAPITestMetricItemStatus}
|
|
39
|
+
* @memberof CovalMetricsAPITestMetricBatchItemResult
|
|
40
|
+
*/
|
|
41
|
+
status: CovalMetricsAPITestMetricItemStatus;
|
|
42
|
+
/**
|
|
43
|
+
* ULID of the created metric output, used to poll for the result. Null unless `status` is `QUEUED`.
|
|
44
|
+
* @type {string}
|
|
45
|
+
* @memberof CovalMetricsAPITestMetricBatchItemResult
|
|
46
|
+
*/
|
|
47
|
+
metric_output_ulid?: string | null;
|
|
48
|
+
/**
|
|
49
|
+
* Human-readable error detail when the item was not queued.
|
|
50
|
+
* @type {string}
|
|
51
|
+
* @memberof CovalMetricsAPITestMetricBatchItemResult
|
|
52
|
+
*/
|
|
53
|
+
error?: string | null;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* Check if a given object implements the CovalMetricsAPITestMetricBatchItemResult interface.
|
|
60
|
+
*/
|
|
61
|
+
export function instanceOfCovalMetricsAPITestMetricBatchItemResult(value: object): value is CovalMetricsAPITestMetricBatchItemResult {
|
|
62
|
+
if (!('simulation_output_id' in value) || value['simulation_output_id'] === undefined) return false;
|
|
63
|
+
if (!('status' in value) || value['status'] === undefined) return false;
|
|
64
|
+
return true;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export function CovalMetricsAPITestMetricBatchItemResultFromJSON(json: any): CovalMetricsAPITestMetricBatchItemResult {
|
|
68
|
+
return CovalMetricsAPITestMetricBatchItemResultFromJSONTyped(json, false);
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
export function CovalMetricsAPITestMetricBatchItemResultFromJSONTyped(json: any, ignoreDiscriminator: boolean): CovalMetricsAPITestMetricBatchItemResult {
|
|
72
|
+
if (json == null) {
|
|
73
|
+
return json;
|
|
74
|
+
}
|
|
75
|
+
return {
|
|
76
|
+
|
|
77
|
+
'simulation_output_id': json['simulation_output_id'],
|
|
78
|
+
'status': CovalMetricsAPITestMetricItemStatusFromJSON(json['status']),
|
|
79
|
+
'metric_output_ulid': json['metric_output_ulid'] == null ? undefined : json['metric_output_ulid'],
|
|
80
|
+
'error': json['error'] == null ? undefined : json['error'],
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export function CovalMetricsAPITestMetricBatchItemResultToJSON(json: any): CovalMetricsAPITestMetricBatchItemResult {
|
|
85
|
+
return CovalMetricsAPITestMetricBatchItemResultToJSONTyped(json, false);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
export function CovalMetricsAPITestMetricBatchItemResultToJSONTyped(value?: CovalMetricsAPITestMetricBatchItemResult | null, ignoreDiscriminator: boolean = false): any {
|
|
89
|
+
if (value == null) {
|
|
90
|
+
return value;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
return {
|
|
94
|
+
|
|
95
|
+
'simulation_output_id': value['simulation_output_id'],
|
|
96
|
+
'status': CovalMetricsAPITestMetricItemStatusToJSON(value['status']),
|
|
97
|
+
'metric_output_ulid': value['metric_output_ulid'],
|
|
98
|
+
'error': value['error'],
|
|
99
|
+
};
|
|
100
|
+
}
|
|
101
|
+
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Coval Agents API
|
|
5
|
+
* Manage configurations for simulations and evaluations.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
* Contact: support@coval.dev
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Per-simulation-output outcome of a test-metric request.
|
|
18
|
+
*
|
|
19
|
+
* - `QUEUED` - Metric execution queued successfully
|
|
20
|
+
* - `NOT_FOUND` - Simulation output not found
|
|
21
|
+
* - `FORBIDDEN` - Access to the simulation output denied
|
|
22
|
+
* - `ENQUEUE_FAILED` - Failed to enqueue the metric execution
|
|
23
|
+
*
|
|
24
|
+
* @export
|
|
25
|
+
*/
|
|
26
|
+
export const CovalMetricsAPITestMetricItemStatus = {
|
|
27
|
+
Queued: 'QUEUED',
|
|
28
|
+
NotFound: 'NOT_FOUND',
|
|
29
|
+
Forbidden: 'FORBIDDEN',
|
|
30
|
+
EnqueueFailed: 'ENQUEUE_FAILED'
|
|
31
|
+
} as const;
|
|
32
|
+
export type CovalMetricsAPITestMetricItemStatus = typeof CovalMetricsAPITestMetricItemStatus[keyof typeof CovalMetricsAPITestMetricItemStatus];
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
export function instanceOfCovalMetricsAPITestMetricItemStatus(value: any): boolean {
|
|
36
|
+
for (const key in CovalMetricsAPITestMetricItemStatus) {
|
|
37
|
+
if (Object.prototype.hasOwnProperty.call(CovalMetricsAPITestMetricItemStatus, key)) {
|
|
38
|
+
if (CovalMetricsAPITestMetricItemStatus[key as keyof typeof CovalMetricsAPITestMetricItemStatus] === value) {
|
|
39
|
+
return true;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
return false;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
export function CovalMetricsAPITestMetricItemStatusFromJSON(json: any): CovalMetricsAPITestMetricItemStatus {
|
|
47
|
+
return CovalMetricsAPITestMetricItemStatusFromJSONTyped(json, false);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export function CovalMetricsAPITestMetricItemStatusFromJSONTyped(json: any, ignoreDiscriminator: boolean): CovalMetricsAPITestMetricItemStatus {
|
|
51
|
+
return json as CovalMetricsAPITestMetricItemStatus;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export function CovalMetricsAPITestMetricItemStatusToJSON(value?: CovalMetricsAPITestMetricItemStatus | null): any {
|
|
55
|
+
return value as any;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export function CovalMetricsAPITestMetricItemStatusToJSONTyped(value: any, ignoreDiscriminator: boolean): CovalMetricsAPITestMetricItemStatus {
|
|
59
|
+
return value as CovalMetricsAPITestMetricItemStatus;
|
|
60
|
+
}
|
|
61
|
+
|
|
@@ -14,17 +14,24 @@
|
|
|
14
14
|
|
|
15
15
|
import { mapValues } from '../runtime.js';
|
|
16
16
|
/**
|
|
17
|
-
*
|
|
17
|
+
* Provide exactly one of `simulation_output_id` or `simulation_output_ids`.
|
|
18
18
|
* @export
|
|
19
19
|
* @interface CovalMetricsAPITestMetricRequest
|
|
20
20
|
*/
|
|
21
21
|
export interface CovalMetricsAPITestMetricRequest {
|
|
22
22
|
/**
|
|
23
|
-
*
|
|
23
|
+
* Deprecated: a single simulation output ID (22-character ShortUUID) to run the metric against. Prefer `simulation_output_ids`.
|
|
24
24
|
* @type {string}
|
|
25
25
|
* @memberof CovalMetricsAPITestMetricRequest
|
|
26
|
+
* @deprecated
|
|
26
27
|
*/
|
|
27
|
-
simulation_output_id
|
|
28
|
+
simulation_output_id?: string;
|
|
29
|
+
/**
|
|
30
|
+
* Simulation output IDs (22-character ShortUUIDs) to run the metric against; 1–100 per call.
|
|
31
|
+
* @type {Array<string>}
|
|
32
|
+
* @memberof CovalMetricsAPITestMetricRequest
|
|
33
|
+
*/
|
|
34
|
+
simulation_output_ids?: Array<string>;
|
|
28
35
|
/**
|
|
29
36
|
* Optional developer identifier for debugging
|
|
30
37
|
* @type {string}
|
|
@@ -37,7 +44,6 @@ export interface CovalMetricsAPITestMetricRequest {
|
|
|
37
44
|
* Check if a given object implements the CovalMetricsAPITestMetricRequest interface.
|
|
38
45
|
*/
|
|
39
46
|
export function instanceOfCovalMetricsAPITestMetricRequest(value: object): value is CovalMetricsAPITestMetricRequest {
|
|
40
|
-
if (!('simulation_output_id' in value) || value['simulation_output_id'] === undefined) return false;
|
|
41
47
|
return true;
|
|
42
48
|
}
|
|
43
49
|
|
|
@@ -51,7 +57,8 @@ export function CovalMetricsAPITestMetricRequestFromJSONTyped(json: any, ignoreD
|
|
|
51
57
|
}
|
|
52
58
|
return {
|
|
53
59
|
|
|
54
|
-
'simulation_output_id': json['simulation_output_id'],
|
|
60
|
+
'simulation_output_id': json['simulation_output_id'] == null ? undefined : json['simulation_output_id'],
|
|
61
|
+
'simulation_output_ids': json['simulation_output_ids'] == null ? undefined : json['simulation_output_ids'],
|
|
55
62
|
'dev_id': json['dev_id'] == null ? undefined : json['dev_id'],
|
|
56
63
|
};
|
|
57
64
|
}
|
|
@@ -68,6 +75,7 @@ export function CovalMetricsAPITestMetricRequestToJSONTyped(value?: CovalMetrics
|
|
|
68
75
|
return {
|
|
69
76
|
|
|
70
77
|
'simulation_output_id': value['simulation_output_id'],
|
|
78
|
+
'simulation_output_ids': value['simulation_output_ids'],
|
|
71
79
|
'dev_id': value['dev_id'],
|
|
72
80
|
};
|
|
73
81
|
}
|
|
@@ -13,6 +13,14 @@
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
import { mapValues } from '../runtime.js';
|
|
16
|
+
import type { CovalMetricsAPITestMetricBatchItemResult } from './CovalMetricsAPITestMetricBatchItemResult.js';
|
|
17
|
+
import {
|
|
18
|
+
CovalMetricsAPITestMetricBatchItemResultFromJSON,
|
|
19
|
+
CovalMetricsAPITestMetricBatchItemResultFromJSONTyped,
|
|
20
|
+
CovalMetricsAPITestMetricBatchItemResultToJSON,
|
|
21
|
+
CovalMetricsAPITestMetricBatchItemResultToJSONTyped,
|
|
22
|
+
} from './CovalMetricsAPITestMetricBatchItemResult.js';
|
|
23
|
+
|
|
16
24
|
/**
|
|
17
25
|
*
|
|
18
26
|
* @export
|
|
@@ -20,17 +28,25 @@ import { mapValues } from '../runtime.js';
|
|
|
20
28
|
*/
|
|
21
29
|
export interface CovalMetricsAPITestMetricResponse {
|
|
22
30
|
/**
|
|
23
|
-
*
|
|
31
|
+
* One entry per requested simulation output.
|
|
32
|
+
* @type {Array<CovalMetricsAPITestMetricBatchItemResult>}
|
|
33
|
+
* @memberof CovalMetricsAPITestMetricResponse
|
|
34
|
+
*/
|
|
35
|
+
results: Array<CovalMetricsAPITestMetricBatchItemResult>;
|
|
36
|
+
/**
|
|
37
|
+
* Deprecated: the ULID of the created metric output, used to track the result. Only set for single `simulation_output_id` requests; null for batch (`simulation_output_ids`) requests, which should read `results` instead.
|
|
24
38
|
* @type {string}
|
|
25
39
|
* @memberof CovalMetricsAPITestMetricResponse
|
|
40
|
+
* @deprecated
|
|
26
41
|
*/
|
|
27
|
-
metric_output_ulid?: string;
|
|
42
|
+
metric_output_ulid?: string | null;
|
|
28
43
|
}
|
|
29
44
|
|
|
30
45
|
/**
|
|
31
46
|
* Check if a given object implements the CovalMetricsAPITestMetricResponse interface.
|
|
32
47
|
*/
|
|
33
48
|
export function instanceOfCovalMetricsAPITestMetricResponse(value: object): value is CovalMetricsAPITestMetricResponse {
|
|
49
|
+
if (!('results' in value) || value['results'] === undefined) return false;
|
|
34
50
|
return true;
|
|
35
51
|
}
|
|
36
52
|
|
|
@@ -44,6 +60,7 @@ export function CovalMetricsAPITestMetricResponseFromJSONTyped(json: any, ignore
|
|
|
44
60
|
}
|
|
45
61
|
return {
|
|
46
62
|
|
|
63
|
+
'results': ((json['results'] as Array<any>).map(CovalMetricsAPITestMetricBatchItemResultFromJSON)),
|
|
47
64
|
'metric_output_ulid': json['metric_output_ulid'] == null ? undefined : json['metric_output_ulid'],
|
|
48
65
|
};
|
|
49
66
|
}
|
|
@@ -59,6 +76,7 @@ export function CovalMetricsAPITestMetricResponseToJSONTyped(value?: CovalMetric
|
|
|
59
76
|
|
|
60
77
|
return {
|
|
61
78
|
|
|
79
|
+
'results': ((value['results'] as Array<any>).map(CovalMetricsAPITestMetricBatchItemResultToJSON)),
|
|
62
80
|
'metric_output_ulid': value['metric_output_ulid'],
|
|
63
81
|
};
|
|
64
82
|
}
|
|
@@ -126,9 +126,41 @@ export interface CovalMetricsAPIUpdateMetricRequest {
|
|
|
126
126
|
* @memberof CovalMetricsAPIUpdateMetricRequest
|
|
127
127
|
*/
|
|
128
128
|
sql_query?: string;
|
|
129
|
+
/**
|
|
130
|
+
* Where a METRIC_COMPOSITE_EVALUATION metric reads its criteria from.
|
|
131
|
+
* @type {CovalMetricsAPIUpdateMetricRequestCriteriaSourceEnum}
|
|
132
|
+
* @memberof CovalMetricsAPIUpdateMetricRequest
|
|
133
|
+
*/
|
|
134
|
+
criteria_source?: CovalMetricsAPIUpdateMetricRequestCriteriaSourceEnum;
|
|
135
|
+
/**
|
|
136
|
+
* Path to the criteria on the source, when `criteria_source` is `test_case`
|
|
137
|
+
* or `test_case_attribute`.
|
|
138
|
+
*
|
|
139
|
+
* @type {string}
|
|
140
|
+
* @memberof CovalMetricsAPIUpdateMetricRequest
|
|
141
|
+
*/
|
|
142
|
+
criteria_path?: string;
|
|
143
|
+
/**
|
|
144
|
+
* Literal list of criteria, when `criteria_source` is `metric_metadata`.
|
|
145
|
+
* @type {Array<string>}
|
|
146
|
+
* @memberof CovalMetricsAPIUpdateMetricRequest
|
|
147
|
+
*/
|
|
148
|
+
criteria?: Array<string>;
|
|
149
|
+
/**
|
|
150
|
+
* How per-criterion verdicts aggregate into the metric's value.
|
|
151
|
+
* @type {CovalMetricsAPIUpdateMetricRequestReportingMethodEnum}
|
|
152
|
+
* @memberof CovalMetricsAPIUpdateMetricRequest
|
|
153
|
+
*/
|
|
154
|
+
reporting_method?: CovalMetricsAPIUpdateMetricRequestReportingMethodEnum;
|
|
155
|
+
/**
|
|
156
|
+
* Custom prompt template used to evaluate each criterion.
|
|
157
|
+
* @type {string}
|
|
158
|
+
* @memberof CovalMetricsAPIUpdateMetricRequest
|
|
159
|
+
*/
|
|
160
|
+
base_prompt_template?: string;
|
|
129
161
|
/**
|
|
130
162
|
* Inject OTel trace context into the LLM judge prompt during evaluation.
|
|
131
|
-
* Supported for LLM judge metric types
|
|
163
|
+
* Supported for LLM judge metric types and `METRIC_COMPOSITE_EVALUATION`.
|
|
132
164
|
*
|
|
133
165
|
* @type {boolean}
|
|
134
166
|
* @memberof CovalMetricsAPIUpdateMetricRequest
|
|
@@ -169,6 +201,26 @@ export const CovalMetricsAPIUpdateMetricRequestRoleEnum = {
|
|
|
169
201
|
} as const;
|
|
170
202
|
export type CovalMetricsAPIUpdateMetricRequestRoleEnum = typeof CovalMetricsAPIUpdateMetricRequestRoleEnum[keyof typeof CovalMetricsAPIUpdateMetricRequestRoleEnum];
|
|
171
203
|
|
|
204
|
+
/**
|
|
205
|
+
* @export
|
|
206
|
+
*/
|
|
207
|
+
export const CovalMetricsAPIUpdateMetricRequestCriteriaSourceEnum = {
|
|
208
|
+
TestCase: 'test_case',
|
|
209
|
+
TestCaseAttribute: 'test_case_attribute',
|
|
210
|
+
MetricMetadata: 'metric_metadata'
|
|
211
|
+
} as const;
|
|
212
|
+
export type CovalMetricsAPIUpdateMetricRequestCriteriaSourceEnum = typeof CovalMetricsAPIUpdateMetricRequestCriteriaSourceEnum[keyof typeof CovalMetricsAPIUpdateMetricRequestCriteriaSourceEnum];
|
|
213
|
+
|
|
214
|
+
/**
|
|
215
|
+
* @export
|
|
216
|
+
*/
|
|
217
|
+
export const CovalMetricsAPIUpdateMetricRequestReportingMethodEnum = {
|
|
218
|
+
PercentageOfCriteriaMet: 'percentage_of_criteria_met',
|
|
219
|
+
CountOfCriteriaMet: 'count_of_criteria_met',
|
|
220
|
+
AllCriteriaMet: 'all_criteria_met'
|
|
221
|
+
} as const;
|
|
222
|
+
export type CovalMetricsAPIUpdateMetricRequestReportingMethodEnum = typeof CovalMetricsAPIUpdateMetricRequestReportingMethodEnum[keyof typeof CovalMetricsAPIUpdateMetricRequestReportingMethodEnum];
|
|
223
|
+
|
|
172
224
|
|
|
173
225
|
/**
|
|
174
226
|
* Check if a given object implements the CovalMetricsAPIUpdateMetricRequest interface.
|
|
@@ -200,6 +252,11 @@ export function CovalMetricsAPIUpdateMetricRequestFromJSONTyped(json: any, ignor
|
|
|
200
252
|
'role': json['role'] == null ? undefined : json['role'],
|
|
201
253
|
'min_pause_duration_seconds': json['min_pause_duration_seconds'] == null ? undefined : json['min_pause_duration_seconds'],
|
|
202
254
|
'sql_query': json['sql_query'] == null ? undefined : json['sql_query'],
|
|
255
|
+
'criteria_source': json['criteria_source'] == null ? undefined : json['criteria_source'],
|
|
256
|
+
'criteria_path': json['criteria_path'] == null ? undefined : json['criteria_path'],
|
|
257
|
+
'criteria': json['criteria'] == null ? undefined : json['criteria'],
|
|
258
|
+
'reporting_method': json['reporting_method'] == null ? undefined : json['reporting_method'],
|
|
259
|
+
'base_prompt_template': json['base_prompt_template'] == null ? undefined : json['base_prompt_template'],
|
|
203
260
|
'include_traces': json['include_traces'] == null ? undefined : json['include_traces'],
|
|
204
261
|
'runtime_config': json['runtime_config'] == null ? undefined : CovalMetricsAPIMetricRuntimeConfigFromJSON(json['runtime_config']),
|
|
205
262
|
'target_condition': json['target_condition'] == null ? undefined : CovalMetricsAPITargetConditionFromJSON(json['target_condition']),
|
|
@@ -231,6 +288,11 @@ export function CovalMetricsAPIUpdateMetricRequestToJSONTyped(value?: CovalMetri
|
|
|
231
288
|
'role': value['role'],
|
|
232
289
|
'min_pause_duration_seconds': value['min_pause_duration_seconds'],
|
|
233
290
|
'sql_query': value['sql_query'],
|
|
291
|
+
'criteria_source': value['criteria_source'],
|
|
292
|
+
'criteria_path': value['criteria_path'],
|
|
293
|
+
'criteria': value['criteria'],
|
|
294
|
+
'reporting_method': value['reporting_method'],
|
|
295
|
+
'base_prompt_template': value['base_prompt_template'],
|
|
234
296
|
'include_traces': value['include_traces'],
|
|
235
297
|
'runtime_config': CovalMetricsAPIMetricRuntimeConfigToJSON(value['runtime_config']),
|
|
236
298
|
'target_condition': CovalMetricsAPITargetConditionToJSON(value['target_condition']),
|
|
@@ -88,6 +88,12 @@ export interface CovalReviewsAPICreateReviewProjectRequest {
|
|
|
88
88
|
* @memberof CovalReviewsAPICreateReviewProjectRequest
|
|
89
89
|
*/
|
|
90
90
|
blind_labeling_shown_metric_ids?: Array<string> | null;
|
|
91
|
+
/**
|
|
92
|
+
* Enforce claims and explicit single-author completion for collaborative projects
|
|
93
|
+
* @type {boolean}
|
|
94
|
+
* @memberof CovalReviewsAPICreateReviewProjectRequest
|
|
95
|
+
*/
|
|
96
|
+
enforced_collaboration?: boolean;
|
|
91
97
|
}
|
|
92
98
|
|
|
93
99
|
|
|
@@ -122,6 +128,7 @@ export function CovalReviewsAPICreateReviewProjectRequestFromJSONTyped(json: any
|
|
|
122
128
|
'notifications': json['notifications'] == null ? undefined : json['notifications'],
|
|
123
129
|
'project_rules': json['project_rules'] == null ? undefined : ((json['project_rules'] as Array<any>).map(CovalReviewsAPIProjectRuleFromJSON)),
|
|
124
130
|
'blind_labeling_shown_metric_ids': json['blind_labeling_shown_metric_ids'] == null ? undefined : json['blind_labeling_shown_metric_ids'],
|
|
131
|
+
'enforced_collaboration': json['enforced_collaboration'] == null ? undefined : json['enforced_collaboration'],
|
|
125
132
|
};
|
|
126
133
|
}
|
|
127
134
|
|
|
@@ -145,6 +152,7 @@ export function CovalReviewsAPICreateReviewProjectRequestToJSONTyped(value?: Cov
|
|
|
145
152
|
'notifications': value['notifications'],
|
|
146
153
|
'project_rules': value['project_rules'] == null ? undefined : ((value['project_rules'] as Array<any>).map(CovalReviewsAPIProjectRuleToJSON)),
|
|
147
154
|
'blind_labeling_shown_metric_ids': value['blind_labeling_shown_metric_ids'],
|
|
155
|
+
'enforced_collaboration': value['enforced_collaboration'],
|
|
148
156
|
};
|
|
149
157
|
}
|
|
150
158
|
|
|
@@ -94,6 +94,12 @@ export interface CovalReviewsAPIReviewProjectResource {
|
|
|
94
94
|
* @memberof CovalReviewsAPIReviewProjectResource
|
|
95
95
|
*/
|
|
96
96
|
project_rules?: Array<CovalReviewsAPIProjectRule> | null;
|
|
97
|
+
/**
|
|
98
|
+
* Whether collaborative claims and explicit single-author completion are enforced
|
|
99
|
+
* @type {boolean}
|
|
100
|
+
* @memberof CovalReviewsAPIReviewProjectResource
|
|
101
|
+
*/
|
|
102
|
+
enforced_collaboration?: boolean;
|
|
97
103
|
/**
|
|
98
104
|
* Creation timestamp (ISO 8601)
|
|
99
105
|
* @type {Date}
|
|
@@ -147,6 +153,7 @@ export function CovalReviewsAPIReviewProjectResourceFromJSONTyped(json: any, ign
|
|
|
147
153
|
'project_type': CovalReviewsAPIProjectTypeFromJSON(json['project_type']),
|
|
148
154
|
'notifications': json['notifications'],
|
|
149
155
|
'project_rules': json['project_rules'] == null ? undefined : ((json['project_rules'] as Array<any>).map(CovalReviewsAPIProjectRuleFromJSON)),
|
|
156
|
+
'enforced_collaboration': json['enforced_collaboration'] == null ? undefined : json['enforced_collaboration'],
|
|
150
157
|
'create_time': (new Date(json['create_time'])),
|
|
151
158
|
'update_time': (new Date(json['update_time'])),
|
|
152
159
|
};
|
|
@@ -173,6 +180,7 @@ export function CovalReviewsAPIReviewProjectResourceToJSONTyped(value?: CovalRev
|
|
|
173
180
|
'project_type': CovalReviewsAPIProjectTypeToJSON(value['project_type']),
|
|
174
181
|
'notifications': value['notifications'],
|
|
175
182
|
'project_rules': value['project_rules'] == null ? undefined : ((value['project_rules'] as Array<any>).map(CovalReviewsAPIProjectRuleToJSON)),
|
|
183
|
+
'enforced_collaboration': value['enforced_collaboration'],
|
|
176
184
|
'create_time': value['create_time'].toISOString(),
|
|
177
185
|
'update_time': value['update_time'].toISOString(),
|
|
178
186
|
};
|