langsmith 0.7.10 → 0.7.12

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.
Files changed (103) hide show
  1. package/README.md +46 -15
  2. package/dist/_openapi_client/client.cjs +0 -80
  3. package/dist/_openapi_client/client.d.ts +2 -32
  4. package/dist/_openapi_client/client.js +0 -80
  5. package/dist/_openapi_client/core/pagination.cjs +2 -2
  6. package/dist/_openapi_client/core/pagination.js +2 -2
  7. package/dist/_openapi_client/internal/utils/query.cjs +1 -1
  8. package/dist/_openapi_client/internal/utils/query.js +1 -1
  9. package/dist/_openapi_client/resources/datasets/datasets.d.ts +52 -4
  10. package/dist/_openapi_client/resources/index.cjs +1 -21
  11. package/dist/_openapi_client/resources/index.d.ts +1 -11
  12. package/dist/_openapi_client/resources/index.js +0 -10
  13. package/dist/_openapi_client/resources/runs/index.cjs +9 -0
  14. package/dist/_openapi_client/resources/runs/index.d.ts +2 -0
  15. package/dist/_openapi_client/resources/runs/index.js +4 -0
  16. package/dist/_openapi_client/resources/runs/runs.cjs +54 -41
  17. package/dist/_openapi_client/resources/runs/runs.d.ts +571 -313
  18. package/dist/_openapi_client/resources/runs/runs.js +54 -41
  19. package/dist/_openapi_client/resources/runs.cjs +19 -0
  20. package/dist/_openapi_client/resources/runs.d.ts +1 -0
  21. package/dist/_openapi_client/resources/runs.js +3 -0
  22. package/dist/anonymizer/index.cjs +142 -0
  23. package/dist/anonymizer/index.d.ts +45 -0
  24. package/dist/anonymizer/index.js +140 -0
  25. package/dist/client.cjs +29 -1
  26. package/dist/client.d.ts +6 -1
  27. package/dist/client.js +28 -1
  28. package/dist/index.cjs +1 -1
  29. package/dist/index.d.ts +1 -1
  30. package/dist/index.js +1 -1
  31. package/dist/sandbox/client.cjs +5 -8
  32. package/dist/sandbox/client.js +5 -8
  33. package/dist/sandbox/index.cjs +2 -1
  34. package/dist/sandbox/index.d.ts +2 -2
  35. package/dist/sandbox/index.js +1 -1
  36. package/dist/sandbox/mounts.cjs +157 -18
  37. package/dist/sandbox/mounts.d.ts +10 -2
  38. package/dist/sandbox/mounts.js +155 -18
  39. package/dist/sandbox/proxy_config.cjs +19 -44
  40. package/dist/sandbox/proxy_config.d.ts +2 -4
  41. package/dist/sandbox/proxy_config.js +19 -43
  42. package/dist/sandbox/types.d.ts +56 -15
  43. package/dist/utils/constants.cjs +4 -0
  44. package/dist/utils/constants.d.ts +1 -0
  45. package/dist/utils/constants.js +1 -0
  46. package/package.json +5 -5
  47. package/dist/_openapi_client/resources/annotation-queues/annotation-queues.cjs +0 -138
  48. package/dist/_openapi_client/resources/annotation-queues/annotation-queues.d.ts +0 -367
  49. package/dist/_openapi_client/resources/annotation-queues/annotation-queues.js +0 -101
  50. package/dist/_openapi_client/resources/annotation-queues/runs.cjs +0 -46
  51. package/dist/_openapi_client/resources/annotation-queues/runs.d.ts +0 -128
  52. package/dist/_openapi_client/resources/annotation-queues/runs.js +0 -42
  53. package/dist/_openapi_client/resources/commits.cjs +0 -44
  54. package/dist/_openapi_client/resources/commits.d.ts +0 -204
  55. package/dist/_openapi_client/resources/commits.js +0 -40
  56. package/dist/_openapi_client/resources/evaluators.cjs +0 -15
  57. package/dist/_openapi_client/resources/evaluators.d.ts +0 -125
  58. package/dist/_openapi_client/resources/evaluators.js +0 -11
  59. package/dist/_openapi_client/resources/examples/bulk.cjs +0 -24
  60. package/dist/_openapi_client/resources/examples/bulk.d.ts +0 -78
  61. package/dist/_openapi_client/resources/examples/bulk.js +0 -20
  62. package/dist/_openapi_client/resources/examples/examples.cjs +0 -124
  63. package/dist/_openapi_client/resources/examples/examples.d.ts +0 -182
  64. package/dist/_openapi_client/resources/examples/examples.js +0 -87
  65. package/dist/_openapi_client/resources/examples/validate.cjs +0 -21
  66. package/dist/_openapi_client/resources/examples/validate.d.ts +0 -38
  67. package/dist/_openapi_client/resources/examples/validate.js +0 -17
  68. package/dist/_openapi_client/resources/feedback/configs.cjs +0 -24
  69. package/dist/_openapi_client/resources/feedback/configs.d.ts +0 -18
  70. package/dist/_openapi_client/resources/feedback/configs.js +0 -20
  71. package/dist/_openapi_client/resources/feedback/feedback.cjs +0 -98
  72. package/dist/_openapi_client/resources/feedback/feedback.d.ts +0 -275
  73. package/dist/_openapi_client/resources/feedback/feedback.js +0 -61
  74. package/dist/_openapi_client/resources/feedback/tokens.cjs +0 -35
  75. package/dist/_openapi_client/resources/feedback/tokens.d.ts +0 -130
  76. package/dist/_openapi_client/resources/feedback/tokens.js +0 -31
  77. package/dist/_openapi_client/resources/public/datasets.cjs +0 -47
  78. package/dist/_openapi_client/resources/public/datasets.d.ts +0 -152
  79. package/dist/_openapi_client/resources/public/datasets.js +0 -43
  80. package/dist/_openapi_client/resources/public/public.cjs +0 -62
  81. package/dist/_openapi_client/resources/public/public.d.ts +0 -32
  82. package/dist/_openapi_client/resources/public/public.js +0 -25
  83. package/dist/_openapi_client/resources/repos/directories.cjs +0 -40
  84. package/dist/_openapi_client/resources/repos/directories.d.ts +0 -72
  85. package/dist/_openapi_client/resources/repos/directories.js +0 -36
  86. package/dist/_openapi_client/resources/repos/repos.cjs +0 -93
  87. package/dist/_openapi_client/resources/repos/repos.d.ts +0 -188
  88. package/dist/_openapi_client/resources/repos/repos.js +0 -56
  89. package/dist/_openapi_client/resources/sandboxes/boxes.cjs +0 -86
  90. package/dist/_openapi_client/resources/sandboxes/boxes.d.ts +0 -1121
  91. package/dist/_openapi_client/resources/sandboxes/boxes.js +0 -82
  92. package/dist/_openapi_client/resources/sandboxes/sandboxes.cjs +0 -63
  93. package/dist/_openapi_client/resources/sandboxes/sandboxes.d.ts +0 -13
  94. package/dist/_openapi_client/resources/sandboxes/sandboxes.js +0 -26
  95. package/dist/_openapi_client/resources/sandboxes/snapshots.cjs +0 -39
  96. package/dist/_openapi_client/resources/sandboxes/snapshots.d.ts +0 -130
  97. package/dist/_openapi_client/resources/sandboxes/snapshots.js +0 -35
  98. package/dist/_openapi_client/resources/settings.cjs +0 -15
  99. package/dist/_openapi_client/resources/settings.d.ts +0 -18
  100. package/dist/_openapi_client/resources/settings.js +0 -11
  101. package/dist/_openapi_client/resources/workspaces.cjs +0 -35
  102. package/dist/_openapi_client/resources/workspaces.d.ts +0 -84
  103. package/dist/_openapi_client/resources/workspaces.js +0 -31
