@aws-sdk/client-bedrock-agent 3.638.0 → 3.645.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/dist-cjs/index.js +11 -1
- package/dist-es/models/models_0.js +6 -0
- package/dist-es/protocols/Aws_restJson1.js +2 -0
- package/dist-types/commands/CreateAgentCommand.d.ts +4 -1
- package/dist-types/commands/CreatePromptCommand.d.ts +12 -0
- package/dist-types/commands/CreatePromptVersionCommand.d.ts +6 -0
- package/dist-types/commands/GetPromptCommand.d.ts +6 -0
- package/dist-types/commands/UpdatePromptCommand.d.ts +12 -0
- package/dist-types/models/models_0.d.ts +26 -1
- package/dist-types/ts3.4/models/models_0.d.ts +8 -0
- package/package.json +6 -6
package/dist-cjs/index.js
CHANGED
|
@@ -151,6 +151,7 @@ __export(src_exports, {
|
|
|
151
151
|
PromptFlowNodeSourceConfiguration: () => PromptFlowNodeSourceConfiguration,
|
|
152
152
|
PromptFlowNodeSourceConfigurationFilterSensitiveLog: () => PromptFlowNodeSourceConfigurationFilterSensitiveLog,
|
|
153
153
|
PromptInferenceConfiguration: () => PromptInferenceConfiguration,
|
|
154
|
+
PromptMetadataEntryFilterSensitiveLog: () => PromptMetadataEntryFilterSensitiveLog,
|
|
154
155
|
PromptOverrideConfigurationFilterSensitiveLog: () => PromptOverrideConfigurationFilterSensitiveLog,
|
|
155
156
|
PromptState: () => PromptState,
|
|
156
157
|
PromptTemplateConfiguration: () => PromptTemplateConfiguration,
|
|
@@ -1103,12 +1104,18 @@ var UpdateFlowResponseFilterSensitiveLog = /* @__PURE__ */ __name((obj) => ({
|
|
|
1103
1104
|
...obj,
|
|
1104
1105
|
...obj.definition && { definition: FlowDefinitionFilterSensitiveLog(obj.definition) }
|
|
1105
1106
|
}), "UpdateFlowResponseFilterSensitiveLog");
|
|
1107
|
+
var PromptMetadataEntryFilterSensitiveLog = /* @__PURE__ */ __name((obj) => ({
|
|
1108
|
+
...obj,
|
|
1109
|
+
...obj.key && { key: import_smithy_client.SENSITIVE_STRING },
|
|
1110
|
+
...obj.value && { value: import_smithy_client.SENSITIVE_STRING }
|
|
1111
|
+
}), "PromptMetadataEntryFilterSensitiveLog");
|
|
1106
1112
|
var PromptVariantFilterSensitiveLog = /* @__PURE__ */ __name((obj) => ({
|
|
1107
1113
|
...obj,
|
|
1108
1114
|
...obj.templateConfiguration && {
|
|
1109
1115
|
templateConfiguration: PromptTemplateConfigurationFilterSensitiveLog(obj.templateConfiguration)
|
|
1110
1116
|
},
|
|
1111
|
-
...obj.inferenceConfiguration && { inferenceConfiguration: obj.inferenceConfiguration }
|
|
1117
|
+
...obj.inferenceConfiguration && { inferenceConfiguration: obj.inferenceConfiguration },
|
|
1118
|
+
...obj.metadata && { metadata: import_smithy_client.SENSITIVE_STRING }
|
|
1112
1119
|
}), "PromptVariantFilterSensitiveLog");
|
|
1113
1120
|
var CreatePromptRequestFilterSensitiveLog = /* @__PURE__ */ __name((obj) => ({
|
|
1114
1121
|
...obj,
|
|
@@ -3277,6 +3284,7 @@ var se_PromptOverrideConfiguration = /* @__PURE__ */ __name((input, context) =>
|
|
|
3277
3284
|
var se_PromptVariant = /* @__PURE__ */ __name((input, context) => {
|
|
3278
3285
|
return (0, import_smithy_client.take)(input, {
|
|
3279
3286
|
inferenceConfiguration: (_) => se_PromptInferenceConfiguration(_, context),
|
|
3287
|
+
metadata: import_smithy_client._json,
|
|
3280
3288
|
modelId: [],
|
|
3281
3289
|
name: [],
|
|
3282
3290
|
templateConfiguration: import_smithy_client._json,
|
|
@@ -3793,6 +3801,7 @@ var de_PromptSummary = /* @__PURE__ */ __name((output, context) => {
|
|
|
3793
3801
|
var de_PromptVariant = /* @__PURE__ */ __name((output, context) => {
|
|
3794
3802
|
return (0, import_smithy_client.take)(output, {
|
|
3795
3803
|
inferenceConfiguration: (_) => de_PromptInferenceConfiguration((0, import_core2.awsExpectUnion)(_), context),
|
|
3804
|
+
metadata: import_smithy_client._json,
|
|
3796
3805
|
modelId: import_smithy_client.expectString,
|
|
3797
3806
|
name: import_smithy_client.expectString,
|
|
3798
3807
|
templateConfiguration: (_) => (0, import_smithy_client._json)((0, import_core2.awsExpectUnion)(_)),
|
|
@@ -5098,6 +5107,7 @@ var paginateListPrompts = (0, import_core.createPaginator)(BedrockAgentClient, L
|
|
|
5098
5107
|
GetFlowResponseFilterSensitiveLog,
|
|
5099
5108
|
UpdateFlowRequestFilterSensitiveLog,
|
|
5100
5109
|
UpdateFlowResponseFilterSensitiveLog,
|
|
5110
|
+
PromptMetadataEntryFilterSensitiveLog,
|
|
5101
5111
|
PromptVariantFilterSensitiveLog,
|
|
5102
5112
|
CreatePromptRequestFilterSensitiveLog,
|
|
5103
5113
|
CreatePromptResponseFilterSensitiveLog,
|
|
@@ -683,12 +683,18 @@ export const UpdateFlowResponseFilterSensitiveLog = (obj) => ({
|
|
|
683
683
|
...obj,
|
|
684
684
|
...(obj.definition && { definition: FlowDefinitionFilterSensitiveLog(obj.definition) }),
|
|
685
685
|
});
|
|
686
|
+
export const PromptMetadataEntryFilterSensitiveLog = (obj) => ({
|
|
687
|
+
...obj,
|
|
688
|
+
...(obj.key && { key: SENSITIVE_STRING }),
|
|
689
|
+
...(obj.value && { value: SENSITIVE_STRING }),
|
|
690
|
+
});
|
|
686
691
|
export const PromptVariantFilterSensitiveLog = (obj) => ({
|
|
687
692
|
...obj,
|
|
688
693
|
...(obj.templateConfiguration && {
|
|
689
694
|
templateConfiguration: PromptTemplateConfigurationFilterSensitiveLog(obj.templateConfiguration),
|
|
690
695
|
}),
|
|
691
696
|
...(obj.inferenceConfiguration && { inferenceConfiguration: obj.inferenceConfiguration }),
|
|
697
|
+
...(obj.metadata && { metadata: SENSITIVE_STRING }),
|
|
692
698
|
});
|
|
693
699
|
export const CreatePromptRequestFilterSensitiveLog = (obj) => ({
|
|
694
700
|
...obj,
|
|
@@ -2085,6 +2085,7 @@ const se_PromptOverrideConfiguration = (input, context) => {
|
|
|
2085
2085
|
const se_PromptVariant = (input, context) => {
|
|
2086
2086
|
return take(input, {
|
|
2087
2087
|
inferenceConfiguration: (_) => se_PromptInferenceConfiguration(_, context),
|
|
2088
|
+
metadata: _json,
|
|
2088
2089
|
modelId: [],
|
|
2089
2090
|
name: [],
|
|
2090
2091
|
templateConfiguration: _json,
|
|
@@ -2633,6 +2634,7 @@ const de_PromptSummary = (output, context) => {
|
|
|
2633
2634
|
const de_PromptVariant = (output, context) => {
|
|
2634
2635
|
return take(output, {
|
|
2635
2636
|
inferenceConfiguration: (_) => de_PromptInferenceConfiguration(__expectUnion(_), context),
|
|
2637
|
+
metadata: _json,
|
|
2636
2638
|
modelId: __expectString,
|
|
2637
2639
|
name: __expectString,
|
|
2638
2640
|
templateConfiguration: (_) => _json(__expectUnion(_)),
|
|
@@ -53,7 +53,10 @@ declare const CreateAgentCommand_base: {
|
|
|
53
53
|
* For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html">Advanced prompts</a>.</p>
|
|
54
54
|
* </li>
|
|
55
55
|
* <li>
|
|
56
|
-
* <p>If
|
|
56
|
+
* <p>If your agent fails to be created, the response returns a list of <code>failureReasons</code> alongside a list of <code>recommendedActions</code> for you to troubleshoot.</p>
|
|
57
|
+
* </li>
|
|
58
|
+
* <li>
|
|
59
|
+
* <p>The agent instructions will not be honored if your agent has only one knowledge base, uses default prompts, has no action group, and user input is disabled.</p>
|
|
57
60
|
* </li>
|
|
58
61
|
* </ul>
|
|
59
62
|
* @example
|
|
@@ -65,6 +65,12 @@ declare const CreatePromptCommand_base: {
|
|
|
65
65
|
* ],
|
|
66
66
|
* },
|
|
67
67
|
* },
|
|
68
|
+
* metadata: [ // PromptMetadataList
|
|
69
|
+
* { // PromptMetadataEntry
|
|
70
|
+
* key: "STRING_VALUE", // required
|
|
71
|
+
* value: "STRING_VALUE", // required
|
|
72
|
+
* },
|
|
73
|
+
* ],
|
|
68
74
|
* },
|
|
69
75
|
* ],
|
|
70
76
|
* clientToken: "STRING_VALUE",
|
|
@@ -105,6 +111,12 @@ declare const CreatePromptCommand_base: {
|
|
|
105
111
|
* // ],
|
|
106
112
|
* // },
|
|
107
113
|
* // },
|
|
114
|
+
* // metadata: [ // PromptMetadataList
|
|
115
|
+
* // { // PromptMetadataEntry
|
|
116
|
+
* // key: "STRING_VALUE", // required
|
|
117
|
+
* // value: "STRING_VALUE", // required
|
|
118
|
+
* // },
|
|
119
|
+
* // ],
|
|
108
120
|
* // },
|
|
109
121
|
* // ],
|
|
110
122
|
* // id: "STRING_VALUE", // required
|
|
@@ -75,6 +75,12 @@ declare const CreatePromptVersionCommand_base: {
|
|
|
75
75
|
* // ],
|
|
76
76
|
* // },
|
|
77
77
|
* // },
|
|
78
|
+
* // metadata: [ // PromptMetadataList
|
|
79
|
+
* // { // PromptMetadataEntry
|
|
80
|
+
* // key: "STRING_VALUE", // required
|
|
81
|
+
* // value: "STRING_VALUE", // required
|
|
82
|
+
* // },
|
|
83
|
+
* // ],
|
|
78
84
|
* // },
|
|
79
85
|
* // ],
|
|
80
86
|
* // id: "STRING_VALUE", // required
|
|
@@ -71,6 +71,12 @@ declare const GetPromptCommand_base: {
|
|
|
71
71
|
* // ],
|
|
72
72
|
* // },
|
|
73
73
|
* // },
|
|
74
|
+
* // metadata: [ // PromptMetadataList
|
|
75
|
+
* // { // PromptMetadataEntry
|
|
76
|
+
* // key: "STRING_VALUE", // required
|
|
77
|
+
* // value: "STRING_VALUE", // required
|
|
78
|
+
* // },
|
|
79
|
+
* // ],
|
|
74
80
|
* // },
|
|
75
81
|
* // ],
|
|
76
82
|
* // id: "STRING_VALUE", // required
|
|
@@ -65,6 +65,12 @@ declare const UpdatePromptCommand_base: {
|
|
|
65
65
|
* ],
|
|
66
66
|
* },
|
|
67
67
|
* },
|
|
68
|
+
* metadata: [ // PromptMetadataList
|
|
69
|
+
* { // PromptMetadataEntry
|
|
70
|
+
* key: "STRING_VALUE", // required
|
|
71
|
+
* value: "STRING_VALUE", // required
|
|
72
|
+
* },
|
|
73
|
+
* ],
|
|
68
74
|
* },
|
|
69
75
|
* ],
|
|
70
76
|
* promptIdentifier: "STRING_VALUE", // required
|
|
@@ -102,6 +108,12 @@ declare const UpdatePromptCommand_base: {
|
|
|
102
108
|
* // ],
|
|
103
109
|
* // },
|
|
104
110
|
* // },
|
|
111
|
+
* // metadata: [ // PromptMetadataList
|
|
112
|
+
* // { // PromptMetadataEntry
|
|
113
|
+
* // key: "STRING_VALUE", // required
|
|
114
|
+
* // value: "STRING_VALUE", // required
|
|
115
|
+
* // },
|
|
116
|
+
* // ],
|
|
105
117
|
* // },
|
|
106
118
|
* // ],
|
|
107
119
|
* // id: "STRING_VALUE", // required
|
|
@@ -2832,7 +2832,7 @@ export type ParsingStrategy = (typeof ParsingStrategy)[keyof typeof ParsingStrat
|
|
|
2832
2832
|
* </p>
|
|
2833
2833
|
* </li>
|
|
2834
2834
|
* </ul>
|
|
2835
|
-
* <p>You can get the ARN of a model with the
|
|
2835
|
+
* <p>You can get the ARN of a model with the <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_ListFoundationModels.html">ListFoundationModels</a> action. Standard model usage
|
|
2836
2836
|
* charges apply for the foundation model parsing strategy.</p>
|
|
2837
2837
|
* @public
|
|
2838
2838
|
*/
|
|
@@ -6424,6 +6424,22 @@ export interface UpdateKnowledgeBaseResponse {
|
|
|
6424
6424
|
*/
|
|
6425
6425
|
knowledgeBase: KnowledgeBase | undefined;
|
|
6426
6426
|
}
|
|
6427
|
+
/**
|
|
6428
|
+
* <p>Contains a key-value pair that defines a metadata tag and value to attach to a prompt variant. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management-create.html">Create a prompt using Prompt management</a>.</p>
|
|
6429
|
+
* @public
|
|
6430
|
+
*/
|
|
6431
|
+
export interface PromptMetadataEntry {
|
|
6432
|
+
/**
|
|
6433
|
+
* <p>The key of a metadata tag for a prompt variant.</p>
|
|
6434
|
+
* @public
|
|
6435
|
+
*/
|
|
6436
|
+
key: string | undefined;
|
|
6437
|
+
/**
|
|
6438
|
+
* <p>The value of a metadata tag for a prompt variant.</p>
|
|
6439
|
+
* @public
|
|
6440
|
+
*/
|
|
6441
|
+
value: string | undefined;
|
|
6442
|
+
}
|
|
6427
6443
|
/**
|
|
6428
6444
|
* <p>Contains details about a variant of the prompt.</p>
|
|
6429
6445
|
* @public
|
|
@@ -6454,6 +6470,11 @@ export interface PromptVariant {
|
|
|
6454
6470
|
* @public
|
|
6455
6471
|
*/
|
|
6456
6472
|
inferenceConfiguration?: PromptInferenceConfiguration;
|
|
6473
|
+
/**
|
|
6474
|
+
* <p>An array of objects, each containing a key-value pair that defines a metadata tag and value to attach to a prompt variant. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management-create.html">Create a prompt using Prompt management</a>.</p>
|
|
6475
|
+
* @public
|
|
6476
|
+
*/
|
|
6477
|
+
metadata?: PromptMetadataEntry[];
|
|
6457
6478
|
}
|
|
6458
6479
|
/**
|
|
6459
6480
|
* @public
|
|
@@ -7278,6 +7299,10 @@ export declare const UpdateFlowRequestFilterSensitiveLog: (obj: UpdateFlowReques
|
|
|
7278
7299
|
* @internal
|
|
7279
7300
|
*/
|
|
7280
7301
|
export declare const UpdateFlowResponseFilterSensitiveLog: (obj: UpdateFlowResponse) => any;
|
|
7302
|
+
/**
|
|
7303
|
+
* @internal
|
|
7304
|
+
*/
|
|
7305
|
+
export declare const PromptMetadataEntryFilterSensitiveLog: (obj: PromptMetadataEntry) => any;
|
|
7281
7306
|
/**
|
|
7282
7307
|
* @internal
|
|
7283
7308
|
*/
|
|
@@ -1894,12 +1894,17 @@ export interface UpdateKnowledgeBaseRequest {
|
|
|
1894
1894
|
export interface UpdateKnowledgeBaseResponse {
|
|
1895
1895
|
knowledgeBase: KnowledgeBase | undefined;
|
|
1896
1896
|
}
|
|
1897
|
+
export interface PromptMetadataEntry {
|
|
1898
|
+
key: string | undefined;
|
|
1899
|
+
value: string | undefined;
|
|
1900
|
+
}
|
|
1897
1901
|
export interface PromptVariant {
|
|
1898
1902
|
name: string | undefined;
|
|
1899
1903
|
templateType: PromptTemplateType | undefined;
|
|
1900
1904
|
templateConfiguration?: PromptTemplateConfiguration;
|
|
1901
1905
|
modelId?: string;
|
|
1902
1906
|
inferenceConfiguration?: PromptInferenceConfiguration;
|
|
1907
|
+
metadata?: PromptMetadataEntry[];
|
|
1903
1908
|
}
|
|
1904
1909
|
export interface CreatePromptRequest {
|
|
1905
1910
|
name: string | undefined;
|
|
@@ -2193,6 +2198,9 @@ export declare const UpdateFlowRequestFilterSensitiveLog: (
|
|
|
2193
2198
|
export declare const UpdateFlowResponseFilterSensitiveLog: (
|
|
2194
2199
|
obj: UpdateFlowResponse
|
|
2195
2200
|
) => any;
|
|
2201
|
+
export declare const PromptMetadataEntryFilterSensitiveLog: (
|
|
2202
|
+
obj: PromptMetadataEntry
|
|
2203
|
+
) => any;
|
|
2196
2204
|
export declare const PromptVariantFilterSensitiveLog: (
|
|
2197
2205
|
obj: PromptVariant
|
|
2198
2206
|
) => any;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/client-bedrock-agent",
|
|
3
3
|
"description": "AWS SDK for JavaScript Bedrock Agent Client for Node.js, Browser and React Native",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.645.0",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
|
|
7
7
|
"build:cjs": "node ../../scripts/compilation/inline client-bedrock-agent",
|
|
@@ -20,17 +20,17 @@
|
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@aws-crypto/sha256-browser": "5.2.0",
|
|
22
22
|
"@aws-crypto/sha256-js": "5.2.0",
|
|
23
|
-
"@aws-sdk/client-sso-oidc": "3.
|
|
24
|
-
"@aws-sdk/client-sts": "3.
|
|
23
|
+
"@aws-sdk/client-sso-oidc": "3.645.0",
|
|
24
|
+
"@aws-sdk/client-sts": "3.645.0",
|
|
25
25
|
"@aws-sdk/core": "3.635.0",
|
|
26
|
-
"@aws-sdk/credential-provider-node": "3.
|
|
26
|
+
"@aws-sdk/credential-provider-node": "3.645.0",
|
|
27
27
|
"@aws-sdk/middleware-host-header": "3.620.0",
|
|
28
28
|
"@aws-sdk/middleware-logger": "3.609.0",
|
|
29
29
|
"@aws-sdk/middleware-recursion-detection": "3.620.0",
|
|
30
|
-
"@aws-sdk/middleware-user-agent": "3.
|
|
30
|
+
"@aws-sdk/middleware-user-agent": "3.645.0",
|
|
31
31
|
"@aws-sdk/region-config-resolver": "3.614.0",
|
|
32
32
|
"@aws-sdk/types": "3.609.0",
|
|
33
|
-
"@aws-sdk/util-endpoints": "3.
|
|
33
|
+
"@aws-sdk/util-endpoints": "3.645.0",
|
|
34
34
|
"@aws-sdk/util-user-agent-browser": "3.609.0",
|
|
35
35
|
"@aws-sdk/util-user-agent-node": "3.614.0",
|
|
36
36
|
"@smithy/config-resolver": "^3.0.5",
|