@aws-sdk/client-bedrock-agent-runtime 3.696.0 → 3.699.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/README.md +16 -0
- package/dist-cjs/index.js +704 -1
- package/dist-es/BedrockAgentRuntime.js +4 -0
- package/dist-es/commands/InvokeInlineAgentCommand.js +27 -0
- package/dist-es/commands/OptimizePromptCommand.js +27 -0
- package/dist-es/commands/index.js +2 -0
- package/dist-es/models/models_0.js +285 -0
- package/dist-es/protocols/Aws_restJson1.js +286 -0
- package/dist-types/BedrockAgentRuntime.d.ts +14 -0
- package/dist-types/BedrockAgentRuntimeClient.d.ts +4 -2
- package/dist-types/commands/InvokeAgentCommand.d.ts +6 -6
- package/dist-types/commands/InvokeFlowCommand.d.ts +1 -1
- package/dist-types/commands/InvokeInlineAgentCommand.d.ts +755 -0
- package/dist-types/commands/OptimizePromptCommand.d.ts +125 -0
- package/dist-types/commands/index.d.ts +2 -0
- package/dist-types/models/models_0.d.ts +1458 -65
- package/dist-types/protocols/Aws_restJson1.d.ts +18 -0
- package/dist-types/ts3.4/BedrockAgentRuntime.d.ts +34 -0
- package/dist-types/ts3.4/BedrockAgentRuntimeClient.d.ts +12 -0
- package/dist-types/ts3.4/commands/InvokeInlineAgentCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/OptimizePromptCommand.d.ts +50 -0
- package/dist-types/ts3.4/commands/index.d.ts +2 -0
- package/dist-types/ts3.4/models/models_0.d.ts +687 -2
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +24 -0
- package/package.json +4 -4
|
@@ -13,6 +13,66 @@ export declare class AccessDeniedException extends __BaseException {
|
|
|
13
13
|
*/
|
|
14
14
|
constructor(opts: __ExceptionOptionType<AccessDeniedException, __BaseException>);
|
|
15
15
|
}
|
|
16
|
+
/**
|
|
17
|
+
* @public
|
|
18
|
+
* @enum
|
|
19
|
+
*/
|
|
20
|
+
export declare const CustomControlMethod: {
|
|
21
|
+
readonly RETURN_CONTROL: "RETURN_CONTROL";
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* @public
|
|
25
|
+
*/
|
|
26
|
+
export type CustomControlMethod = (typeof CustomControlMethod)[keyof typeof CustomControlMethod];
|
|
27
|
+
/**
|
|
28
|
+
* <p>
|
|
29
|
+
* Contains details about the Lambda function containing the business logic that is carried out upon invoking the action or the
|
|
30
|
+
* custom control method for handling the information elicited from the user.
|
|
31
|
+
* </p>
|
|
32
|
+
* @public
|
|
33
|
+
*/
|
|
34
|
+
export type ActionGroupExecutor = ActionGroupExecutor.CustomControlMember | ActionGroupExecutor.LambdaMember | ActionGroupExecutor.$UnknownMember;
|
|
35
|
+
/**
|
|
36
|
+
* @public
|
|
37
|
+
*/
|
|
38
|
+
export declare namespace ActionGroupExecutor {
|
|
39
|
+
/**
|
|
40
|
+
* <p>
|
|
41
|
+
* The Amazon Resource Name (ARN) of the Lambda function containing the business logic that is carried out upon invoking the action.
|
|
42
|
+
* </p>
|
|
43
|
+
* @public
|
|
44
|
+
*/
|
|
45
|
+
interface LambdaMember {
|
|
46
|
+
lambda: string;
|
|
47
|
+
customControl?: never;
|
|
48
|
+
$unknown?: never;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* <p>
|
|
52
|
+
* To return the action group invocation results directly in the <code>InvokeInlineAgent</code> response, specify <code>RETURN_CONTROL</code>.
|
|
53
|
+
* </p>
|
|
54
|
+
* @public
|
|
55
|
+
*/
|
|
56
|
+
interface CustomControlMember {
|
|
57
|
+
lambda?: never;
|
|
58
|
+
customControl: CustomControlMethod;
|
|
59
|
+
$unknown?: never;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* @public
|
|
63
|
+
*/
|
|
64
|
+
interface $UnknownMember {
|
|
65
|
+
lambda?: never;
|
|
66
|
+
customControl?: never;
|
|
67
|
+
$unknown: [string, any];
|
|
68
|
+
}
|
|
69
|
+
interface Visitor<T> {
|
|
70
|
+
lambda: (value: string) => T;
|
|
71
|
+
customControl: (value: CustomControlMethod) => T;
|
|
72
|
+
_: (name: string, value: any) => T;
|
|
73
|
+
}
|
|
74
|
+
const visit: <T>(value: ActionGroupExecutor, visitor: Visitor<T>) => T;
|
|
75
|
+
}
|
|
16
76
|
/**
|
|
17
77
|
* @public
|
|
18
78
|
* @enum
|
|
@@ -58,7 +118,7 @@ export interface RequestBody {
|
|
|
58
118
|
content?: Record<string, Parameter[]> | undefined;
|
|
59
119
|
}
|
|
60
120
|
/**
|
|
61
|
-
* <p>Contains information about the action group being invoked. For more information about the possible structures, see the InvocationInput tab in <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/trace-orchestration.html">OrchestrationTrace</a> in the Amazon Bedrock User Guide
|
|
121
|
+
* <p>Contains information about the action group being invoked. For more information about the possible structures, see the InvocationInput tab in <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/trace-orchestration.html">OrchestrationTrace</a> in the <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/what-is-service.html">Amazon Bedrock User Guide</a>.</p>
|
|
62
122
|
* @public
|
|
63
123
|
*/
|
|
64
124
|
export interface ActionGroupInvocationInput {
|
|
@@ -114,6 +174,18 @@ export interface ActionGroupInvocationOutput {
|
|
|
114
174
|
*/
|
|
115
175
|
text?: string | undefined;
|
|
116
176
|
}
|
|
177
|
+
/**
|
|
178
|
+
* @public
|
|
179
|
+
* @enum
|
|
180
|
+
*/
|
|
181
|
+
export declare const ActionGroupSignature: {
|
|
182
|
+
readonly AMAZON_CODEINTERPRETER: "AMAZON.CodeInterpreter";
|
|
183
|
+
readonly AMAZON_USERINPUT: "AMAZON.UserInput";
|
|
184
|
+
};
|
|
185
|
+
/**
|
|
186
|
+
* @public
|
|
187
|
+
*/
|
|
188
|
+
export type ActionGroupSignature = (typeof ActionGroupSignature)[keyof typeof ActionGroupSignature];
|
|
117
189
|
/**
|
|
118
190
|
* @public
|
|
119
191
|
* @enum
|
|
@@ -127,6 +199,260 @@ export declare const ActionInvocationType: {
|
|
|
127
199
|
* @public
|
|
128
200
|
*/
|
|
129
201
|
export type ActionInvocationType = (typeof ActionInvocationType)[keyof typeof ActionInvocationType];
|
|
202
|
+
/**
|
|
203
|
+
* <p>
|
|
204
|
+
* The identifier information for an Amazon S3 bucket.
|
|
205
|
+
* </p>
|
|
206
|
+
* @public
|
|
207
|
+
*/
|
|
208
|
+
export interface S3Identifier {
|
|
209
|
+
/**
|
|
210
|
+
* <p>
|
|
211
|
+
* The name of the S3 bucket.
|
|
212
|
+
* </p>
|
|
213
|
+
* @public
|
|
214
|
+
*/
|
|
215
|
+
s3BucketName?: string | undefined;
|
|
216
|
+
/**
|
|
217
|
+
* <p>
|
|
218
|
+
* The S3 object key for the S3 resource.
|
|
219
|
+
* </p>
|
|
220
|
+
* @public
|
|
221
|
+
*/
|
|
222
|
+
s3ObjectKey?: string | undefined;
|
|
223
|
+
}
|
|
224
|
+
/**
|
|
225
|
+
* <p>
|
|
226
|
+
* Contains details about the OpenAPI schema for the action group. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html">Action group OpenAPI schemas</a>.
|
|
227
|
+
* You can either include the schema directly in the payload field or you can upload it to an S3 bucket and specify the S3 bucket location in the s3 field.
|
|
228
|
+
* </p>
|
|
229
|
+
* @public
|
|
230
|
+
*/
|
|
231
|
+
export type APISchema = APISchema.PayloadMember | APISchema.S3Member | APISchema.$UnknownMember;
|
|
232
|
+
/**
|
|
233
|
+
* @public
|
|
234
|
+
*/
|
|
235
|
+
export declare namespace APISchema {
|
|
236
|
+
/**
|
|
237
|
+
* <p>
|
|
238
|
+
* Contains details about the S3 object containing the OpenAPI schema for the action group.
|
|
239
|
+
* </p>
|
|
240
|
+
* @public
|
|
241
|
+
*/
|
|
242
|
+
interface S3Member {
|
|
243
|
+
s3: S3Identifier;
|
|
244
|
+
payload?: never;
|
|
245
|
+
$unknown?: never;
|
|
246
|
+
}
|
|
247
|
+
/**
|
|
248
|
+
* <p>
|
|
249
|
+
* The JSON or YAML-formatted payload defining the OpenAPI schema for the action group.
|
|
250
|
+
* </p>
|
|
251
|
+
* @public
|
|
252
|
+
*/
|
|
253
|
+
interface PayloadMember {
|
|
254
|
+
s3?: never;
|
|
255
|
+
payload: string;
|
|
256
|
+
$unknown?: never;
|
|
257
|
+
}
|
|
258
|
+
/**
|
|
259
|
+
* @public
|
|
260
|
+
*/
|
|
261
|
+
interface $UnknownMember {
|
|
262
|
+
s3?: never;
|
|
263
|
+
payload?: never;
|
|
264
|
+
$unknown: [string, any];
|
|
265
|
+
}
|
|
266
|
+
interface Visitor<T> {
|
|
267
|
+
s3: (value: S3Identifier) => T;
|
|
268
|
+
payload: (value: string) => T;
|
|
269
|
+
_: (name: string, value: any) => T;
|
|
270
|
+
}
|
|
271
|
+
const visit: <T>(value: APISchema, visitor: Visitor<T>) => T;
|
|
272
|
+
}
|
|
273
|
+
/**
|
|
274
|
+
* @public
|
|
275
|
+
* @enum
|
|
276
|
+
*/
|
|
277
|
+
export declare const ParameterType: {
|
|
278
|
+
readonly ARRAY: "array";
|
|
279
|
+
readonly BOOLEAN: "boolean";
|
|
280
|
+
readonly INTEGER: "integer";
|
|
281
|
+
readonly NUMBER: "number";
|
|
282
|
+
readonly STRING: "string";
|
|
283
|
+
};
|
|
284
|
+
/**
|
|
285
|
+
* @public
|
|
286
|
+
*/
|
|
287
|
+
export type ParameterType = (typeof ParameterType)[keyof typeof ParameterType];
|
|
288
|
+
/**
|
|
289
|
+
* <p>
|
|
290
|
+
* Contains details about a parameter in a function for an action group.
|
|
291
|
+
* </p>
|
|
292
|
+
* @public
|
|
293
|
+
*/
|
|
294
|
+
export interface ParameterDetail {
|
|
295
|
+
/**
|
|
296
|
+
* <p>
|
|
297
|
+
* A description of the parameter. Helps the foundation model determine how to elicit the parameters from the user.
|
|
298
|
+
* </p>
|
|
299
|
+
* @public
|
|
300
|
+
*/
|
|
301
|
+
description?: string | undefined;
|
|
302
|
+
/**
|
|
303
|
+
* <p>
|
|
304
|
+
* The data type of the parameter.
|
|
305
|
+
* </p>
|
|
306
|
+
* @public
|
|
307
|
+
*/
|
|
308
|
+
type: ParameterType | undefined;
|
|
309
|
+
/**
|
|
310
|
+
* <p>
|
|
311
|
+
* Whether the parameter is required for the agent to complete the function for action group invocation.
|
|
312
|
+
* </p>
|
|
313
|
+
* @public
|
|
314
|
+
*/
|
|
315
|
+
required?: boolean | undefined;
|
|
316
|
+
}
|
|
317
|
+
/**
|
|
318
|
+
* @public
|
|
319
|
+
* @enum
|
|
320
|
+
*/
|
|
321
|
+
export declare const RequireConfirmation: {
|
|
322
|
+
readonly DISABLED: "DISABLED";
|
|
323
|
+
readonly ENABLED: "ENABLED";
|
|
324
|
+
};
|
|
325
|
+
/**
|
|
326
|
+
* @public
|
|
327
|
+
*/
|
|
328
|
+
export type RequireConfirmation = (typeof RequireConfirmation)[keyof typeof RequireConfirmation];
|
|
329
|
+
/**
|
|
330
|
+
* <p>
|
|
331
|
+
* Defines parameters that the agent needs to invoke from the user to complete the function. Corresponds to an action in an action group.
|
|
332
|
+
* </p>
|
|
333
|
+
* @public
|
|
334
|
+
*/
|
|
335
|
+
export interface FunctionDefinition {
|
|
336
|
+
/**
|
|
337
|
+
* <p>
|
|
338
|
+
* A name for the function.
|
|
339
|
+
* </p>
|
|
340
|
+
* @public
|
|
341
|
+
*/
|
|
342
|
+
name: string | undefined;
|
|
343
|
+
/**
|
|
344
|
+
* <p>
|
|
345
|
+
* A description of the function and its purpose.
|
|
346
|
+
* </p>
|
|
347
|
+
* @public
|
|
348
|
+
*/
|
|
349
|
+
description?: string | undefined;
|
|
350
|
+
/**
|
|
351
|
+
* <p>
|
|
352
|
+
* The parameters that the agent elicits from the user to fulfill the function.
|
|
353
|
+
* </p>
|
|
354
|
+
* @public
|
|
355
|
+
*/
|
|
356
|
+
parameters?: Record<string, ParameterDetail> | undefined;
|
|
357
|
+
/**
|
|
358
|
+
* <p>
|
|
359
|
+
* Contains information if user confirmation is required to invoke the function.
|
|
360
|
+
* </p>
|
|
361
|
+
* @public
|
|
362
|
+
*/
|
|
363
|
+
requireConfirmation?: RequireConfirmation | undefined;
|
|
364
|
+
}
|
|
365
|
+
/**
|
|
366
|
+
* <p>
|
|
367
|
+
* Contains details about the function schema for the action group or the JSON or YAML-formatted payload defining the schema.
|
|
368
|
+
* </p>
|
|
369
|
+
* @public
|
|
370
|
+
*/
|
|
371
|
+
export type FunctionSchema = FunctionSchema.FunctionsMember | FunctionSchema.$UnknownMember;
|
|
372
|
+
/**
|
|
373
|
+
* @public
|
|
374
|
+
*/
|
|
375
|
+
export declare namespace FunctionSchema {
|
|
376
|
+
/**
|
|
377
|
+
* <p>
|
|
378
|
+
* A list of functions that each define an action in the action group.
|
|
379
|
+
* </p>
|
|
380
|
+
* @public
|
|
381
|
+
*/
|
|
382
|
+
interface FunctionsMember {
|
|
383
|
+
functions: FunctionDefinition[];
|
|
384
|
+
$unknown?: never;
|
|
385
|
+
}
|
|
386
|
+
/**
|
|
387
|
+
* @public
|
|
388
|
+
*/
|
|
389
|
+
interface $UnknownMember {
|
|
390
|
+
functions?: never;
|
|
391
|
+
$unknown: [string, any];
|
|
392
|
+
}
|
|
393
|
+
interface Visitor<T> {
|
|
394
|
+
functions: (value: FunctionDefinition[]) => T;
|
|
395
|
+
_: (name: string, value: any) => T;
|
|
396
|
+
}
|
|
397
|
+
const visit: <T>(value: FunctionSchema, visitor: Visitor<T>) => T;
|
|
398
|
+
}
|
|
399
|
+
/**
|
|
400
|
+
* <p>
|
|
401
|
+
* Contains details of the inline agent's action group.
|
|
402
|
+
* </p>
|
|
403
|
+
* @public
|
|
404
|
+
*/
|
|
405
|
+
export interface AgentActionGroup {
|
|
406
|
+
/**
|
|
407
|
+
* <p>
|
|
408
|
+
* The name of the action group.
|
|
409
|
+
* </p>
|
|
410
|
+
* @public
|
|
411
|
+
*/
|
|
412
|
+
actionGroupName: string | undefined;
|
|
413
|
+
/**
|
|
414
|
+
* <p>
|
|
415
|
+
* A description of the action group.
|
|
416
|
+
* </p>
|
|
417
|
+
* @public
|
|
418
|
+
*/
|
|
419
|
+
description?: string | undefined;
|
|
420
|
+
/**
|
|
421
|
+
* <p>
|
|
422
|
+
* To allow your agent to request the user for additional information when trying to complete a task, set this field to <code>AMAZON.UserInput</code>.
|
|
423
|
+
* You must leave the <code>description</code>, <code>apiSchema</code>, and <code>actionGroupExecutor</code> fields blank for this action group.
|
|
424
|
+
* </p>
|
|
425
|
+
* <p>To allow your agent to generate, run, and troubleshoot code when trying to complete a task, set this field to <code>AMAZON.CodeInterpreter</code>. You must
|
|
426
|
+
* leave the <code>description</code>, <code>apiSchema</code>, and <code>actionGroupExecutor</code> fields blank for this action group.</p>
|
|
427
|
+
* <p>During orchestration, if your agent determines that it needs to invoke an API in an action group, but doesn't have enough information to complete the API request,
|
|
428
|
+
* it will invoke this action group instead and return an <a href="https://docs.aws.amazon.com/https:/docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html">Observation</a> reprompting the user for more information.</p>
|
|
429
|
+
* @public
|
|
430
|
+
*/
|
|
431
|
+
parentActionGroupSignature?: ActionGroupSignature | undefined;
|
|
432
|
+
/**
|
|
433
|
+
* <p>
|
|
434
|
+
* The Amazon Resource Name (ARN) of the Lambda function containing the business logic that is carried out upon invoking
|
|
435
|
+
* the action or the custom control method for handling the information elicited from the user.
|
|
436
|
+
* </p>
|
|
437
|
+
* @public
|
|
438
|
+
*/
|
|
439
|
+
actionGroupExecutor?: ActionGroupExecutor | undefined;
|
|
440
|
+
/**
|
|
441
|
+
* <p>
|
|
442
|
+
* Contains either details about the S3 object containing the OpenAPI schema for the action group or the JSON or YAML-formatted
|
|
443
|
+
* payload defining the schema. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html">Action group OpenAPI schemas</a>.
|
|
444
|
+
* </p>
|
|
445
|
+
* @public
|
|
446
|
+
*/
|
|
447
|
+
apiSchema?: APISchema | undefined;
|
|
448
|
+
/**
|
|
449
|
+
* <p>
|
|
450
|
+
* Contains details about the function schema for the action group or the JSON or YAML-formatted payload defining the schema.
|
|
451
|
+
* </p>
|
|
452
|
+
* @public
|
|
453
|
+
*/
|
|
454
|
+
functionSchema?: FunctionSchema | undefined;
|
|
455
|
+
}
|
|
130
456
|
/**
|
|
131
457
|
* <p>There was an issue with a dependency due to a server issue. Retry your request.</p>
|
|
132
458
|
* @public
|
|
@@ -2340,6 +2666,7 @@ export declare const PromptType: {
|
|
|
2340
2666
|
readonly ORCHESTRATION: "ORCHESTRATION";
|
|
2341
2667
|
readonly POST_PROCESSING: "POST_PROCESSING";
|
|
2342
2668
|
readonly PRE_PROCESSING: "PRE_PROCESSING";
|
|
2669
|
+
readonly ROUTING_CLASSIFIER: "ROUTING_CLASSIFIER";
|
|
2343
2670
|
};
|
|
2344
2671
|
/**
|
|
2345
2672
|
* @public
|
|
@@ -3017,30 +3344,30 @@ export declare namespace Trace {
|
|
|
3017
3344
|
*/
|
|
3018
3345
|
export interface TracePart {
|
|
3019
3346
|
/**
|
|
3020
|
-
* <p>The unique identifier of the agent.</p>
|
|
3347
|
+
* <p>The unique identifier of the session with the agent.</p>
|
|
3021
3348
|
* @public
|
|
3022
3349
|
*/
|
|
3023
|
-
|
|
3350
|
+
sessionId?: string | undefined;
|
|
3024
3351
|
/**
|
|
3025
|
-
* <p>
|
|
3352
|
+
* <p>Contains one part of the agent's reasoning process and results from calling API actions and querying knowledge bases. You can use the trace to understand how the agent arrived at the response it provided the customer. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-test.html#trace-enablement">Trace enablement</a>.</p>
|
|
3026
3353
|
* @public
|
|
3027
3354
|
*/
|
|
3028
|
-
|
|
3355
|
+
trace?: Trace | undefined;
|
|
3029
3356
|
/**
|
|
3030
|
-
* <p>The unique identifier of the
|
|
3357
|
+
* <p>The unique identifier of the agent.</p>
|
|
3031
3358
|
* @public
|
|
3032
3359
|
*/
|
|
3033
|
-
|
|
3360
|
+
agentId?: string | undefined;
|
|
3034
3361
|
/**
|
|
3035
|
-
* <p>The
|
|
3362
|
+
* <p>The unique identifier of the alias of the agent.</p>
|
|
3036
3363
|
* @public
|
|
3037
3364
|
*/
|
|
3038
|
-
|
|
3365
|
+
agentAliasId?: string | undefined;
|
|
3039
3366
|
/**
|
|
3040
|
-
* <p>
|
|
3367
|
+
* <p>The version of the agent.</p>
|
|
3041
3368
|
* @public
|
|
3042
3369
|
*/
|
|
3043
|
-
|
|
3370
|
+
agentVersion?: string | undefined;
|
|
3044
3371
|
}
|
|
3045
3372
|
/**
|
|
3046
3373
|
* <p>The response from invoking the agent and associated citations and trace information.</p>
|
|
@@ -3374,41 +3701,607 @@ export interface InvokeAgentResponse {
|
|
|
3374
3701
|
memoryId?: string | undefined;
|
|
3375
3702
|
}
|
|
3376
3703
|
/**
|
|
3704
|
+
* <p>
|
|
3705
|
+
* The configuration details for the guardrail.
|
|
3706
|
+
* </p>
|
|
3377
3707
|
* @public
|
|
3378
3708
|
*/
|
|
3379
|
-
export interface
|
|
3380
|
-
/**
|
|
3381
|
-
* <p>The unique identifier of the agent to which the alias belongs.</p>
|
|
3382
|
-
* @public
|
|
3383
|
-
*/
|
|
3384
|
-
agentId: string | undefined;
|
|
3709
|
+
export interface GuardrailConfigurationWithArn {
|
|
3385
3710
|
/**
|
|
3386
|
-
* <p>
|
|
3711
|
+
* <p>
|
|
3712
|
+
* The unique identifier for the guardrail.
|
|
3713
|
+
* </p>
|
|
3387
3714
|
* @public
|
|
3388
3715
|
*/
|
|
3389
|
-
|
|
3716
|
+
guardrailIdentifier: string | undefined;
|
|
3390
3717
|
/**
|
|
3391
|
-
* <p>
|
|
3718
|
+
* <p>
|
|
3719
|
+
* The version of the guardrail.
|
|
3720
|
+
* </p>
|
|
3392
3721
|
* @public
|
|
3393
3722
|
*/
|
|
3394
|
-
|
|
3395
|
-
}
|
|
3396
|
-
/**
|
|
3397
|
-
* @public
|
|
3398
|
-
*/
|
|
3399
|
-
export interface DeleteAgentMemoryResponse {
|
|
3723
|
+
guardrailVersion: string | undefined;
|
|
3400
3724
|
}
|
|
3401
3725
|
/**
|
|
3402
|
-
*
|
|
3403
|
-
*
|
|
3404
|
-
|
|
3405
|
-
|
|
3406
|
-
|
|
3407
|
-
|
|
3408
|
-
/**
|
|
3726
|
+
* <p>
|
|
3727
|
+
* Contains parameters that specify various attributes that persist across a session or prompt. You can define session state
|
|
3728
|
+
* attributes as key-value pairs when writing a <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-lambda.html">Lambda function</a> for an action group or pass them when making an <code>InvokeInlineAgent</code> request.
|
|
3729
|
+
* Use session state attributes to control and provide conversational context for your inline agent and to help customize your agent's behavior.
|
|
3730
|
+
* For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-session-state.html">Control session context</a>
|
|
3731
|
+
* </p>
|
|
3409
3732
|
* @public
|
|
3410
3733
|
*/
|
|
3411
|
-
export
|
|
3734
|
+
export interface InlineSessionState {
|
|
3735
|
+
/**
|
|
3736
|
+
* <p>
|
|
3737
|
+
* Contains attributes that persist across a session and the values of those attributes.
|
|
3738
|
+
* </p>
|
|
3739
|
+
* @public
|
|
3740
|
+
*/
|
|
3741
|
+
sessionAttributes?: Record<string, string> | undefined;
|
|
3742
|
+
/**
|
|
3743
|
+
* <p>
|
|
3744
|
+
* Contains attributes that persist across a session and the values of those attributes.
|
|
3745
|
+
* </p>
|
|
3746
|
+
* @public
|
|
3747
|
+
*/
|
|
3748
|
+
promptSessionAttributes?: Record<string, string> | undefined;
|
|
3749
|
+
/**
|
|
3750
|
+
* <p>
|
|
3751
|
+
* Contains information about the results from the action group invocation. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-returncontrol.html">Return control to the agent developer</a>.
|
|
3752
|
+
* </p>
|
|
3753
|
+
* <note>
|
|
3754
|
+
* <p>If you include this field in the <code>sessionState</code> field, the <code>inputText</code> field will be ignored.</p>
|
|
3755
|
+
* </note>
|
|
3756
|
+
* @public
|
|
3757
|
+
*/
|
|
3758
|
+
returnControlInvocationResults?: InvocationResultMember[] | undefined;
|
|
3759
|
+
/**
|
|
3760
|
+
* <p>
|
|
3761
|
+
* The identifier of the invocation of an action. This value must match the <code>invocationId</code> returned in the <code>InvokeInlineAgent</code> response for the action
|
|
3762
|
+
* whose results are provided in the <code>returnControlInvocationResults</code> field. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-returncontrol.html">Return control to the agent developer</a>.
|
|
3763
|
+
* </p>
|
|
3764
|
+
* @public
|
|
3765
|
+
*/
|
|
3766
|
+
invocationId?: string | undefined;
|
|
3767
|
+
/**
|
|
3768
|
+
* <p>
|
|
3769
|
+
* Contains information about the files used by code interpreter.
|
|
3770
|
+
* </p>
|
|
3771
|
+
* @public
|
|
3772
|
+
*/
|
|
3773
|
+
files?: InputFile[] | undefined;
|
|
3774
|
+
}
|
|
3775
|
+
/**
|
|
3776
|
+
* @public
|
|
3777
|
+
* @enum
|
|
3778
|
+
*/
|
|
3779
|
+
export declare const PromptState: {
|
|
3780
|
+
readonly DISABLED: "DISABLED";
|
|
3781
|
+
readonly ENABLED: "ENABLED";
|
|
3782
|
+
};
|
|
3783
|
+
/**
|
|
3784
|
+
* @public
|
|
3785
|
+
*/
|
|
3786
|
+
export type PromptState = (typeof PromptState)[keyof typeof PromptState];
|
|
3787
|
+
/**
|
|
3788
|
+
* <p>
|
|
3789
|
+
* Contains configurations to override a prompt template in one part of an agent sequence. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html">Advanced prompts</a>.
|
|
3790
|
+
* </p>
|
|
3791
|
+
* @public
|
|
3792
|
+
*/
|
|
3793
|
+
export interface PromptConfiguration {
|
|
3794
|
+
/**
|
|
3795
|
+
* <p>
|
|
3796
|
+
* The step in the agent sequence that this prompt configuration applies to.
|
|
3797
|
+
* </p>
|
|
3798
|
+
* @public
|
|
3799
|
+
*/
|
|
3800
|
+
promptType?: PromptType | undefined;
|
|
3801
|
+
/**
|
|
3802
|
+
* <p>Specifies whether to override the default prompt template for this <code>promptType</code>. Set this value to <code>OVERRIDDEN</code> to use the prompt that you provide in the <code>basePromptTemplate</code>. If you leave it as <code>DEFAULT</code>, the agent uses a default prompt template.</p>
|
|
3803
|
+
* @public
|
|
3804
|
+
*/
|
|
3805
|
+
promptCreationMode?: CreationMode | undefined;
|
|
3806
|
+
/**
|
|
3807
|
+
* <p>Specifies whether to allow the inline agent to carry out the step specified in the <code>promptType</code>. If you set this value to <code>DISABLED</code>, the agent skips that step. The default state for each <code>promptType</code> is as follows.</p>
|
|
3808
|
+
* <ul>
|
|
3809
|
+
* <li>
|
|
3810
|
+
* <p>
|
|
3811
|
+
* <code>PRE_PROCESSING</code> – <code>ENABLED</code>
|
|
3812
|
+
* </p>
|
|
3813
|
+
* </li>
|
|
3814
|
+
* <li>
|
|
3815
|
+
* <p>
|
|
3816
|
+
* <code>ORCHESTRATION</code> – <code>ENABLED</code>
|
|
3817
|
+
* </p>
|
|
3818
|
+
* </li>
|
|
3819
|
+
* <li>
|
|
3820
|
+
* <p>
|
|
3821
|
+
* <code>KNOWLEDGE_BASE_RESPONSE_GENERATION</code> – <code>ENABLED</code>
|
|
3822
|
+
* </p>
|
|
3823
|
+
* </li>
|
|
3824
|
+
* <li>
|
|
3825
|
+
* <p>
|
|
3826
|
+
* <code>POST_PROCESSING</code> – <code>DISABLED</code>
|
|
3827
|
+
* </p>
|
|
3828
|
+
* </li>
|
|
3829
|
+
* </ul>
|
|
3830
|
+
* @public
|
|
3831
|
+
*/
|
|
3832
|
+
promptState?: PromptState | undefined;
|
|
3833
|
+
/**
|
|
3834
|
+
* <p>Defines the prompt template with which to replace the default prompt template. You can use placeholder variables in the base prompt template to customize the prompt. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-placeholders.html">Prompt template placeholder variables</a>. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts-configure.html">Configure the prompt templates</a>.</p>
|
|
3835
|
+
* @public
|
|
3836
|
+
*/
|
|
3837
|
+
basePromptTemplate?: string | undefined;
|
|
3838
|
+
/**
|
|
3839
|
+
* <p>Contains inference parameters to use when the agent invokes a foundation model in the part of the agent sequence defined by the <code>promptType</code>. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html">Inference parameters for foundation models</a>.</p>
|
|
3840
|
+
* @public
|
|
3841
|
+
*/
|
|
3842
|
+
inferenceConfiguration?: InferenceConfiguration | undefined;
|
|
3843
|
+
/**
|
|
3844
|
+
* <p>Specifies whether to override the default parser Lambda function when parsing the raw foundation model output in the part of the agent sequence defined by the <code>promptType</code>. If you set the field as <code>OVERRIDEN</code>, the <code>overrideLambda</code> field in the <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_PromptOverrideConfiguration.html">PromptOverrideConfiguration</a> must be specified with the ARN of a Lambda function.</p>
|
|
3845
|
+
* @public
|
|
3846
|
+
*/
|
|
3847
|
+
parserMode?: CreationMode | undefined;
|
|
3848
|
+
}
|
|
3849
|
+
/**
|
|
3850
|
+
* <p>Contains configurations to override prompts in different parts of an agent sequence. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html">Advanced prompts</a>. </p>
|
|
3851
|
+
* @public
|
|
3852
|
+
*/
|
|
3853
|
+
export interface PromptOverrideConfiguration {
|
|
3854
|
+
/**
|
|
3855
|
+
* <p>Contains configurations to override a prompt template in one part of an agent sequence. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html">Advanced prompts</a>. </p>
|
|
3856
|
+
* @public
|
|
3857
|
+
*/
|
|
3858
|
+
promptConfigurations: PromptConfiguration[] | undefined;
|
|
3859
|
+
/**
|
|
3860
|
+
* <p>The ARN of the Lambda function to use when parsing the raw foundation model output in parts of the agent sequence.
|
|
3861
|
+
* If you specify this field, at least one of the <code>promptConfigurations</code> must contain a <code>parserMode</code> value that is
|
|
3862
|
+
* set to <code>OVERRIDDEN</code>. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/lambda-parser.html">Parser Lambda function in Amazon Bedrock Agents</a>.
|
|
3863
|
+
* </p>
|
|
3864
|
+
* @public
|
|
3865
|
+
*/
|
|
3866
|
+
overrideLambda?: string | undefined;
|
|
3867
|
+
}
|
|
3868
|
+
/**
|
|
3869
|
+
* <p>Contains a part of an agent response and citations for it. </p>
|
|
3870
|
+
* @public
|
|
3871
|
+
*/
|
|
3872
|
+
export interface InlineAgentPayloadPart {
|
|
3873
|
+
/**
|
|
3874
|
+
* <p>A part of the agent response in bytes.</p>
|
|
3875
|
+
* @public
|
|
3876
|
+
*/
|
|
3877
|
+
bytes?: Uint8Array | undefined;
|
|
3878
|
+
/**
|
|
3879
|
+
* <p>Contains citations for a part of an agent response.</p>
|
|
3880
|
+
* @public
|
|
3881
|
+
*/
|
|
3882
|
+
attribution?: Attribution | undefined;
|
|
3883
|
+
}
|
|
3884
|
+
/**
|
|
3885
|
+
* <p>Contains intermediate response for code interpreter if any files have been generated.</p>
|
|
3886
|
+
* @public
|
|
3887
|
+
*/
|
|
3888
|
+
export interface InlineAgentFilePart {
|
|
3889
|
+
/**
|
|
3890
|
+
* <p>Files containing intermediate response for the user.</p>
|
|
3891
|
+
* @public
|
|
3892
|
+
*/
|
|
3893
|
+
files?: OutputFile[] | undefined;
|
|
3894
|
+
}
|
|
3895
|
+
/**
|
|
3896
|
+
* <p>Contains information to return from the action group that the agent has predicted to invoke.</p>
|
|
3897
|
+
* <p>This data type is used in the <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html#API_agent-runtime_InvokeAgent_ResponseSyntax">InvokeAgent response</a> API operation.</p>
|
|
3898
|
+
* @public
|
|
3899
|
+
*/
|
|
3900
|
+
export interface InlineAgentReturnControlPayload {
|
|
3901
|
+
/**
|
|
3902
|
+
* <p>A list of objects that contain information about the parameters and inputs that need to be sent into the API operation or function, based on what the agent
|
|
3903
|
+
* determines from its session with the user.</p>
|
|
3904
|
+
* @public
|
|
3905
|
+
*/
|
|
3906
|
+
invocationInputs?: InvocationInputMember[] | undefined;
|
|
3907
|
+
/**
|
|
3908
|
+
* <p>The identifier of the action group invocation. </p>
|
|
3909
|
+
* @public
|
|
3910
|
+
*/
|
|
3911
|
+
invocationId?: string | undefined;
|
|
3912
|
+
}
|
|
3913
|
+
/**
|
|
3914
|
+
* <p>Contains information about the agent and session, alongside the agent's reasoning process and results from calling API actions and querying knowledge bases
|
|
3915
|
+
* and metadata about the trace. You can use the trace to understand how the agent arrived at the response it provided the customer.
|
|
3916
|
+
* For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-test.html#trace-enablement">Trace enablement</a>.</p>
|
|
3917
|
+
* @public
|
|
3918
|
+
*/
|
|
3919
|
+
export interface InlineAgentTracePart {
|
|
3920
|
+
/**
|
|
3921
|
+
* <p>The unique identifier of the session with the agent.</p>
|
|
3922
|
+
* @public
|
|
3923
|
+
*/
|
|
3924
|
+
sessionId?: string | undefined;
|
|
3925
|
+
/**
|
|
3926
|
+
* <p>Contains one part of the agent's reasoning process and results from calling API actions and querying knowledge bases. You can use the trace to understand how the
|
|
3927
|
+
* agent arrived at the response it provided the customer. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-test.html#trace-enablement">Trace enablement</a>.
|
|
3928
|
+
* </p>
|
|
3929
|
+
* @public
|
|
3930
|
+
*/
|
|
3931
|
+
trace?: Trace | undefined;
|
|
3932
|
+
}
|
|
3933
|
+
/**
|
|
3934
|
+
* <p>The response from invoking the agent and associated citations and trace information.</p>
|
|
3935
|
+
* @public
|
|
3936
|
+
*/
|
|
3937
|
+
export type InlineAgentResponseStream = InlineAgentResponseStream.AccessDeniedExceptionMember | InlineAgentResponseStream.BadGatewayExceptionMember | InlineAgentResponseStream.ChunkMember | InlineAgentResponseStream.ConflictExceptionMember | InlineAgentResponseStream.DependencyFailedExceptionMember | InlineAgentResponseStream.FilesMember | InlineAgentResponseStream.InternalServerExceptionMember | InlineAgentResponseStream.ResourceNotFoundExceptionMember | InlineAgentResponseStream.ReturnControlMember | InlineAgentResponseStream.ServiceQuotaExceededExceptionMember | InlineAgentResponseStream.ThrottlingExceptionMember | InlineAgentResponseStream.TraceMember | InlineAgentResponseStream.ValidationExceptionMember | InlineAgentResponseStream.$UnknownMember;
|
|
3938
|
+
/**
|
|
3939
|
+
* @public
|
|
3940
|
+
*/
|
|
3941
|
+
export declare namespace InlineAgentResponseStream {
|
|
3942
|
+
/**
|
|
3943
|
+
* <p>Contains a part of an agent response and citations for it.</p>
|
|
3944
|
+
* @public
|
|
3945
|
+
*/
|
|
3946
|
+
interface ChunkMember {
|
|
3947
|
+
chunk: InlineAgentPayloadPart;
|
|
3948
|
+
trace?: never;
|
|
3949
|
+
returnControl?: never;
|
|
3950
|
+
internalServerException?: never;
|
|
3951
|
+
validationException?: never;
|
|
3952
|
+
resourceNotFoundException?: never;
|
|
3953
|
+
serviceQuotaExceededException?: never;
|
|
3954
|
+
throttlingException?: never;
|
|
3955
|
+
accessDeniedException?: never;
|
|
3956
|
+
conflictException?: never;
|
|
3957
|
+
dependencyFailedException?: never;
|
|
3958
|
+
badGatewayException?: never;
|
|
3959
|
+
files?: never;
|
|
3960
|
+
$unknown?: never;
|
|
3961
|
+
}
|
|
3962
|
+
/**
|
|
3963
|
+
* <p>Contains information about the agent and session, alongside the agent's reasoning process and results from calling actions and querying
|
|
3964
|
+
* knowledge bases and metadata about the trace. You can use the trace to understand how the agent arrived at the response it provided the customer.
|
|
3965
|
+
* For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/trace-events.html">Trace events</a>.
|
|
3966
|
+
* </p>
|
|
3967
|
+
* @public
|
|
3968
|
+
*/
|
|
3969
|
+
interface TraceMember {
|
|
3970
|
+
chunk?: never;
|
|
3971
|
+
trace: InlineAgentTracePart;
|
|
3972
|
+
returnControl?: never;
|
|
3973
|
+
internalServerException?: never;
|
|
3974
|
+
validationException?: never;
|
|
3975
|
+
resourceNotFoundException?: never;
|
|
3976
|
+
serviceQuotaExceededException?: never;
|
|
3977
|
+
throttlingException?: never;
|
|
3978
|
+
accessDeniedException?: never;
|
|
3979
|
+
conflictException?: never;
|
|
3980
|
+
dependencyFailedException?: never;
|
|
3981
|
+
badGatewayException?: never;
|
|
3982
|
+
files?: never;
|
|
3983
|
+
$unknown?: never;
|
|
3984
|
+
}
|
|
3985
|
+
/**
|
|
3986
|
+
* <p>Contains the parameters and information that the agent elicited from the customer to carry out an action. This information is returned to the system
|
|
3987
|
+
* and can be used in your own setup for fulfilling the action.</p>
|
|
3988
|
+
* @public
|
|
3989
|
+
*/
|
|
3990
|
+
interface ReturnControlMember {
|
|
3991
|
+
chunk?: never;
|
|
3992
|
+
trace?: never;
|
|
3993
|
+
returnControl: InlineAgentReturnControlPayload;
|
|
3994
|
+
internalServerException?: never;
|
|
3995
|
+
validationException?: never;
|
|
3996
|
+
resourceNotFoundException?: never;
|
|
3997
|
+
serviceQuotaExceededException?: never;
|
|
3998
|
+
throttlingException?: never;
|
|
3999
|
+
accessDeniedException?: never;
|
|
4000
|
+
conflictException?: never;
|
|
4001
|
+
dependencyFailedException?: never;
|
|
4002
|
+
badGatewayException?: never;
|
|
4003
|
+
files?: never;
|
|
4004
|
+
$unknown?: never;
|
|
4005
|
+
}
|
|
4006
|
+
/**
|
|
4007
|
+
* <p>An internal server error occurred. Retry your request.</p>
|
|
4008
|
+
* @public
|
|
4009
|
+
*/
|
|
4010
|
+
interface InternalServerExceptionMember {
|
|
4011
|
+
chunk?: never;
|
|
4012
|
+
trace?: never;
|
|
4013
|
+
returnControl?: never;
|
|
4014
|
+
internalServerException: InternalServerException;
|
|
4015
|
+
validationException?: never;
|
|
4016
|
+
resourceNotFoundException?: never;
|
|
4017
|
+
serviceQuotaExceededException?: never;
|
|
4018
|
+
throttlingException?: never;
|
|
4019
|
+
accessDeniedException?: never;
|
|
4020
|
+
conflictException?: never;
|
|
4021
|
+
dependencyFailedException?: never;
|
|
4022
|
+
badGatewayException?: never;
|
|
4023
|
+
files?: never;
|
|
4024
|
+
$unknown?: never;
|
|
4025
|
+
}
|
|
4026
|
+
/**
|
|
4027
|
+
* <p>Input validation failed. Check your request parameters and retry the request.</p>
|
|
4028
|
+
* @public
|
|
4029
|
+
*/
|
|
4030
|
+
interface ValidationExceptionMember {
|
|
4031
|
+
chunk?: never;
|
|
4032
|
+
trace?: never;
|
|
4033
|
+
returnControl?: never;
|
|
4034
|
+
internalServerException?: never;
|
|
4035
|
+
validationException: ValidationException;
|
|
4036
|
+
resourceNotFoundException?: never;
|
|
4037
|
+
serviceQuotaExceededException?: never;
|
|
4038
|
+
throttlingException?: never;
|
|
4039
|
+
accessDeniedException?: never;
|
|
4040
|
+
conflictException?: never;
|
|
4041
|
+
dependencyFailedException?: never;
|
|
4042
|
+
badGatewayException?: never;
|
|
4043
|
+
files?: never;
|
|
4044
|
+
$unknown?: never;
|
|
4045
|
+
}
|
|
4046
|
+
/**
|
|
4047
|
+
* <p>The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again. </p>
|
|
4048
|
+
* @public
|
|
4049
|
+
*/
|
|
4050
|
+
interface ResourceNotFoundExceptionMember {
|
|
4051
|
+
chunk?: never;
|
|
4052
|
+
trace?: never;
|
|
4053
|
+
returnControl?: never;
|
|
4054
|
+
internalServerException?: never;
|
|
4055
|
+
validationException?: never;
|
|
4056
|
+
resourceNotFoundException: ResourceNotFoundException;
|
|
4057
|
+
serviceQuotaExceededException?: never;
|
|
4058
|
+
throttlingException?: never;
|
|
4059
|
+
accessDeniedException?: never;
|
|
4060
|
+
conflictException?: never;
|
|
4061
|
+
dependencyFailedException?: never;
|
|
4062
|
+
badGatewayException?: never;
|
|
4063
|
+
files?: never;
|
|
4064
|
+
$unknown?: never;
|
|
4065
|
+
}
|
|
4066
|
+
/**
|
|
4067
|
+
* <p>The number of requests exceeds the service quota. Resubmit your request later.</p>
|
|
4068
|
+
* @public
|
|
4069
|
+
*/
|
|
4070
|
+
interface ServiceQuotaExceededExceptionMember {
|
|
4071
|
+
chunk?: never;
|
|
4072
|
+
trace?: never;
|
|
4073
|
+
returnControl?: never;
|
|
4074
|
+
internalServerException?: never;
|
|
4075
|
+
validationException?: never;
|
|
4076
|
+
resourceNotFoundException?: never;
|
|
4077
|
+
serviceQuotaExceededException: ServiceQuotaExceededException;
|
|
4078
|
+
throttlingException?: never;
|
|
4079
|
+
accessDeniedException?: never;
|
|
4080
|
+
conflictException?: never;
|
|
4081
|
+
dependencyFailedException?: never;
|
|
4082
|
+
badGatewayException?: never;
|
|
4083
|
+
files?: never;
|
|
4084
|
+
$unknown?: never;
|
|
4085
|
+
}
|
|
4086
|
+
/**
|
|
4087
|
+
* <p>The number of requests exceeds the limit. Resubmit your request later.</p>
|
|
4088
|
+
* @public
|
|
4089
|
+
*/
|
|
4090
|
+
interface ThrottlingExceptionMember {
|
|
4091
|
+
chunk?: never;
|
|
4092
|
+
trace?: never;
|
|
4093
|
+
returnControl?: never;
|
|
4094
|
+
internalServerException?: never;
|
|
4095
|
+
validationException?: never;
|
|
4096
|
+
resourceNotFoundException?: never;
|
|
4097
|
+
serviceQuotaExceededException?: never;
|
|
4098
|
+
throttlingException: ThrottlingException;
|
|
4099
|
+
accessDeniedException?: never;
|
|
4100
|
+
conflictException?: never;
|
|
4101
|
+
dependencyFailedException?: never;
|
|
4102
|
+
badGatewayException?: never;
|
|
4103
|
+
files?: never;
|
|
4104
|
+
$unknown?: never;
|
|
4105
|
+
}
|
|
4106
|
+
/**
|
|
4107
|
+
* <p>The request is denied because of missing access permissions. Check your permissions and retry your request.</p>
|
|
4108
|
+
* @public
|
|
4109
|
+
*/
|
|
4110
|
+
interface AccessDeniedExceptionMember {
|
|
4111
|
+
chunk?: never;
|
|
4112
|
+
trace?: never;
|
|
4113
|
+
returnControl?: never;
|
|
4114
|
+
internalServerException?: never;
|
|
4115
|
+
validationException?: never;
|
|
4116
|
+
resourceNotFoundException?: never;
|
|
4117
|
+
serviceQuotaExceededException?: never;
|
|
4118
|
+
throttlingException?: never;
|
|
4119
|
+
accessDeniedException: AccessDeniedException;
|
|
4120
|
+
conflictException?: never;
|
|
4121
|
+
dependencyFailedException?: never;
|
|
4122
|
+
badGatewayException?: never;
|
|
4123
|
+
files?: never;
|
|
4124
|
+
$unknown?: never;
|
|
4125
|
+
}
|
|
4126
|
+
/**
|
|
4127
|
+
* <p>There was a conflict performing an operation. Resolve the conflict and retry your request. </p>
|
|
4128
|
+
* @public
|
|
4129
|
+
*/
|
|
4130
|
+
interface ConflictExceptionMember {
|
|
4131
|
+
chunk?: never;
|
|
4132
|
+
trace?: never;
|
|
4133
|
+
returnControl?: never;
|
|
4134
|
+
internalServerException?: never;
|
|
4135
|
+
validationException?: never;
|
|
4136
|
+
resourceNotFoundException?: never;
|
|
4137
|
+
serviceQuotaExceededException?: never;
|
|
4138
|
+
throttlingException?: never;
|
|
4139
|
+
accessDeniedException?: never;
|
|
4140
|
+
conflictException: ConflictException;
|
|
4141
|
+
dependencyFailedException?: never;
|
|
4142
|
+
badGatewayException?: never;
|
|
4143
|
+
files?: never;
|
|
4144
|
+
$unknown?: never;
|
|
4145
|
+
}
|
|
4146
|
+
/**
|
|
4147
|
+
* <p>There was an issue with a dependency. Check the resource configurations and retry the request.</p>
|
|
4148
|
+
* @public
|
|
4149
|
+
*/
|
|
4150
|
+
interface DependencyFailedExceptionMember {
|
|
4151
|
+
chunk?: never;
|
|
4152
|
+
trace?: never;
|
|
4153
|
+
returnControl?: never;
|
|
4154
|
+
internalServerException?: never;
|
|
4155
|
+
validationException?: never;
|
|
4156
|
+
resourceNotFoundException?: never;
|
|
4157
|
+
serviceQuotaExceededException?: never;
|
|
4158
|
+
throttlingException?: never;
|
|
4159
|
+
accessDeniedException?: never;
|
|
4160
|
+
conflictException?: never;
|
|
4161
|
+
dependencyFailedException: DependencyFailedException;
|
|
4162
|
+
badGatewayException?: never;
|
|
4163
|
+
files?: never;
|
|
4164
|
+
$unknown?: never;
|
|
4165
|
+
}
|
|
4166
|
+
/**
|
|
4167
|
+
* <p>There was an issue with a dependency due to a server issue. Retry your request. </p>
|
|
4168
|
+
* @public
|
|
4169
|
+
*/
|
|
4170
|
+
interface BadGatewayExceptionMember {
|
|
4171
|
+
chunk?: never;
|
|
4172
|
+
trace?: never;
|
|
4173
|
+
returnControl?: never;
|
|
4174
|
+
internalServerException?: never;
|
|
4175
|
+
validationException?: never;
|
|
4176
|
+
resourceNotFoundException?: never;
|
|
4177
|
+
serviceQuotaExceededException?: never;
|
|
4178
|
+
throttlingException?: never;
|
|
4179
|
+
accessDeniedException?: never;
|
|
4180
|
+
conflictException?: never;
|
|
4181
|
+
dependencyFailedException?: never;
|
|
4182
|
+
badGatewayException: BadGatewayException;
|
|
4183
|
+
files?: never;
|
|
4184
|
+
$unknown?: never;
|
|
4185
|
+
}
|
|
4186
|
+
/**
|
|
4187
|
+
* <p>Contains intermediate response for code interpreter if any files have been generated.</p>
|
|
4188
|
+
* @public
|
|
4189
|
+
*/
|
|
4190
|
+
interface FilesMember {
|
|
4191
|
+
chunk?: never;
|
|
4192
|
+
trace?: never;
|
|
4193
|
+
returnControl?: never;
|
|
4194
|
+
internalServerException?: never;
|
|
4195
|
+
validationException?: never;
|
|
4196
|
+
resourceNotFoundException?: never;
|
|
4197
|
+
serviceQuotaExceededException?: never;
|
|
4198
|
+
throttlingException?: never;
|
|
4199
|
+
accessDeniedException?: never;
|
|
4200
|
+
conflictException?: never;
|
|
4201
|
+
dependencyFailedException?: never;
|
|
4202
|
+
badGatewayException?: never;
|
|
4203
|
+
files: InlineAgentFilePart;
|
|
4204
|
+
$unknown?: never;
|
|
4205
|
+
}
|
|
4206
|
+
/**
|
|
4207
|
+
* @public
|
|
4208
|
+
*/
|
|
4209
|
+
interface $UnknownMember {
|
|
4210
|
+
chunk?: never;
|
|
4211
|
+
trace?: never;
|
|
4212
|
+
returnControl?: never;
|
|
4213
|
+
internalServerException?: never;
|
|
4214
|
+
validationException?: never;
|
|
4215
|
+
resourceNotFoundException?: never;
|
|
4216
|
+
serviceQuotaExceededException?: never;
|
|
4217
|
+
throttlingException?: never;
|
|
4218
|
+
accessDeniedException?: never;
|
|
4219
|
+
conflictException?: never;
|
|
4220
|
+
dependencyFailedException?: never;
|
|
4221
|
+
badGatewayException?: never;
|
|
4222
|
+
files?: never;
|
|
4223
|
+
$unknown: [string, any];
|
|
4224
|
+
}
|
|
4225
|
+
interface Visitor<T> {
|
|
4226
|
+
chunk: (value: InlineAgentPayloadPart) => T;
|
|
4227
|
+
trace: (value: InlineAgentTracePart) => T;
|
|
4228
|
+
returnControl: (value: InlineAgentReturnControlPayload) => T;
|
|
4229
|
+
internalServerException: (value: InternalServerException) => T;
|
|
4230
|
+
validationException: (value: ValidationException) => T;
|
|
4231
|
+
resourceNotFoundException: (value: ResourceNotFoundException) => T;
|
|
4232
|
+
serviceQuotaExceededException: (value: ServiceQuotaExceededException) => T;
|
|
4233
|
+
throttlingException: (value: ThrottlingException) => T;
|
|
4234
|
+
accessDeniedException: (value: AccessDeniedException) => T;
|
|
4235
|
+
conflictException: (value: ConflictException) => T;
|
|
4236
|
+
dependencyFailedException: (value: DependencyFailedException) => T;
|
|
4237
|
+
badGatewayException: (value: BadGatewayException) => T;
|
|
4238
|
+
files: (value: InlineAgentFilePart) => T;
|
|
4239
|
+
_: (name: string, value: any) => T;
|
|
4240
|
+
}
|
|
4241
|
+
const visit: <T>(value: InlineAgentResponseStream, visitor: Visitor<T>) => T;
|
|
4242
|
+
}
|
|
4243
|
+
/**
|
|
4244
|
+
* @public
|
|
4245
|
+
*/
|
|
4246
|
+
export interface InvokeInlineAgentResponse {
|
|
4247
|
+
/**
|
|
4248
|
+
* <p>
|
|
4249
|
+
*
|
|
4250
|
+
* </p>
|
|
4251
|
+
* @public
|
|
4252
|
+
*/
|
|
4253
|
+
completion: AsyncIterable<InlineAgentResponseStream> | undefined;
|
|
4254
|
+
/**
|
|
4255
|
+
* <p>
|
|
4256
|
+
* The MIME type of the input data in the request. The default value is application/json.
|
|
4257
|
+
* </p>
|
|
4258
|
+
* @public
|
|
4259
|
+
*/
|
|
4260
|
+
contentType: string | undefined;
|
|
4261
|
+
/**
|
|
4262
|
+
* <p>
|
|
4263
|
+
* The unique identifier of the session with the agent.
|
|
4264
|
+
* </p>
|
|
4265
|
+
* @public
|
|
4266
|
+
*/
|
|
4267
|
+
sessionId: string | undefined;
|
|
4268
|
+
}
|
|
4269
|
+
/**
|
|
4270
|
+
* @public
|
|
4271
|
+
*/
|
|
4272
|
+
export interface DeleteAgentMemoryRequest {
|
|
4273
|
+
/**
|
|
4274
|
+
* <p>The unique identifier of the agent to which the alias belongs.</p>
|
|
4275
|
+
* @public
|
|
4276
|
+
*/
|
|
4277
|
+
agentId: string | undefined;
|
|
4278
|
+
/**
|
|
4279
|
+
* <p>The unique identifier of an alias of an agent.</p>
|
|
4280
|
+
* @public
|
|
4281
|
+
*/
|
|
4282
|
+
agentAliasId: string | undefined;
|
|
4283
|
+
/**
|
|
4284
|
+
* <p>The unique identifier of the memory.</p>
|
|
4285
|
+
* @public
|
|
4286
|
+
*/
|
|
4287
|
+
memoryId?: string | undefined;
|
|
4288
|
+
}
|
|
4289
|
+
/**
|
|
4290
|
+
* @public
|
|
4291
|
+
*/
|
|
4292
|
+
export interface DeleteAgentMemoryResponse {
|
|
4293
|
+
}
|
|
4294
|
+
/**
|
|
4295
|
+
* @public
|
|
4296
|
+
* @enum
|
|
4297
|
+
*/
|
|
4298
|
+
export declare const MemoryType: {
|
|
4299
|
+
readonly SESSION_SUMMARY: "SESSION_SUMMARY";
|
|
4300
|
+
};
|
|
4301
|
+
/**
|
|
4302
|
+
* @public
|
|
4303
|
+
*/
|
|
4304
|
+
export type MemoryType = (typeof MemoryType)[keyof typeof MemoryType];
|
|
3412
4305
|
/**
|
|
3413
4306
|
* @public
|
|
3414
4307
|
*/
|
|
@@ -3463,66 +4356,340 @@ export interface MemorySessionSummary {
|
|
|
3463
4356
|
*/
|
|
3464
4357
|
sessionId?: string | undefined;
|
|
3465
4358
|
/**
|
|
3466
|
-
* <p>The start time for this session.</p>
|
|
4359
|
+
* <p>The start time for this session.</p>
|
|
4360
|
+
* @public
|
|
4361
|
+
*/
|
|
4362
|
+
sessionStartTime?: Date | undefined;
|
|
4363
|
+
/**
|
|
4364
|
+
* <p>The time when the memory duration for the session is set to end.</p>
|
|
4365
|
+
* @public
|
|
4366
|
+
*/
|
|
4367
|
+
sessionExpiryTime?: Date | undefined;
|
|
4368
|
+
/**
|
|
4369
|
+
* <p>The summarized text for this session.</p>
|
|
4370
|
+
* @public
|
|
4371
|
+
*/
|
|
4372
|
+
summaryText?: string | undefined;
|
|
4373
|
+
}
|
|
4374
|
+
/**
|
|
4375
|
+
* <p>Contains sessions summaries.</p>
|
|
4376
|
+
* @public
|
|
4377
|
+
*/
|
|
4378
|
+
export type Memory = Memory.SessionSummaryMember | Memory.$UnknownMember;
|
|
4379
|
+
/**
|
|
4380
|
+
* @public
|
|
4381
|
+
*/
|
|
4382
|
+
export declare namespace Memory {
|
|
4383
|
+
/**
|
|
4384
|
+
* <p>Contains summary of a session.</p>
|
|
4385
|
+
* @public
|
|
4386
|
+
*/
|
|
4387
|
+
interface SessionSummaryMember {
|
|
4388
|
+
sessionSummary: MemorySessionSummary;
|
|
4389
|
+
$unknown?: never;
|
|
4390
|
+
}
|
|
4391
|
+
/**
|
|
4392
|
+
* @public
|
|
4393
|
+
*/
|
|
4394
|
+
interface $UnknownMember {
|
|
4395
|
+
sessionSummary?: never;
|
|
4396
|
+
$unknown: [string, any];
|
|
4397
|
+
}
|
|
4398
|
+
interface Visitor<T> {
|
|
4399
|
+
sessionSummary: (value: MemorySessionSummary) => T;
|
|
4400
|
+
_: (name: string, value: any) => T;
|
|
4401
|
+
}
|
|
4402
|
+
const visit: <T>(value: Memory, visitor: Visitor<T>) => T;
|
|
4403
|
+
}
|
|
4404
|
+
/**
|
|
4405
|
+
* @public
|
|
4406
|
+
*/
|
|
4407
|
+
export interface GetAgentMemoryResponse {
|
|
4408
|
+
/**
|
|
4409
|
+
* <p>If the total number of results is greater than the maxItems value provided in the request, use this token
|
|
4410
|
+
* when making another request in the <code>nextToken</code> field to return the next batch of results.</p>
|
|
4411
|
+
* @public
|
|
4412
|
+
*/
|
|
4413
|
+
nextToken?: string | undefined;
|
|
4414
|
+
/**
|
|
4415
|
+
* <p>Contains details of the sessions stored in the memory</p>
|
|
4416
|
+
* @public
|
|
4417
|
+
*/
|
|
4418
|
+
memoryContents?: Memory[] | undefined;
|
|
4419
|
+
}
|
|
4420
|
+
/**
|
|
4421
|
+
* <p>Contains information about the text prompt to optimize.</p>
|
|
4422
|
+
* @public
|
|
4423
|
+
*/
|
|
4424
|
+
export interface TextPrompt {
|
|
4425
|
+
/**
|
|
4426
|
+
* <p>The text in the text prompt to optimize.</p>
|
|
4427
|
+
* @public
|
|
4428
|
+
*/
|
|
4429
|
+
text: string | undefined;
|
|
4430
|
+
}
|
|
4431
|
+
/**
|
|
4432
|
+
* <p>Contains information about the prompt to optimize.</p>
|
|
4433
|
+
* @public
|
|
4434
|
+
*/
|
|
4435
|
+
export type InputPrompt = InputPrompt.TextPromptMember | InputPrompt.$UnknownMember;
|
|
4436
|
+
/**
|
|
4437
|
+
* @public
|
|
4438
|
+
*/
|
|
4439
|
+
export declare namespace InputPrompt {
|
|
4440
|
+
/**
|
|
4441
|
+
* <p>Contains information about the text prompt to optimize.</p>
|
|
4442
|
+
* @public
|
|
4443
|
+
*/
|
|
4444
|
+
interface TextPromptMember {
|
|
4445
|
+
textPrompt: TextPrompt;
|
|
4446
|
+
$unknown?: never;
|
|
4447
|
+
}
|
|
4448
|
+
/**
|
|
4449
|
+
* @public
|
|
4450
|
+
*/
|
|
4451
|
+
interface $UnknownMember {
|
|
4452
|
+
textPrompt?: never;
|
|
4453
|
+
$unknown: [string, any];
|
|
4454
|
+
}
|
|
4455
|
+
interface Visitor<T> {
|
|
4456
|
+
textPrompt: (value: TextPrompt) => T;
|
|
4457
|
+
_: (name: string, value: any) => T;
|
|
4458
|
+
}
|
|
4459
|
+
const visit: <T>(value: InputPrompt, visitor: Visitor<T>) => T;
|
|
4460
|
+
}
|
|
4461
|
+
/**
|
|
4462
|
+
* @public
|
|
4463
|
+
*/
|
|
4464
|
+
export interface OptimizePromptRequest {
|
|
4465
|
+
/**
|
|
4466
|
+
* <p>Contains the prompt to optimize.</p>
|
|
4467
|
+
* @public
|
|
4468
|
+
*/
|
|
4469
|
+
input: InputPrompt | undefined;
|
|
4470
|
+
/**
|
|
4471
|
+
* <p>The unique identifier of the model that you want to optimize the prompt for.</p>
|
|
4472
|
+
* @public
|
|
4473
|
+
*/
|
|
4474
|
+
targetModelId: string | undefined;
|
|
4475
|
+
}
|
|
4476
|
+
/**
|
|
4477
|
+
* <p>An event in which the prompt was analyzed in preparation for optimization.</p>
|
|
4478
|
+
* @public
|
|
4479
|
+
*/
|
|
4480
|
+
export interface AnalyzePromptEvent {
|
|
4481
|
+
/**
|
|
4482
|
+
* <p>A message describing the analysis of the prompt.</p>
|
|
4483
|
+
* @public
|
|
4484
|
+
*/
|
|
4485
|
+
message?: string | undefined;
|
|
4486
|
+
}
|
|
4487
|
+
/**
|
|
4488
|
+
* <p>Contains information about the optimized prompt.</p>
|
|
4489
|
+
* @public
|
|
4490
|
+
*/
|
|
4491
|
+
export type OptimizedPrompt = OptimizedPrompt.TextPromptMember | OptimizedPrompt.$UnknownMember;
|
|
4492
|
+
/**
|
|
4493
|
+
* @public
|
|
4494
|
+
*/
|
|
4495
|
+
export declare namespace OptimizedPrompt {
|
|
4496
|
+
/**
|
|
4497
|
+
* <p>Contains information about the text in the prompt that was optimized.</p>
|
|
4498
|
+
* @public
|
|
4499
|
+
*/
|
|
4500
|
+
interface TextPromptMember {
|
|
4501
|
+
textPrompt: TextPrompt;
|
|
4502
|
+
$unknown?: never;
|
|
4503
|
+
}
|
|
4504
|
+
/**
|
|
4505
|
+
* @public
|
|
4506
|
+
*/
|
|
4507
|
+
interface $UnknownMember {
|
|
4508
|
+
textPrompt?: never;
|
|
4509
|
+
$unknown: [string, any];
|
|
4510
|
+
}
|
|
4511
|
+
interface Visitor<T> {
|
|
4512
|
+
textPrompt: (value: TextPrompt) => T;
|
|
4513
|
+
_: (name: string, value: any) => T;
|
|
4514
|
+
}
|
|
4515
|
+
const visit: <T>(value: OptimizedPrompt, visitor: Visitor<T>) => T;
|
|
4516
|
+
}
|
|
4517
|
+
/**
|
|
4518
|
+
* <p>An event in which the prompt was optimized.</p>
|
|
4519
|
+
* @public
|
|
4520
|
+
*/
|
|
4521
|
+
export interface OptimizedPromptEvent {
|
|
4522
|
+
/**
|
|
4523
|
+
* <p>Contains information about the optimized prompt.</p>
|
|
4524
|
+
* @public
|
|
4525
|
+
*/
|
|
4526
|
+
optimizedPrompt?: OptimizedPrompt | undefined;
|
|
4527
|
+
}
|
|
4528
|
+
/**
|
|
4529
|
+
* <p>The stream containing events in the prompt optimization process.</p>
|
|
4530
|
+
* @public
|
|
4531
|
+
*/
|
|
4532
|
+
export type OptimizedPromptStream = OptimizedPromptStream.AccessDeniedExceptionMember | OptimizedPromptStream.AnalyzePromptEventMember | OptimizedPromptStream.BadGatewayExceptionMember | OptimizedPromptStream.DependencyFailedExceptionMember | OptimizedPromptStream.InternalServerExceptionMember | OptimizedPromptStream.OptimizedPromptEventMember | OptimizedPromptStream.ThrottlingExceptionMember | OptimizedPromptStream.ValidationExceptionMember | OptimizedPromptStream.$UnknownMember;
|
|
4533
|
+
/**
|
|
4534
|
+
* @public
|
|
4535
|
+
*/
|
|
4536
|
+
export declare namespace OptimizedPromptStream {
|
|
4537
|
+
/**
|
|
4538
|
+
* <p>An event in which the prompt was optimized.</p>
|
|
4539
|
+
* @public
|
|
4540
|
+
*/
|
|
4541
|
+
interface OptimizedPromptEventMember {
|
|
4542
|
+
optimizedPromptEvent: OptimizedPromptEvent;
|
|
4543
|
+
analyzePromptEvent?: never;
|
|
4544
|
+
internalServerException?: never;
|
|
4545
|
+
throttlingException?: never;
|
|
4546
|
+
validationException?: never;
|
|
4547
|
+
dependencyFailedException?: never;
|
|
4548
|
+
accessDeniedException?: never;
|
|
4549
|
+
badGatewayException?: never;
|
|
4550
|
+
$unknown?: never;
|
|
4551
|
+
}
|
|
4552
|
+
/**
|
|
4553
|
+
* <p>An event in which the prompt was analyzed in preparation for optimization.</p>
|
|
4554
|
+
* @public
|
|
4555
|
+
*/
|
|
4556
|
+
interface AnalyzePromptEventMember {
|
|
4557
|
+
optimizedPromptEvent?: never;
|
|
4558
|
+
analyzePromptEvent: AnalyzePromptEvent;
|
|
4559
|
+
internalServerException?: never;
|
|
4560
|
+
throttlingException?: never;
|
|
4561
|
+
validationException?: never;
|
|
4562
|
+
dependencyFailedException?: never;
|
|
4563
|
+
accessDeniedException?: never;
|
|
4564
|
+
badGatewayException?: never;
|
|
4565
|
+
$unknown?: never;
|
|
4566
|
+
}
|
|
4567
|
+
/**
|
|
4568
|
+
* <p>An internal server error occurred. Retry your request.</p>
|
|
4569
|
+
* @public
|
|
4570
|
+
*/
|
|
4571
|
+
interface InternalServerExceptionMember {
|
|
4572
|
+
optimizedPromptEvent?: never;
|
|
4573
|
+
analyzePromptEvent?: never;
|
|
4574
|
+
internalServerException: InternalServerException;
|
|
4575
|
+
throttlingException?: never;
|
|
4576
|
+
validationException?: never;
|
|
4577
|
+
dependencyFailedException?: never;
|
|
4578
|
+
accessDeniedException?: never;
|
|
4579
|
+
badGatewayException?: never;
|
|
4580
|
+
$unknown?: never;
|
|
4581
|
+
}
|
|
4582
|
+
/**
|
|
4583
|
+
* <p>Your request was throttled because of service-wide limitations. Resubmit your request later or in a different region. You can also purchase <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/prov-throughput.html">Provisioned Throughput</a> to increase the rate or number of tokens you can process.</p>
|
|
4584
|
+
* @public
|
|
4585
|
+
*/
|
|
4586
|
+
interface ThrottlingExceptionMember {
|
|
4587
|
+
optimizedPromptEvent?: never;
|
|
4588
|
+
analyzePromptEvent?: never;
|
|
4589
|
+
internalServerException?: never;
|
|
4590
|
+
throttlingException: ThrottlingException;
|
|
4591
|
+
validationException?: never;
|
|
4592
|
+
dependencyFailedException?: never;
|
|
4593
|
+
accessDeniedException?: never;
|
|
4594
|
+
badGatewayException?: never;
|
|
4595
|
+
$unknown?: never;
|
|
4596
|
+
}
|
|
4597
|
+
/**
|
|
4598
|
+
* <p>Input validation failed. Check your request parameters and retry the request.</p>
|
|
3467
4599
|
* @public
|
|
3468
4600
|
*/
|
|
3469
|
-
|
|
4601
|
+
interface ValidationExceptionMember {
|
|
4602
|
+
optimizedPromptEvent?: never;
|
|
4603
|
+
analyzePromptEvent?: never;
|
|
4604
|
+
internalServerException?: never;
|
|
4605
|
+
throttlingException?: never;
|
|
4606
|
+
validationException: ValidationException;
|
|
4607
|
+
dependencyFailedException?: never;
|
|
4608
|
+
accessDeniedException?: never;
|
|
4609
|
+
badGatewayException?: never;
|
|
4610
|
+
$unknown?: never;
|
|
4611
|
+
}
|
|
3470
4612
|
/**
|
|
3471
|
-
* <p>
|
|
4613
|
+
* <p>There was an issue with a dependency. Check the resource configurations and retry the request.</p>
|
|
3472
4614
|
* @public
|
|
3473
4615
|
*/
|
|
3474
|
-
|
|
4616
|
+
interface DependencyFailedExceptionMember {
|
|
4617
|
+
optimizedPromptEvent?: never;
|
|
4618
|
+
analyzePromptEvent?: never;
|
|
4619
|
+
internalServerException?: never;
|
|
4620
|
+
throttlingException?: never;
|
|
4621
|
+
validationException?: never;
|
|
4622
|
+
dependencyFailedException: DependencyFailedException;
|
|
4623
|
+
accessDeniedException?: never;
|
|
4624
|
+
badGatewayException?: never;
|
|
4625
|
+
$unknown?: never;
|
|
4626
|
+
}
|
|
3475
4627
|
/**
|
|
3476
|
-
* <p>The
|
|
4628
|
+
* <p>The request is denied because of missing access permissions. Check your permissions and retry your request.</p>
|
|
3477
4629
|
* @public
|
|
3478
4630
|
*/
|
|
3479
|
-
|
|
3480
|
-
|
|
3481
|
-
|
|
3482
|
-
|
|
3483
|
-
|
|
3484
|
-
|
|
3485
|
-
|
|
3486
|
-
|
|
3487
|
-
|
|
3488
|
-
|
|
3489
|
-
|
|
4631
|
+
interface AccessDeniedExceptionMember {
|
|
4632
|
+
optimizedPromptEvent?: never;
|
|
4633
|
+
analyzePromptEvent?: never;
|
|
4634
|
+
internalServerException?: never;
|
|
4635
|
+
throttlingException?: never;
|
|
4636
|
+
validationException?: never;
|
|
4637
|
+
dependencyFailedException?: never;
|
|
4638
|
+
accessDeniedException: AccessDeniedException;
|
|
4639
|
+
badGatewayException?: never;
|
|
4640
|
+
$unknown?: never;
|
|
4641
|
+
}
|
|
3490
4642
|
/**
|
|
3491
|
-
* <p>
|
|
4643
|
+
* <p>There was an issue with a dependency due to a server issue. Retry your request.</p>
|
|
3492
4644
|
* @public
|
|
3493
4645
|
*/
|
|
3494
|
-
interface
|
|
3495
|
-
|
|
4646
|
+
interface BadGatewayExceptionMember {
|
|
4647
|
+
optimizedPromptEvent?: never;
|
|
4648
|
+
analyzePromptEvent?: never;
|
|
4649
|
+
internalServerException?: never;
|
|
4650
|
+
throttlingException?: never;
|
|
4651
|
+
validationException?: never;
|
|
4652
|
+
dependencyFailedException?: never;
|
|
4653
|
+
accessDeniedException?: never;
|
|
4654
|
+
badGatewayException: BadGatewayException;
|
|
3496
4655
|
$unknown?: never;
|
|
3497
4656
|
}
|
|
3498
4657
|
/**
|
|
3499
4658
|
* @public
|
|
3500
4659
|
*/
|
|
3501
4660
|
interface $UnknownMember {
|
|
3502
|
-
|
|
4661
|
+
optimizedPromptEvent?: never;
|
|
4662
|
+
analyzePromptEvent?: never;
|
|
4663
|
+
internalServerException?: never;
|
|
4664
|
+
throttlingException?: never;
|
|
4665
|
+
validationException?: never;
|
|
4666
|
+
dependencyFailedException?: never;
|
|
4667
|
+
accessDeniedException?: never;
|
|
4668
|
+
badGatewayException?: never;
|
|
3503
4669
|
$unknown: [string, any];
|
|
3504
4670
|
}
|
|
3505
4671
|
interface Visitor<T> {
|
|
3506
|
-
|
|
4672
|
+
optimizedPromptEvent: (value: OptimizedPromptEvent) => T;
|
|
4673
|
+
analyzePromptEvent: (value: AnalyzePromptEvent) => T;
|
|
4674
|
+
internalServerException: (value: InternalServerException) => T;
|
|
4675
|
+
throttlingException: (value: ThrottlingException) => T;
|
|
4676
|
+
validationException: (value: ValidationException) => T;
|
|
4677
|
+
dependencyFailedException: (value: DependencyFailedException) => T;
|
|
4678
|
+
accessDeniedException: (value: AccessDeniedException) => T;
|
|
4679
|
+
badGatewayException: (value: BadGatewayException) => T;
|
|
3507
4680
|
_: (name: string, value: any) => T;
|
|
3508
4681
|
}
|
|
3509
|
-
const visit: <T>(value:
|
|
4682
|
+
const visit: <T>(value: OptimizedPromptStream, visitor: Visitor<T>) => T;
|
|
3510
4683
|
}
|
|
3511
4684
|
/**
|
|
3512
4685
|
* @public
|
|
3513
4686
|
*/
|
|
3514
|
-
export interface
|
|
3515
|
-
/**
|
|
3516
|
-
* <p>If the total number of results is greater than the maxItems value provided in the request, use this token
|
|
3517
|
-
* when making another request in the <code>nextToken</code> field to return the next batch of results.</p>
|
|
3518
|
-
* @public
|
|
3519
|
-
*/
|
|
3520
|
-
nextToken?: string | undefined;
|
|
4687
|
+
export interface OptimizePromptResponse {
|
|
3521
4688
|
/**
|
|
3522
|
-
* <p>
|
|
4689
|
+
* <p>The prompt after being optimized for the task.</p>
|
|
3523
4690
|
* @public
|
|
3524
4691
|
*/
|
|
3525
|
-
|
|
4692
|
+
optimizedPrompt: AsyncIterable<OptimizedPromptStream> | undefined;
|
|
3526
4693
|
}
|
|
3527
4694
|
/**
|
|
3528
4695
|
* <p>Contains the query made to the knowledge base.</p>
|
|
@@ -4411,6 +5578,35 @@ export interface KnowledgeBaseRetrievalConfiguration {
|
|
|
4411
5578
|
*/
|
|
4412
5579
|
vectorSearchConfiguration: KnowledgeBaseVectorSearchConfiguration | undefined;
|
|
4413
5580
|
}
|
|
5581
|
+
/**
|
|
5582
|
+
* <p>
|
|
5583
|
+
* Details of the knowledge base associated withe inline agent.
|
|
5584
|
+
* </p>
|
|
5585
|
+
* @public
|
|
5586
|
+
*/
|
|
5587
|
+
export interface KnowledgeBase {
|
|
5588
|
+
/**
|
|
5589
|
+
* <p>
|
|
5590
|
+
* The unique identifier for a knowledge base associated with the inline agent.
|
|
5591
|
+
* </p>
|
|
5592
|
+
* @public
|
|
5593
|
+
*/
|
|
5594
|
+
knowledgeBaseId: string | undefined;
|
|
5595
|
+
/**
|
|
5596
|
+
* <p>
|
|
5597
|
+
* The description of the knowledge base associated with the inline agent.
|
|
5598
|
+
* </p>
|
|
5599
|
+
* @public
|
|
5600
|
+
*/
|
|
5601
|
+
description: string | undefined;
|
|
5602
|
+
/**
|
|
5603
|
+
* <p>
|
|
5604
|
+
* The configurations to apply to the knowledge base during query. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html">Query configurations</a>.
|
|
5605
|
+
* </p>
|
|
5606
|
+
* @public
|
|
5607
|
+
*/
|
|
5608
|
+
retrievalConfiguration?: KnowledgeBaseRetrievalConfiguration | undefined;
|
|
5609
|
+
}
|
|
4414
5610
|
/**
|
|
4415
5611
|
* <p>Configurations to apply to a knowledge base attached to the agent during query. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-session-state.html#session-state-kb">Knowledge base retrieval configurations</a>.</p>
|
|
4416
5612
|
* @public
|
|
@@ -4523,6 +5719,111 @@ export interface RetrieveAndGenerateConfiguration {
|
|
|
4523
5719
|
*/
|
|
4524
5720
|
externalSourcesConfiguration?: ExternalSourcesRetrieveAndGenerateConfiguration | undefined;
|
|
4525
5721
|
}
|
|
5722
|
+
/**
|
|
5723
|
+
* @public
|
|
5724
|
+
*/
|
|
5725
|
+
export interface InvokeInlineAgentRequest {
|
|
5726
|
+
/**
|
|
5727
|
+
* <p>
|
|
5728
|
+
* The unique identifier of the session. Use the same value across requests to continue the same conversation.
|
|
5729
|
+
* </p>
|
|
5730
|
+
* @public
|
|
5731
|
+
*/
|
|
5732
|
+
sessionId: string | undefined;
|
|
5733
|
+
/**
|
|
5734
|
+
* <p>
|
|
5735
|
+
* The Amazon Resource Name (ARN) of the Amazon Web Services KMS key to use to encrypt your inline agent.
|
|
5736
|
+
* </p>
|
|
5737
|
+
* @public
|
|
5738
|
+
*/
|
|
5739
|
+
customerEncryptionKeyArn?: string | undefined;
|
|
5740
|
+
/**
|
|
5741
|
+
* <p>
|
|
5742
|
+
* Specifies whether to end the session with the inline agent or not.
|
|
5743
|
+
* </p>
|
|
5744
|
+
* @public
|
|
5745
|
+
*/
|
|
5746
|
+
endSession?: boolean | undefined;
|
|
5747
|
+
/**
|
|
5748
|
+
* <p>
|
|
5749
|
+
* Specifies whether to turn on the trace or not to track the agent's reasoning process. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/trace-events.html">Using trace</a>.
|
|
5750
|
+
*
|
|
5751
|
+
* </p>
|
|
5752
|
+
* @public
|
|
5753
|
+
*/
|
|
5754
|
+
enableTrace?: boolean | undefined;
|
|
5755
|
+
/**
|
|
5756
|
+
* <p>
|
|
5757
|
+
* The prompt text to send to the agent.
|
|
5758
|
+
* </p>
|
|
5759
|
+
* <note>
|
|
5760
|
+
* <p>If you include <code>returnControlInvocationResults</code> in the <code>sessionState</code> field, the <code>inputText</code> field will be ignored.</p>
|
|
5761
|
+
* </note>
|
|
5762
|
+
* @public
|
|
5763
|
+
*/
|
|
5764
|
+
inputText?: string | undefined;
|
|
5765
|
+
/**
|
|
5766
|
+
* <p>
|
|
5767
|
+
* Parameters that specify the various attributes of a sessions. You can include attributes for the session or prompt or, if you configured an
|
|
5768
|
+
* action group to return control, results from invocation of the action group. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-session-state.html">Control session context</a>.
|
|
5769
|
+
* </p>
|
|
5770
|
+
* <note>
|
|
5771
|
+
* <p>If you include <code>returnControlInvocationResults</code> in the <code>sessionState</code> field, the <code>inputText</code> field will be ignored.</p>
|
|
5772
|
+
* </note>
|
|
5773
|
+
* @public
|
|
5774
|
+
*/
|
|
5775
|
+
inlineSessionState?: InlineSessionState | undefined;
|
|
5776
|
+
/**
|
|
5777
|
+
* <p>
|
|
5778
|
+
* The <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/model-ids.html#model-ids-arns">model identifier (ID)</a> of the model to use for orchestration by the inline agent. For example, <code>meta.llama3-1-70b-instruct-v1:0</code>.
|
|
5779
|
+
* </p>
|
|
5780
|
+
* @public
|
|
5781
|
+
*/
|
|
5782
|
+
foundationModel: string | undefined;
|
|
5783
|
+
/**
|
|
5784
|
+
* <p>
|
|
5785
|
+
* The instructions that tell the inline agent what it should do and how it should interact with users.
|
|
5786
|
+
* </p>
|
|
5787
|
+
* @public
|
|
5788
|
+
*/
|
|
5789
|
+
instruction: string | undefined;
|
|
5790
|
+
/**
|
|
5791
|
+
* <p>
|
|
5792
|
+
* The number of seconds for which the inline agent should maintain session information. After this time expires, the subsequent <code>InvokeInlineAgent</code> request begins a new session.
|
|
5793
|
+
* </p>
|
|
5794
|
+
* <p>A user interaction remains active for the amount of time specified. If no conversation occurs during this time, the session expires and the data provided before the timeout is deleted.</p>
|
|
5795
|
+
* @public
|
|
5796
|
+
*/
|
|
5797
|
+
idleSessionTTLInSeconds?: number | undefined;
|
|
5798
|
+
/**
|
|
5799
|
+
* <p>
|
|
5800
|
+
* A list of action groups with each action group defining the action the inline agent needs to carry out.
|
|
5801
|
+
* </p>
|
|
5802
|
+
* @public
|
|
5803
|
+
*/
|
|
5804
|
+
actionGroups?: AgentActionGroup[] | undefined;
|
|
5805
|
+
/**
|
|
5806
|
+
* <p>
|
|
5807
|
+
* Contains information of the knowledge bases to associate with.
|
|
5808
|
+
* </p>
|
|
5809
|
+
* @public
|
|
5810
|
+
*/
|
|
5811
|
+
knowledgeBases?: KnowledgeBase[] | undefined;
|
|
5812
|
+
/**
|
|
5813
|
+
* <p>
|
|
5814
|
+
* The <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails.html">guardrails</a> to assign to the inline agent.
|
|
5815
|
+
* </p>
|
|
5816
|
+
* @public
|
|
5817
|
+
*/
|
|
5818
|
+
guardrailConfiguration?: GuardrailConfigurationWithArn | undefined;
|
|
5819
|
+
/**
|
|
5820
|
+
* <p>
|
|
5821
|
+
* Configurations for advanced prompts used to override the default prompts to enhance the accuracy of the inline agent.
|
|
5822
|
+
* </p>
|
|
5823
|
+
* @public
|
|
5824
|
+
*/
|
|
5825
|
+
promptOverrideConfiguration?: PromptOverrideConfiguration | undefined;
|
|
5826
|
+
}
|
|
4526
5827
|
/**
|
|
4527
5828
|
* @public
|
|
4528
5829
|
*/
|
|
@@ -4646,6 +5947,22 @@ export declare const ActionGroupInvocationInputFilterSensitiveLog: (obj: ActionG
|
|
|
4646
5947
|
* @internal
|
|
4647
5948
|
*/
|
|
4648
5949
|
export declare const ActionGroupInvocationOutputFilterSensitiveLog: (obj: ActionGroupInvocationOutput) => any;
|
|
5950
|
+
/**
|
|
5951
|
+
* @internal
|
|
5952
|
+
*/
|
|
5953
|
+
export declare const APISchemaFilterSensitiveLog: (obj: APISchema) => any;
|
|
5954
|
+
/**
|
|
5955
|
+
* @internal
|
|
5956
|
+
*/
|
|
5957
|
+
export declare const FunctionDefinitionFilterSensitiveLog: (obj: FunctionDefinition) => any;
|
|
5958
|
+
/**
|
|
5959
|
+
* @internal
|
|
5960
|
+
*/
|
|
5961
|
+
export declare const FunctionSchemaFilterSensitiveLog: (obj: FunctionSchema) => any;
|
|
5962
|
+
/**
|
|
5963
|
+
* @internal
|
|
5964
|
+
*/
|
|
5965
|
+
export declare const AgentActionGroupFilterSensitiveLog: (obj: AgentActionGroup) => any;
|
|
4649
5966
|
/**
|
|
4650
5967
|
* @internal
|
|
4651
5968
|
*/
|
|
@@ -4926,6 +6243,74 @@ export declare const ResponseStreamFilterSensitiveLog: (obj: ResponseStream) =>
|
|
|
4926
6243
|
* @internal
|
|
4927
6244
|
*/
|
|
4928
6245
|
export declare const InvokeAgentResponseFilterSensitiveLog: (obj: InvokeAgentResponse) => any;
|
|
6246
|
+
/**
|
|
6247
|
+
* @internal
|
|
6248
|
+
*/
|
|
6249
|
+
export declare const InlineSessionStateFilterSensitiveLog: (obj: InlineSessionState) => any;
|
|
6250
|
+
/**
|
|
6251
|
+
* @internal
|
|
6252
|
+
*/
|
|
6253
|
+
export declare const PromptConfigurationFilterSensitiveLog: (obj: PromptConfiguration) => any;
|
|
6254
|
+
/**
|
|
6255
|
+
* @internal
|
|
6256
|
+
*/
|
|
6257
|
+
export declare const PromptOverrideConfigurationFilterSensitiveLog: (obj: PromptOverrideConfiguration) => any;
|
|
6258
|
+
/**
|
|
6259
|
+
* @internal
|
|
6260
|
+
*/
|
|
6261
|
+
export declare const InlineAgentPayloadPartFilterSensitiveLog: (obj: InlineAgentPayloadPart) => any;
|
|
6262
|
+
/**
|
|
6263
|
+
* @internal
|
|
6264
|
+
*/
|
|
6265
|
+
export declare const InlineAgentFilePartFilterSensitiveLog: (obj: InlineAgentFilePart) => any;
|
|
6266
|
+
/**
|
|
6267
|
+
* @internal
|
|
6268
|
+
*/
|
|
6269
|
+
export declare const InlineAgentReturnControlPayloadFilterSensitiveLog: (obj: InlineAgentReturnControlPayload) => any;
|
|
6270
|
+
/**
|
|
6271
|
+
* @internal
|
|
6272
|
+
*/
|
|
6273
|
+
export declare const InlineAgentTracePartFilterSensitiveLog: (obj: InlineAgentTracePart) => any;
|
|
6274
|
+
/**
|
|
6275
|
+
* @internal
|
|
6276
|
+
*/
|
|
6277
|
+
export declare const InlineAgentResponseStreamFilterSensitiveLog: (obj: InlineAgentResponseStream) => any;
|
|
6278
|
+
/**
|
|
6279
|
+
* @internal
|
|
6280
|
+
*/
|
|
6281
|
+
export declare const InvokeInlineAgentResponseFilterSensitiveLog: (obj: InvokeInlineAgentResponse) => any;
|
|
6282
|
+
/**
|
|
6283
|
+
* @internal
|
|
6284
|
+
*/
|
|
6285
|
+
export declare const TextPromptFilterSensitiveLog: (obj: TextPrompt) => any;
|
|
6286
|
+
/**
|
|
6287
|
+
* @internal
|
|
6288
|
+
*/
|
|
6289
|
+
export declare const InputPromptFilterSensitiveLog: (obj: InputPrompt) => any;
|
|
6290
|
+
/**
|
|
6291
|
+
* @internal
|
|
6292
|
+
*/
|
|
6293
|
+
export declare const OptimizePromptRequestFilterSensitiveLog: (obj: OptimizePromptRequest) => any;
|
|
6294
|
+
/**
|
|
6295
|
+
* @internal
|
|
6296
|
+
*/
|
|
6297
|
+
export declare const AnalyzePromptEventFilterSensitiveLog: (obj: AnalyzePromptEvent) => any;
|
|
6298
|
+
/**
|
|
6299
|
+
* @internal
|
|
6300
|
+
*/
|
|
6301
|
+
export declare const OptimizedPromptFilterSensitiveLog: (obj: OptimizedPrompt) => any;
|
|
6302
|
+
/**
|
|
6303
|
+
* @internal
|
|
6304
|
+
*/
|
|
6305
|
+
export declare const OptimizedPromptEventFilterSensitiveLog: (obj: OptimizedPromptEvent) => any;
|
|
6306
|
+
/**
|
|
6307
|
+
* @internal
|
|
6308
|
+
*/
|
|
6309
|
+
export declare const OptimizedPromptStreamFilterSensitiveLog: (obj: OptimizedPromptStream) => any;
|
|
6310
|
+
/**
|
|
6311
|
+
* @internal
|
|
6312
|
+
*/
|
|
6313
|
+
export declare const OptimizePromptResponseFilterSensitiveLog: (obj: OptimizePromptResponse) => any;
|
|
4929
6314
|
/**
|
|
4930
6315
|
* @internal
|
|
4931
6316
|
*/
|
|
@@ -4990,6 +6375,10 @@ export declare const KnowledgeBaseVectorSearchConfigurationFilterSensitiveLog: (
|
|
|
4990
6375
|
* @internal
|
|
4991
6376
|
*/
|
|
4992
6377
|
export declare const KnowledgeBaseRetrievalConfigurationFilterSensitiveLog: (obj: KnowledgeBaseRetrievalConfiguration) => any;
|
|
6378
|
+
/**
|
|
6379
|
+
* @internal
|
|
6380
|
+
*/
|
|
6381
|
+
export declare const KnowledgeBaseFilterSensitiveLog: (obj: KnowledgeBase) => any;
|
|
4993
6382
|
/**
|
|
4994
6383
|
* @internal
|
|
4995
6384
|
*/
|
|
@@ -5006,6 +6395,10 @@ export declare const RetrieveRequestFilterSensitiveLog: (obj: RetrieveRequest) =
|
|
|
5006
6395
|
* @internal
|
|
5007
6396
|
*/
|
|
5008
6397
|
export declare const RetrieveAndGenerateConfigurationFilterSensitiveLog: (obj: RetrieveAndGenerateConfiguration) => any;
|
|
6398
|
+
/**
|
|
6399
|
+
* @internal
|
|
6400
|
+
*/
|
|
6401
|
+
export declare const InvokeInlineAgentRequestFilterSensitiveLog: (obj: InvokeInlineAgentRequest) => any;
|
|
5009
6402
|
/**
|
|
5010
6403
|
* @internal
|
|
5011
6404
|
*/
|