-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrows.ts
79 lines (67 loc) · 1.87 KB
/
rows.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
import { APIResource } from '../../resource';
import * as Core from '../../core';
export class Rows extends APIResource {
/**
* Update an inference data point in an inference pipeline.
*/
update(
inferencePipelineId: string,
params: RowUpdateParams,
options?: Core.RequestOptions,
): Core.APIPromise<RowUpdateResponse> {
const { inferenceId, ...body } = params;
return this._client.put(`/inference-pipelines/${inferencePipelineId}/rows`, {
query: { inferenceId },
body,
...options,
});
}
}
export interface RowUpdateResponse {
success: true;
}
export interface RowUpdateParams {
/**
* Query param: Specify the inference id as a query param.
*/
inferenceId: string;
/**
* Body param:
*/
row: unknown;
/**
* Body param:
*/
config?: RowUpdateParams.Config | null;
}
export namespace RowUpdateParams {
export interface Config {
/**
* Name of the column with the ground truths.
*/
groundTruthColumnName?: string | null;
/**
* Name of the column with human feedback.
*/
humanFeedbackColumnName?: string | null;
/**
* Name of the column with the inference ids. This is useful if you want to update
* rows at a later point in time. If not provided, a unique id is generated by
* Openlayer.
*/
inferenceIdColumnName?: string | null;
/**
* Name of the column with the latencies.
*/
latencyColumnName?: string | null;
/**
* Name of the column with the timestamps. Timestamps must be in UNIX sec format.
* If not provided, the upload timestamp is used.
*/
timestampColumnName?: string | null;
}
}
export declare namespace Rows {
export { type RowUpdateResponse as RowUpdateResponse, type RowUpdateParams as RowUpdateParams };
}