vellum-ai 0.3.4 → 0.3.6
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/Client.d.ts +5 -22
- package/Client.js +32 -31
- package/api/client/requests/GenerateBodyRequest.d.ts +3 -4
- package/api/client/requests/SearchRequestBodyRequest.d.ts +1 -11
- package/api/client/requests/SubmitCompletionActualsRequest.d.ts +1 -1
- package/api/resources/deployments/client/Client.d.ts +1 -1
- package/api/resources/deployments/client/Client.js +10 -4
- package/api/resources/deployments/client/requests/DeploymentsListRequest.d.ts +1 -3
- package/api/resources/documentIndexes/client/Client.d.ts +1 -3
- package/api/resources/documentIndexes/client/Client.js +7 -5
- package/api/resources/documentIndexes/client/requests/DocumentIndexCreateRequest.d.ts +0 -2
- package/api/resources/documents/client/Client.d.ts +1 -3
- package/api/resources/documents/client/Client.js +13 -7
- package/api/resources/documents/client/requests/PatchedDocumentUpdateRequest.d.ts +1 -3
- package/api/resources/modelVersions/client/Client.d.ts +1 -1
- package/api/resources/modelVersions/client/Client.js +4 -2
- package/api/resources/registeredPrompts/client/Client.d.ts +11 -6
- package/api/resources/registeredPrompts/client/Client.js +14 -7
- package/api/resources/registeredPrompts/client/requests/RegisterPromptRequestRequest.d.ts +11 -6
- package/api/resources/sandboxes/client/Client.d.ts +4 -2
- package/api/resources/sandboxes/client/Client.js +10 -4
- package/api/resources/sandboxes/client/requests/UpsertSandboxScenarioRequestRequest.d.ts +2 -0
- package/api/resources/testSuites/client/Client.d.ts +2 -2
- package/api/resources/testSuites/client/Client.js +8 -4
- package/api/resources/workflowDeployments/client/Client.js +3 -1
- package/api/resources/workflowDeployments/client/requests/WorkflowDeploymentsListRequest.d.ts +1 -3
- package/core/fetcher/Fetcher.js +8 -1
- package/core/index.d.ts +1 -0
- package/core/index.js +1 -0
- package/core/runtime/index.d.ts +1 -0
- package/core/runtime/index.js +5 -0
- package/core/runtime/runtime.d.ts +8 -0
- package/core/runtime/runtime.js +82 -0
- package/core/streaming-fetcher/Stream.d.ts +4 -0
- package/core/streaming-fetcher/Stream.js +63 -5
- package/dist/Client.d.ts +5 -22
- package/dist/Client.js +32 -31
- package/dist/api/client/requests/GenerateBodyRequest.d.ts +3 -4
- package/dist/api/client/requests/SearchRequestBodyRequest.d.ts +1 -11
- package/dist/api/client/requests/SubmitCompletionActualsRequest.d.ts +1 -1
- package/dist/api/resources/deployments/client/Client.d.ts +1 -1
- package/dist/api/resources/deployments/client/Client.js +10 -4
- package/dist/api/resources/deployments/client/requests/DeploymentsListRequest.d.ts +1 -3
- package/dist/api/resources/documentIndexes/client/Client.d.ts +1 -3
- package/dist/api/resources/documentIndexes/client/Client.js +7 -5
- package/dist/api/resources/documentIndexes/client/requests/DocumentIndexCreateRequest.d.ts +0 -2
- package/dist/api/resources/documents/client/Client.d.ts +1 -3
- package/dist/api/resources/documents/client/Client.js +13 -7
- package/dist/api/resources/documents/client/requests/PatchedDocumentUpdateRequest.d.ts +1 -3
- package/dist/api/resources/modelVersions/client/Client.d.ts +1 -1
- package/dist/api/resources/modelVersions/client/Client.js +4 -2
- package/dist/api/resources/registeredPrompts/client/Client.d.ts +11 -6
- package/dist/api/resources/registeredPrompts/client/Client.js +14 -7
- package/dist/api/resources/registeredPrompts/client/requests/RegisterPromptRequestRequest.d.ts +11 -6
- package/dist/api/resources/sandboxes/client/Client.d.ts +4 -2
- package/dist/api/resources/sandboxes/client/Client.js +10 -4
- package/dist/api/resources/sandboxes/client/requests/UpsertSandboxScenarioRequestRequest.d.ts +2 -0
- package/dist/api/resources/testSuites/client/Client.d.ts +2 -2
- package/dist/api/resources/testSuites/client/Client.js +8 -4
- package/dist/api/resources/workflowDeployments/client/Client.js +3 -1
- package/dist/api/resources/workflowDeployments/client/requests/WorkflowDeploymentsListRequest.d.ts +1 -3
- package/dist/core/fetcher/Fetcher.js +8 -1
- package/dist/core/index.d.ts +1 -0
- package/dist/core/index.js +1 -0
- package/dist/core/runtime/index.d.ts +1 -0
- package/dist/core/runtime/index.js +5 -0
- package/dist/core/runtime/runtime.d.ts +8 -0
- package/dist/core/runtime/runtime.js +82 -0
- package/dist/core/streaming-fetcher/Stream.d.ts +4 -0
- package/dist/core/streaming-fetcher/Stream.js +63 -5
- package/jest.config.js +5 -0
- package/package.json +6 -2
- package/tests/client.test.ts +11 -0
package/Client.d.ts
CHANGED
|
@@ -27,9 +27,6 @@ export declare class VellumClient {
|
|
|
27
27
|
constructor(_options: VellumClient.Options);
|
|
28
28
|
/**
|
|
29
29
|
* Executes a deployed Prompt and returns the result.
|
|
30
|
-
*
|
|
31
|
-
* Note: This endpoint temporarily does not support prompts with function calling, support is coming soon.
|
|
32
|
-
* In the meantime, we recommend still using the `/generate` endpoint for prompts with function calling.
|
|
33
30
|
* @throws {@link Vellum.BadRequestError}
|
|
34
31
|
* @throws {@link Vellum.ForbiddenError}
|
|
35
32
|
* @throws {@link Vellum.NotFoundError}
|
|
@@ -38,9 +35,6 @@ export declare class VellumClient {
|
|
|
38
35
|
executePrompt(request: Vellum.ExecutePromptRequest, requestOptions?: VellumClient.RequestOptions): Promise<Vellum.ExecutePromptResponse>;
|
|
39
36
|
/**
|
|
40
37
|
* Executes a deployed Prompt and streams back the results.
|
|
41
|
-
*
|
|
42
|
-
* Note: This endpoint temporarily does not support prompts with function calling, support is coming soon.
|
|
43
|
-
* In the meantime, we recommend still using the `/generate-stream` endpoint for prompts with function calling
|
|
44
38
|
*/
|
|
45
39
|
executePromptStream(request: Vellum.ExecutePromptStreamRequest, requestOptions?: VellumClient.RequestOptions): Promise<core.Stream<Vellum.ExecutePromptEvent>>;
|
|
46
40
|
/**
|
|
@@ -65,10 +59,9 @@ export declare class VellumClient {
|
|
|
65
59
|
*
|
|
66
60
|
* @example
|
|
67
61
|
* await vellum.generate({
|
|
68
|
-
* requests: [
|
|
69
|
-
*
|
|
70
|
-
*
|
|
71
|
-
* }
|
|
62
|
+
* requests: [{
|
|
63
|
+
* inputValues: {}
|
|
64
|
+
* }]
|
|
72
65
|
* })
|
|
73
66
|
*/
|
|
74
67
|
generate(request: Vellum.GenerateBodyRequest, requestOptions?: VellumClient.RequestOptions): Promise<Vellum.GenerateResponse>;
|
|
@@ -88,17 +81,7 @@ export declare class VellumClient {
|
|
|
88
81
|
*
|
|
89
82
|
* @example
|
|
90
83
|
* await vellum.search({
|
|
91
|
-
* query: "
|
|
92
|
-
* options: {
|
|
93
|
-
* weights: {},
|
|
94
|
-
* resultMerging: {},
|
|
95
|
-
* filters: {
|
|
96
|
-
* metadata: {
|
|
97
|
-
* combinator: Vellum.MetadataFilterRuleCombinator.And,
|
|
98
|
-
* operator: Vellum.LogicalOperator.Equals
|
|
99
|
-
* }
|
|
100
|
-
* }
|
|
101
|
-
* }
|
|
84
|
+
* query: "query"
|
|
102
85
|
* })
|
|
103
86
|
*/
|
|
104
87
|
search(request: Vellum.SearchRequestBodyRequest, requestOptions?: VellumClient.RequestOptions): Promise<Vellum.SearchResponse>;
|
|
@@ -112,7 +95,7 @@ export declare class VellumClient {
|
|
|
112
95
|
*
|
|
113
96
|
* @example
|
|
114
97
|
* await vellum.submitCompletionActuals({
|
|
115
|
-
* actuals: []
|
|
98
|
+
* actuals: [{}]
|
|
116
99
|
* })
|
|
117
100
|
*/
|
|
118
101
|
submitCompletionActuals(request: Vellum.SubmitCompletionActualsRequest, requestOptions?: VellumClient.RequestOptions): Promise<void>;
|
package/Client.js
CHANGED
|
@@ -59,9 +59,6 @@ class VellumClient {
|
|
|
59
59
|
}
|
|
60
60
|
/**
|
|
61
61
|
* Executes a deployed Prompt and returns the result.
|
|
62
|
-
*
|
|
63
|
-
* Note: This endpoint temporarily does not support prompts with function calling, support is coming soon.
|
|
64
|
-
* In the meantime, we recommend still using the `/generate` endpoint for prompts with function calling.
|
|
65
62
|
* @throws {@link Vellum.BadRequestError}
|
|
66
63
|
* @throws {@link Vellum.ForbiddenError}
|
|
67
64
|
* @throws {@link Vellum.NotFoundError}
|
|
@@ -78,7 +75,9 @@ class VellumClient {
|
|
|
78
75
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
79
76
|
"X-Fern-Language": "JavaScript",
|
|
80
77
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
81
|
-
"X-Fern-SDK-Version": "0.3.
|
|
78
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
79
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
80
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
82
81
|
},
|
|
83
82
|
contentType: "application/json",
|
|
84
83
|
body: yield serializers.ExecutePromptRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -127,9 +126,6 @@ class VellumClient {
|
|
|
127
126
|
}
|
|
128
127
|
/**
|
|
129
128
|
* Executes a deployed Prompt and streams back the results.
|
|
130
|
-
*
|
|
131
|
-
* Note: This endpoint temporarily does not support prompts with function calling, support is coming soon.
|
|
132
|
-
* In the meantime, we recommend still using the `/generate-stream` endpoint for prompts with function calling
|
|
133
129
|
*/
|
|
134
130
|
executePromptStream(request, requestOptions) {
|
|
135
131
|
var _a;
|
|
@@ -142,7 +138,9 @@ class VellumClient {
|
|
|
142
138
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
143
139
|
"X-Fern-Language": "JavaScript",
|
|
144
140
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
145
|
-
"X-Fern-SDK-Version": "0.3.
|
|
141
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
142
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
143
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
146
144
|
},
|
|
147
145
|
contentType: "application/json",
|
|
148
146
|
body: yield serializers.ExecutePromptStreamRequest.jsonOrThrow(request, {
|
|
@@ -215,7 +213,9 @@ class VellumClient {
|
|
|
215
213
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
216
214
|
"X-Fern-Language": "JavaScript",
|
|
217
215
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
218
|
-
"X-Fern-SDK-Version": "0.3.
|
|
216
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
217
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
218
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
219
219
|
},
|
|
220
220
|
contentType: "application/json",
|
|
221
221
|
body: yield serializers.ExecuteWorkflowRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -274,7 +274,9 @@ class VellumClient {
|
|
|
274
274
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
275
275
|
"X-Fern-Language": "JavaScript",
|
|
276
276
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
277
|
-
"X-Fern-SDK-Version": "0.3.
|
|
277
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
278
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
279
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
278
280
|
},
|
|
279
281
|
contentType: "application/json",
|
|
280
282
|
body: yield serializers.ExecuteWorkflowStreamRequest.jsonOrThrow(request, {
|
|
@@ -339,10 +341,9 @@ class VellumClient {
|
|
|
339
341
|
*
|
|
340
342
|
* @example
|
|
341
343
|
* await vellum.generate({
|
|
342
|
-
* requests: [
|
|
343
|
-
*
|
|
344
|
-
*
|
|
345
|
-
* }
|
|
344
|
+
* requests: [{
|
|
345
|
+
* inputValues: {}
|
|
346
|
+
* }]
|
|
346
347
|
* })
|
|
347
348
|
*/
|
|
348
349
|
generate(request, requestOptions) {
|
|
@@ -356,7 +357,9 @@ class VellumClient {
|
|
|
356
357
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
357
358
|
"X-Fern-Language": "JavaScript",
|
|
358
359
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
359
|
-
"X-Fern-SDK-Version": "0.3.
|
|
360
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
361
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
362
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
360
363
|
},
|
|
361
364
|
contentType: "application/json",
|
|
362
365
|
body: yield serializers.GenerateBodyRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -419,7 +422,9 @@ class VellumClient {
|
|
|
419
422
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
420
423
|
"X-Fern-Language": "JavaScript",
|
|
421
424
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
422
|
-
"X-Fern-SDK-Version": "0.3.
|
|
425
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
426
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
427
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
423
428
|
},
|
|
424
429
|
contentType: "application/json",
|
|
425
430
|
body: yield serializers.GenerateStreamBodyRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -483,17 +488,7 @@ class VellumClient {
|
|
|
483
488
|
*
|
|
484
489
|
* @example
|
|
485
490
|
* await vellum.search({
|
|
486
|
-
* query: "
|
|
487
|
-
* options: {
|
|
488
|
-
* weights: {},
|
|
489
|
-
* resultMerging: {},
|
|
490
|
-
* filters: {
|
|
491
|
-
* metadata: {
|
|
492
|
-
* combinator: Vellum.MetadataFilterRuleCombinator.And,
|
|
493
|
-
* operator: Vellum.LogicalOperator.Equals
|
|
494
|
-
* }
|
|
495
|
-
* }
|
|
496
|
-
* }
|
|
491
|
+
* query: "query"
|
|
497
492
|
* })
|
|
498
493
|
*/
|
|
499
494
|
search(request, requestOptions) {
|
|
@@ -507,7 +502,9 @@ class VellumClient {
|
|
|
507
502
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
508
503
|
"X-Fern-Language": "JavaScript",
|
|
509
504
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
510
|
-
"X-Fern-SDK-Version": "0.3.
|
|
505
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
506
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
507
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
511
508
|
},
|
|
512
509
|
contentType: "application/json",
|
|
513
510
|
body: yield serializers.SearchRequestBodyRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -562,7 +559,7 @@ class VellumClient {
|
|
|
562
559
|
*
|
|
563
560
|
* @example
|
|
564
561
|
* await vellum.submitCompletionActuals({
|
|
565
|
-
* actuals: []
|
|
562
|
+
* actuals: [{}]
|
|
566
563
|
* })
|
|
567
564
|
*/
|
|
568
565
|
submitCompletionActuals(request, requestOptions) {
|
|
@@ -576,7 +573,9 @@ class VellumClient {
|
|
|
576
573
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
577
574
|
"X-Fern-Language": "JavaScript",
|
|
578
575
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
579
|
-
"X-Fern-SDK-Version": "0.3.
|
|
576
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
577
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
578
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
580
579
|
},
|
|
581
580
|
contentType: "application/json",
|
|
582
581
|
body: yield serializers.SubmitCompletionActualsRequest.jsonOrThrow(request, {
|
|
@@ -639,7 +638,9 @@ class VellumClient {
|
|
|
639
638
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
640
639
|
"X-Fern-Language": "JavaScript",
|
|
641
640
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
642
|
-
"X-Fern-SDK-Version": "0.3.
|
|
641
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
642
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
643
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
643
644
|
},
|
|
644
645
|
contentType: "application/json",
|
|
645
646
|
body: yield serializers.SubmitWorkflowExecutionActualsRequest.jsonOrThrow(request, {
|
|
@@ -5,17 +5,7 @@ import * as Vellum from "../..";
|
|
|
5
5
|
/**
|
|
6
6
|
* @example
|
|
7
7
|
* {
|
|
8
|
-
* query: "
|
|
9
|
-
* options: {
|
|
10
|
-
* weights: {},
|
|
11
|
-
* resultMerging: {},
|
|
12
|
-
* filters: {
|
|
13
|
-
* metadata: {
|
|
14
|
-
* combinator: Vellum.MetadataFilterRuleCombinator.And,
|
|
15
|
-
* operator: Vellum.LogicalOperator.Equals
|
|
16
|
-
* }
|
|
17
|
-
* }
|
|
18
|
-
* }
|
|
8
|
+
* query: "query"
|
|
19
9
|
* }
|
|
20
10
|
*/
|
|
21
11
|
export interface SearchRequestBodyRequest {
|
|
@@ -22,7 +22,7 @@ export declare class Deployments {
|
|
|
22
22
|
* Used to retrieve a deployment given its ID or name.
|
|
23
23
|
*
|
|
24
24
|
* @example
|
|
25
|
-
* await vellum.deployments.retrieve("
|
|
25
|
+
* await vellum.deployments.retrieve("id")
|
|
26
26
|
*/
|
|
27
27
|
retrieve(id: string, requestOptions?: Deployments.RequestOptions): Promise<Vellum.DeploymentRead>;
|
|
28
28
|
retrieveProviderPayload(request: Vellum.DeploymentProviderPayloadRequest, requestOptions?: Deployments.RequestOptions): Promise<Vellum.DeploymentProviderPayloadResponse>;
|
|
@@ -73,7 +73,9 @@ class Deployments {
|
|
|
73
73
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
74
74
|
"X-Fern-Language": "JavaScript",
|
|
75
75
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
76
|
-
"X-Fern-SDK-Version": "0.3.
|
|
76
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
77
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
78
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
77
79
|
},
|
|
78
80
|
contentType: "application/json",
|
|
79
81
|
queryParameters: _queryParams,
|
|
@@ -113,7 +115,7 @@ class Deployments {
|
|
|
113
115
|
* Used to retrieve a deployment given its ID or name.
|
|
114
116
|
*
|
|
115
117
|
* @example
|
|
116
|
-
* await vellum.deployments.retrieve("
|
|
118
|
+
* await vellum.deployments.retrieve("id")
|
|
117
119
|
*/
|
|
118
120
|
retrieve(id, requestOptions) {
|
|
119
121
|
var _a;
|
|
@@ -126,7 +128,9 @@ class Deployments {
|
|
|
126
128
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
127
129
|
"X-Fern-Language": "JavaScript",
|
|
128
130
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
129
|
-
"X-Fern-SDK-Version": "0.3.
|
|
131
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
132
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
133
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
130
134
|
},
|
|
131
135
|
contentType: "application/json",
|
|
132
136
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : undefined,
|
|
@@ -172,7 +176,9 @@ class Deployments {
|
|
|
172
176
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
173
177
|
"X-Fern-Language": "JavaScript",
|
|
174
178
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
175
|
-
"X-Fern-SDK-Version": "0.3.
|
|
179
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
180
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
181
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
176
182
|
},
|
|
177
183
|
contentType: "application/json",
|
|
178
184
|
body: yield serializers.DeploymentProviderPayloadRequest.jsonOrThrow(request, {
|
|
@@ -24,8 +24,6 @@ export declare class DocumentIndexes {
|
|
|
24
24
|
* await vellum.documentIndexes.create({
|
|
25
25
|
* label: "My Document Index",
|
|
26
26
|
* name: "my-document-index",
|
|
27
|
-
* status: Vellum.EntityStatus.Active,
|
|
28
|
-
* environment: Vellum.EnvironmentEnum.Development,
|
|
29
27
|
* indexingConfig: {
|
|
30
28
|
* "chunking": {
|
|
31
29
|
* "chunker_name": "sentence-chunker",
|
|
@@ -50,7 +48,7 @@ export declare class DocumentIndexes {
|
|
|
50
48
|
* Used to retrieve a Document Index given its ID or name.
|
|
51
49
|
*
|
|
52
50
|
* @example
|
|
53
|
-
* await vellum.documentIndexes.retrieve("
|
|
51
|
+
* await vellum.documentIndexes.retrieve("id")
|
|
54
52
|
*/
|
|
55
53
|
retrieve(id: string, requestOptions?: DocumentIndexes.RequestOptions): Promise<Vellum.DocumentIndexRead>;
|
|
56
54
|
}
|
|
@@ -55,8 +55,6 @@ class DocumentIndexes {
|
|
|
55
55
|
* await vellum.documentIndexes.create({
|
|
56
56
|
* label: "My Document Index",
|
|
57
57
|
* name: "my-document-index",
|
|
58
|
-
* status: Vellum.EntityStatus.Active,
|
|
59
|
-
* environment: Vellum.EnvironmentEnum.Development,
|
|
60
58
|
* indexingConfig: {
|
|
61
59
|
* "chunking": {
|
|
62
60
|
* "chunker_name": "sentence-chunker",
|
|
@@ -87,7 +85,9 @@ class DocumentIndexes {
|
|
|
87
85
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
88
86
|
"X-Fern-Language": "JavaScript",
|
|
89
87
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
90
|
-
"X-Fern-SDK-Version": "0.3.
|
|
88
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
89
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
90
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
91
91
|
},
|
|
92
92
|
contentType: "application/json",
|
|
93
93
|
body: yield serializers.DocumentIndexCreateRequest.jsonOrThrow(request, {
|
|
@@ -129,7 +129,7 @@ class DocumentIndexes {
|
|
|
129
129
|
* Used to retrieve a Document Index given its ID or name.
|
|
130
130
|
*
|
|
131
131
|
* @example
|
|
132
|
-
* await vellum.documentIndexes.retrieve("
|
|
132
|
+
* await vellum.documentIndexes.retrieve("id")
|
|
133
133
|
*/
|
|
134
134
|
retrieve(id, requestOptions) {
|
|
135
135
|
var _a;
|
|
@@ -142,7 +142,9 @@ class DocumentIndexes {
|
|
|
142
142
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
143
143
|
"X-Fern-Language": "JavaScript",
|
|
144
144
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
145
|
-
"X-Fern-SDK-Version": "0.3.
|
|
145
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
146
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
147
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
146
148
|
},
|
|
147
149
|
contentType: "application/json",
|
|
148
150
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : undefined,
|
|
@@ -7,8 +7,6 @@ import * as Vellum from "../../../..";
|
|
|
7
7
|
* {
|
|
8
8
|
* label: "My Document Index",
|
|
9
9
|
* name: "my-document-index",
|
|
10
|
-
* status: Vellum.EntityStatus.Active,
|
|
11
|
-
* environment: Vellum.EnvironmentEnum.Development,
|
|
12
10
|
* indexingConfig: {
|
|
13
11
|
* "chunking": {
|
|
14
12
|
* "chunker_name": "sentence-chunker",
|
|
@@ -31,9 +31,7 @@ export declare class Documents {
|
|
|
31
31
|
* Update a Document, keying off of its Vellum-generated ID. Particularly useful for updating its metadata.
|
|
32
32
|
*
|
|
33
33
|
* @example
|
|
34
|
-
* await vellum.documents.partialUpdate("
|
|
35
|
-
* status: "ACTIVE"
|
|
36
|
-
* })
|
|
34
|
+
* await vellum.documents.partialUpdate("id", {})
|
|
37
35
|
*/
|
|
38
36
|
partialUpdate(id: string, request?: Vellum.PatchedDocumentUpdateRequest, requestOptions?: Documents.RequestOptions): Promise<Vellum.DocumentRead>;
|
|
39
37
|
/**
|
|
@@ -81,7 +81,9 @@ class Documents {
|
|
|
81
81
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
82
82
|
"X-Fern-Language": "JavaScript",
|
|
83
83
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
84
|
-
"X-Fern-SDK-Version": "0.3.
|
|
84
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
85
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
86
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
85
87
|
},
|
|
86
88
|
contentType: "application/json",
|
|
87
89
|
queryParameters: _queryParams,
|
|
@@ -128,7 +130,9 @@ class Documents {
|
|
|
128
130
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
129
131
|
"X-Fern-Language": "JavaScript",
|
|
130
132
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
131
|
-
"X-Fern-SDK-Version": "0.3.
|
|
133
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
134
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
135
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
132
136
|
},
|
|
133
137
|
contentType: "application/json",
|
|
134
138
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : undefined,
|
|
@@ -162,9 +166,7 @@ class Documents {
|
|
|
162
166
|
* Update a Document, keying off of its Vellum-generated ID. Particularly useful for updating its metadata.
|
|
163
167
|
*
|
|
164
168
|
* @example
|
|
165
|
-
* await vellum.documents.partialUpdate("
|
|
166
|
-
* status: "ACTIVE"
|
|
167
|
-
* })
|
|
169
|
+
* await vellum.documents.partialUpdate("id", {})
|
|
168
170
|
*/
|
|
169
171
|
partialUpdate(id, request = {}, requestOptions) {
|
|
170
172
|
var _a;
|
|
@@ -177,7 +179,9 @@ class Documents {
|
|
|
177
179
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
178
180
|
"X-Fern-Language": "JavaScript",
|
|
179
181
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
180
|
-
"X-Fern-SDK-Version": "0.3.
|
|
182
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
183
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
184
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
181
185
|
},
|
|
182
186
|
contentType: "application/json",
|
|
183
187
|
body: yield serializers.PatchedDocumentUpdateRequest.jsonOrThrow(request, {
|
|
@@ -261,7 +265,9 @@ class Documents {
|
|
|
261
265
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
262
266
|
"X-Fern-Language": "JavaScript",
|
|
263
267
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
264
|
-
"X-Fern-SDK-Version": "0.3.
|
|
268
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
269
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
270
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
265
271
|
},
|
|
266
272
|
contentType: "multipart/form-data; boundary=" + _request.getBoundary(),
|
|
267
273
|
body: _request,
|
|
@@ -21,7 +21,7 @@ export declare class ModelVersions {
|
|
|
21
21
|
* Deprecated. Use the `deployments/provider-payload` endpoint to fetch information that we send to Model providers.
|
|
22
22
|
*
|
|
23
23
|
* @example
|
|
24
|
-
* await vellum.modelVersions.retrieve("
|
|
24
|
+
* await vellum.modelVersions.retrieve("id")
|
|
25
25
|
*/
|
|
26
26
|
retrieve(id: string, requestOptions?: ModelVersions.RequestOptions): Promise<Vellum.ModelVersionRead>;
|
|
27
27
|
}
|
|
@@ -52,7 +52,7 @@ class ModelVersions {
|
|
|
52
52
|
* Deprecated. Use the `deployments/provider-payload` endpoint to fetch information that we send to Model providers.
|
|
53
53
|
*
|
|
54
54
|
* @example
|
|
55
|
-
* await vellum.modelVersions.retrieve("
|
|
55
|
+
* await vellum.modelVersions.retrieve("id")
|
|
56
56
|
*/
|
|
57
57
|
retrieve(id, requestOptions) {
|
|
58
58
|
var _a;
|
|
@@ -65,7 +65,9 @@ class ModelVersions {
|
|
|
65
65
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
66
66
|
"X-Fern-Language": "JavaScript",
|
|
67
67
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
68
|
-
"X-Fern-SDK-Version": "0.3.
|
|
68
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
69
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
70
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
69
71
|
},
|
|
70
72
|
contentType: "application/json",
|
|
71
73
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : undefined,
|
|
@@ -28,17 +28,22 @@ export declare class RegisteredPrompts {
|
|
|
28
28
|
*
|
|
29
29
|
* @example
|
|
30
30
|
* await vellum.registeredPrompts.registerPrompt({
|
|
31
|
-
* label: "
|
|
32
|
-
* name: "
|
|
31
|
+
* label: "label",
|
|
32
|
+
* name: "name",
|
|
33
33
|
* prompt: {
|
|
34
34
|
* promptBlockData: {
|
|
35
35
|
* version: 1,
|
|
36
|
-
* blocks: [
|
|
36
|
+
* blocks: [{
|
|
37
|
+
* id: "id",
|
|
38
|
+
* blockType: Vellum.BlockTypeEnum.ChatMessage,
|
|
39
|
+
* properties: {}
|
|
40
|
+
* }]
|
|
37
41
|
* },
|
|
38
|
-
* inputVariables: [
|
|
42
|
+
* inputVariables: [{
|
|
43
|
+
* key: "key"
|
|
44
|
+
* }]
|
|
39
45
|
* },
|
|
40
|
-
*
|
|
41
|
-
* model: "string",
|
|
46
|
+
* model: "model",
|
|
42
47
|
* parameters: {
|
|
43
48
|
* temperature: 1.1,
|
|
44
49
|
* maxTokens: 1,
|
|
@@ -60,17 +60,22 @@ class RegisteredPrompts {
|
|
|
60
60
|
*
|
|
61
61
|
* @example
|
|
62
62
|
* await vellum.registeredPrompts.registerPrompt({
|
|
63
|
-
* label: "
|
|
64
|
-
* name: "
|
|
63
|
+
* label: "label",
|
|
64
|
+
* name: "name",
|
|
65
65
|
* prompt: {
|
|
66
66
|
* promptBlockData: {
|
|
67
67
|
* version: 1,
|
|
68
|
-
* blocks: [
|
|
68
|
+
* blocks: [{
|
|
69
|
+
* id: "id",
|
|
70
|
+
* blockType: Vellum.BlockTypeEnum.ChatMessage,
|
|
71
|
+
* properties: {}
|
|
72
|
+
* }]
|
|
69
73
|
* },
|
|
70
|
-
* inputVariables: [
|
|
74
|
+
* inputVariables: [{
|
|
75
|
+
* key: "key"
|
|
76
|
+
* }]
|
|
71
77
|
* },
|
|
72
|
-
*
|
|
73
|
-
* model: "string",
|
|
78
|
+
* model: "model",
|
|
74
79
|
* parameters: {
|
|
75
80
|
* temperature: 1.1,
|
|
76
81
|
* maxTokens: 1,
|
|
@@ -91,7 +96,9 @@ class RegisteredPrompts {
|
|
|
91
96
|
X_API_KEY: yield core.Supplier.get(this._options.apiKey),
|
|
92
97
|
"X-Fern-Language": "JavaScript",
|
|
93
98
|
"X-Fern-SDK-Name": "vellum-ai",
|
|
94
|
-
"X-Fern-SDK-Version": "0.3.
|
|
99
|
+
"X-Fern-SDK-Version": "0.3.6",
|
|
100
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
101
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
95
102
|
},
|
|
96
103
|
contentType: "application/json",
|
|
97
104
|
body: yield serializers.RegisterPromptRequestRequest.jsonOrThrow(request, {
|
|
@@ -5,17 +5,22 @@ import * as Vellum from "../../../..";
|
|
|
5
5
|
/**
|
|
6
6
|
* @example
|
|
7
7
|
* {
|
|
8
|
-
* label: "
|
|
9
|
-
* name: "
|
|
8
|
+
* label: "label",
|
|
9
|
+
* name: "name",
|
|
10
10
|
* prompt: {
|
|
11
11
|
* promptBlockData: {
|
|
12
12
|
* version: 1,
|
|
13
|
-
* blocks: [
|
|
13
|
+
* blocks: [{
|
|
14
|
+
* id: "id",
|
|
15
|
+
* blockType: Vellum.BlockTypeEnum.ChatMessage,
|
|
16
|
+
* properties: {}
|
|
17
|
+
* }]
|
|
14
18
|
* },
|
|
15
|
-
* inputVariables: [
|
|
19
|
+
* inputVariables: [{
|
|
20
|
+
* key: "key"
|
|
21
|
+
* }]
|
|
16
22
|
* },
|
|
17
|
-
*
|
|
18
|
-
* model: "string",
|
|
23
|
+
* model: "model",
|
|
19
24
|
* parameters: {
|
|
20
25
|
* temperature: 1.1,
|
|
21
26
|
* maxTokens: 1,
|
|
@@ -27,7 +27,7 @@ export declare class Sandboxes {
|
|
|
27
27
|
* or overwritten with default values.
|
|
28
28
|
*
|
|
29
29
|
* @example
|
|
30
|
-
* await vellum.sandboxes.upsertSandboxScenario("
|
|
30
|
+
* await vellum.sandboxes.upsertSandboxScenario("id", {
|
|
31
31
|
* label: "Scenario 1",
|
|
32
32
|
* inputs: [{
|
|
33
33
|
* key: "var_1",
|
|
@@ -37,6 +37,8 @@ export declare class Sandboxes {
|
|
|
37
37
|
* key: "var_2",
|
|
38
38
|
* type: Vellum.ScenarioInputTypeEnum.Text,
|
|
39
39
|
* value: "Why hello, there!"
|
|
40
|
+
* }, {
|
|
41
|
+
* key: "key"
|
|
40
42
|
* }]
|
|
41
43
|
* })
|
|
42
44
|
*/
|
|
@@ -45,7 +47,7 @@ export declare class Sandboxes {
|
|
|
45
47
|
* Deletes an existing scenario from a sandbox, keying off of the provided scenario id.
|
|
46
48
|
*
|
|
47
49
|
* @example
|
|
48
|
-
* await vellum.sandboxes.deleteSandboxScenario("
|
|
50
|
+
* await vellum.sandboxes.deleteSandboxScenario("id", "scenario_id")
|
|
49
51
|
*/
|
|
50
52
|
deleteSandboxScenario(id: string, scenarioId: string, requestOptions?: Sandboxes.RequestOptions): Promise<void>;
|
|
51
53
|
}
|