@@ -1,128 +0,0 @@
1
- import { APIResource } from '../../core/resource.js';
2
- import * as AnnotationQueuesAPI from './annotation-queues.js';
3
- import { APIPromise } from '../../core/api-promise.js';
4
- import { RequestOptions } from '../../internal/request-options.js';
5
- export declare class Runs extends APIResource {
6
- /**
7
- * Add Runs To Annotation Queue
8
- */
9
- create(queueID: string, params: RunCreateParams, options?: RequestOptions): APIPromise<RunCreateResponse>;
10
- /**
11
- * Update Run In Annotation Queue
12
- */
13
- update(queueRunID: string, params: RunUpdateParams, options?: RequestOptions): APIPromise<unknown>;
14
- /**
15
- * Get Runs From Annotation Queue
16
- */
17
- list(queueID: string, query?: RunListParams | null | undefined, options?: RequestOptions): APIPromise<RunListResponse>;
18
- /**
19
- * Delete Runs From Annotation Queue
20
- */
21
- deleteAll(queueID: string, body: RunDeleteAllParams, options?: RequestOptions): APIPromise<unknown>;
22
- /**
23
- * Delete Run From Annotation Queue
24
- */
25
- deleteQueue(queueRunID: string, params: RunDeleteQueueParams, options?: RequestOptions): APIPromise<unknown>;
26
- }
27
- export type RunCreateResponse = Array<RunCreateResponse.RunCreateResponseItem>;
28
- export declare namespace RunCreateResponse {
29
- interface RunCreateResponseItem {
30
- id: string;
31
- queue_id: string;
32
- run_id: string;
33
- added_at?: string;
34
- last_reviewed_time?: string | null;
35
- source_proposed_example_id?: string | null;
36
- }
37
- }
38
- export type RunUpdateResponse = unknown;
39
- export type RunListResponse = Array<AnnotationQueuesAPI.RunSchemaWithAnnotationQueueInfo>;
40
- export type RunDeleteAllResponse = unknown;
41
- export type RunDeleteQueueResponse = unknown;
42
- export type RunCreateParams = RunCreateParams.RunsUuidArray | RunCreateParams.RunsAnnotationQueueRunAddSchemaArray | RunCreateParams.Variant2;
43
- export declare namespace RunCreateParams {
44
- interface RunsUuidArray {
45
- body: Array<string>;
46
- }
47
- interface RunsAnnotationQueueRunAddSchemaArray {
48
- body: Array<RunsAnnotationQueueRunAddSchemaArray.Body>;
49
- }
50
- namespace RunsAnnotationQueueRunAddSchemaArray {
51
- /**
52
- * Add a single run to AQ (CH path) with an optional back-pointer to the
53
- * issues-agent proposal that seeded this add. Use when bulk-adding runs that come
54
- * from different proposals — each row carries its own source_proposed_example_id.
55
- * For unrelated bulk adds, prefer plain List[UUID] on the same endpoint.
56
- */
57
- interface Body {
58
- run_id: string;
59
- source_proposed_example_id?: string | null;
60
- }
61
- }
62
- interface Variant2 {
63
- body: Array<Variant2.Body>;
64
- }
65
- namespace Variant2 {
66
- /**
67
- * Deprecated: use plain UUID list or AddRunToQueueByKeyRequest instead.
68
- */
69
- interface Body {
70
- /**
71
- * @deprecated
72
- */
73
- run_id: string;
74
- /**
75
- * @deprecated
76
- */
77
- parent_run_id?: string | null;
78
- /**
79
- * @deprecated
80
- */
81
- session_id?: string | null;
82
- /**
83
- * @deprecated
84
- */
85
- start_time?: string | null;
86
- /**
87
- * @deprecated
88
- */
89
- trace_id?: string | null;
90
- /**
91
- * @deprecated
92
- */
93
- trace_tier?: 'longlived' | 'shortlived' | null;
94
- }
95
- }
96
- }
97
- export interface RunUpdateParams {
98
- /**
99
- * Path param
100
- */
101
- queue_id: string;
102
- /**
103
- * Body param
104
- */
105
- added_at?: string | null;
106
- /**
107
- * Body param
108
- */
109
- last_reviewed_time?: string | null;
110
- }
111
- export interface RunListParams {
112
- archived?: boolean | null;
113
- include_stats?: boolean | null;
114
- limit?: number;
115
- offset?: number;
116
- status?: 'needs_my_review' | 'needs_others_review' | 'completed' | null;
117
- }
118
- export interface RunDeleteAllParams {
119
- delete_all?: boolean;
120
- exclude_run_ids?: Array<string> | null;
121
- run_ids?: Array<string> | null;
122
- }
123
- export interface RunDeleteQueueParams {
124
- queue_id: string;
125
- }
126
- export declare namespace Runs {
127
- export { type RunCreateResponse as RunCreateResponse, type RunUpdateResponse as RunUpdateResponse, type RunListResponse as RunListResponse, type RunDeleteAllResponse as RunDeleteAllResponse, type RunDeleteQueueResponse as RunDeleteQueueResponse, type RunCreateParams as RunCreateParams, type RunUpdateParams as RunUpdateParams, type RunListParams as RunListParams, type RunDeleteAllParams as RunDeleteAllParams, type RunDeleteQueueParams as RunDeleteQueueParams, };
128
- }
@@ -1,42 +0,0 @@
1
- // @ts-nocheck
2
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
- import { APIResource } from '../../core/resource.js';
4
- import { path } from '../../internal/utils/path.js';
5
- export class Runs extends APIResource {
6
- /**
7
- * Add Runs To Annotation Queue
8
- */
9
- create(queueID, params, options) {
10
- const { body } = params;
11
- return this._client.post(path `/api/v1/annotation-queues/${queueID}/runs`, { body: body, ...options });
12
- }
13
- /**
14
- * Update Run In Annotation Queue
15
- */
16
- update(queueRunID, params, options) {
17
- const { queue_id, ...body } = params;
18
- return this._client.patch(path `/api/v1/annotation-queues/${queue_id}/runs/${queueRunID}`, {
19
- body,
20
- ...options,
21
- });
22
- }
23
- /**
24
- * Get Runs From Annotation Queue
25
- */
26
- list(queueID, query = {}, options) {
27
- return this._client.get(path `/api/v1/annotation-queues/${queueID}/runs`, { query, ...options });
28
- }
29
- /**
30
- * Delete Runs From Annotation Queue
31
- */
32
- deleteAll(queueID, body, options) {
33
- return this._client.post(path `/api/v1/annotation-queues/${queueID}/runs/delete`, { body, ...options });
34
- }
35
- /**
36
- * Delete Run From Annotation Queue
37
- */
38
- deleteQueue(queueRunID, params, options) {
39
- const { queue_id } = params;
40
- return this._client.delete(path `/api/v1/annotation-queues/${queue_id}/runs/${queueRunID}`, options);
41
- }
42
- }
@@ -1,44 +0,0 @@
1
- "use strict";
2
- // @ts-nocheck
3
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
4
- Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.Commits = void 0;
6
- const resource_js_1 = require("../core/resource.cjs");
7
- const pagination_js_1 = require("../core/pagination.cjs");
8
- const path_js_1 = require("../internal/utils/path.cjs");
9
- class Commits extends resource_js_1.APIResource {
10
- /**
11
- * Creates a new commit in a repository. Requires authentication and write access
12
- * to the repository.
13
- */
14
- create(repo, params, options) {
15
- const { owner, ...body } = params;
16
- return this._client.post((0, path_js_1.path) `/commits/${owner}/${repo}`, { body, ...options });
17
- }
18
- /**
19
- * Retrieves a specific commit by hash, tag, or "latest" for a repository. This
20
- * endpoint supports both authenticated and unauthenticated access. Authenticated
21
- * users can access private repos, while unauthenticated users can only access
22
- * public repos. Commit resolution logic:
23
- *
24
- * - "latest" or empty: Get the most recent commit
25
- * - Less than 8 characters: Only check for tags
26
- * - 8 or more characters: Prioritize commit hash over tag, check both
27
- */
28
- retrieve(commit, params, options) {
29
- const { owner, repo, ...query } = params;
30
- return this._client.get((0, path_js_1.path) `/commits/${owner}/${repo}/${commit}`, { query, ...options });
31
- }
32
- /**
33
- * Lists all commits for a repository with pagination support. This endpoint
34
- * supports both authenticated and unauthenticated access. Authenticated users can
35
- * access private repos, while unauthenticated users can only access public repos.
36
- * The include_stats parameter controls whether download and view statistics are
37
- * computed (defaults to true).
38
- */
39
- list(repo, params, options) {
40
- const { owner, ...query } = params;
41
- return this._client.getAPIList((0, path_js_1.path) `/commits/${owner}/${repo}`, (pagination_js_1.OffsetPaginationCommits), { query, ...options });
42
- }
43
- }
44
- exports.Commits = Commits;
@@ -1,204 +0,0 @@
1
- import { APIResource } from '../core/resource.js';
2
- import { APIPromise } from '../core/api-promise.js';
3
- import { OffsetPaginationCommits, type OffsetPaginationCommitsParams, PagePromise } from '../core/pagination.js';
4
- import { RequestOptions } from '../internal/request-options.js';
5
- export declare class Commits extends APIResource {
6
- /**
7
- * Creates a new commit in a repository. Requires authentication and write access
8
- * to the repository.
9
- */
10
- create(repo: string, params: CommitCreateParams, options?: RequestOptions): APIPromise<CommitCreateResponse>;
11
- /**
12
- * Retrieves a specific commit by hash, tag, or "latest" for a repository. This
13
- * endpoint supports both authenticated and unauthenticated access. Authenticated
14
- * users can access private repos, while unauthenticated users can only access
15
- * public repos. Commit resolution logic:
16
- *
17
- * - "latest" or empty: Get the most recent commit
18
- * - Less than 8 characters: Only check for tags
19
- * - 8 or more characters: Prioritize commit hash over tag, check both
20
- */
21
- retrieve(commit: string, params: CommitRetrieveParams, options?: RequestOptions): APIPromise<CommitRetrieveResponse>;
22
- /**
23
- * Lists all commits for a repository with pagination support. This endpoint
24
- * supports both authenticated and unauthenticated access. Authenticated users can
25
- * access private repos, while unauthenticated users can only access public repos.
26
- * The include_stats parameter controls whether download and view statistics are
27
- * computed (defaults to true).
28
- */
29
- list(repo: string, params: CommitListParams, options?: RequestOptions): PagePromise<CommitWithLookupsOffsetPaginationCommits, CommitWithLookups>;
30
- }
31
- export type CommitWithLookupsOffsetPaginationCommits = OffsetPaginationCommits<CommitWithLookups>;
32
- /**
33
- * Response model for get_commit_manifest.
34
- */
35
- export interface CommitManifestResponse {
36
- commit_hash: string;
37
- manifest: {
38
- [key: string]: unknown;
39
- };
40
- examples?: Array<CommitManifestResponse.Example> | null;
41
- }
42
- export declare namespace CommitManifestResponse {
43
- /**
44
- * Response model for example runs
45
- */
46
- interface Example {
47
- id: string;
48
- session_id: string;
49
- inputs?: {
50
- [key: string]: unknown;
51
- } | null;
52
- outputs?: {
53
- [key: string]: unknown;
54
- } | null;
55
- start_time?: string | null;
56
- }
57
- }
58
- export interface CommitWithLookups {
59
- /**
60
- * The commit ID
61
- */
62
- id?: string;
63
- /**
64
- * The hash of the commit
65
- */
66
- commit_hash?: string;
67
- /**
68
- * When the commit was created
69
- */
70
- created_at?: string;
71
- /**
72
- * Optional human-readable description for the commit
73
- */
74
- description?: string;
75
- /**
76
- * Example run IDs associated with the commit
77
- */
78
- example_run_ids?: Array<string>;
79
- /**
80
- * Author's full name
81
- */
82
- full_name?: string;
83
- /**
84
- * The manifest of the commit
85
- */
86
- manifest?: unknown;
87
- /**
88
- * The SHA of the manifest
89
- */
90
- manifest_sha?: Array<number>;
91
- /**
92
- * Number of API downloads
93
- */
94
- num_downloads?: number;
95
- /**
96
- * Number of web views
97
- */
98
- num_views?: number;
99
- /**
100
- * The hash of the parent commit
101
- */
102
- parent_commit_hash?: string;
103
- /**
104
- * The ID of the parent commit
105
- */
106
- parent_id?: string;
107
- /**
108
- * Repository ID
109
- */
110
- repo_id?: string;
111
- /**
112
- * When the commit was last updated
113
- */
114
- updated_at?: string;
115
- }
116
- export interface CommitCreateResponse {
117
- commit?: CommitWithLookups;
118
- }
119
- export interface CommitRetrieveResponse {
120
- commit_hash?: string;
121
- description?: string;
122
- examples?: Array<CommitRetrieveResponse.Example>;
123
- is_draft?: boolean;
124
- manifest?: unknown;
125
- model_config?: unknown;
126
- model_provider?: string;
127
- }
128
- export declare namespace CommitRetrieveResponse {
129
- interface Example {
130
- id?: string;
131
- inputs?: unknown;
132
- outputs?: unknown;
133
- session_id?: string;
134
- start_time?: string;
135
- }
136
- }
137
- export interface CommitCreateParams {
138
- /**
139
- * Path param: Repository owner (tenant handle) or '-' for private repos
140
- */
141
- owner: string;
142
- /**
143
- * Body param
144
- */
145
- description?: string;
146
- /**
147
- * Body param
148
- */
149
- manifest?: unknown;
150
- /**
151
- * Body param
152
- */
153
- parent_commit?: string;
154
- /**
155
- * Body param: SkipWebhooks allows skipping webhook notifications. Can be true
156
- * (boolean) to skip all, or an array of webhook UUIDs to skip specific ones.
157
- */
158
- skip_webhooks?: unknown;
159
- }
160
- export interface CommitRetrieveParams {
161
- /**
162
- * Path param: Repository owner (tenant handle) or '-' for private repos
163
- */
164
- owner: string;
165
- /**
166
- * Path param: Repository handle
167
- */
168
- repo: string;
169
- /**
170
- * Query param
171
- */
172
- get_examples?: boolean;
173
- /**
174
- * Query param: Comma-separated list of optional fields: "model", "is_draft"
175
- */
176
- include?: string;
177
- /**
178
- * Query param: Deprecated: use Include instead
179
- */
180
- include_model?: boolean;
181
- /**
182
- * Query param
183
- */
184
- is_view?: boolean;
185
- }
186
- export interface CommitListParams extends OffsetPaginationCommitsParams {
187
- /**
188
- * Path param: Repository owner (tenant handle) or '-' for private repos
189
- */
190
- owner: string;
191
- /**
192
- * Query param: IncludeStats determines whether to compute num_downloads and
193
- * num_views
194
- */
195
- include_stats?: boolean;
196
- /**
197
- * Query param: Tag filters commits to only those with a specific tag (e.g.
198
- * "production", "staging")
199
- */
200
- tag?: string;
201
- }
202
- export declare namespace Commits {
203
- export { type CommitManifestResponse as CommitManifestResponse, type CommitWithLookups as CommitWithLookups, type CommitCreateResponse as CommitCreateResponse, type CommitRetrieveResponse as CommitRetrieveResponse, type CommitWithLookupsOffsetPaginationCommits as CommitWithLookupsOffsetPaginationCommits, type CommitCreateParams as CommitCreateParams, type CommitRetrieveParams as CommitRetrieveParams, type CommitListParams as CommitListParams, };
204
- }
@@ -1,40 +0,0 @@
1
- // @ts-nocheck
2
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
- import { APIResource } from '../core/resource.js';
4
- import { OffsetPaginationCommits } from '../core/pagination.js';
5
- import { path } from '../internal/utils/path.js';
6
- export class Commits extends APIResource {
7
- /**
8
- * Creates a new commit in a repository. Requires authentication and write access
9
- * to the repository.
10
- */
11
- create(repo, params, options) {
12
- const { owner, ...body } = params;
13
- return this._client.post(path `/commits/${owner}/${repo}`, { body, ...options });
14
- }
15
- /**
16
- * Retrieves a specific commit by hash, tag, or "latest" for a repository. This
17
- * endpoint supports both authenticated and unauthenticated access. Authenticated
18
- * users can access private repos, while unauthenticated users can only access
19
- * public repos. Commit resolution logic:
20
- *
21
- * - "latest" or empty: Get the most recent commit
22
- * - Less than 8 characters: Only check for tags
23
- * - 8 or more characters: Prioritize commit hash over tag, check both
24
- */
25
- retrieve(commit, params, options) {
26
- const { owner, repo, ...query } = params;
27
- return this._client.get(path `/commits/${owner}/${repo}/${commit}`, { query, ...options });
28
- }
29
- /**
30
- * Lists all commits for a repository with pagination support. This endpoint
31
- * supports both authenticated and unauthenticated access. Authenticated users can
32
- * access private repos, while unauthenticated users can only access public repos.
33
- * The include_stats parameter controls whether download and view statistics are
34
- * computed (defaults to true).
35
- */
36
- list(repo, params, options) {
37
- const { owner, ...query } = params;
38
- return this._client.getAPIList(path `/commits/${owner}/${repo}`, (OffsetPaginationCommits), { query, ...options });
39
- }
40
- }
@@ -1,15 +0,0 @@
1
- "use strict";
2
- // @ts-nocheck
3
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
4
- Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.Evaluators = void 0;
6
- const resource_js_1 = require("../core/resource.cjs");
7
- class Evaluators extends resource_js_1.APIResource {
8
- /**
9
- * List all run rules.
10
- */
11
- list(query = {}, options) {
12
- return this._client.get('/api/v1/runs/rules', { query, ...options });
13
- }
14
- }
15
- exports.Evaluators = Evaluators;
@@ -1,125 +0,0 @@
1
- import { APIResource } from '../core/resource.js';
2
- import { APIPromise } from '../core/api-promise.js';
3
- import { RequestOptions } from '../internal/request-options.js';
4
- export declare class Evaluators extends APIResource {
5
- /**
6
- * List all run rules.
7
- */
8
- list(query?: EvaluatorListParams | null | undefined, options?: RequestOptions): APIPromise<EvaluatorListResponse>;
9
- }
10
- export interface CodeEvaluatorTopLevel {
11
- code: string;
12
- language?: 'python' | 'javascript' | null;
13
- }
14
- /**
15
- * Run rules schema.
16
- */
17
- export interface Evaluator {
18
- id: string;
19
- created_at: string;
20
- display_name: string;
21
- evaluator_version: number;
22
- sampling_rate: number;
23
- tenant_id: string;
24
- updated_at: string;
25
- webhooks: Array<EvaluatorWebhook> | null;
26
- add_to_annotation_queue_id?: string | null;
27
- add_to_annotation_queue_name?: string | null;
28
- add_to_dataset_id?: string | null;
29
- add_to_dataset_name?: string | null;
30
- add_to_dataset_prefer_correction?: boolean;
31
- alerts?: Array<EvaluatorPagerdutyAlert> | null;
32
- alignment_annotation_queue_id?: string | null;
33
- backfill_completed_at?: string | null;
34
- backfill_error?: string | null;
35
- backfill_from?: string | null;
36
- backfill_id?: string | null;
37
- backfill_progress?: number | null;
38
- backfill_status?: string | null;
39
- code_evaluators?: Array<CodeEvaluatorTopLevel> | null;
40
- corrections_dataset_id?: string | null;
41
- dataset_id?: string | null;
42
- dataset_name?: string | null;
43
- evaluator_id?: string | null;
44
- evaluators?: Array<EvaluatorTopLevel> | null;
45
- extend_evaluator_trace_retention?: boolean | null;
46
- extend_only?: boolean;
47
- filter?: string | null;
48
- group_by?: 'thread_id' | null;
49
- include_extended_stats?: boolean;
50
- is_enabled?: boolean;
51
- num_few_shot_examples?: number | null;
52
- session_id?: string | null;
53
- session_name?: string | null;
54
- spend_limit?: Evaluator.SpendLimit | null;
55
- spend_usd?: number | null;
56
- trace_count?: number | null;
57
- trace_filter?: string | null;
58
- transient?: boolean;
59
- tree_filter?: string | null;
60
- use_corrections_dataset?: boolean;
61
- }
62
- export declare namespace Evaluator {
63
- interface SpendLimit {
64
- limit_usd: string;
65
- window: 'weekly';
66
- }
67
- }
68
- export interface EvaluatorPagerdutyAlert {
69
- routing_key: string;
70
- /**
71
- * Enum for severity.
72
- */
73
- severity?: 'critical' | 'warning' | 'error' | 'info' | null;
74
- summary?: string | null;
75
- /**
76
- * Enum for alert types.
77
- */
78
- type?: 'pagerduty' | null;
79
- }
80
- export interface EvaluatorTopLevel {
81
- /**
82
- * Evaluator structured output schema.
83
- */
84
- structured: EvaluatorTopLevel.Structured;
85
- }
86
- export declare namespace EvaluatorTopLevel {
87
- /**
88
- * Evaluator structured output schema.
89
- */
90
- interface Structured {
91
- hub_ref?: string | null;
92
- model?: {
93
- [key: string]: unknown;
94
- } | null;
95
- playground_settings_id?: string | null;
96
- prompt?: Array<Array<unknown>> | null;
97
- schema?: {
98
- [key: string]: unknown;
99
- } | null;
100
- template_format?: string | null;
101
- variable_mapping?: {
102
- [key: string]: string;
103
- } | null;
104
- }
105
- }
106
- export interface EvaluatorWebhook {
107
- url: string;
108
- headers?: {
109
- [key: string]: string;
110
- } | null;
111
- }
112
- export type EvaluatorListResponse = Array<Evaluator>;
113
- export interface EvaluatorListParams {
114
- id?: Array<string> | null;
115
- dataset_id?: string | null;
116
- evaluator_id?: string | null;
117
- include_backfill_progress?: boolean;
118
- name_contains?: string | null;
119
- session_id?: string | null;
120
- tag_value_id?: Array<string> | null;
121
- type?: 'session' | 'dataset' | null;
122
- }
123
- export declare namespace Evaluators {
124
- export { type CodeEvaluatorTopLevel as CodeEvaluatorTopLevel, type Evaluator as Evaluator, type EvaluatorPagerdutyAlert as EvaluatorPagerdutyAlert, type EvaluatorTopLevel as EvaluatorTopLevel, type EvaluatorWebhook as EvaluatorWebhook, type EvaluatorListResponse as EvaluatorListResponse, type EvaluatorListParams as EvaluatorListParams, };
125
- }
@@ -1,11 +0,0 @@
1
- // @ts-nocheck
2
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
- import { APIResource } from '../core/resource.js';
4
- export class Evaluators extends APIResource {
5
- /**
6
- * List all run rules.
7
- */
8
- list(query = {}, options) {
9
- return this._client.get('/api/v1/runs/rules', { query, ...options });
10
- }
11
- }
@@ -1,24 +0,0 @@
1
- "use strict";
2
- // @ts-nocheck
3
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
4
- Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.Bulk = void 0;
6
- const resource_js_1 = require("../../core/resource.cjs");
7
- class Bulk extends resource_js_1.APIResource {
8
- /**
9
- * Create bulk examples.
10
- */
11
- create(params, options) {
12
- const { body } = params;
13
- return this._client.post('/api/v1/examples/bulk', { body: body, ...options });
14
- }
15
- /**
16
- * Legacy update examples in bulk. For update involving attachments, use PATCH
17
- * /v1/platform/datasets/{dataset_id}/examples instead.
18
- */
19
- patchAll(params, options) {
20
- const { body } = params;
21
- return this._client.patch('/api/v1/examples/bulk', { body: body, ...options });
22
- }
23
- }
24
- exports.Bulk = Bulk;