@aws-sdk/client-bedrock-agent-runtime 3.697.0 → 3.701.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 +8 -0
- package/dist-cjs/index.js +505 -2
- package/dist-es/BedrockAgentRuntime.js +2 -0
- package/dist-es/commands/InvokeInlineAgentCommand.js +27 -0
- package/dist-es/commands/index.js +1 -0
- package/dist-es/models/models_0.js +208 -0
- package/dist-es/protocols/Aws_restJson1.js +210 -0
- package/dist-types/BedrockAgentRuntime.d.ts +7 -0
- package/dist-types/BedrockAgentRuntimeClient.d.ts +3 -2
- package/dist-types/commands/InvokeAgentCommand.d.ts +16 -6
- package/dist-types/commands/InvokeInlineAgentCommand.d.ts +761 -0
- package/dist-types/commands/index.d.ts +1 -0
- package/dist-types/models/models_0.d.ts +1227 -44
- package/dist-types/protocols/Aws_restJson1.d.ts +9 -0
- package/dist-types/ts3.4/BedrockAgentRuntime.d.ts +17 -0
- package/dist-types/ts3.4/BedrockAgentRuntimeClient.d.ts +6 -0
- package/dist-types/ts3.4/commands/InvokeInlineAgentCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/index.d.ts +1 -0
- package/dist-types/ts3.4/models/models_0.d.ts +527 -2
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +12 -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
|
|
@@ -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
|
|
@@ -1221,6 +1547,28 @@ export declare namespace InvocationResultMember {
|
|
|
1221
1547
|
}
|
|
1222
1548
|
const visit: <T>(value: InvocationResultMember, visitor: Visitor<T>) => T;
|
|
1223
1549
|
}
|
|
1550
|
+
/**
|
|
1551
|
+
* <p>
|
|
1552
|
+
* Configurations for streaming.
|
|
1553
|
+
* </p>
|
|
1554
|
+
* @public
|
|
1555
|
+
*/
|
|
1556
|
+
export interface StreamingConfigurations {
|
|
1557
|
+
/**
|
|
1558
|
+
* <p>
|
|
1559
|
+
* Specifies whether to enable streaming for the final response. This is set to <code>false</code> by default.
|
|
1560
|
+
* </p>
|
|
1561
|
+
* @public
|
|
1562
|
+
*/
|
|
1563
|
+
streamFinalResponse?: boolean | undefined;
|
|
1564
|
+
/**
|
|
1565
|
+
* <p>
|
|
1566
|
+
* The guardrail interval to apply as response is generated.
|
|
1567
|
+
* </p>
|
|
1568
|
+
* @public
|
|
1569
|
+
*/
|
|
1570
|
+
applyGuardrailInterval?: number | undefined;
|
|
1571
|
+
}
|
|
1224
1572
|
/**
|
|
1225
1573
|
* <p>Contains information about where the text with a citation begins and ends in the generated output.</p>
|
|
1226
1574
|
* <p>This data type is used in the following API operations:</p>
|
|
@@ -1813,6 +2161,43 @@ export interface ReturnControlPayload {
|
|
|
1813
2161
|
*/
|
|
1814
2162
|
invocationId?: string | undefined;
|
|
1815
2163
|
}
|
|
2164
|
+
/**
|
|
2165
|
+
* <p>
|
|
2166
|
+
* The event in the custom orchestration sequence.
|
|
2167
|
+
* </p>
|
|
2168
|
+
* @public
|
|
2169
|
+
*/
|
|
2170
|
+
export interface CustomOrchestrationTraceEvent {
|
|
2171
|
+
/**
|
|
2172
|
+
* <p>
|
|
2173
|
+
* The text that prompted the event at this step.
|
|
2174
|
+
* </p>
|
|
2175
|
+
* @public
|
|
2176
|
+
*/
|
|
2177
|
+
text?: string | undefined;
|
|
2178
|
+
}
|
|
2179
|
+
/**
|
|
2180
|
+
* <p>
|
|
2181
|
+
* The trace behavior for the custom orchestration.
|
|
2182
|
+
* </p>
|
|
2183
|
+
* @public
|
|
2184
|
+
*/
|
|
2185
|
+
export interface CustomOrchestrationTrace {
|
|
2186
|
+
/**
|
|
2187
|
+
* <p>
|
|
2188
|
+
* The unique identifier of the trace.
|
|
2189
|
+
* </p>
|
|
2190
|
+
* @public
|
|
2191
|
+
*/
|
|
2192
|
+
traceId?: string | undefined;
|
|
2193
|
+
/**
|
|
2194
|
+
* <p>
|
|
2195
|
+
* The trace event details used with the custom orchestration.
|
|
2196
|
+
* </p>
|
|
2197
|
+
* @public
|
|
2198
|
+
*/
|
|
2199
|
+
event?: CustomOrchestrationTraceEvent | undefined;
|
|
2200
|
+
}
|
|
1816
2201
|
/**
|
|
1817
2202
|
* <p>Contains information about the failure of the interaction.</p>
|
|
1818
2203
|
* @public
|
|
@@ -2340,6 +2725,7 @@ export declare const PromptType: {
|
|
|
2340
2725
|
readonly ORCHESTRATION: "ORCHESTRATION";
|
|
2341
2726
|
readonly POST_PROCESSING: "POST_PROCESSING";
|
|
2342
2727
|
readonly PRE_PROCESSING: "PRE_PROCESSING";
|
|
2728
|
+
readonly ROUTING_CLASSIFIER: "ROUTING_CLASSIFIER";
|
|
2343
2729
|
};
|
|
2344
2730
|
/**
|
|
2345
2731
|
* @public
|
|
@@ -2925,7 +3311,7 @@ export declare namespace PreProcessingTrace {
|
|
|
2925
3311
|
* <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>
|
|
2926
3312
|
* @public
|
|
2927
3313
|
*/
|
|
2928
|
-
export type Trace = Trace.FailureTraceMember | Trace.GuardrailTraceMember | Trace.OrchestrationTraceMember | Trace.PostProcessingTraceMember | Trace.PreProcessingTraceMember | Trace.$UnknownMember;
|
|
3314
|
+
export type Trace = Trace.CustomOrchestrationTraceMember | Trace.FailureTraceMember | Trace.GuardrailTraceMember | Trace.OrchestrationTraceMember | Trace.PostProcessingTraceMember | Trace.PreProcessingTraceMember | Trace.$UnknownMember;
|
|
2929
3315
|
/**
|
|
2930
3316
|
* @public
|
|
2931
3317
|
*/
|
|
@@ -2940,6 +3326,7 @@ export declare namespace Trace {
|
|
|
2940
3326
|
orchestrationTrace?: never;
|
|
2941
3327
|
postProcessingTrace?: never;
|
|
2942
3328
|
failureTrace?: never;
|
|
3329
|
+
customOrchestrationTrace?: never;
|
|
2943
3330
|
$unknown?: never;
|
|
2944
3331
|
}
|
|
2945
3332
|
/**
|
|
@@ -2952,6 +3339,7 @@ export declare namespace Trace {
|
|
|
2952
3339
|
orchestrationTrace?: never;
|
|
2953
3340
|
postProcessingTrace?: never;
|
|
2954
3341
|
failureTrace?: never;
|
|
3342
|
+
customOrchestrationTrace?: never;
|
|
2955
3343
|
$unknown?: never;
|
|
2956
3344
|
}
|
|
2957
3345
|
/**
|
|
@@ -2964,6 +3352,7 @@ export declare namespace Trace {
|
|
|
2964
3352
|
orchestrationTrace: OrchestrationTrace;
|
|
2965
3353
|
postProcessingTrace?: never;
|
|
2966
3354
|
failureTrace?: never;
|
|
3355
|
+
customOrchestrationTrace?: never;
|
|
2967
3356
|
$unknown?: never;
|
|
2968
3357
|
}
|
|
2969
3358
|
/**
|
|
@@ -2976,6 +3365,7 @@ export declare namespace Trace {
|
|
|
2976
3365
|
orchestrationTrace?: never;
|
|
2977
3366
|
postProcessingTrace: PostProcessingTrace;
|
|
2978
3367
|
failureTrace?: never;
|
|
3368
|
+
customOrchestrationTrace?: never;
|
|
2979
3369
|
$unknown?: never;
|
|
2980
3370
|
}
|
|
2981
3371
|
/**
|
|
@@ -2988,56 +3378,635 @@ export declare namespace Trace {
|
|
|
2988
3378
|
orchestrationTrace?: never;
|
|
2989
3379
|
postProcessingTrace?: never;
|
|
2990
3380
|
failureTrace: FailureTrace;
|
|
3381
|
+
customOrchestrationTrace?: never;
|
|
2991
3382
|
$unknown?: never;
|
|
2992
3383
|
}
|
|
2993
3384
|
/**
|
|
3385
|
+
* <p>
|
|
3386
|
+
* Details about the custom orchestration step in which the agent determines the order in which actions are executed.
|
|
3387
|
+
* </p>
|
|
2994
3388
|
* @public
|
|
2995
3389
|
*/
|
|
2996
|
-
interface
|
|
3390
|
+
interface CustomOrchestrationTraceMember {
|
|
2997
3391
|
guardrailTrace?: never;
|
|
2998
3392
|
preProcessingTrace?: never;
|
|
2999
3393
|
orchestrationTrace?: never;
|
|
3000
3394
|
postProcessingTrace?: never;
|
|
3001
3395
|
failureTrace?: never;
|
|
3002
|
-
|
|
3396
|
+
customOrchestrationTrace: CustomOrchestrationTrace;
|
|
3397
|
+
$unknown?: never;
|
|
3003
3398
|
}
|
|
3004
|
-
|
|
3005
|
-
|
|
3006
|
-
|
|
3007
|
-
|
|
3399
|
+
/**
|
|
3400
|
+
* @public
|
|
3401
|
+
*/
|
|
3402
|
+
interface $UnknownMember {
|
|
3403
|
+
guardrailTrace?: never;
|
|
3404
|
+
preProcessingTrace?: never;
|
|
3405
|
+
orchestrationTrace?: never;
|
|
3406
|
+
postProcessingTrace?: never;
|
|
3407
|
+
failureTrace?: never;
|
|
3408
|
+
customOrchestrationTrace?: never;
|
|
3409
|
+
$unknown: [string, any];
|
|
3410
|
+
}
|
|
3411
|
+
interface Visitor<T> {
|
|
3412
|
+
guardrailTrace: (value: GuardrailTrace) => T;
|
|
3413
|
+
preProcessingTrace: (value: PreProcessingTrace) => T;
|
|
3414
|
+
orchestrationTrace: (value: OrchestrationTrace) => T;
|
|
3008
3415
|
postProcessingTrace: (value: PostProcessingTrace) => T;
|
|
3009
3416
|
failureTrace: (value: FailureTrace) => T;
|
|
3417
|
+
customOrchestrationTrace: (value: CustomOrchestrationTrace) => T;
|
|
3010
3418
|
_: (name: string, value: any) => T;
|
|
3011
3419
|
}
|
|
3012
3420
|
const visit: <T>(value: Trace, visitor: Visitor<T>) => T;
|
|
3013
3421
|
}
|
|
3014
3422
|
/**
|
|
3015
|
-
* <p>Contains information about the agent and session, alongside the agent's reasoning process and results from calling API actions and querying 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. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-test.html#trace-enablement">Trace enablement</a>.</p>
|
|
3423
|
+
* <p>Contains information about the agent and session, alongside the agent's reasoning process and results from calling API actions and querying 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. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-test.html#trace-enablement">Trace enablement</a>.</p>
|
|
3424
|
+
* @public
|
|
3425
|
+
*/
|
|
3426
|
+
export interface TracePart {
|
|
3427
|
+
/**
|
|
3428
|
+
* <p>The unique identifier of the session with the agent.</p>
|
|
3429
|
+
* @public
|
|
3430
|
+
*/
|
|
3431
|
+
sessionId?: string | undefined;
|
|
3432
|
+
/**
|
|
3433
|
+
* <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>
|
|
3434
|
+
* @public
|
|
3435
|
+
*/
|
|
3436
|
+
trace?: Trace | undefined;
|
|
3437
|
+
/**
|
|
3438
|
+
* <p>The unique identifier of the agent.</p>
|
|
3439
|
+
* @public
|
|
3440
|
+
*/
|
|
3441
|
+
agentId?: string | undefined;
|
|
3442
|
+
/**
|
|
3443
|
+
* <p>The unique identifier of the alias of the agent.</p>
|
|
3444
|
+
* @public
|
|
3445
|
+
*/
|
|
3446
|
+
agentAliasId?: string | undefined;
|
|
3447
|
+
/**
|
|
3448
|
+
* <p>The version of the agent.</p>
|
|
3449
|
+
* @public
|
|
3450
|
+
*/
|
|
3451
|
+
agentVersion?: string | undefined;
|
|
3452
|
+
}
|
|
3453
|
+
/**
|
|
3454
|
+
* <p>The response from invoking the agent and associated citations and trace information.</p>
|
|
3455
|
+
* @public
|
|
3456
|
+
*/
|
|
3457
|
+
export type ResponseStream = ResponseStream.AccessDeniedExceptionMember | ResponseStream.BadGatewayExceptionMember | ResponseStream.ChunkMember | ResponseStream.ConflictExceptionMember | ResponseStream.DependencyFailedExceptionMember | ResponseStream.FilesMember | ResponseStream.InternalServerExceptionMember | ResponseStream.ResourceNotFoundExceptionMember | ResponseStream.ReturnControlMember | ResponseStream.ServiceQuotaExceededExceptionMember | ResponseStream.ThrottlingExceptionMember | ResponseStream.TraceMember | ResponseStream.ValidationExceptionMember | ResponseStream.$UnknownMember;
|
|
3458
|
+
/**
|
|
3459
|
+
* @public
|
|
3460
|
+
*/
|
|
3461
|
+
export declare namespace ResponseStream {
|
|
3462
|
+
/**
|
|
3463
|
+
* <p>Contains a part of an agent response and citations for it.</p>
|
|
3464
|
+
* @public
|
|
3465
|
+
*/
|
|
3466
|
+
interface ChunkMember {
|
|
3467
|
+
chunk: PayloadPart;
|
|
3468
|
+
trace?: never;
|
|
3469
|
+
returnControl?: never;
|
|
3470
|
+
internalServerException?: never;
|
|
3471
|
+
validationException?: never;
|
|
3472
|
+
resourceNotFoundException?: never;
|
|
3473
|
+
serviceQuotaExceededException?: never;
|
|
3474
|
+
throttlingException?: never;
|
|
3475
|
+
accessDeniedException?: never;
|
|
3476
|
+
conflictException?: never;
|
|
3477
|
+
dependencyFailedException?: never;
|
|
3478
|
+
badGatewayException?: never;
|
|
3479
|
+
files?: never;
|
|
3480
|
+
$unknown?: never;
|
|
3481
|
+
}
|
|
3482
|
+
/**
|
|
3483
|
+
* <p>Contains information about the agent and session, alongside the agent's reasoning process and results from calling actions and querying 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. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/trace-events.html">Trace events</a>.</p>
|
|
3484
|
+
* @public
|
|
3485
|
+
*/
|
|
3486
|
+
interface TraceMember {
|
|
3487
|
+
chunk?: never;
|
|
3488
|
+
trace: TracePart;
|
|
3489
|
+
returnControl?: never;
|
|
3490
|
+
internalServerException?: never;
|
|
3491
|
+
validationException?: never;
|
|
3492
|
+
resourceNotFoundException?: never;
|
|
3493
|
+
serviceQuotaExceededException?: never;
|
|
3494
|
+
throttlingException?: never;
|
|
3495
|
+
accessDeniedException?: never;
|
|
3496
|
+
conflictException?: never;
|
|
3497
|
+
dependencyFailedException?: never;
|
|
3498
|
+
badGatewayException?: never;
|
|
3499
|
+
files?: never;
|
|
3500
|
+
$unknown?: never;
|
|
3501
|
+
}
|
|
3502
|
+
/**
|
|
3503
|
+
* <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 and can be used in your own setup for fulfilling the action.</p>
|
|
3504
|
+
* @public
|
|
3505
|
+
*/
|
|
3506
|
+
interface ReturnControlMember {
|
|
3507
|
+
chunk?: never;
|
|
3508
|
+
trace?: never;
|
|
3509
|
+
returnControl: ReturnControlPayload;
|
|
3510
|
+
internalServerException?: never;
|
|
3511
|
+
validationException?: never;
|
|
3512
|
+
resourceNotFoundException?: never;
|
|
3513
|
+
serviceQuotaExceededException?: never;
|
|
3514
|
+
throttlingException?: never;
|
|
3515
|
+
accessDeniedException?: never;
|
|
3516
|
+
conflictException?: never;
|
|
3517
|
+
dependencyFailedException?: never;
|
|
3518
|
+
badGatewayException?: never;
|
|
3519
|
+
files?: never;
|
|
3520
|
+
$unknown?: never;
|
|
3521
|
+
}
|
|
3522
|
+
/**
|
|
3523
|
+
* <p>An internal server error occurred. Retry your request.</p>
|
|
3524
|
+
* @public
|
|
3525
|
+
*/
|
|
3526
|
+
interface InternalServerExceptionMember {
|
|
3527
|
+
chunk?: never;
|
|
3528
|
+
trace?: never;
|
|
3529
|
+
returnControl?: never;
|
|
3530
|
+
internalServerException: InternalServerException;
|
|
3531
|
+
validationException?: never;
|
|
3532
|
+
resourceNotFoundException?: never;
|
|
3533
|
+
serviceQuotaExceededException?: never;
|
|
3534
|
+
throttlingException?: never;
|
|
3535
|
+
accessDeniedException?: never;
|
|
3536
|
+
conflictException?: never;
|
|
3537
|
+
dependencyFailedException?: never;
|
|
3538
|
+
badGatewayException?: never;
|
|
3539
|
+
files?: never;
|
|
3540
|
+
$unknown?: never;
|
|
3541
|
+
}
|
|
3542
|
+
/**
|
|
3543
|
+
* <p>Input validation failed. Check your request parameters and retry the request.</p>
|
|
3544
|
+
* @public
|
|
3545
|
+
*/
|
|
3546
|
+
interface ValidationExceptionMember {
|
|
3547
|
+
chunk?: never;
|
|
3548
|
+
trace?: never;
|
|
3549
|
+
returnControl?: never;
|
|
3550
|
+
internalServerException?: never;
|
|
3551
|
+
validationException: ValidationException;
|
|
3552
|
+
resourceNotFoundException?: never;
|
|
3553
|
+
serviceQuotaExceededException?: never;
|
|
3554
|
+
throttlingException?: never;
|
|
3555
|
+
accessDeniedException?: never;
|
|
3556
|
+
conflictException?: never;
|
|
3557
|
+
dependencyFailedException?: never;
|
|
3558
|
+
badGatewayException?: never;
|
|
3559
|
+
files?: never;
|
|
3560
|
+
$unknown?: never;
|
|
3561
|
+
}
|
|
3562
|
+
/**
|
|
3563
|
+
* <p>The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.</p>
|
|
3564
|
+
* @public
|
|
3565
|
+
*/
|
|
3566
|
+
interface ResourceNotFoundExceptionMember {
|
|
3567
|
+
chunk?: never;
|
|
3568
|
+
trace?: never;
|
|
3569
|
+
returnControl?: never;
|
|
3570
|
+
internalServerException?: never;
|
|
3571
|
+
validationException?: never;
|
|
3572
|
+
resourceNotFoundException: ResourceNotFoundException;
|
|
3573
|
+
serviceQuotaExceededException?: never;
|
|
3574
|
+
throttlingException?: never;
|
|
3575
|
+
accessDeniedException?: never;
|
|
3576
|
+
conflictException?: never;
|
|
3577
|
+
dependencyFailedException?: never;
|
|
3578
|
+
badGatewayException?: never;
|
|
3579
|
+
files?: never;
|
|
3580
|
+
$unknown?: never;
|
|
3581
|
+
}
|
|
3582
|
+
/**
|
|
3583
|
+
* <p>The number of requests exceeds the service quota. Resubmit your request later.</p>
|
|
3584
|
+
* @public
|
|
3585
|
+
*/
|
|
3586
|
+
interface ServiceQuotaExceededExceptionMember {
|
|
3587
|
+
chunk?: never;
|
|
3588
|
+
trace?: never;
|
|
3589
|
+
returnControl?: never;
|
|
3590
|
+
internalServerException?: never;
|
|
3591
|
+
validationException?: never;
|
|
3592
|
+
resourceNotFoundException?: never;
|
|
3593
|
+
serviceQuotaExceededException: ServiceQuotaExceededException;
|
|
3594
|
+
throttlingException?: never;
|
|
3595
|
+
accessDeniedException?: never;
|
|
3596
|
+
conflictException?: never;
|
|
3597
|
+
dependencyFailedException?: never;
|
|
3598
|
+
badGatewayException?: never;
|
|
3599
|
+
files?: never;
|
|
3600
|
+
$unknown?: never;
|
|
3601
|
+
}
|
|
3602
|
+
/**
|
|
3603
|
+
* <p>The number of requests exceeds the limit. Resubmit your request later.</p>
|
|
3604
|
+
* @public
|
|
3605
|
+
*/
|
|
3606
|
+
interface ThrottlingExceptionMember {
|
|
3607
|
+
chunk?: never;
|
|
3608
|
+
trace?: never;
|
|
3609
|
+
returnControl?: never;
|
|
3610
|
+
internalServerException?: never;
|
|
3611
|
+
validationException?: never;
|
|
3612
|
+
resourceNotFoundException?: never;
|
|
3613
|
+
serviceQuotaExceededException?: never;
|
|
3614
|
+
throttlingException: ThrottlingException;
|
|
3615
|
+
accessDeniedException?: never;
|
|
3616
|
+
conflictException?: never;
|
|
3617
|
+
dependencyFailedException?: never;
|
|
3618
|
+
badGatewayException?: never;
|
|
3619
|
+
files?: never;
|
|
3620
|
+
$unknown?: never;
|
|
3621
|
+
}
|
|
3622
|
+
/**
|
|
3623
|
+
* <p>The request is denied because of missing access permissions. Check your permissions and retry your request.</p>
|
|
3624
|
+
* @public
|
|
3625
|
+
*/
|
|
3626
|
+
interface AccessDeniedExceptionMember {
|
|
3627
|
+
chunk?: never;
|
|
3628
|
+
trace?: never;
|
|
3629
|
+
returnControl?: never;
|
|
3630
|
+
internalServerException?: never;
|
|
3631
|
+
validationException?: never;
|
|
3632
|
+
resourceNotFoundException?: never;
|
|
3633
|
+
serviceQuotaExceededException?: never;
|
|
3634
|
+
throttlingException?: never;
|
|
3635
|
+
accessDeniedException: AccessDeniedException;
|
|
3636
|
+
conflictException?: never;
|
|
3637
|
+
dependencyFailedException?: never;
|
|
3638
|
+
badGatewayException?: never;
|
|
3639
|
+
files?: never;
|
|
3640
|
+
$unknown?: never;
|
|
3641
|
+
}
|
|
3642
|
+
/**
|
|
3643
|
+
* <p>There was a conflict performing an operation. Resolve the conflict and retry your request.</p>
|
|
3644
|
+
* @public
|
|
3645
|
+
*/
|
|
3646
|
+
interface ConflictExceptionMember {
|
|
3647
|
+
chunk?: never;
|
|
3648
|
+
trace?: never;
|
|
3649
|
+
returnControl?: never;
|
|
3650
|
+
internalServerException?: never;
|
|
3651
|
+
validationException?: never;
|
|
3652
|
+
resourceNotFoundException?: never;
|
|
3653
|
+
serviceQuotaExceededException?: never;
|
|
3654
|
+
throttlingException?: never;
|
|
3655
|
+
accessDeniedException?: never;
|
|
3656
|
+
conflictException: ConflictException;
|
|
3657
|
+
dependencyFailedException?: never;
|
|
3658
|
+
badGatewayException?: never;
|
|
3659
|
+
files?: never;
|
|
3660
|
+
$unknown?: never;
|
|
3661
|
+
}
|
|
3662
|
+
/**
|
|
3663
|
+
* <p>There was an issue with a dependency. Check the resource configurations and retry the request.</p>
|
|
3664
|
+
* @public
|
|
3665
|
+
*/
|
|
3666
|
+
interface DependencyFailedExceptionMember {
|
|
3667
|
+
chunk?: never;
|
|
3668
|
+
trace?: never;
|
|
3669
|
+
returnControl?: never;
|
|
3670
|
+
internalServerException?: never;
|
|
3671
|
+
validationException?: never;
|
|
3672
|
+
resourceNotFoundException?: never;
|
|
3673
|
+
serviceQuotaExceededException?: never;
|
|
3674
|
+
throttlingException?: never;
|
|
3675
|
+
accessDeniedException?: never;
|
|
3676
|
+
conflictException?: never;
|
|
3677
|
+
dependencyFailedException: DependencyFailedException;
|
|
3678
|
+
badGatewayException?: never;
|
|
3679
|
+
files?: never;
|
|
3680
|
+
$unknown?: never;
|
|
3681
|
+
}
|
|
3682
|
+
/**
|
|
3683
|
+
* <p>There was an issue with a dependency due to a server issue. Retry your request.</p>
|
|
3684
|
+
* @public
|
|
3685
|
+
*/
|
|
3686
|
+
interface BadGatewayExceptionMember {
|
|
3687
|
+
chunk?: never;
|
|
3688
|
+
trace?: never;
|
|
3689
|
+
returnControl?: never;
|
|
3690
|
+
internalServerException?: never;
|
|
3691
|
+
validationException?: never;
|
|
3692
|
+
resourceNotFoundException?: never;
|
|
3693
|
+
serviceQuotaExceededException?: never;
|
|
3694
|
+
throttlingException?: never;
|
|
3695
|
+
accessDeniedException?: never;
|
|
3696
|
+
conflictException?: never;
|
|
3697
|
+
dependencyFailedException?: never;
|
|
3698
|
+
badGatewayException: BadGatewayException;
|
|
3699
|
+
files?: never;
|
|
3700
|
+
$unknown?: never;
|
|
3701
|
+
}
|
|
3702
|
+
/**
|
|
3703
|
+
* <p>Contains intermediate response for code interpreter if any files have been generated.</p>
|
|
3704
|
+
* @public
|
|
3705
|
+
*/
|
|
3706
|
+
interface FilesMember {
|
|
3707
|
+
chunk?: never;
|
|
3708
|
+
trace?: never;
|
|
3709
|
+
returnControl?: never;
|
|
3710
|
+
internalServerException?: never;
|
|
3711
|
+
validationException?: never;
|
|
3712
|
+
resourceNotFoundException?: never;
|
|
3713
|
+
serviceQuotaExceededException?: never;
|
|
3714
|
+
throttlingException?: never;
|
|
3715
|
+
accessDeniedException?: never;
|
|
3716
|
+
conflictException?: never;
|
|
3717
|
+
dependencyFailedException?: never;
|
|
3718
|
+
badGatewayException?: never;
|
|
3719
|
+
files: FilePart;
|
|
3720
|
+
$unknown?: never;
|
|
3721
|
+
}
|
|
3722
|
+
/**
|
|
3723
|
+
* @public
|
|
3724
|
+
*/
|
|
3725
|
+
interface $UnknownMember {
|
|
3726
|
+
chunk?: never;
|
|
3727
|
+
trace?: never;
|
|
3728
|
+
returnControl?: never;
|
|
3729
|
+
internalServerException?: never;
|
|
3730
|
+
validationException?: never;
|
|
3731
|
+
resourceNotFoundException?: never;
|
|
3732
|
+
serviceQuotaExceededException?: never;
|
|
3733
|
+
throttlingException?: never;
|
|
3734
|
+
accessDeniedException?: never;
|
|
3735
|
+
conflictException?: never;
|
|
3736
|
+
dependencyFailedException?: never;
|
|
3737
|
+
badGatewayException?: never;
|
|
3738
|
+
files?: never;
|
|
3739
|
+
$unknown: [string, any];
|
|
3740
|
+
}
|
|
3741
|
+
interface Visitor<T> {
|
|
3742
|
+
chunk: (value: PayloadPart) => T;
|
|
3743
|
+
trace: (value: TracePart) => T;
|
|
3744
|
+
returnControl: (value: ReturnControlPayload) => T;
|
|
3745
|
+
internalServerException: (value: InternalServerException) => T;
|
|
3746
|
+
validationException: (value: ValidationException) => T;
|
|
3747
|
+
resourceNotFoundException: (value: ResourceNotFoundException) => T;
|
|
3748
|
+
serviceQuotaExceededException: (value: ServiceQuotaExceededException) => T;
|
|
3749
|
+
throttlingException: (value: ThrottlingException) => T;
|
|
3750
|
+
accessDeniedException: (value: AccessDeniedException) => T;
|
|
3751
|
+
conflictException: (value: ConflictException) => T;
|
|
3752
|
+
dependencyFailedException: (value: DependencyFailedException) => T;
|
|
3753
|
+
badGatewayException: (value: BadGatewayException) => T;
|
|
3754
|
+
files: (value: FilePart) => T;
|
|
3755
|
+
_: (name: string, value: any) => T;
|
|
3756
|
+
}
|
|
3757
|
+
const visit: <T>(value: ResponseStream, visitor: Visitor<T>) => T;
|
|
3758
|
+
}
|
|
3759
|
+
/**
|
|
3760
|
+
* @public
|
|
3761
|
+
*/
|
|
3762
|
+
export interface InvokeAgentResponse {
|
|
3763
|
+
/**
|
|
3764
|
+
* <p>The agent's response to the user prompt.</p>
|
|
3765
|
+
* @public
|
|
3766
|
+
*/
|
|
3767
|
+
completion: AsyncIterable<ResponseStream> | undefined;
|
|
3768
|
+
/**
|
|
3769
|
+
* <p>The MIME type of the input data in the request. The default value is <code>application/json</code>.</p>
|
|
3770
|
+
* @public
|
|
3771
|
+
*/
|
|
3772
|
+
contentType: string | undefined;
|
|
3773
|
+
/**
|
|
3774
|
+
* <p>The unique identifier of the session with the agent.</p>
|
|
3775
|
+
* @public
|
|
3776
|
+
*/
|
|
3777
|
+
sessionId: string | undefined;
|
|
3778
|
+
/**
|
|
3779
|
+
* <p>The unique identifier of the agent memory.</p>
|
|
3780
|
+
* @public
|
|
3781
|
+
*/
|
|
3782
|
+
memoryId?: string | undefined;
|
|
3783
|
+
}
|
|
3784
|
+
/**
|
|
3785
|
+
* <p>
|
|
3786
|
+
* The configuration details for the guardrail.
|
|
3787
|
+
* </p>
|
|
3788
|
+
* @public
|
|
3789
|
+
*/
|
|
3790
|
+
export interface GuardrailConfigurationWithArn {
|
|
3791
|
+
/**
|
|
3792
|
+
* <p>
|
|
3793
|
+
* The unique identifier for the guardrail.
|
|
3794
|
+
* </p>
|
|
3795
|
+
* @public
|
|
3796
|
+
*/
|
|
3797
|
+
guardrailIdentifier: string | undefined;
|
|
3798
|
+
/**
|
|
3799
|
+
* <p>
|
|
3800
|
+
* The version of the guardrail.
|
|
3801
|
+
* </p>
|
|
3802
|
+
* @public
|
|
3803
|
+
*/
|
|
3804
|
+
guardrailVersion: string | undefined;
|
|
3805
|
+
}
|
|
3806
|
+
/**
|
|
3807
|
+
* <p>
|
|
3808
|
+
* Contains parameters that specify various attributes that persist across a session or prompt. You can define session state
|
|
3809
|
+
* 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.
|
|
3810
|
+
* Use session state attributes to control and provide conversational context for your inline agent and to help customize your agent's behavior.
|
|
3811
|
+
* For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-session-state.html">Control session context</a>
|
|
3812
|
+
* </p>
|
|
3813
|
+
* @public
|
|
3814
|
+
*/
|
|
3815
|
+
export interface InlineSessionState {
|
|
3816
|
+
/**
|
|
3817
|
+
* <p>
|
|
3818
|
+
* Contains attributes that persist across a session and the values of those attributes.
|
|
3819
|
+
* </p>
|
|
3820
|
+
* @public
|
|
3821
|
+
*/
|
|
3822
|
+
sessionAttributes?: Record<string, string> | undefined;
|
|
3823
|
+
/**
|
|
3824
|
+
* <p>
|
|
3825
|
+
* Contains attributes that persist across a session and the values of those attributes.
|
|
3826
|
+
* </p>
|
|
3827
|
+
* @public
|
|
3828
|
+
*/
|
|
3829
|
+
promptSessionAttributes?: Record<string, string> | undefined;
|
|
3830
|
+
/**
|
|
3831
|
+
* <p>
|
|
3832
|
+
* 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>.
|
|
3833
|
+
* </p>
|
|
3834
|
+
* <note>
|
|
3835
|
+
* <p>If you include this field in the <code>sessionState</code> field, the <code>inputText</code> field will be ignored.</p>
|
|
3836
|
+
* </note>
|
|
3837
|
+
* @public
|
|
3838
|
+
*/
|
|
3839
|
+
returnControlInvocationResults?: InvocationResultMember[] | undefined;
|
|
3840
|
+
/**
|
|
3841
|
+
* <p>
|
|
3842
|
+
* 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
|
|
3843
|
+
* 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>.
|
|
3844
|
+
* </p>
|
|
3845
|
+
* @public
|
|
3846
|
+
*/
|
|
3847
|
+
invocationId?: string | undefined;
|
|
3848
|
+
/**
|
|
3849
|
+
* <p>
|
|
3850
|
+
* Contains information about the files used by code interpreter.
|
|
3851
|
+
* </p>
|
|
3852
|
+
* @public
|
|
3853
|
+
*/
|
|
3854
|
+
files?: InputFile[] | undefined;
|
|
3855
|
+
}
|
|
3856
|
+
/**
|
|
3857
|
+
* @public
|
|
3858
|
+
* @enum
|
|
3859
|
+
*/
|
|
3860
|
+
export declare const PromptState: {
|
|
3861
|
+
readonly DISABLED: "DISABLED";
|
|
3862
|
+
readonly ENABLED: "ENABLED";
|
|
3863
|
+
};
|
|
3864
|
+
/**
|
|
3865
|
+
* @public
|
|
3866
|
+
*/
|
|
3867
|
+
export type PromptState = (typeof PromptState)[keyof typeof PromptState];
|
|
3868
|
+
/**
|
|
3869
|
+
* <p>
|
|
3870
|
+
* 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>.
|
|
3871
|
+
* </p>
|
|
3872
|
+
* @public
|
|
3873
|
+
*/
|
|
3874
|
+
export interface PromptConfiguration {
|
|
3875
|
+
/**
|
|
3876
|
+
* <p>
|
|
3877
|
+
* The step in the agent sequence that this prompt configuration applies to.
|
|
3878
|
+
* </p>
|
|
3879
|
+
* @public
|
|
3880
|
+
*/
|
|
3881
|
+
promptType?: PromptType | undefined;
|
|
3882
|
+
/**
|
|
3883
|
+
* <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>
|
|
3884
|
+
* @public
|
|
3885
|
+
*/
|
|
3886
|
+
promptCreationMode?: CreationMode | undefined;
|
|
3887
|
+
/**
|
|
3888
|
+
* <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>
|
|
3889
|
+
* <ul>
|
|
3890
|
+
* <li>
|
|
3891
|
+
* <p>
|
|
3892
|
+
* <code>PRE_PROCESSING</code> – <code>ENABLED</code>
|
|
3893
|
+
* </p>
|
|
3894
|
+
* </li>
|
|
3895
|
+
* <li>
|
|
3896
|
+
* <p>
|
|
3897
|
+
* <code>ORCHESTRATION</code> – <code>ENABLED</code>
|
|
3898
|
+
* </p>
|
|
3899
|
+
* </li>
|
|
3900
|
+
* <li>
|
|
3901
|
+
* <p>
|
|
3902
|
+
* <code>KNOWLEDGE_BASE_RESPONSE_GENERATION</code> – <code>ENABLED</code>
|
|
3903
|
+
* </p>
|
|
3904
|
+
* </li>
|
|
3905
|
+
* <li>
|
|
3906
|
+
* <p>
|
|
3907
|
+
* <code>POST_PROCESSING</code> – <code>DISABLED</code>
|
|
3908
|
+
* </p>
|
|
3909
|
+
* </li>
|
|
3910
|
+
* </ul>
|
|
3911
|
+
* @public
|
|
3912
|
+
*/
|
|
3913
|
+
promptState?: PromptState | undefined;
|
|
3914
|
+
/**
|
|
3915
|
+
* <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>
|
|
3916
|
+
* @public
|
|
3917
|
+
*/
|
|
3918
|
+
basePromptTemplate?: string | undefined;
|
|
3919
|
+
/**
|
|
3920
|
+
* <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>
|
|
3921
|
+
* @public
|
|
3922
|
+
*/
|
|
3923
|
+
inferenceConfiguration?: InferenceConfiguration | undefined;
|
|
3924
|
+
/**
|
|
3925
|
+
* <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>
|
|
3926
|
+
* @public
|
|
3927
|
+
*/
|
|
3928
|
+
parserMode?: CreationMode | undefined;
|
|
3929
|
+
}
|
|
3930
|
+
/**
|
|
3931
|
+
* <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>
|
|
3016
3932
|
* @public
|
|
3017
3933
|
*/
|
|
3018
|
-
export interface
|
|
3934
|
+
export interface PromptOverrideConfiguration {
|
|
3019
3935
|
/**
|
|
3020
|
-
* <p>
|
|
3936
|
+
* <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>
|
|
3021
3937
|
* @public
|
|
3022
3938
|
*/
|
|
3023
|
-
|
|
3939
|
+
promptConfigurations: PromptConfiguration[] | undefined;
|
|
3024
3940
|
/**
|
|
3025
|
-
* <p>The
|
|
3941
|
+
* <p>The ARN of the Lambda function to use when parsing the raw foundation model output in parts of the agent sequence.
|
|
3942
|
+
* If you specify this field, at least one of the <code>promptConfigurations</code> must contain a <code>parserMode</code> value that is
|
|
3943
|
+
* 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>.
|
|
3944
|
+
* </p>
|
|
3026
3945
|
* @public
|
|
3027
3946
|
*/
|
|
3028
|
-
|
|
3947
|
+
overrideLambda?: string | undefined;
|
|
3948
|
+
}
|
|
3949
|
+
/**
|
|
3950
|
+
* <p>Contains a part of an agent response and citations for it. </p>
|
|
3951
|
+
* @public
|
|
3952
|
+
*/
|
|
3953
|
+
export interface InlineAgentPayloadPart {
|
|
3029
3954
|
/**
|
|
3030
|
-
* <p>
|
|
3955
|
+
* <p>A part of the agent response in bytes.</p>
|
|
3031
3956
|
* @public
|
|
3032
3957
|
*/
|
|
3033
|
-
|
|
3958
|
+
bytes?: Uint8Array | undefined;
|
|
3034
3959
|
/**
|
|
3035
|
-
* <p>
|
|
3960
|
+
* <p>Contains citations for a part of an agent response.</p>
|
|
3036
3961
|
* @public
|
|
3037
3962
|
*/
|
|
3038
|
-
|
|
3963
|
+
attribution?: Attribution | undefined;
|
|
3964
|
+
}
|
|
3965
|
+
/**
|
|
3966
|
+
* <p>Contains intermediate response for code interpreter if any files have been generated.</p>
|
|
3967
|
+
* @public
|
|
3968
|
+
*/
|
|
3969
|
+
export interface InlineAgentFilePart {
|
|
3039
3970
|
/**
|
|
3040
|
-
* <p>
|
|
3971
|
+
* <p>Files containing intermediate response for the user.</p>
|
|
3972
|
+
* @public
|
|
3973
|
+
*/
|
|
3974
|
+
files?: OutputFile[] | undefined;
|
|
3975
|
+
}
|
|
3976
|
+
/**
|
|
3977
|
+
* <p>Contains information to return from the action group that the agent has predicted to invoke.</p>
|
|
3978
|
+
* <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>
|
|
3979
|
+
* @public
|
|
3980
|
+
*/
|
|
3981
|
+
export interface InlineAgentReturnControlPayload {
|
|
3982
|
+
/**
|
|
3983
|
+
* <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
|
|
3984
|
+
* determines from its session with the user.</p>
|
|
3985
|
+
* @public
|
|
3986
|
+
*/
|
|
3987
|
+
invocationInputs?: InvocationInputMember[] | undefined;
|
|
3988
|
+
/**
|
|
3989
|
+
* <p>The identifier of the action group invocation. </p>
|
|
3990
|
+
* @public
|
|
3991
|
+
*/
|
|
3992
|
+
invocationId?: string | undefined;
|
|
3993
|
+
}
|
|
3994
|
+
/**
|
|
3995
|
+
* <p>Contains information about the agent and session, alongside the agent's reasoning process and results from calling API actions and querying knowledge bases
|
|
3996
|
+
* and metadata about the trace. You can use the trace to understand how the agent arrived at the response it provided the customer.
|
|
3997
|
+
* For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-test.html#trace-enablement">Trace enablement</a>.</p>
|
|
3998
|
+
* @public
|
|
3999
|
+
*/
|
|
4000
|
+
export interface InlineAgentTracePart {
|
|
4001
|
+
/**
|
|
4002
|
+
* <p>The unique identifier of the session with the agent.</p>
|
|
4003
|
+
* @public
|
|
4004
|
+
*/
|
|
4005
|
+
sessionId?: string | undefined;
|
|
4006
|
+
/**
|
|
4007
|
+
* <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
|
|
4008
|
+
* 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>.
|
|
4009
|
+
* </p>
|
|
3041
4010
|
* @public
|
|
3042
4011
|
*/
|
|
3043
4012
|
trace?: Trace | undefined;
|
|
@@ -3046,17 +4015,17 @@ export interface TracePart {
|
|
|
3046
4015
|
* <p>The response from invoking the agent and associated citations and trace information.</p>
|
|
3047
4016
|
* @public
|
|
3048
4017
|
*/
|
|
3049
|
-
export type
|
|
4018
|
+
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;
|
|
3050
4019
|
/**
|
|
3051
4020
|
* @public
|
|
3052
4021
|
*/
|
|
3053
|
-
export declare namespace
|
|
4022
|
+
export declare namespace InlineAgentResponseStream {
|
|
3054
4023
|
/**
|
|
3055
4024
|
* <p>Contains a part of an agent response and citations for it.</p>
|
|
3056
4025
|
* @public
|
|
3057
4026
|
*/
|
|
3058
4027
|
interface ChunkMember {
|
|
3059
|
-
chunk:
|
|
4028
|
+
chunk: InlineAgentPayloadPart;
|
|
3060
4029
|
trace?: never;
|
|
3061
4030
|
returnControl?: never;
|
|
3062
4031
|
internalServerException?: never;
|
|
@@ -3072,12 +4041,15 @@ export declare namespace ResponseStream {
|
|
|
3072
4041
|
$unknown?: never;
|
|
3073
4042
|
}
|
|
3074
4043
|
/**
|
|
3075
|
-
* <p>Contains information about the agent and session, alongside the agent's reasoning process and results from calling actions and querying
|
|
4044
|
+
* <p>Contains information about the agent and session, alongside the agent's reasoning process and results from calling actions and querying
|
|
4045
|
+
* 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.
|
|
4046
|
+
* For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/trace-events.html">Trace events</a>.
|
|
4047
|
+
* </p>
|
|
3076
4048
|
* @public
|
|
3077
4049
|
*/
|
|
3078
4050
|
interface TraceMember {
|
|
3079
4051
|
chunk?: never;
|
|
3080
|
-
trace:
|
|
4052
|
+
trace: InlineAgentTracePart;
|
|
3081
4053
|
returnControl?: never;
|
|
3082
4054
|
internalServerException?: never;
|
|
3083
4055
|
validationException?: never;
|
|
@@ -3092,13 +4064,14 @@ export declare namespace ResponseStream {
|
|
|
3092
4064
|
$unknown?: never;
|
|
3093
4065
|
}
|
|
3094
4066
|
/**
|
|
3095
|
-
* <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
|
|
4067
|
+
* <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
|
|
4068
|
+
* and can be used in your own setup for fulfilling the action.</p>
|
|
3096
4069
|
* @public
|
|
3097
4070
|
*/
|
|
3098
4071
|
interface ReturnControlMember {
|
|
3099
4072
|
chunk?: never;
|
|
3100
4073
|
trace?: never;
|
|
3101
|
-
returnControl:
|
|
4074
|
+
returnControl: InlineAgentReturnControlPayload;
|
|
3102
4075
|
internalServerException?: never;
|
|
3103
4076
|
validationException?: never;
|
|
3104
4077
|
resourceNotFoundException?: never;
|
|
@@ -3152,7 +4125,7 @@ export declare namespace ResponseStream {
|
|
|
3152
4125
|
$unknown?: never;
|
|
3153
4126
|
}
|
|
3154
4127
|
/**
|
|
3155
|
-
* <p>The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again
|
|
4128
|
+
* <p>The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again. </p>
|
|
3156
4129
|
* @public
|
|
3157
4130
|
*/
|
|
3158
4131
|
interface ResourceNotFoundExceptionMember {
|
|
@@ -3232,7 +4205,7 @@ export declare namespace ResponseStream {
|
|
|
3232
4205
|
$unknown?: never;
|
|
3233
4206
|
}
|
|
3234
4207
|
/**
|
|
3235
|
-
* <p>There was a conflict performing an operation. Resolve the conflict and retry your request
|
|
4208
|
+
* <p>There was a conflict performing an operation. Resolve the conflict and retry your request. </p>
|
|
3236
4209
|
* @public
|
|
3237
4210
|
*/
|
|
3238
4211
|
interface ConflictExceptionMember {
|
|
@@ -3272,7 +4245,7 @@ export declare namespace ResponseStream {
|
|
|
3272
4245
|
$unknown?: never;
|
|
3273
4246
|
}
|
|
3274
4247
|
/**
|
|
3275
|
-
* <p>There was an issue with a dependency due to a server issue. Retry your request
|
|
4248
|
+
* <p>There was an issue with a dependency due to a server issue. Retry your request. </p>
|
|
3276
4249
|
* @public
|
|
3277
4250
|
*/
|
|
3278
4251
|
interface BadGatewayExceptionMember {
|
|
@@ -3308,7 +4281,7 @@ export declare namespace ResponseStream {
|
|
|
3308
4281
|
conflictException?: never;
|
|
3309
4282
|
dependencyFailedException?: never;
|
|
3310
4283
|
badGatewayException?: never;
|
|
3311
|
-
files:
|
|
4284
|
+
files: InlineAgentFilePart;
|
|
3312
4285
|
$unknown?: never;
|
|
3313
4286
|
}
|
|
3314
4287
|
/**
|
|
@@ -3331,9 +4304,9 @@ export declare namespace ResponseStream {
|
|
|
3331
4304
|
$unknown: [string, any];
|
|
3332
4305
|
}
|
|
3333
4306
|
interface Visitor<T> {
|
|
3334
|
-
chunk: (value:
|
|
3335
|
-
trace: (value:
|
|
3336
|
-
returnControl: (value:
|
|
4307
|
+
chunk: (value: InlineAgentPayloadPart) => T;
|
|
4308
|
+
trace: (value: InlineAgentTracePart) => T;
|
|
4309
|
+
returnControl: (value: InlineAgentReturnControlPayload) => T;
|
|
3337
4310
|
internalServerException: (value: InternalServerException) => T;
|
|
3338
4311
|
validationException: (value: ValidationException) => T;
|
|
3339
4312
|
resourceNotFoundException: (value: ResourceNotFoundException) => T;
|
|
@@ -3343,35 +4316,36 @@ export declare namespace ResponseStream {
|
|
|
3343
4316
|
conflictException: (value: ConflictException) => T;
|
|
3344
4317
|
dependencyFailedException: (value: DependencyFailedException) => T;
|
|
3345
4318
|
badGatewayException: (value: BadGatewayException) => T;
|
|
3346
|
-
files: (value:
|
|
4319
|
+
files: (value: InlineAgentFilePart) => T;
|
|
3347
4320
|
_: (name: string, value: any) => T;
|
|
3348
4321
|
}
|
|
3349
|
-
const visit: <T>(value:
|
|
4322
|
+
const visit: <T>(value: InlineAgentResponseStream, visitor: Visitor<T>) => T;
|
|
3350
4323
|
}
|
|
3351
4324
|
/**
|
|
3352
4325
|
* @public
|
|
3353
4326
|
*/
|
|
3354
|
-
export interface
|
|
4327
|
+
export interface InvokeInlineAgentResponse {
|
|
3355
4328
|
/**
|
|
3356
|
-
* <p>
|
|
4329
|
+
* <p>
|
|
4330
|
+
*
|
|
4331
|
+
* </p>
|
|
3357
4332
|
* @public
|
|
3358
4333
|
*/
|
|
3359
|
-
completion: AsyncIterable<
|
|
4334
|
+
completion: AsyncIterable<InlineAgentResponseStream> | undefined;
|
|
3360
4335
|
/**
|
|
3361
|
-
* <p>
|
|
4336
|
+
* <p>
|
|
4337
|
+
* The MIME type of the input data in the request. The default value is application/json.
|
|
4338
|
+
* </p>
|
|
3362
4339
|
* @public
|
|
3363
4340
|
*/
|
|
3364
4341
|
contentType: string | undefined;
|
|
3365
4342
|
/**
|
|
3366
|
-
* <p>
|
|
4343
|
+
* <p>
|
|
4344
|
+
* The unique identifier of the session with the agent.
|
|
4345
|
+
* </p>
|
|
3367
4346
|
* @public
|
|
3368
4347
|
*/
|
|
3369
4348
|
sessionId: string | undefined;
|
|
3370
|
-
/**
|
|
3371
|
-
* <p>The unique identifier of the agent memory.</p>
|
|
3372
|
-
* @public
|
|
3373
|
-
*/
|
|
3374
|
-
memoryId?: string | undefined;
|
|
3375
4349
|
}
|
|
3376
4350
|
/**
|
|
3377
4351
|
* @public
|
|
@@ -4685,6 +5659,35 @@ export interface KnowledgeBaseRetrievalConfiguration {
|
|
|
4685
5659
|
*/
|
|
4686
5660
|
vectorSearchConfiguration: KnowledgeBaseVectorSearchConfiguration | undefined;
|
|
4687
5661
|
}
|
|
5662
|
+
/**
|
|
5663
|
+
* <p>
|
|
5664
|
+
* Details of the knowledge base associated withe inline agent.
|
|
5665
|
+
* </p>
|
|
5666
|
+
* @public
|
|
5667
|
+
*/
|
|
5668
|
+
export interface KnowledgeBase {
|
|
5669
|
+
/**
|
|
5670
|
+
* <p>
|
|
5671
|
+
* The unique identifier for a knowledge base associated with the inline agent.
|
|
5672
|
+
* </p>
|
|
5673
|
+
* @public
|
|
5674
|
+
*/
|
|
5675
|
+
knowledgeBaseId: string | undefined;
|
|
5676
|
+
/**
|
|
5677
|
+
* <p>
|
|
5678
|
+
* The description of the knowledge base associated with the inline agent.
|
|
5679
|
+
* </p>
|
|
5680
|
+
* @public
|
|
5681
|
+
*/
|
|
5682
|
+
description: string | undefined;
|
|
5683
|
+
/**
|
|
5684
|
+
* <p>
|
|
5685
|
+
* 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>.
|
|
5686
|
+
* </p>
|
|
5687
|
+
* @public
|
|
5688
|
+
*/
|
|
5689
|
+
retrievalConfiguration?: KnowledgeBaseRetrievalConfiguration | undefined;
|
|
5690
|
+
}
|
|
4688
5691
|
/**
|
|
4689
5692
|
* <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>
|
|
4690
5693
|
* @public
|
|
@@ -4797,6 +5800,111 @@ export interface RetrieveAndGenerateConfiguration {
|
|
|
4797
5800
|
*/
|
|
4798
5801
|
externalSourcesConfiguration?: ExternalSourcesRetrieveAndGenerateConfiguration | undefined;
|
|
4799
5802
|
}
|
|
5803
|
+
/**
|
|
5804
|
+
* @public
|
|
5805
|
+
*/
|
|
5806
|
+
export interface InvokeInlineAgentRequest {
|
|
5807
|
+
/**
|
|
5808
|
+
* <p>
|
|
5809
|
+
* The unique identifier of the session. Use the same value across requests to continue the same conversation.
|
|
5810
|
+
* </p>
|
|
5811
|
+
* @public
|
|
5812
|
+
*/
|
|
5813
|
+
sessionId: string | undefined;
|
|
5814
|
+
/**
|
|
5815
|
+
* <p>
|
|
5816
|
+
* The Amazon Resource Name (ARN) of the Amazon Web Services KMS key to use to encrypt your inline agent.
|
|
5817
|
+
* </p>
|
|
5818
|
+
* @public
|
|
5819
|
+
*/
|
|
5820
|
+
customerEncryptionKeyArn?: string | undefined;
|
|
5821
|
+
/**
|
|
5822
|
+
* <p>
|
|
5823
|
+
* Specifies whether to end the session with the inline agent or not.
|
|
5824
|
+
* </p>
|
|
5825
|
+
* @public
|
|
5826
|
+
*/
|
|
5827
|
+
endSession?: boolean | undefined;
|
|
5828
|
+
/**
|
|
5829
|
+
* <p>
|
|
5830
|
+
* 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>.
|
|
5831
|
+
*
|
|
5832
|
+
* </p>
|
|
5833
|
+
* @public
|
|
5834
|
+
*/
|
|
5835
|
+
enableTrace?: boolean | undefined;
|
|
5836
|
+
/**
|
|
5837
|
+
* <p>
|
|
5838
|
+
* The prompt text to send to the agent.
|
|
5839
|
+
* </p>
|
|
5840
|
+
* <note>
|
|
5841
|
+
* <p>If you include <code>returnControlInvocationResults</code> in the <code>sessionState</code> field, the <code>inputText</code> field will be ignored.</p>
|
|
5842
|
+
* </note>
|
|
5843
|
+
* @public
|
|
5844
|
+
*/
|
|
5845
|
+
inputText?: string | undefined;
|
|
5846
|
+
/**
|
|
5847
|
+
* <p>
|
|
5848
|
+
* Parameters that specify the various attributes of a sessions. You can include attributes for the session or prompt or, if you configured an
|
|
5849
|
+
* 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>.
|
|
5850
|
+
* </p>
|
|
5851
|
+
* <note>
|
|
5852
|
+
* <p>If you include <code>returnControlInvocationResults</code> in the <code>sessionState</code> field, the <code>inputText</code> field will be ignored.</p>
|
|
5853
|
+
* </note>
|
|
5854
|
+
* @public
|
|
5855
|
+
*/
|
|
5856
|
+
inlineSessionState?: InlineSessionState | undefined;
|
|
5857
|
+
/**
|
|
5858
|
+
* <p>
|
|
5859
|
+
* 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>.
|
|
5860
|
+
* </p>
|
|
5861
|
+
* @public
|
|
5862
|
+
*/
|
|
5863
|
+
foundationModel: string | undefined;
|
|
5864
|
+
/**
|
|
5865
|
+
* <p>
|
|
5866
|
+
* The instructions that tell the inline agent what it should do and how it should interact with users.
|
|
5867
|
+
* </p>
|
|
5868
|
+
* @public
|
|
5869
|
+
*/
|
|
5870
|
+
instruction: string | undefined;
|
|
5871
|
+
/**
|
|
5872
|
+
* <p>
|
|
5873
|
+
* 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.
|
|
5874
|
+
* </p>
|
|
5875
|
+
* <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>
|
|
5876
|
+
* @public
|
|
5877
|
+
*/
|
|
5878
|
+
idleSessionTTLInSeconds?: number | undefined;
|
|
5879
|
+
/**
|
|
5880
|
+
* <p>
|
|
5881
|
+
* A list of action groups with each action group defining the action the inline agent needs to carry out.
|
|
5882
|
+
* </p>
|
|
5883
|
+
* @public
|
|
5884
|
+
*/
|
|
5885
|
+
actionGroups?: AgentActionGroup[] | undefined;
|
|
5886
|
+
/**
|
|
5887
|
+
* <p>
|
|
5888
|
+
* Contains information of the knowledge bases to associate with.
|
|
5889
|
+
* </p>
|
|
5890
|
+
* @public
|
|
5891
|
+
*/
|
|
5892
|
+
knowledgeBases?: KnowledgeBase[] | undefined;
|
|
5893
|
+
/**
|
|
5894
|
+
* <p>
|
|
5895
|
+
* The <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails.html">guardrails</a> to assign to the inline agent.
|
|
5896
|
+
* </p>
|
|
5897
|
+
* @public
|
|
5898
|
+
*/
|
|
5899
|
+
guardrailConfiguration?: GuardrailConfigurationWithArn | undefined;
|
|
5900
|
+
/**
|
|
5901
|
+
* <p>
|
|
5902
|
+
* Configurations for advanced prompts used to override the default prompts to enhance the accuracy of the inline agent.
|
|
5903
|
+
* </p>
|
|
5904
|
+
* @public
|
|
5905
|
+
*/
|
|
5906
|
+
promptOverrideConfiguration?: PromptOverrideConfiguration | undefined;
|
|
5907
|
+
}
|
|
4800
5908
|
/**
|
|
4801
5909
|
* @public
|
|
4802
5910
|
*/
|
|
@@ -4911,6 +6019,13 @@ export interface InvokeAgentRequest {
|
|
|
4911
6019
|
* @public
|
|
4912
6020
|
*/
|
|
4913
6021
|
memoryId?: string | undefined;
|
|
6022
|
+
/**
|
|
6023
|
+
* <p>
|
|
6024
|
+
* Specifies the configurations for streaming.
|
|
6025
|
+
* </p>
|
|
6026
|
+
* @public
|
|
6027
|
+
*/
|
|
6028
|
+
streamingConfigurations?: StreamingConfigurations | undefined;
|
|
4914
6029
|
}
|
|
4915
6030
|
/**
|
|
4916
6031
|
* @internal
|
|
@@ -4920,6 +6035,22 @@ export declare const ActionGroupInvocationInputFilterSensitiveLog: (obj: ActionG
|
|
|
4920
6035
|
* @internal
|
|
4921
6036
|
*/
|
|
4922
6037
|
export declare const ActionGroupInvocationOutputFilterSensitiveLog: (obj: ActionGroupInvocationOutput) => any;
|
|
6038
|
+
/**
|
|
6039
|
+
* @internal
|
|
6040
|
+
*/
|
|
6041
|
+
export declare const APISchemaFilterSensitiveLog: (obj: APISchema) => any;
|
|
6042
|
+
/**
|
|
6043
|
+
* @internal
|
|
6044
|
+
*/
|
|
6045
|
+
export declare const FunctionDefinitionFilterSensitiveLog: (obj: FunctionDefinition) => any;
|
|
6046
|
+
/**
|
|
6047
|
+
* @internal
|
|
6048
|
+
*/
|
|
6049
|
+
export declare const FunctionSchemaFilterSensitiveLog: (obj: FunctionSchema) => any;
|
|
6050
|
+
/**
|
|
6051
|
+
* @internal
|
|
6052
|
+
*/
|
|
6053
|
+
export declare const AgentActionGroupFilterSensitiveLog: (obj: AgentActionGroup) => any;
|
|
4923
6054
|
/**
|
|
4924
6055
|
* @internal
|
|
4925
6056
|
*/
|
|
@@ -5056,6 +6187,14 @@ export declare const InvocationInputMemberFilterSensitiveLog: (obj: InvocationIn
|
|
|
5056
6187
|
* @internal
|
|
5057
6188
|
*/
|
|
5058
6189
|
export declare const ReturnControlPayloadFilterSensitiveLog: (obj: ReturnControlPayload) => any;
|
|
6190
|
+
/**
|
|
6191
|
+
* @internal
|
|
6192
|
+
*/
|
|
6193
|
+
export declare const CustomOrchestrationTraceEventFilterSensitiveLog: (obj: CustomOrchestrationTraceEvent) => any;
|
|
6194
|
+
/**
|
|
6195
|
+
* @internal
|
|
6196
|
+
*/
|
|
6197
|
+
export declare const CustomOrchestrationTraceFilterSensitiveLog: (obj: CustomOrchestrationTrace) => any;
|
|
5059
6198
|
/**
|
|
5060
6199
|
* @internal
|
|
5061
6200
|
*/
|
|
@@ -5200,6 +6339,42 @@ export declare const ResponseStreamFilterSensitiveLog: (obj: ResponseStream) =>
|
|
|
5200
6339
|
* @internal
|
|
5201
6340
|
*/
|
|
5202
6341
|
export declare const InvokeAgentResponseFilterSensitiveLog: (obj: InvokeAgentResponse) => any;
|
|
6342
|
+
/**
|
|
6343
|
+
* @internal
|
|
6344
|
+
*/
|
|
6345
|
+
export declare const InlineSessionStateFilterSensitiveLog: (obj: InlineSessionState) => any;
|
|
6346
|
+
/**
|
|
6347
|
+
* @internal
|
|
6348
|
+
*/
|
|
6349
|
+
export declare const PromptConfigurationFilterSensitiveLog: (obj: PromptConfiguration) => any;
|
|
6350
|
+
/**
|
|
6351
|
+
* @internal
|
|
6352
|
+
*/
|
|
6353
|
+
export declare const PromptOverrideConfigurationFilterSensitiveLog: (obj: PromptOverrideConfiguration) => any;
|
|
6354
|
+
/**
|
|
6355
|
+
* @internal
|
|
6356
|
+
*/
|
|
6357
|
+
export declare const InlineAgentPayloadPartFilterSensitiveLog: (obj: InlineAgentPayloadPart) => any;
|
|
6358
|
+
/**
|
|
6359
|
+
* @internal
|
|
6360
|
+
*/
|
|
6361
|
+
export declare const InlineAgentFilePartFilterSensitiveLog: (obj: InlineAgentFilePart) => any;
|
|
6362
|
+
/**
|
|
6363
|
+
* @internal
|
|
6364
|
+
*/
|
|
6365
|
+
export declare const InlineAgentReturnControlPayloadFilterSensitiveLog: (obj: InlineAgentReturnControlPayload) => any;
|
|
6366
|
+
/**
|
|
6367
|
+
* @internal
|
|
6368
|
+
*/
|
|
6369
|
+
export declare const InlineAgentTracePartFilterSensitiveLog: (obj: InlineAgentTracePart) => any;
|
|
6370
|
+
/**
|
|
6371
|
+
* @internal
|
|
6372
|
+
*/
|
|
6373
|
+
export declare const InlineAgentResponseStreamFilterSensitiveLog: (obj: InlineAgentResponseStream) => any;
|
|
6374
|
+
/**
|
|
6375
|
+
* @internal
|
|
6376
|
+
*/
|
|
6377
|
+
export declare const InvokeInlineAgentResponseFilterSensitiveLog: (obj: InvokeInlineAgentResponse) => any;
|
|
5203
6378
|
/**
|
|
5204
6379
|
* @internal
|
|
5205
6380
|
*/
|
|
@@ -5296,6 +6471,10 @@ export declare const KnowledgeBaseVectorSearchConfigurationFilterSensitiveLog: (
|
|
|
5296
6471
|
* @internal
|
|
5297
6472
|
*/
|
|
5298
6473
|
export declare const KnowledgeBaseRetrievalConfigurationFilterSensitiveLog: (obj: KnowledgeBaseRetrievalConfiguration) => any;
|
|
6474
|
+
/**
|
|
6475
|
+
* @internal
|
|
6476
|
+
*/
|
|
6477
|
+
export declare const KnowledgeBaseFilterSensitiveLog: (obj: KnowledgeBase) => any;
|
|
5299
6478
|
/**
|
|
5300
6479
|
* @internal
|
|
5301
6480
|
*/
|
|
@@ -5312,6 +6491,10 @@ export declare const RetrieveRequestFilterSensitiveLog: (obj: RetrieveRequest) =
|
|
|
5312
6491
|
* @internal
|
|
5313
6492
|
*/
|
|
5314
6493
|
export declare const RetrieveAndGenerateConfigurationFilterSensitiveLog: (obj: RetrieveAndGenerateConfiguration) => any;
|
|
6494
|
+
/**
|
|
6495
|
+
* @internal
|
|
6496
|
+
*/
|
|
6497
|
+
export declare const InvokeInlineAgentRequestFilterSensitiveLog: (obj: InvokeInlineAgentRequest) => any;
|
|
5315
6498
|
/**
|
|
5316
6499
|
* @internal
|
|
5317
6500
|
*/
|