openlayer 0.11.0 → 0.13.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 +95 -0
- package/README.md +67 -77
- package/_shims/index.d.ts +2 -0
- package/_shims/index.js +5 -1
- package/_shims/index.mjs +5 -1
- package/core.d.ts +17 -3
- package/core.d.ts.map +1 -1
- package/core.js +32 -18
- package/core.js.map +1 -1
- package/core.mjs +33 -19
- package/core.mjs.map +1 -1
- package/index.d.mts +8 -5
- package/index.d.ts +8 -5
- package/index.d.ts.map +1 -1
- package/index.js +6 -2
- package/index.js.map +1 -1
- package/index.mjs +6 -2
- package/index.mjs.map +1 -1
- package/package.json +1 -1
- package/resource.d.ts +1 -1
- package/resource.d.ts.map +1 -1
- package/resource.js.map +1 -1
- package/resource.mjs.map +1 -1
- package/resources/commits/test-results.d.ts +24 -6
- package/resources/commits/test-results.d.ts.map +1 -1
- package/resources/commits.d.ts +2 -0
- package/resources/commits.d.ts.map +1 -0
- package/resources/commits.js +19 -0
- package/resources/commits.js.map +1 -0
- package/resources/commits.mjs +3 -0
- package/resources/commits.mjs.map +1 -0
- package/resources/inference-pipelines/data.d.ts +23 -1
- package/resources/inference-pipelines/data.d.ts.map +1 -1
- package/resources/inference-pipelines/data.js +20 -0
- package/resources/inference-pipelines/data.js.map +1 -1
- package/resources/inference-pipelines/data.mjs +20 -0
- package/resources/inference-pipelines/data.mjs.map +1 -1
- package/resources/inference-pipelines/inference-pipelines.d.ts +95 -0
- package/resources/inference-pipelines/inference-pipelines.d.ts.map +1 -1
- package/resources/inference-pipelines/inference-pipelines.js +7 -0
- package/resources/inference-pipelines/inference-pipelines.js.map +1 -1
- package/resources/inference-pipelines/inference-pipelines.mjs +7 -0
- package/resources/inference-pipelines/inference-pipelines.mjs.map +1 -1
- package/resources/inference-pipelines/rows.d.ts +8 -0
- package/resources/inference-pipelines/rows.d.ts.map +1 -1
- package/resources/inference-pipelines/rows.js +8 -0
- package/resources/inference-pipelines/rows.js.map +1 -1
- package/resources/inference-pipelines/rows.mjs +8 -0
- package/resources/inference-pipelines/rows.mjs.map +1 -1
- package/resources/inference-pipelines/test-results.d.ts +31 -5
- package/resources/inference-pipelines/test-results.d.ts.map +1 -1
- package/resources/inference-pipelines/test-results.js.map +1 -1
- package/resources/inference-pipelines/test-results.mjs.map +1 -1
- package/resources/inference-pipelines.d.ts +2 -0
- package/resources/inference-pipelines.d.ts.map +1 -0
- package/resources/inference-pipelines.js +19 -0
- package/resources/inference-pipelines.js.map +1 -0
- package/resources/inference-pipelines.mjs +3 -0
- package/resources/inference-pipelines.mjs.map +1 -0
- package/resources/projects/commits.d.ts +18 -0
- package/resources/projects/commits.d.ts.map +1 -1
- package/resources/projects/commits.js +11 -0
- package/resources/projects/commits.js.map +1 -1
- package/resources/projects/commits.mjs +11 -0
- package/resources/projects/commits.mjs.map +1 -1
- package/resources/projects/index.d.ts +1 -0
- package/resources/projects/index.d.ts.map +1 -1
- package/resources/projects/index.js +3 -1
- package/resources/projects/index.js.map +1 -1
- package/resources/projects/index.mjs +1 -0
- package/resources/projects/index.mjs.map +1 -1
- package/resources/projects/inference-pipelines.d.ts +104 -0
- package/resources/projects/inference-pipelines.d.ts.map +1 -1
- package/resources/projects/inference-pipelines.js +12 -0
- package/resources/projects/inference-pipelines.js.map +1 -1
- package/resources/projects/inference-pipelines.mjs +12 -0
- package/resources/projects/inference-pipelines.mjs.map +1 -1
- package/resources/projects/projects.d.ts +17 -0
- package/resources/projects/projects.d.ts.map +1 -1
- package/resources/projects/projects.js +12 -0
- package/resources/projects/projects.js.map +1 -1
- package/resources/projects/projects.mjs +12 -0
- package/resources/projects/projects.mjs.map +1 -1
- package/resources/projects/tests.d.ts +501 -0
- package/resources/projects/tests.d.ts.map +1 -0
- package/resources/projects/tests.js +55 -0
- package/resources/projects/tests.js.map +1 -0
- package/resources/projects/tests.mjs +51 -0
- package/resources/projects/tests.mjs.map +1 -0
- package/resources/projects.d.ts +2 -0
- package/resources/projects.d.ts.map +1 -0
- package/resources/projects.js +19 -0
- package/resources/projects.js.map +1 -0
- package/resources/projects.mjs +3 -0
- package/resources/projects.mjs.map +1 -0
- package/resources/storage.d.ts +2 -0
- package/resources/storage.d.ts.map +1 -0
- package/resources/storage.js +19 -0
- package/resources/storage.js.map +1 -0
- package/resources/storage.mjs +3 -0
- package/resources/storage.mjs.map +1 -0
- package/resources.d.ts +2 -0
- package/resources.d.ts.map +1 -0
- package/resources.js +18 -0
- package/resources.js.map +1 -0
- package/resources.mjs +2 -0
- package/resources.mjs.map +1 -0
- package/src/_shims/index.d.ts +2 -0
- package/src/_shims/index.js +5 -1
- package/src/_shims/index.mjs +5 -1
- package/src/core.ts +51 -17
- package/src/index.ts +15 -5
- package/src/resource.ts +1 -1
- package/src/resources/commits/test-results.ts +102 -6
- package/src/resources/commits.ts +3 -0
- package/src/resources/inference-pipelines/data.ts +21 -1
- package/src/resources/inference-pipelines/inference-pipelines.ts +95 -0
- package/src/resources/inference-pipelines/rows.ts +8 -0
- package/src/resources/inference-pipelines/test-results.ts +109 -5
- package/src/resources/inference-pipelines.ts +3 -0
- package/src/resources/projects/commits.ts +18 -0
- package/src/resources/projects/index.ts +9 -0
- package/src/resources/projects/inference-pipelines.ts +104 -0
- package/src/resources/projects/projects.ts +35 -0
- package/src/resources/projects/tests.ts +905 -0
- package/src/resources/projects.ts +3 -0
- package/src/resources/storage.ts +3 -0
- package/src/resources.ts +1 -0
- package/src/version.ts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -6,6 +6,26 @@ import * as Core from '../../core';
|
|
|
6
6
|
export class Data extends APIResource {
|
|
7
7
|
/**
|
|
8
8
|
* Publish an inference data point to an inference pipeline.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```ts
|
|
12
|
+
* const response =
|
|
13
|
+
* await client.inferencePipelines.data.stream(
|
|
14
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
15
|
+
* {
|
|
16
|
+
* config: { outputColumnName: 'output' },
|
|
17
|
+
* rows: [
|
|
18
|
+
* {
|
|
19
|
+
* user_query: 'bar',
|
|
20
|
+
* output: 'bar',
|
|
21
|
+
* tokens: 'bar',
|
|
22
|
+
* cost: 'bar',
|
|
23
|
+
* timestamp: 'bar',
|
|
24
|
+
* },
|
|
25
|
+
* ],
|
|
26
|
+
* },
|
|
27
|
+
* );
|
|
28
|
+
* ```
|
|
9
29
|
*/
|
|
10
30
|
stream(
|
|
11
31
|
inferencePipelineId: string,
|
|
@@ -34,7 +54,7 @@ export interface DataStreamParams {
|
|
|
34
54
|
/**
|
|
35
55
|
* A list of inference data points with inputs and outputs
|
|
36
56
|
*/
|
|
37
|
-
rows: Array<
|
|
57
|
+
rows: Array<{ [key: string]: unknown }>;
|
|
38
58
|
}
|
|
39
59
|
|
|
40
60
|
export namespace DataStreamParams {
|
|
@@ -17,6 +17,14 @@ export class InferencePipelines extends APIResource {
|
|
|
17
17
|
|
|
18
18
|
/**
|
|
19
19
|
* Retrieve inference pipeline.
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* ```ts
|
|
23
|
+
* const inferencePipeline =
|
|
24
|
+
* await client.inferencePipelines.retrieve(
|
|
25
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
26
|
+
* );
|
|
27
|
+
* ```
|
|
20
28
|
*/
|
|
21
29
|
retrieve(
|
|
22
30
|
inferencePipelineId: string,
|
|
@@ -40,6 +48,14 @@ export class InferencePipelines extends APIResource {
|
|
|
40
48
|
|
|
41
49
|
/**
|
|
42
50
|
* Update inference pipeline.
|
|
51
|
+
*
|
|
52
|
+
* @example
|
|
53
|
+
* ```ts
|
|
54
|
+
* const inferencePipeline =
|
|
55
|
+
* await client.inferencePipelines.update(
|
|
56
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
57
|
+
* );
|
|
58
|
+
* ```
|
|
43
59
|
*/
|
|
44
60
|
update(
|
|
45
61
|
inferencePipelineId: string,
|
|
@@ -63,6 +79,13 @@ export class InferencePipelines extends APIResource {
|
|
|
63
79
|
|
|
64
80
|
/**
|
|
65
81
|
* Delete inference pipeline.
|
|
82
|
+
*
|
|
83
|
+
* @example
|
|
84
|
+
* ```ts
|
|
85
|
+
* await client.inferencePipelines.delete(
|
|
86
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
87
|
+
* );
|
|
88
|
+
* ```
|
|
66
89
|
*/
|
|
67
90
|
delete(inferencePipelineId: string, options?: Core.RequestOptions): Core.APIPromise<void> {
|
|
68
91
|
return this._client.delete(`/inference-pipelines/${inferencePipelineId}`, {
|
|
@@ -275,26 +298,59 @@ export namespace InferencePipelineRetrieveResponse {
|
|
|
275
298
|
}
|
|
276
299
|
|
|
277
300
|
export interface Workspace {
|
|
301
|
+
/**
|
|
302
|
+
* The workspace id.
|
|
303
|
+
*/
|
|
278
304
|
id: string;
|
|
279
305
|
|
|
306
|
+
/**
|
|
307
|
+
* The workspace creator id.
|
|
308
|
+
*/
|
|
280
309
|
creatorId: string | null;
|
|
281
310
|
|
|
311
|
+
/**
|
|
312
|
+
* The workspace creation date.
|
|
313
|
+
*/
|
|
282
314
|
dateCreated: string;
|
|
283
315
|
|
|
316
|
+
/**
|
|
317
|
+
* The workspace last updated date.
|
|
318
|
+
*/
|
|
284
319
|
dateUpdated: string;
|
|
285
320
|
|
|
321
|
+
/**
|
|
322
|
+
* The number of invites in the workspace.
|
|
323
|
+
*/
|
|
286
324
|
inviteCount: number;
|
|
287
325
|
|
|
326
|
+
/**
|
|
327
|
+
* The number of members in the workspace.
|
|
328
|
+
*/
|
|
288
329
|
memberCount: number;
|
|
289
330
|
|
|
331
|
+
/**
|
|
332
|
+
* The workspace name.
|
|
333
|
+
*/
|
|
290
334
|
name: string;
|
|
291
335
|
|
|
336
|
+
/**
|
|
337
|
+
* The end date of the current billing period.
|
|
338
|
+
*/
|
|
292
339
|
periodEndDate: string | null;
|
|
293
340
|
|
|
341
|
+
/**
|
|
342
|
+
* The start date of the current billing period.
|
|
343
|
+
*/
|
|
294
344
|
periodStartDate: string | null;
|
|
295
345
|
|
|
346
|
+
/**
|
|
347
|
+
* The number of projects in the workspace.
|
|
348
|
+
*/
|
|
296
349
|
projectCount: number;
|
|
297
350
|
|
|
351
|
+
/**
|
|
352
|
+
* The workspace slug.
|
|
353
|
+
*/
|
|
298
354
|
slug: string;
|
|
299
355
|
|
|
300
356
|
status:
|
|
@@ -309,6 +365,9 @@ export namespace InferencePipelineRetrieveResponse {
|
|
|
309
365
|
|
|
310
366
|
monthlyUsage?: Array<Workspace.MonthlyUsage>;
|
|
311
367
|
|
|
368
|
+
/**
|
|
369
|
+
* Whether the workspace only allows SAML authentication.
|
|
370
|
+
*/
|
|
312
371
|
samlOnlyAccess?: boolean;
|
|
313
372
|
|
|
314
373
|
wildcardDomains?: Array<string>;
|
|
@@ -528,26 +587,59 @@ export namespace InferencePipelineUpdateResponse {
|
|
|
528
587
|
}
|
|
529
588
|
|
|
530
589
|
export interface Workspace {
|
|
590
|
+
/**
|
|
591
|
+
* The workspace id.
|
|
592
|
+
*/
|
|
531
593
|
id: string;
|
|
532
594
|
|
|
595
|
+
/**
|
|
596
|
+
* The workspace creator id.
|
|
597
|
+
*/
|
|
533
598
|
creatorId: string | null;
|
|
534
599
|
|
|
600
|
+
/**
|
|
601
|
+
* The workspace creation date.
|
|
602
|
+
*/
|
|
535
603
|
dateCreated: string;
|
|
536
604
|
|
|
605
|
+
/**
|
|
606
|
+
* The workspace last updated date.
|
|
607
|
+
*/
|
|
537
608
|
dateUpdated: string;
|
|
538
609
|
|
|
610
|
+
/**
|
|
611
|
+
* The number of invites in the workspace.
|
|
612
|
+
*/
|
|
539
613
|
inviteCount: number;
|
|
540
614
|
|
|
615
|
+
/**
|
|
616
|
+
* The number of members in the workspace.
|
|
617
|
+
*/
|
|
541
618
|
memberCount: number;
|
|
542
619
|
|
|
620
|
+
/**
|
|
621
|
+
* The workspace name.
|
|
622
|
+
*/
|
|
543
623
|
name: string;
|
|
544
624
|
|
|
625
|
+
/**
|
|
626
|
+
* The end date of the current billing period.
|
|
627
|
+
*/
|
|
545
628
|
periodEndDate: string | null;
|
|
546
629
|
|
|
630
|
+
/**
|
|
631
|
+
* The start date of the current billing period.
|
|
632
|
+
*/
|
|
547
633
|
periodStartDate: string | null;
|
|
548
634
|
|
|
635
|
+
/**
|
|
636
|
+
* The number of projects in the workspace.
|
|
637
|
+
*/
|
|
549
638
|
projectCount: number;
|
|
550
639
|
|
|
640
|
+
/**
|
|
641
|
+
* The workspace slug.
|
|
642
|
+
*/
|
|
551
643
|
slug: string;
|
|
552
644
|
|
|
553
645
|
status:
|
|
@@ -562,6 +654,9 @@ export namespace InferencePipelineUpdateResponse {
|
|
|
562
654
|
|
|
563
655
|
monthlyUsage?: Array<Workspace.MonthlyUsage>;
|
|
564
656
|
|
|
657
|
+
/**
|
|
658
|
+
* Whether the workspace only allows SAML authentication.
|
|
659
|
+
*/
|
|
565
660
|
samlOnlyAccess?: boolean;
|
|
566
661
|
|
|
567
662
|
wildcardDomains?: Array<string>;
|
|
@@ -6,6 +6,14 @@ import * as Core from '../../core';
|
|
|
6
6
|
export class Rows extends APIResource {
|
|
7
7
|
/**
|
|
8
8
|
* Update an inference data point in an inference pipeline.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```ts
|
|
12
|
+
* const row = await client.inferencePipelines.rows.update(
|
|
13
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
14
|
+
* { inferenceId: 'inferenceId', row: {} },
|
|
15
|
+
* );
|
|
16
|
+
* ```
|
|
9
17
|
*/
|
|
10
18
|
update(
|
|
11
19
|
inferencePipelineId: string,
|
|
@@ -7,6 +7,14 @@ import * as Core from '../../core';
|
|
|
7
7
|
export class TestResults extends APIResource {
|
|
8
8
|
/**
|
|
9
9
|
* List the latest test results for an inference pipeline.
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* ```ts
|
|
13
|
+
* const testResults =
|
|
14
|
+
* await client.inferencePipelines.testResults.list(
|
|
15
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
16
|
+
* );
|
|
17
|
+
* ```
|
|
10
18
|
*/
|
|
11
19
|
list(
|
|
12
20
|
inferencePipelineId: string,
|
|
@@ -140,7 +148,48 @@ export namespace TestResultListResponse {
|
|
|
140
148
|
/**
|
|
141
149
|
* The test subtype.
|
|
142
150
|
*/
|
|
143
|
-
subtype:
|
|
151
|
+
subtype:
|
|
152
|
+
| 'anomalousColumnCount'
|
|
153
|
+
| 'characterLength'
|
|
154
|
+
| 'classImbalanceRatio'
|
|
155
|
+
| 'expectColumnAToBeInColumnB'
|
|
156
|
+
| 'columnAverage'
|
|
157
|
+
| 'columnDrift'
|
|
158
|
+
| 'columnStatistic'
|
|
159
|
+
| 'columnValuesMatch'
|
|
160
|
+
| 'conflictingLabelRowCount'
|
|
161
|
+
| 'containsPii'
|
|
162
|
+
| 'containsValidUrl'
|
|
163
|
+
| 'correlatedFeatureCount'
|
|
164
|
+
| 'customMetricThreshold'
|
|
165
|
+
| 'duplicateRowCount'
|
|
166
|
+
| 'emptyFeature'
|
|
167
|
+
| 'emptyFeatureCount'
|
|
168
|
+
| 'driftedFeatureCount'
|
|
169
|
+
| 'featureMissingValues'
|
|
170
|
+
| 'featureValueValidation'
|
|
171
|
+
| 'greatExpectations'
|
|
172
|
+
| 'groupByColumnStatsCheck'
|
|
173
|
+
| 'illFormedRowCount'
|
|
174
|
+
| 'isCode'
|
|
175
|
+
| 'isJson'
|
|
176
|
+
| 'llmRubricThresholdV2'
|
|
177
|
+
| 'labelDrift'
|
|
178
|
+
| 'metricThreshold'
|
|
179
|
+
| 'newCategoryCount'
|
|
180
|
+
| 'newLabelCount'
|
|
181
|
+
| 'nullRowCount'
|
|
182
|
+
| 'rowCount'
|
|
183
|
+
| 'ppScoreValueValidation'
|
|
184
|
+
| 'quasiConstantFeature'
|
|
185
|
+
| 'quasiConstantFeatureCount'
|
|
186
|
+
| 'sqlQuery'
|
|
187
|
+
| 'dtypeValidation'
|
|
188
|
+
| 'sentenceLength'
|
|
189
|
+
| 'sizeRatio'
|
|
190
|
+
| 'specialCharactersRatio'
|
|
191
|
+
| 'stringValidation'
|
|
192
|
+
| 'trainValLeakageRowCount';
|
|
144
193
|
|
|
145
194
|
/**
|
|
146
195
|
* Whether the test is suggested or user-created.
|
|
@@ -152,7 +201,7 @@ export namespace TestResultListResponse {
|
|
|
152
201
|
/**
|
|
153
202
|
* The test type.
|
|
154
203
|
*/
|
|
155
|
-
type:
|
|
204
|
+
type: 'integrity' | 'consistency' | 'performance';
|
|
156
205
|
|
|
157
206
|
/**
|
|
158
207
|
* Whether the test is archived.
|
|
@@ -201,9 +250,48 @@ export namespace TestResultListResponse {
|
|
|
201
250
|
/**
|
|
202
251
|
* The insight name to be evaluated.
|
|
203
252
|
*/
|
|
204
|
-
insightName?:
|
|
253
|
+
insightName?:
|
|
254
|
+
| 'characterLength'
|
|
255
|
+
| 'classImbalance'
|
|
256
|
+
| 'expectColumnAToBeInColumnB'
|
|
257
|
+
| 'columnAverage'
|
|
258
|
+
| 'columnDrift'
|
|
259
|
+
| 'columnValuesMatch'
|
|
260
|
+
| 'confidenceDistribution'
|
|
261
|
+
| 'conflictingLabelRowCount'
|
|
262
|
+
| 'containsPii'
|
|
263
|
+
| 'containsValidUrl'
|
|
264
|
+
| 'correlatedFeatures'
|
|
265
|
+
| 'customMetric'
|
|
266
|
+
| 'duplicateRowCount'
|
|
267
|
+
| 'emptyFeatures'
|
|
268
|
+
| 'featureDrift'
|
|
269
|
+
| 'featureProfile'
|
|
270
|
+
| 'greatExpectations'
|
|
271
|
+
| 'groupByColumnStatsCheck'
|
|
272
|
+
| 'illFormedRowCount'
|
|
273
|
+
| 'isCode'
|
|
274
|
+
| 'isJson'
|
|
275
|
+
| 'llmRubricV2'
|
|
276
|
+
| 'labelDrift'
|
|
277
|
+
| 'metrics'
|
|
278
|
+
| 'newCategories'
|
|
279
|
+
| 'newLabels'
|
|
280
|
+
| 'nullRowCount'
|
|
281
|
+
| 'ppScore'
|
|
282
|
+
| 'quasiConstantFeatures'
|
|
283
|
+
| 'sentenceLength'
|
|
284
|
+
| 'sizeRatio'
|
|
285
|
+
| 'specialCharacters'
|
|
286
|
+
| 'stringValidation'
|
|
287
|
+
| 'trainValLeakageRowCount';
|
|
205
288
|
|
|
206
|
-
|
|
289
|
+
/**
|
|
290
|
+
* The insight parameters. Required only for some test subtypes. For example, for
|
|
291
|
+
* tests that require a column name, the insight parameters will be [{'name':
|
|
292
|
+
* 'column_name', 'value': 'Age'}]
|
|
293
|
+
*/
|
|
294
|
+
insightParameters?: Array<Threshold.InsightParameter> | null;
|
|
207
295
|
|
|
208
296
|
/**
|
|
209
297
|
* The measurement to be evaluated.
|
|
@@ -213,13 +301,29 @@ export namespace TestResultListResponse {
|
|
|
213
301
|
/**
|
|
214
302
|
* The operator to be used for the evaluation.
|
|
215
303
|
*/
|
|
216
|
-
operator?:
|
|
304
|
+
operator?: 'is' | '>' | '>=' | '<' | '<=' | '!=';
|
|
305
|
+
|
|
306
|
+
/**
|
|
307
|
+
* Whether to use automatic anomaly detection or manual thresholds
|
|
308
|
+
*/
|
|
309
|
+
thresholdMode?: 'automatic' | 'manual';
|
|
217
310
|
|
|
218
311
|
/**
|
|
219
312
|
* The value to be compared.
|
|
220
313
|
*/
|
|
221
314
|
value?: number | boolean | string | Array<string>;
|
|
222
315
|
}
|
|
316
|
+
|
|
317
|
+
export namespace Threshold {
|
|
318
|
+
export interface InsightParameter {
|
|
319
|
+
/**
|
|
320
|
+
* The name of the insight filter.
|
|
321
|
+
*/
|
|
322
|
+
name: string;
|
|
323
|
+
|
|
324
|
+
value: unknown;
|
|
325
|
+
}
|
|
326
|
+
}
|
|
223
327
|
}
|
|
224
328
|
}
|
|
225
329
|
}
|
|
@@ -7,6 +7,17 @@ import * as Core from '../../core';
|
|
|
7
7
|
export class Commits extends APIResource {
|
|
8
8
|
/**
|
|
9
9
|
* Create a new commit (project version) in a project.
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* ```ts
|
|
13
|
+
* const commit = await client.projects.commits.create(
|
|
14
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
15
|
+
* {
|
|
16
|
+
* commit: { message: 'Updated the prompt.' },
|
|
17
|
+
* storageUri: 's3://...',
|
|
18
|
+
* },
|
|
19
|
+
* );
|
|
20
|
+
* ```
|
|
10
21
|
*/
|
|
11
22
|
create(
|
|
12
23
|
projectId: string,
|
|
@@ -18,6 +29,13 @@ export class Commits extends APIResource {
|
|
|
18
29
|
|
|
19
30
|
/**
|
|
20
31
|
* List the commits (project versions) in a project.
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```ts
|
|
35
|
+
* const commits = await client.projects.commits.list(
|
|
36
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
37
|
+
* );
|
|
38
|
+
* ```
|
|
21
39
|
*/
|
|
22
40
|
list(
|
|
23
41
|
projectId: string,
|
|
@@ -21,3 +21,12 @@ export {
|
|
|
21
21
|
type ProjectCreateParams,
|
|
22
22
|
type ProjectListParams,
|
|
23
23
|
} from './projects';
|
|
24
|
+
export {
|
|
25
|
+
Tests,
|
|
26
|
+
type TestCreateResponse,
|
|
27
|
+
type TestUpdateResponse,
|
|
28
|
+
type TestListResponse,
|
|
29
|
+
type TestCreateParams,
|
|
30
|
+
type TestUpdateParams,
|
|
31
|
+
type TestListParams,
|
|
32
|
+
} from './tests';
|
|
@@ -7,6 +7,18 @@ import * as Core from '../../core';
|
|
|
7
7
|
export class InferencePipelines extends APIResource {
|
|
8
8
|
/**
|
|
9
9
|
* Create an inference pipeline in a project.
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* ```ts
|
|
13
|
+
* const inferencePipeline =
|
|
14
|
+
* await client.projects.inferencePipelines.create(
|
|
15
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
16
|
+
* {
|
|
17
|
+
* description: 'This pipeline is used for production.',
|
|
18
|
+
* name: 'production',
|
|
19
|
+
* },
|
|
20
|
+
* );
|
|
21
|
+
* ```
|
|
10
22
|
*/
|
|
11
23
|
create(
|
|
12
24
|
projectId: string,
|
|
@@ -18,6 +30,14 @@ export class InferencePipelines extends APIResource {
|
|
|
18
30
|
|
|
19
31
|
/**
|
|
20
32
|
* List the inference pipelines in a project.
|
|
33
|
+
*
|
|
34
|
+
* @example
|
|
35
|
+
* ```ts
|
|
36
|
+
* const inferencePipelines =
|
|
37
|
+
* await client.projects.inferencePipelines.list(
|
|
38
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
39
|
+
* );
|
|
40
|
+
* ```
|
|
21
41
|
*/
|
|
22
42
|
list(
|
|
23
43
|
projectId: string,
|
|
@@ -240,26 +260,59 @@ export namespace InferencePipelineCreateResponse {
|
|
|
240
260
|
}
|
|
241
261
|
|
|
242
262
|
export interface Workspace {
|
|
263
|
+
/**
|
|
264
|
+
* The workspace id.
|
|
265
|
+
*/
|
|
243
266
|
id: string;
|
|
244
267
|
|
|
268
|
+
/**
|
|
269
|
+
* The workspace creator id.
|
|
270
|
+
*/
|
|
245
271
|
creatorId: string | null;
|
|
246
272
|
|
|
273
|
+
/**
|
|
274
|
+
* The workspace creation date.
|
|
275
|
+
*/
|
|
247
276
|
dateCreated: string;
|
|
248
277
|
|
|
278
|
+
/**
|
|
279
|
+
* The workspace last updated date.
|
|
280
|
+
*/
|
|
249
281
|
dateUpdated: string;
|
|
250
282
|
|
|
283
|
+
/**
|
|
284
|
+
* The number of invites in the workspace.
|
|
285
|
+
*/
|
|
251
286
|
inviteCount: number;
|
|
252
287
|
|
|
288
|
+
/**
|
|
289
|
+
* The number of members in the workspace.
|
|
290
|
+
*/
|
|
253
291
|
memberCount: number;
|
|
254
292
|
|
|
293
|
+
/**
|
|
294
|
+
* The workspace name.
|
|
295
|
+
*/
|
|
255
296
|
name: string;
|
|
256
297
|
|
|
298
|
+
/**
|
|
299
|
+
* The end date of the current billing period.
|
|
300
|
+
*/
|
|
257
301
|
periodEndDate: string | null;
|
|
258
302
|
|
|
303
|
+
/**
|
|
304
|
+
* The start date of the current billing period.
|
|
305
|
+
*/
|
|
259
306
|
periodStartDate: string | null;
|
|
260
307
|
|
|
308
|
+
/**
|
|
309
|
+
* The number of projects in the workspace.
|
|
310
|
+
*/
|
|
261
311
|
projectCount: number;
|
|
262
312
|
|
|
313
|
+
/**
|
|
314
|
+
* The workspace slug.
|
|
315
|
+
*/
|
|
263
316
|
slug: string;
|
|
264
317
|
|
|
265
318
|
status:
|
|
@@ -274,6 +327,9 @@ export namespace InferencePipelineCreateResponse {
|
|
|
274
327
|
|
|
275
328
|
monthlyUsage?: Array<Workspace.MonthlyUsage>;
|
|
276
329
|
|
|
330
|
+
/**
|
|
331
|
+
* Whether the workspace only allows SAML authentication.
|
|
332
|
+
*/
|
|
277
333
|
samlOnlyAccess?: boolean;
|
|
278
334
|
|
|
279
335
|
wildcardDomains?: Array<string>;
|
|
@@ -498,26 +554,59 @@ export namespace InferencePipelineListResponse {
|
|
|
498
554
|
}
|
|
499
555
|
|
|
500
556
|
export interface Workspace {
|
|
557
|
+
/**
|
|
558
|
+
* The workspace id.
|
|
559
|
+
*/
|
|
501
560
|
id: string;
|
|
502
561
|
|
|
562
|
+
/**
|
|
563
|
+
* The workspace creator id.
|
|
564
|
+
*/
|
|
503
565
|
creatorId: string | null;
|
|
504
566
|
|
|
567
|
+
/**
|
|
568
|
+
* The workspace creation date.
|
|
569
|
+
*/
|
|
505
570
|
dateCreated: string;
|
|
506
571
|
|
|
572
|
+
/**
|
|
573
|
+
* The workspace last updated date.
|
|
574
|
+
*/
|
|
507
575
|
dateUpdated: string;
|
|
508
576
|
|
|
577
|
+
/**
|
|
578
|
+
* The number of invites in the workspace.
|
|
579
|
+
*/
|
|
509
580
|
inviteCount: number;
|
|
510
581
|
|
|
582
|
+
/**
|
|
583
|
+
* The number of members in the workspace.
|
|
584
|
+
*/
|
|
511
585
|
memberCount: number;
|
|
512
586
|
|
|
587
|
+
/**
|
|
588
|
+
* The workspace name.
|
|
589
|
+
*/
|
|
513
590
|
name: string;
|
|
514
591
|
|
|
592
|
+
/**
|
|
593
|
+
* The end date of the current billing period.
|
|
594
|
+
*/
|
|
515
595
|
periodEndDate: string | null;
|
|
516
596
|
|
|
597
|
+
/**
|
|
598
|
+
* The start date of the current billing period.
|
|
599
|
+
*/
|
|
517
600
|
periodStartDate: string | null;
|
|
518
601
|
|
|
602
|
+
/**
|
|
603
|
+
* The number of projects in the workspace.
|
|
604
|
+
*/
|
|
519
605
|
projectCount: number;
|
|
520
606
|
|
|
607
|
+
/**
|
|
608
|
+
* The workspace slug.
|
|
609
|
+
*/
|
|
521
610
|
slug: string;
|
|
522
611
|
|
|
523
612
|
status:
|
|
@@ -532,6 +621,9 @@ export namespace InferencePipelineListResponse {
|
|
|
532
621
|
|
|
533
622
|
monthlyUsage?: Array<Workspace.MonthlyUsage>;
|
|
534
623
|
|
|
624
|
+
/**
|
|
625
|
+
* Whether the workspace only allows SAML authentication.
|
|
626
|
+
*/
|
|
535
627
|
samlOnlyAccess?: boolean;
|
|
536
628
|
|
|
537
629
|
wildcardDomains?: Array<string>;
|
|
@@ -584,12 +676,24 @@ export namespace InferencePipelineCreateParams {
|
|
|
584
676
|
}
|
|
585
677
|
|
|
586
678
|
export interface Workspace {
|
|
679
|
+
/**
|
|
680
|
+
* The workspace name.
|
|
681
|
+
*/
|
|
587
682
|
name: string;
|
|
588
683
|
|
|
684
|
+
/**
|
|
685
|
+
* The workspace slug.
|
|
686
|
+
*/
|
|
589
687
|
slug: string;
|
|
590
688
|
|
|
689
|
+
/**
|
|
690
|
+
* The workspace invite code.
|
|
691
|
+
*/
|
|
591
692
|
inviteCode?: string;
|
|
592
693
|
|
|
694
|
+
/**
|
|
695
|
+
* Whether the workspace only allows SAML authentication.
|
|
696
|
+
*/
|
|
593
697
|
samlOnlyAccess?: boolean;
|
|
594
698
|
|
|
595
699
|
wildcardDomains?: Array<string>;
|
|
@@ -19,15 +19,34 @@ import {
|
|
|
19
19
|
InferencePipelineListResponse,
|
|
20
20
|
InferencePipelines,
|
|
21
21
|
} from './inference-pipelines';
|
|
22
|
+
import * as TestsAPI from './tests';
|
|
23
|
+
import {
|
|
24
|
+
TestCreateParams,
|
|
25
|
+
TestCreateResponse,
|
|
26
|
+
TestListParams,
|
|
27
|
+
TestListResponse,
|
|
28
|
+
TestUpdateParams,
|
|
29
|
+
TestUpdateResponse,
|
|
30
|
+
Tests,
|
|
31
|
+
} from './tests';
|
|
22
32
|
|
|
23
33
|
export class Projects extends APIResource {
|
|
24
34
|
commits: CommitsAPI.Commits = new CommitsAPI.Commits(this._client);
|
|
25
35
|
inferencePipelines: InferencePipelinesAPI.InferencePipelines = new InferencePipelinesAPI.InferencePipelines(
|
|
26
36
|
this._client,
|
|
27
37
|
);
|
|
38
|
+
tests: TestsAPI.Tests = new TestsAPI.Tests(this._client);
|
|
28
39
|
|
|
29
40
|
/**
|
|
30
41
|
* Create a project in your workspace.
|
|
42
|
+
*
|
|
43
|
+
* @example
|
|
44
|
+
* ```ts
|
|
45
|
+
* const project = await client.projects.create({
|
|
46
|
+
* name: 'My Project',
|
|
47
|
+
* taskType: 'llm-base',
|
|
48
|
+
* });
|
|
49
|
+
* ```
|
|
31
50
|
*/
|
|
32
51
|
create(body: ProjectCreateParams, options?: Core.RequestOptions): Core.APIPromise<ProjectCreateResponse> {
|
|
33
52
|
return this._client.post('/projects', { body, ...options });
|
|
@@ -35,6 +54,11 @@ export class Projects extends APIResource {
|
|
|
35
54
|
|
|
36
55
|
/**
|
|
37
56
|
* List your workspace's projects.
|
|
57
|
+
*
|
|
58
|
+
* @example
|
|
59
|
+
* ```ts
|
|
60
|
+
* const projects = await client.projects.list();
|
|
61
|
+
* ```
|
|
38
62
|
*/
|
|
39
63
|
list(query?: ProjectListParams, options?: Core.RequestOptions): Core.APIPromise<ProjectListResponse>;
|
|
40
64
|
list(options?: Core.RequestOptions): Core.APIPromise<ProjectListResponse>;
|
|
@@ -324,6 +348,7 @@ export interface ProjectListParams {
|
|
|
324
348
|
|
|
325
349
|
Projects.Commits = Commits;
|
|
326
350
|
Projects.InferencePipelines = InferencePipelines;
|
|
351
|
+
Projects.Tests = Tests;
|
|
327
352
|
|
|
328
353
|
export declare namespace Projects {
|
|
329
354
|
export {
|
|
@@ -348,4 +373,14 @@ export declare namespace Projects {
|
|
|
348
373
|
type InferencePipelineCreateParams as InferencePipelineCreateParams,
|
|
349
374
|
type InferencePipelineListParams as InferencePipelineListParams,
|
|
350
375
|
};
|
|
376
|
+
|
|
377
|
+
export {
|
|
378
|
+
Tests as Tests,
|
|
379
|
+
type TestCreateResponse as TestCreateResponse,
|
|
380
|
+
type TestUpdateResponse as TestUpdateResponse,
|
|
381
|
+
type TestListResponse as TestListResponse,
|
|
382
|
+
type TestCreateParams as TestCreateParams,
|
|
383
|
+
type TestUpdateParams as TestUpdateParams,
|
|
384
|
+
type TestListParams as TestListParams,
|
|
385
|
+
};
|
|
351
386
|
}
|