@aws-sdk/client-bedrock-agent-runtime 3.1070.0 → 3.1071.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.
Files changed (65) hide show
  1. package/README.md +14 -0
  2. package/dist-cjs/index.js +93 -8
  3. package/dist-cjs/models/errors.js +42 -42
  4. package/dist-cjs/runtimeConfig.js +5 -2
  5. package/dist-cjs/schemas/schemas_0.js +567 -139
  6. package/dist-es/BedrockAgentRuntime.js +4 -0
  7. package/dist-es/commands/AgenticRetrieveStreamCommand.js +20 -0
  8. package/dist-es/commands/GetDocumentContentCommand.js +16 -0
  9. package/dist-es/commands/index.js +2 -0
  10. package/dist-es/models/enums.js +50 -7
  11. package/dist-es/models/errors.js +42 -42
  12. package/dist-es/runtimeConfig.js +5 -2
  13. package/dist-es/schemas/schemas_0.js +521 -139
  14. package/dist-types/BedrockAgentRuntime.d.ts +14 -0
  15. package/dist-types/BedrockAgentRuntimeClient.d.ts +4 -2
  16. package/dist-types/commands/AgenticRetrieveStreamCommand.d.ts +338 -0
  17. package/dist-types/commands/GetDocumentContentCommand.d.ts +99 -0
  18. package/dist-types/commands/GetInvocationStepCommand.d.ts +1 -1
  19. package/dist-types/commands/InvokeAgentCommand.d.ts +55 -4
  20. package/dist-types/commands/InvokeFlowCommand.d.ts +14 -2
  21. package/dist-types/commands/InvokeInlineAgentCommand.d.ts +78 -8
  22. package/dist-types/commands/ListFlowExecutionEventsCommand.d.ts +14 -2
  23. package/dist-types/commands/ListInvocationStepsCommand.d.ts +1 -1
  24. package/dist-types/commands/ListInvocationsCommand.d.ts +1 -1
  25. package/dist-types/commands/ListSessionsCommand.d.ts +1 -1
  26. package/dist-types/commands/ListTagsForResourceCommand.d.ts +1 -1
  27. package/dist-types/commands/PutInvocationStepCommand.d.ts +1 -1
  28. package/dist-types/commands/RetrieveAndGenerateCommand.d.ts +45 -3
  29. package/dist-types/commands/RetrieveAndGenerateStreamCommand.d.ts +52 -4
  30. package/dist-types/commands/RetrieveCommand.d.ts +45 -2
  31. package/dist-types/commands/TagResourceCommand.d.ts +1 -1
  32. package/dist-types/commands/UntagResourceCommand.d.ts +1 -1
  33. package/dist-types/commands/UpdateSessionCommand.d.ts +1 -1
  34. package/dist-types/commands/index.d.ts +2 -0
  35. package/dist-types/models/enums.d.ts +163 -16
  36. package/dist-types/models/errors.d.ts +45 -45
  37. package/dist-types/models/models_0.d.ts +4105 -4355
  38. package/dist-types/models/models_1.d.ts +1396 -2
  39. package/dist-types/runtimeConfig.d.ts +1 -1
  40. package/dist-types/schemas/schemas_0.d.ts +48 -0
  41. package/dist-types/ts3.4/BedrockAgentRuntime.d.ts +34 -0
  42. package/dist-types/ts3.4/BedrockAgentRuntimeClient.d.ts +12 -0
  43. package/dist-types/ts3.4/commands/AgenticRetrieveStreamCommand.d.ts +51 -0
  44. package/dist-types/ts3.4/commands/GetDocumentContentCommand.d.ts +53 -0
  45. package/dist-types/ts3.4/commands/GetInvocationStepCommand.d.ts +1 -1
  46. package/dist-types/ts3.4/commands/InvokeAgentCommand.d.ts +2 -1
  47. package/dist-types/ts3.4/commands/ListInvocationStepsCommand.d.ts +1 -1
  48. package/dist-types/ts3.4/commands/ListInvocationsCommand.d.ts +1 -1
  49. package/dist-types/ts3.4/commands/ListSessionsCommand.d.ts +1 -1
  50. package/dist-types/ts3.4/commands/ListTagsForResourceCommand.d.ts +1 -1
  51. package/dist-types/ts3.4/commands/PutInvocationStepCommand.d.ts +1 -1
  52. package/dist-types/ts3.4/commands/RetrieveAndGenerateCommand.d.ts +2 -4
  53. package/dist-types/ts3.4/commands/RetrieveAndGenerateStreamCommand.d.ts +2 -4
  54. package/dist-types/ts3.4/commands/RetrieveCommand.d.ts +2 -1
  55. package/dist-types/ts3.4/commands/TagResourceCommand.d.ts +1 -1
  56. package/dist-types/ts3.4/commands/UntagResourceCommand.d.ts +1 -1
  57. package/dist-types/ts3.4/commands/UpdateSessionCommand.d.ts +1 -1
  58. package/dist-types/ts3.4/commands/index.d.ts +2 -0
  59. package/dist-types/ts3.4/models/enums.d.ts +74 -11
  60. package/dist-types/ts3.4/models/errors.d.ts +28 -28
  61. package/dist-types/ts3.4/models/models_0.d.ts +448 -541
  62. package/dist-types/ts3.4/models/models_1.d.ts +602 -3
  63. package/dist-types/ts3.4/runtimeConfig.d.ts +1 -1
  64. package/dist-types/ts3.4/schemas/schemas_0.d.ts +48 -0
  65. package/package.json +3 -3
@@ -1,5 +1,1399 @@
1
- import type { AgentCollaboration, OrchestrationType } from "./enums";
2
- import type { AgentActionGroup, Collaborator, CollaboratorConfiguration, CustomOrchestration, GuardrailConfigurationWithArn, InlineBedrockModelConfigurations, InlineSessionState, KnowledgeBase, PromptCreationConfigurations, PromptOverrideConfiguration, StreamingConfigurations } from "./models_0";
1
+ import type { AgentCollaboration, ImageFormat, OrchestrationType, RerankingModelType, RetrieveAndGenerateType, SearchType, SessionStatus } from "./enums";
2
+ import type { AgentActionGroup, AgenticRetrieveConfiguration, AgenticRetrieveMessage, AgenticRetrievePolicyConfiguration, BedrockModelConfigurations, CollaboratorConfiguration, ConversationHistory, CustomOrchestration, ExternalSourcesRetrieveAndGenerateConfiguration, FilterAttribute, GenerationConfiguration, GuardrailConfiguration, GuardrailConfigurationWithArn, ImplicitFilterConfiguration, InlineBedrockModelConfigurations, InlineSessionState, InputFile, InvocationResultMember, KnowledgeBaseQuery, ManagedSearchRerankingConfiguration, OrchestrationConfiguration, PromptCreationConfigurations, PromptOverrideConfiguration, RetrieveAndGenerateInput, RetrieveAndGenerateSessionConfiguration, StreamingConfigurations, UserContext, VectorSearchRerankingConfiguration } from "./models_0";
3
+ /**
4
+ * @public
5
+ */
6
+ export interface ListInvocationsRequest {
7
+ /**
8
+ * <p>If the total number of results is greater than the <code>maxResults</code> value provided in the request, enter the token returned in the <code>nextToken</code> field in the response in this field to return the next batch of results. </p>
9
+ * @public
10
+ */
11
+ nextToken?: string | undefined;
12
+ /**
13
+ * <p>The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the <code>nextToken</code> field when making another request to return the next batch of results.</p>
14
+ * @public
15
+ */
16
+ maxResults?: number | undefined;
17
+ /**
18
+ * <p>The unique identifier for the session to list invocations for. You can specify either the session's <code>sessionId</code> or its Amazon Resource Name (ARN).</p>
19
+ * @public
20
+ */
21
+ sessionIdentifier: string | undefined;
22
+ }
23
+ /**
24
+ * <p>Contains details about an invocation in a session. For more information about sessions, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/sessions.html">Store and retrieve conversation history and context with Amazon Bedrock sessions</a>.</p>
25
+ * @public
26
+ */
27
+ export interface InvocationSummary {
28
+ /**
29
+ * <p>The unique identifier for the session associated with the invocation.</p>
30
+ * @public
31
+ */
32
+ sessionId: string | undefined;
33
+ /**
34
+ * <p>A unique identifier for the invocation in UUID format.</p>
35
+ * @public
36
+ */
37
+ invocationId: string | undefined;
38
+ /**
39
+ * <p>The timestamp for when the invocation was created.</p>
40
+ * @public
41
+ */
42
+ createdAt: Date | undefined;
43
+ }
44
+ /**
45
+ * @public
46
+ */
47
+ export interface ListInvocationsResponse {
48
+ /**
49
+ * <p>A list of invocation summaries associated with the session.</p>
50
+ * @public
51
+ */
52
+ invocationSummaries: InvocationSummary[] | undefined;
53
+ /**
54
+ * <p>If the total number of results is greater than the <code>maxResults</code> value provided in the request, use this token when making another request in the <code>nextToken</code> field to return the next batch of results.</p>
55
+ * @public
56
+ */
57
+ nextToken?: string | undefined;
58
+ }
59
+ /**
60
+ * @public
61
+ */
62
+ export interface GetInvocationStepRequest {
63
+ /**
64
+ * <p>The unique identifier for the invocation in UUID format.</p>
65
+ * @public
66
+ */
67
+ invocationIdentifier: string | undefined;
68
+ /**
69
+ * <p>The unique identifier (in UUID format) for the specific invocation step to retrieve.</p>
70
+ * @public
71
+ */
72
+ invocationStepId: string | undefined;
73
+ /**
74
+ * <p>The unique identifier for the invocation step's associated session. You can specify either the session's <code>sessionId</code> or its Amazon Resource Name (ARN).</p>
75
+ * @public
76
+ */
77
+ sessionIdentifier: string | undefined;
78
+ }
79
+ /**
80
+ * <p>Information about the Amazon S3 bucket where the image is stored.</p>
81
+ * @public
82
+ */
83
+ export interface S3Location {
84
+ /**
85
+ * <p>The path to the Amazon S3 bucket where the image is stored.</p>
86
+ * @public
87
+ */
88
+ uri: string | undefined;
89
+ }
90
+ /**
91
+ * <p>The source for an image.</p>
92
+ * @public
93
+ */
94
+ export type ImageSource = ImageSource.BytesMember | ImageSource.S3LocationMember | ImageSource.$UnknownMember;
95
+ /**
96
+ * @public
97
+ */
98
+ export declare namespace ImageSource {
99
+ /**
100
+ * <p> The raw image bytes for the image. If you use an Amazon Web Services SDK, you don't need to encode the image bytes in base64.</p>
101
+ * @public
102
+ */
103
+ interface BytesMember {
104
+ bytes: Uint8Array;
105
+ s3Location?: never;
106
+ $unknown?: never;
107
+ }
108
+ /**
109
+ * <p>The path to the Amazon S3 bucket where the image is stored.</p>
110
+ * @public
111
+ */
112
+ interface S3LocationMember {
113
+ bytes?: never;
114
+ s3Location: S3Location;
115
+ $unknown?: never;
116
+ }
117
+ /**
118
+ * @public
119
+ */
120
+ interface $UnknownMember {
121
+ bytes?: never;
122
+ s3Location?: never;
123
+ $unknown: [string, any];
124
+ }
125
+ /**
126
+ * @deprecated unused in schema-serde mode.
127
+ *
128
+ */
129
+ interface Visitor<T> {
130
+ bytes: (value: Uint8Array) => T;
131
+ s3Location: (value: S3Location) => T;
132
+ _: (name: string, value: any) => T;
133
+ }
134
+ }
135
+ /**
136
+ * <p>Image content for an invocation step.</p>
137
+ * @public
138
+ */
139
+ export interface ImageBlock {
140
+ /**
141
+ * <p>The format of the image.</p>
142
+ * @public
143
+ */
144
+ format: ImageFormat | undefined;
145
+ /**
146
+ * <p>The source for the image.</p>
147
+ * @public
148
+ */
149
+ source: ImageSource | undefined;
150
+ }
151
+ /**
152
+ * <p>A block of content that you pass to, or receive from, a Amazon Bedrock session in an invocation step. You pass the content to a session in the <code>payLoad</code> of the <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_PutInvocationStep.html">PutInvocationStep</a> API operation. You retrieve the content with the <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_GetInvocationStep.html">GetInvocationStep</a> API operation.</p> <p>For more information about sessions, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/sessions.html">Store and retrieve conversation history and context with Amazon Bedrock sessions</a>.</p>
153
+ * @public
154
+ */
155
+ export type BedrockSessionContentBlock = BedrockSessionContentBlock.ImageMember | BedrockSessionContentBlock.TextMember | BedrockSessionContentBlock.$UnknownMember;
156
+ /**
157
+ * @public
158
+ */
159
+ export declare namespace BedrockSessionContentBlock {
160
+ /**
161
+ * <p>The text in the invocation step.</p>
162
+ * @public
163
+ */
164
+ interface TextMember {
165
+ text: string;
166
+ image?: never;
167
+ $unknown?: never;
168
+ }
169
+ /**
170
+ * <p>The image in the invocation step.</p>
171
+ * @public
172
+ */
173
+ interface ImageMember {
174
+ text?: never;
175
+ image: ImageBlock;
176
+ $unknown?: never;
177
+ }
178
+ /**
179
+ * @public
180
+ */
181
+ interface $UnknownMember {
182
+ text?: never;
183
+ image?: never;
184
+ $unknown: [string, any];
185
+ }
186
+ /**
187
+ * @deprecated unused in schema-serde mode.
188
+ *
189
+ */
190
+ interface Visitor<T> {
191
+ text: (value: string) => T;
192
+ image: (value: ImageBlock) => T;
193
+ _: (name: string, value: any) => T;
194
+ }
195
+ }
196
+ /**
197
+ * <p>Payload content, such as text and images, for the invocation step.</p>
198
+ * @public
199
+ */
200
+ export type InvocationStepPayload = InvocationStepPayload.ContentBlocksMember | InvocationStepPayload.$UnknownMember;
201
+ /**
202
+ * @public
203
+ */
204
+ export declare namespace InvocationStepPayload {
205
+ /**
206
+ * <p>The content for the invocation step.</p>
207
+ * @public
208
+ */
209
+ interface ContentBlocksMember {
210
+ contentBlocks: BedrockSessionContentBlock[];
211
+ $unknown?: never;
212
+ }
213
+ /**
214
+ * @public
215
+ */
216
+ interface $UnknownMember {
217
+ contentBlocks?: never;
218
+ $unknown: [string, any];
219
+ }
220
+ /**
221
+ * @deprecated unused in schema-serde mode.
222
+ *
223
+ */
224
+ interface Visitor<T> {
225
+ contentBlocks: (value: BedrockSessionContentBlock[]) => T;
226
+ _: (name: string, value: any) => T;
227
+ }
228
+ }
229
+ /**
230
+ * <p>Stores fine-grained state checkpoints, including text and images, for each interaction in an invocation in a session. For more information about sessions, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/sessions.html">Store and retrieve conversation history and context with Amazon Bedrock sessions</a>. </p>
231
+ * @public
232
+ */
233
+ export interface InvocationStep {
234
+ /**
235
+ * <p>The unique identifier of the session containing the invocation step.</p>
236
+ * @public
237
+ */
238
+ sessionId: string | undefined;
239
+ /**
240
+ * <p>The unique identifier (in UUID format) for the invocation that includes the invocation step.</p>
241
+ * @public
242
+ */
243
+ invocationId: string | undefined;
244
+ /**
245
+ * <p>The unique identifier (in UUID format) for the invocation step.</p>
246
+ * @public
247
+ */
248
+ invocationStepId: string | undefined;
249
+ /**
250
+ * <p>The timestamp for when the invocation step was created.</p>
251
+ * @public
252
+ */
253
+ invocationStepTime: Date | undefined;
254
+ /**
255
+ * <p>Payload content, such as text and images, for the invocation step.</p>
256
+ * @public
257
+ */
258
+ payload: InvocationStepPayload | undefined;
259
+ }
260
+ /**
261
+ * @public
262
+ */
263
+ export interface GetInvocationStepResponse {
264
+ /**
265
+ * <p>The complete details of the requested invocation step.</p>
266
+ * @public
267
+ */
268
+ invocationStep: InvocationStep | undefined;
269
+ }
270
+ /**
271
+ * @public
272
+ */
273
+ export interface ListInvocationStepsRequest {
274
+ /**
275
+ * <p>The unique identifier (in UUID format) for the invocation to list invocation steps for.</p>
276
+ * @public
277
+ */
278
+ invocationIdentifier?: string | undefined;
279
+ /**
280
+ * <p>If the total number of results is greater than the <code>maxResults</code> value provided in the request, enter the token returned in the <code>nextToken</code> field in the response in this field to return the next batch of results. </p>
281
+ * @public
282
+ */
283
+ nextToken?: string | undefined;
284
+ /**
285
+ * <p>The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the <code>nextToken</code> field when making another request to return the next batch of results.</p>
286
+ * @public
287
+ */
288
+ maxResults?: number | undefined;
289
+ /**
290
+ * <p>The unique identifier for the session associated with the invocation steps. You can specify either the session's <code>sessionId</code> or its Amazon Resource Name (ARN).</p>
291
+ * @public
292
+ */
293
+ sessionIdentifier: string | undefined;
294
+ }
295
+ /**
296
+ * <p>Contains details about an invocation step within an invocation in a session. For more information about sessions, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/sessions.html">Store and retrieve conversation history and context with Amazon Bedrock sessions</a>.</p>
297
+ * @public
298
+ */
299
+ export interface InvocationStepSummary {
300
+ /**
301
+ * <p>The unique identifier for the session associated with the invocation step.</p>
302
+ * @public
303
+ */
304
+ sessionId: string | undefined;
305
+ /**
306
+ * <p>A unique identifier for the invocation in UUID format.</p>
307
+ * @public
308
+ */
309
+ invocationId: string | undefined;
310
+ /**
311
+ * <p>The unique identifier (in UUID format) for the invocation step.</p>
312
+ * @public
313
+ */
314
+ invocationStepId: string | undefined;
315
+ /**
316
+ * <p>The timestamp for when the invocation step was created.</p>
317
+ * @public
318
+ */
319
+ invocationStepTime: Date | undefined;
320
+ }
321
+ /**
322
+ * @public
323
+ */
324
+ export interface ListInvocationStepsResponse {
325
+ /**
326
+ * <p>A list of summaries for each invocation step associated with a session and if you specified it, an invocation within the session.</p>
327
+ * @public
328
+ */
329
+ invocationStepSummaries: InvocationStepSummary[] | undefined;
330
+ /**
331
+ * <p>If the total number of results is greater than the <code>maxResults</code> value provided in the request, use this token when making another request in the <code>nextToken</code> field to return the next batch of results.</p>
332
+ * @public
333
+ */
334
+ nextToken?: string | undefined;
335
+ }
336
+ /**
337
+ * @public
338
+ */
339
+ export interface PutInvocationStepRequest {
340
+ /**
341
+ * <p>The unique identifier for the session to add the invocation step to. You can specify either the session's <code>sessionId</code> or its Amazon Resource Name (ARN).</p>
342
+ * @public
343
+ */
344
+ sessionIdentifier: string | undefined;
345
+ /**
346
+ * <p>The unique identifier (in UUID format) of the invocation to add the invocation step to.</p>
347
+ * @public
348
+ */
349
+ invocationIdentifier: string | undefined;
350
+ /**
351
+ * <p>The timestamp for when the invocation step occurred.</p>
352
+ * @public
353
+ */
354
+ invocationStepTime: Date | undefined;
355
+ /**
356
+ * <p>The payload for the invocation step, including text and images for the interaction.</p>
357
+ * @public
358
+ */
359
+ payload: InvocationStepPayload | undefined;
360
+ /**
361
+ * <p>The unique identifier of the invocation step in UUID format.</p>
362
+ * @public
363
+ */
364
+ invocationStepId?: string | undefined;
365
+ }
366
+ /**
367
+ * @public
368
+ */
369
+ export interface PutInvocationStepResponse {
370
+ /**
371
+ * <p>The unique identifier of the invocation step in UUID format.</p>
372
+ * @public
373
+ */
374
+ invocationStepId: string | undefined;
375
+ }
376
+ /**
377
+ * @public
378
+ */
379
+ export interface ListSessionsRequest {
380
+ /**
381
+ * <p>The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the <code>nextToken</code> field when making another request to return the next batch of results.</p>
382
+ * @public
383
+ */
384
+ maxResults?: number | undefined;
385
+ /**
386
+ * <p>If the total number of results is greater than the <code>maxResults</code> value provided in the request, enter the token returned in the <code>nextToken</code> field in the response in this field to return the next batch of results. </p>
387
+ * @public
388
+ */
389
+ nextToken?: string | undefined;
390
+ }
391
+ /**
392
+ * <p>Contains details about a session. For more information about sessions, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/sessions.html">Store and retrieve conversation history and context with Amazon Bedrock sessions</a>.</p>
393
+ * @public
394
+ */
395
+ export interface SessionSummary {
396
+ /**
397
+ * <p>The unique identifier for the session.</p>
398
+ * @public
399
+ */
400
+ sessionId: string | undefined;
401
+ /**
402
+ * <p>The Amazon Resource Name (ARN) of the session.</p>
403
+ * @public
404
+ */
405
+ sessionArn: string | undefined;
406
+ /**
407
+ * <p>The current status of the session.</p>
408
+ * @public
409
+ */
410
+ sessionStatus: SessionStatus | undefined;
411
+ /**
412
+ * <p>The timestamp for when the session was created.</p>
413
+ * @public
414
+ */
415
+ createdAt: Date | undefined;
416
+ /**
417
+ * <p>The timestamp for when the session was last modified.</p>
418
+ * @public
419
+ */
420
+ lastUpdatedAt: Date | undefined;
421
+ }
422
+ /**
423
+ * @public
424
+ */
425
+ export interface ListSessionsResponse {
426
+ /**
427
+ * <p>A list of summaries for each session in your Amazon Web Services account.</p>
428
+ * @public
429
+ */
430
+ sessionSummaries: SessionSummary[] | undefined;
431
+ /**
432
+ * <p>If the total number of results is greater than the <code>maxResults</code> value provided in the request, use this token when making another request in the <code>nextToken</code> field to return the next batch of results.</p>
433
+ * @public
434
+ */
435
+ nextToken?: string | undefined;
436
+ }
437
+ /**
438
+ * @public
439
+ */
440
+ export interface UpdateSessionRequest {
441
+ /**
442
+ * <p>A map of key-value pairs containing attributes to be persisted across the session. For example the user's ID, their language preference, and the type of device they are using.</p>
443
+ * @public
444
+ */
445
+ sessionMetadata?: Record<string, string> | undefined;
446
+ /**
447
+ * <p>The unique identifier of the session to modify. You can specify either the session's <code>sessionId</code> or its Amazon Resource Name (ARN).</p>
448
+ * @public
449
+ */
450
+ sessionIdentifier: string | undefined;
451
+ }
452
+ /**
453
+ * @public
454
+ */
455
+ export interface UpdateSessionResponse {
456
+ /**
457
+ * <p>The unique identifier of the session you updated.</p>
458
+ * @public
459
+ */
460
+ sessionId: string | undefined;
461
+ /**
462
+ * <p>The Amazon Resource Name (ARN) of the session that was updated.</p>
463
+ * @public
464
+ */
465
+ sessionArn: string | undefined;
466
+ /**
467
+ * <p>The status of the session you updated.</p>
468
+ * @public
469
+ */
470
+ sessionStatus: SessionStatus | undefined;
471
+ /**
472
+ * <p>The timestamp for when the session was created.</p>
473
+ * @public
474
+ */
475
+ createdAt: Date | undefined;
476
+ /**
477
+ * <p>The timestamp for when the session was last modified.</p>
478
+ * @public
479
+ */
480
+ lastUpdatedAt: Date | undefined;
481
+ }
482
+ /**
483
+ * @public
484
+ */
485
+ export interface ListTagsForResourceRequest {
486
+ /**
487
+ * <p>The Amazon Resource Name (ARN) of the resource for which to list tags.</p>
488
+ * @public
489
+ */
490
+ resourceArn: string | undefined;
491
+ }
492
+ /**
493
+ * @public
494
+ */
495
+ export interface ListTagsForResourceResponse {
496
+ /**
497
+ * <p>The key-value pairs for the tags associated with the resource.</p>
498
+ * @public
499
+ */
500
+ tags?: Record<string, string> | undefined;
501
+ }
502
+ /**
503
+ * @public
504
+ */
505
+ export interface TagResourceRequest {
506
+ /**
507
+ * <p>The Amazon Resource Name (ARN) of the resource to tag.</p>
508
+ * @public
509
+ */
510
+ resourceArn: string | undefined;
511
+ /**
512
+ * <p>An object containing key-value pairs that define the tags to attach to the resource.</p>
513
+ * @public
514
+ */
515
+ tags: Record<string, string> | undefined;
516
+ }
517
+ /**
518
+ * @public
519
+ */
520
+ export interface TagResourceResponse {
521
+ }
522
+ /**
523
+ * @public
524
+ */
525
+ export interface UntagResourceRequest {
526
+ /**
527
+ * <p>The Amazon Resource Name (ARN) of the resource from which to remove tags.</p>
528
+ * @public
529
+ */
530
+ resourceArn: string | undefined;
531
+ /**
532
+ * <p>A list of keys of the tags to remove from the resource.</p>
533
+ * @public
534
+ */
535
+ tagKeys: string[] | undefined;
536
+ }
537
+ /**
538
+ * @public
539
+ */
540
+ export interface UntagResourceResponse {
541
+ }
542
+ /**
543
+ * <p>Specifies the filters to use on the metadata attributes in the knowledge base data sources before returning results. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html">Query configurations</a>. See the examples below to see how to use these filters.</p> <p>This data type is used in the following API operations:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Retrieve.html#API_agent-runtime_Retrieve_RequestSyntax">Retrieve request</a> – in the <code>filter</code> field</p> </li> <li> <p> <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_RetrieveAndGenerate.html#API_agent-runtime_RetrieveAndGenerate_RequestSyntax">RetrieveAndGenerate request</a> – in the <code>filter</code> field</p> </li> </ul>
544
+ * @public
545
+ */
546
+ export type RetrievalFilter = RetrievalFilter.AndAllMember | RetrievalFilter.EqualsMember | RetrievalFilter.GreaterThanMember | RetrievalFilter.GreaterThanOrEqualsMember | RetrievalFilter.InMember | RetrievalFilter.LessThanMember | RetrievalFilter.LessThanOrEqualsMember | RetrievalFilter.ListContainsMember | RetrievalFilter.NotEqualsMember | RetrievalFilter.NotInMember | RetrievalFilter.OrAllMember | RetrievalFilter.StartsWithMember | RetrievalFilter.StringContainsMember | RetrievalFilter.$UnknownMember;
547
+ /**
548
+ * @public
549
+ */
550
+ export declare namespace RetrievalFilter {
551
+ /**
552
+ * <p>Knowledge base data sources are returned if they contain a metadata attribute whose name matches the <code>key</code> and whose value matches the <code>value</code> in this object.</p> <p>The following example would return data sources with an <code>animal</code> attribute whose value is <code>cat</code>:</p> <p> <code>"equals": \{ "key": "animal", "value": "cat" \}</code> </p>
553
+ * @public
554
+ */
555
+ interface EqualsMember {
556
+ equals: FilterAttribute;
557
+ notEquals?: never;
558
+ greaterThan?: never;
559
+ greaterThanOrEquals?: never;
560
+ lessThan?: never;
561
+ lessThanOrEquals?: never;
562
+ in?: never;
563
+ notIn?: never;
564
+ startsWith?: never;
565
+ listContains?: never;
566
+ stringContains?: never;
567
+ andAll?: never;
568
+ orAll?: never;
569
+ $unknown?: never;
570
+ }
571
+ /**
572
+ * <p>Knowledge base data sources are returned when:</p> <ul> <li> <p>It contains a metadata attribute whose name matches the <code>key</code> and whose value doesn't match the <code>value</code> in this object.</p> </li> <li> <p>The key is not present in the document.</p> </li> </ul> <p>The following example would return data sources that don't contain an <code>animal</code> attribute whose value is <code>cat</code>.</p> <p> <code>"notEquals": \{ "key": "animal", "value": "cat" \}</code> </p>
573
+ * @public
574
+ */
575
+ interface NotEqualsMember {
576
+ equals?: never;
577
+ notEquals: FilterAttribute;
578
+ greaterThan?: never;
579
+ greaterThanOrEquals?: never;
580
+ lessThan?: never;
581
+ lessThanOrEquals?: never;
582
+ in?: never;
583
+ notIn?: never;
584
+ startsWith?: never;
585
+ listContains?: never;
586
+ stringContains?: never;
587
+ andAll?: never;
588
+ orAll?: never;
589
+ $unknown?: never;
590
+ }
591
+ /**
592
+ * <p>Knowledge base data sources are returned if they contain a metadata attribute whose name matches the <code>key</code> and whose value is greater than the <code>value</code> in this object.</p> <p>The following example would return data sources with an <code>year</code> attribute whose value is greater than <code>1989</code>:</p> <p> <code>"greaterThan": \{ "key": "year", "value": 1989 \}</code> </p>
593
+ * @public
594
+ */
595
+ interface GreaterThanMember {
596
+ equals?: never;
597
+ notEquals?: never;
598
+ greaterThan: FilterAttribute;
599
+ greaterThanOrEquals?: never;
600
+ lessThan?: never;
601
+ lessThanOrEquals?: never;
602
+ in?: never;
603
+ notIn?: never;
604
+ startsWith?: never;
605
+ listContains?: never;
606
+ stringContains?: never;
607
+ andAll?: never;
608
+ orAll?: never;
609
+ $unknown?: never;
610
+ }
611
+ /**
612
+ * <p>Knowledge base data sources are returned if they contain a metadata attribute whose name matches the <code>key</code> and whose value is greater than or equal to the <code>value</code> in this object.</p> <p>The following example would return data sources with an <code>year</code> attribute whose value is greater than or equal to <code>1989</code>:</p> <p> <code>"greaterThanOrEquals": \{ "key": "year", "value": 1989 \}</code> </p>
613
+ * @public
614
+ */
615
+ interface GreaterThanOrEqualsMember {
616
+ equals?: never;
617
+ notEquals?: never;
618
+ greaterThan?: never;
619
+ greaterThanOrEquals: FilterAttribute;
620
+ lessThan?: never;
621
+ lessThanOrEquals?: never;
622
+ in?: never;
623
+ notIn?: never;
624
+ startsWith?: never;
625
+ listContains?: never;
626
+ stringContains?: never;
627
+ andAll?: never;
628
+ orAll?: never;
629
+ $unknown?: never;
630
+ }
631
+ /**
632
+ * <p>Knowledge base data sources are returned if they contain a metadata attribute whose name matches the <code>key</code> and whose value is less than the <code>value</code> in this object.</p> <p>The following example would return data sources with an <code>year</code> attribute whose value is less than to <code>1989</code>.</p> <p> <code>"lessThan": \{ "key": "year", "value": 1989 \}</code> </p>
633
+ * @public
634
+ */
635
+ interface LessThanMember {
636
+ equals?: never;
637
+ notEquals?: never;
638
+ greaterThan?: never;
639
+ greaterThanOrEquals?: never;
640
+ lessThan: FilterAttribute;
641
+ lessThanOrEquals?: never;
642
+ in?: never;
643
+ notIn?: never;
644
+ startsWith?: never;
645
+ listContains?: never;
646
+ stringContains?: never;
647
+ andAll?: never;
648
+ orAll?: never;
649
+ $unknown?: never;
650
+ }
651
+ /**
652
+ * <p>Knowledge base data sources are returned if they contain a metadata attribute whose name matches the <code>key</code> and whose value is less than or equal to the <code>value</code> in this object.</p> <p>The following example would return data sources with an <code>year</code> attribute whose value is less than or equal to <code>1989</code>.</p> <p> <code>"lessThanOrEquals": \{ "key": "year", "value": 1989 \}</code> </p>
653
+ * @public
654
+ */
655
+ interface LessThanOrEqualsMember {
656
+ equals?: never;
657
+ notEquals?: never;
658
+ greaterThan?: never;
659
+ greaterThanOrEquals?: never;
660
+ lessThan?: never;
661
+ lessThanOrEquals: FilterAttribute;
662
+ in?: never;
663
+ notIn?: never;
664
+ startsWith?: never;
665
+ listContains?: never;
666
+ stringContains?: never;
667
+ andAll?: never;
668
+ orAll?: never;
669
+ $unknown?: never;
670
+ }
671
+ /**
672
+ * <p>Knowledge base data sources are returned if they contain a metadata attribute whose name matches the <code>key</code> and whose value is in the list specified in the <code>value</code> in this object.</p> <p>The following example would return data sources with an <code>animal</code> attribute that is either <code>cat</code> or <code>dog</code>:</p> <p> <code>"in": \{ "key": "animal", "value": ["cat", "dog"] \}</code> </p>
673
+ * @public
674
+ */
675
+ interface InMember {
676
+ equals?: never;
677
+ notEquals?: never;
678
+ greaterThan?: never;
679
+ greaterThanOrEquals?: never;
680
+ lessThan?: never;
681
+ lessThanOrEquals?: never;
682
+ in: FilterAttribute;
683
+ notIn?: never;
684
+ startsWith?: never;
685
+ listContains?: never;
686
+ stringContains?: never;
687
+ andAll?: never;
688
+ orAll?: never;
689
+ $unknown?: never;
690
+ }
691
+ /**
692
+ * <p>Knowledge base data sources are returned if they contain a metadata attribute whose name matches the <code>key</code> and whose value isn't in the list specified in the <code>value</code> in this object.</p> <p>The following example would return data sources whose <code>animal</code> attribute is neither <code>cat</code> nor <code>dog</code>.</p> <p> <code>"notIn": \{ "key": "animal", "value": ["cat", "dog"] \}</code> </p>
693
+ * @public
694
+ */
695
+ interface NotInMember {
696
+ equals?: never;
697
+ notEquals?: never;
698
+ greaterThan?: never;
699
+ greaterThanOrEquals?: never;
700
+ lessThan?: never;
701
+ lessThanOrEquals?: never;
702
+ in?: never;
703
+ notIn: FilterAttribute;
704
+ startsWith?: never;
705
+ listContains?: never;
706
+ stringContains?: never;
707
+ andAll?: never;
708
+ orAll?: never;
709
+ $unknown?: never;
710
+ }
711
+ /**
712
+ * <p>Knowledge base data sources are returned if they contain a metadata attribute whose name matches the <code>key</code> and whose value starts with the <code>value</code> in this object. This filter is currently only supported for Amazon OpenSearch Serverless vector stores.</p> <p>The following example would return data sources with an <code>animal</code> attribute starts with <code>ca</code> (for example, <code>cat</code> or <code>camel</code>).</p> <p> <code>"startsWith": \{ "key": "animal", "value": "ca" \}</code> </p>
713
+ * @public
714
+ */
715
+ interface StartsWithMember {
716
+ equals?: never;
717
+ notEquals?: never;
718
+ greaterThan?: never;
719
+ greaterThanOrEquals?: never;
720
+ lessThan?: never;
721
+ lessThanOrEquals?: never;
722
+ in?: never;
723
+ notIn?: never;
724
+ startsWith: FilterAttribute;
725
+ listContains?: never;
726
+ stringContains?: never;
727
+ andAll?: never;
728
+ orAll?: never;
729
+ $unknown?: never;
730
+ }
731
+ /**
732
+ * <p>Knowledge base data sources are returned if they contain a metadata attribute whose name matches the <code>key</code> and whose value is a list that contains the <code>value</code> as one of its members.</p> <p>The following example would return data sources with an <code>animals</code> attribute that is a list containing a <code>cat</code> member (for example <code>["dog", "cat"]</code>).</p> <p> <code>"listContains": \{ "key": "animals", "value": "cat" \}</code> </p>
733
+ * @public
734
+ */
735
+ interface ListContainsMember {
736
+ equals?: never;
737
+ notEquals?: never;
738
+ greaterThan?: never;
739
+ greaterThanOrEquals?: never;
740
+ lessThan?: never;
741
+ lessThanOrEquals?: never;
742
+ in?: never;
743
+ notIn?: never;
744
+ startsWith?: never;
745
+ listContains: FilterAttribute;
746
+ stringContains?: never;
747
+ andAll?: never;
748
+ orAll?: never;
749
+ $unknown?: never;
750
+ }
751
+ /**
752
+ * <p>Knowledge base data sources are returned if they contain a metadata attribute whose name matches the <code>key</code> and whose value is one of the following:</p> <ul> <li> <p>A string that contains the <code>value</code> as a substring. The following example would return data sources with an <code>animal</code> attribute that contains the substring <code>at</code> (for example <code>cat</code>).</p> <p> <code>"stringContains": \{ "key": "animal", "value": "at" \}</code> </p> </li> <li> <p>A list with a member that contains the <code>value</code> as a substring. The following example would return data sources with an <code>animals</code> attribute that is a list containing a member that contains the substring <code>at</code> (for example <code>["dog", "cat"]</code>).</p> <p> <code>"stringContains": \{ "key": "animals", "value": "at" \}</code> </p> </li> </ul>
753
+ * @public
754
+ */
755
+ interface StringContainsMember {
756
+ equals?: never;
757
+ notEquals?: never;
758
+ greaterThan?: never;
759
+ greaterThanOrEquals?: never;
760
+ lessThan?: never;
761
+ lessThanOrEquals?: never;
762
+ in?: never;
763
+ notIn?: never;
764
+ startsWith?: never;
765
+ listContains?: never;
766
+ stringContains: FilterAttribute;
767
+ andAll?: never;
768
+ orAll?: never;
769
+ $unknown?: never;
770
+ }
771
+ /**
772
+ * <p>Knowledge base data sources are returned if their metadata attributes fulfill all the filter conditions inside this list.</p>
773
+ * @public
774
+ */
775
+ interface AndAllMember {
776
+ equals?: never;
777
+ notEquals?: never;
778
+ greaterThan?: never;
779
+ greaterThanOrEquals?: never;
780
+ lessThan?: never;
781
+ lessThanOrEquals?: never;
782
+ in?: never;
783
+ notIn?: never;
784
+ startsWith?: never;
785
+ listContains?: never;
786
+ stringContains?: never;
787
+ andAll: RetrievalFilter[];
788
+ orAll?: never;
789
+ $unknown?: never;
790
+ }
791
+ /**
792
+ * <p>Knowledge base data sources are returned if their metadata attributes fulfill at least one of the filter conditions inside this list.</p>
793
+ * @public
794
+ */
795
+ interface OrAllMember {
796
+ equals?: never;
797
+ notEquals?: never;
798
+ greaterThan?: never;
799
+ greaterThanOrEquals?: never;
800
+ lessThan?: never;
801
+ lessThanOrEquals?: never;
802
+ in?: never;
803
+ notIn?: never;
804
+ startsWith?: never;
805
+ listContains?: never;
806
+ stringContains?: never;
807
+ andAll?: never;
808
+ orAll: RetrievalFilter[];
809
+ $unknown?: never;
810
+ }
811
+ /**
812
+ * @public
813
+ */
814
+ interface $UnknownMember {
815
+ equals?: never;
816
+ notEquals?: never;
817
+ greaterThan?: never;
818
+ greaterThanOrEquals?: never;
819
+ lessThan?: never;
820
+ lessThanOrEquals?: never;
821
+ in?: never;
822
+ notIn?: never;
823
+ startsWith?: never;
824
+ listContains?: never;
825
+ stringContains?: never;
826
+ andAll?: never;
827
+ orAll?: never;
828
+ $unknown: [string, any];
829
+ }
830
+ /**
831
+ * @deprecated unused in schema-serde mode.
832
+ *
833
+ */
834
+ interface Visitor<T> {
835
+ equals: (value: FilterAttribute) => T;
836
+ notEquals: (value: FilterAttribute) => T;
837
+ greaterThan: (value: FilterAttribute) => T;
838
+ greaterThanOrEquals: (value: FilterAttribute) => T;
839
+ lessThan: (value: FilterAttribute) => T;
840
+ lessThanOrEquals: (value: FilterAttribute) => T;
841
+ in: (value: FilterAttribute) => T;
842
+ notIn: (value: FilterAttribute) => T;
843
+ startsWith: (value: FilterAttribute) => T;
844
+ listContains: (value: FilterAttribute) => T;
845
+ stringContains: (value: FilterAttribute) => T;
846
+ andAll: (value: RetrievalFilter[]) => T;
847
+ orAll: (value: RetrievalFilter[]) => T;
848
+ _: (name: string, value: any) => T;
849
+ }
850
+ }
851
+ /**
852
+ * <p>Configurations for how to perform the search query and return results. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html">Query configurations</a>.</p> <p>This data type is used in the following API operations:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Retrieve.html#API_agent-runtime_Retrieve_RequestSyntax">Retrieve request</a> – in the <code>vectorSearchConfiguration</code> field</p> </li> <li> <p> <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_RetrieveAndGenerate.html#API_agent-runtime_RetrieveAndGenerate_RequestSyntax">RetrieveAndGenerate request</a> – in the <code>vectorSearchConfiguration</code> field</p> </li> </ul>
853
+ * @public
854
+ */
855
+ export interface KnowledgeBaseVectorSearchConfiguration {
856
+ /**
857
+ * <p>The number of source chunks to retrieve.</p>
858
+ * @public
859
+ */
860
+ numberOfResults?: number | undefined;
861
+ /**
862
+ * <p>By default, Amazon Bedrock decides a search strategy for you. If you're using an Amazon OpenSearch Serverless vector store that contains a filterable text field, you can specify whether to query the knowledge base with a <code>HYBRID</code> search using both vector embeddings and raw text, or <code>SEMANTIC</code> search using only vector embeddings. For other vector store configurations, only <code>SEMANTIC</code> search is available. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-test.html">Test a knowledge base</a>.</p>
863
+ * @public
864
+ */
865
+ overrideSearchType?: SearchType | undefined;
866
+ /**
867
+ * <p>Specifies the filters to use on the metadata in the knowledge base data sources before returning results. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html">Query configurations</a>.</p>
868
+ * @public
869
+ */
870
+ filter?: RetrievalFilter | undefined;
871
+ /**
872
+ * <p>Contains configurations for reranking the retrieved results. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/rerank.html">Improve the relevance of query responses with a reranker model</a>.</p>
873
+ * @public
874
+ */
875
+ rerankingConfiguration?: VectorSearchRerankingConfiguration | undefined;
876
+ /**
877
+ * <p>Settings for implicit filtering.</p>
878
+ * @public
879
+ */
880
+ implicitFilterConfiguration?: ImplicitFilterConfiguration | undefined;
881
+ }
882
+ /**
883
+ * <p>Configuration for managed search in a knowledge base. Managed search automatically determines the best search strategy based on your data store configuration.</p>
884
+ * @public
885
+ */
886
+ export interface ManagedSearchConfiguration {
887
+ /**
888
+ * <p>The number of results to retrieve.</p>
889
+ * @public
890
+ */
891
+ numberOfResults?: number | undefined;
892
+ /**
893
+ * <p>Specifies the filters to use on the metadata attributes in the knowledge base data sources before returning results. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html">Query configurations</a>. See the examples below to see how to use these filters.</p> <p>This data type is used in the following API operations:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Retrieve.html#API_agent-runtime_Retrieve_RequestSyntax">Retrieve request</a> – in the <code>filter</code> field</p> </li> <li> <p> <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_RetrieveAndGenerate.html#API_agent-runtime_RetrieveAndGenerate_RequestSyntax">RetrieveAndGenerate request</a> – in the <code>filter</code> field</p> </li> </ul>
894
+ * @public
895
+ */
896
+ filter?: RetrievalFilter | undefined;
897
+ /**
898
+ * <p>The type of reranking model to use when reranking results retrieved from the managed search. Use <code>CUSTOM</code> to specify a model, <code>MANAGED</code> to use the service default, or <code>NONE</code> to disable reranking.</p>
899
+ * @public
900
+ */
901
+ rerankingModelType?: RerankingModelType | undefined;
902
+ /**
903
+ * <p>Contains configurations for reranking the results retrieved from the managed search.</p>
904
+ * @public
905
+ */
906
+ rerankingConfiguration?: ManagedSearchRerankingConfiguration | undefined;
907
+ }
908
+ /**
909
+ * <p>Overrides for retrieval behavior.</p>
910
+ * @public
911
+ */
912
+ export interface RetrievalOverrides {
913
+ /**
914
+ * <p>A filter to apply to the retrieval results.</p>
915
+ * @public
916
+ */
917
+ filter?: RetrievalFilter | undefined;
918
+ /**
919
+ * <p>The maximum number of results to return.</p>
920
+ * @public
921
+ */
922
+ maxNumberOfResults?: number | undefined;
923
+ }
924
+ /**
925
+ * <p>Configuration for retrieving from a Bedrock knowledge base.</p>
926
+ * @public
927
+ */
928
+ export interface KnowledgeBaseRetrieverConfiguration {
929
+ /**
930
+ * <p>The unique identifier of the knowledge base.</p>
931
+ * @public
932
+ */
933
+ knowledgeBaseId: string | undefined;
934
+ /**
935
+ * <p>Overrides for retrieval behavior such as filters and result limits.</p>
936
+ * @public
937
+ */
938
+ retrievalOverrides?: RetrievalOverrides | undefined;
939
+ }
940
+ /**
941
+ * <p>Configuration for a retriever, specified as a union of retriever types.</p>
942
+ * @public
943
+ */
944
+ export type RetrieverConfiguration = RetrieverConfiguration.KnowledgeBaseMember | RetrieverConfiguration.$UnknownMember;
945
+ /**
946
+ * @public
947
+ */
948
+ export declare namespace RetrieverConfiguration {
949
+ /**
950
+ * <p>Configuration for a knowledge base retriever.</p>
951
+ * @public
952
+ */
953
+ interface KnowledgeBaseMember {
954
+ knowledgeBase: KnowledgeBaseRetrieverConfiguration;
955
+ $unknown?: never;
956
+ }
957
+ /**
958
+ * @public
959
+ */
960
+ interface $UnknownMember {
961
+ knowledgeBase?: never;
962
+ $unknown: [string, any];
963
+ }
964
+ /**
965
+ * @deprecated unused in schema-serde mode.
966
+ *
967
+ */
968
+ interface Visitor<T> {
969
+ knowledgeBase: (value: KnowledgeBaseRetrieverConfiguration) => T;
970
+ _: (name: string, value: any) => T;
971
+ }
972
+ }
973
+ /**
974
+ * <p>A retriever used in agentic retrieval.</p>
975
+ * @public
976
+ */
977
+ export interface AgenticRetriever {
978
+ /**
979
+ * <p>A description of the retriever's purpose.</p>
980
+ * @public
981
+ */
982
+ description?: string | undefined;
983
+ /**
984
+ * <p>The configuration for this retriever.</p>
985
+ * @public
986
+ */
987
+ configuration: RetrieverConfiguration | undefined;
988
+ }
989
+ /**
990
+ * <p>Request structure for the agentic retrieve stream operation.</p>
991
+ * @public
992
+ */
993
+ export interface AgenticRetrieveStreamRequest {
994
+ /**
995
+ * <p>The list of messages for the agentic retrieval conversation.</p>
996
+ * @public
997
+ */
998
+ messages: AgenticRetrieveMessage[] | undefined;
999
+ /**
1000
+ * <p>The list of retrievers to use for agentic retrieval.</p>
1001
+ * @public
1002
+ */
1003
+ retrievers: AgenticRetriever[] | undefined;
1004
+ /**
1005
+ * <p>Configuration settings for the agentic retrieval operation.</p>
1006
+ * @public
1007
+ */
1008
+ agenticRetrieveConfiguration: AgenticRetrieveConfiguration | undefined;
1009
+ /**
1010
+ * <p>Policy configuration for guardrails and content filtering.</p>
1011
+ * @public
1012
+ */
1013
+ policyConfiguration?: AgenticRetrievePolicyConfiguration | undefined;
1014
+ /**
1015
+ * <p>Opaque continuation token for paginated results.</p>
1016
+ * @public
1017
+ */
1018
+ nextToken?: string | undefined;
1019
+ /**
1020
+ * <p>Contains information about the user making the request. This is used for access control filtering to ensure that retrieval results only include documents the user is authorized to access.</p>
1021
+ * @public
1022
+ */
1023
+ userContext?: UserContext | undefined;
1024
+ /**
1025
+ * <p>Whether to generate a response based on the retrieved results.</p>
1026
+ * @public
1027
+ */
1028
+ generateResponse?: boolean | undefined;
1029
+ }
1030
+ /**
1031
+ * <p>Contains configurations for knowledge base query. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html">Query configurations</a>.</p> <p>This data type is used in the following API operations:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Retrieve.html#API_agent-runtime_Retrieve_RequestSyntax">Retrieve request</a> – in the <code>retrievalConfiguration</code> field</p> </li> <li> <p> <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_RetrieveAndGenerate.html#API_agent-runtime_RetrieveAndGenerate_RequestSyntax">RetrieveAndGenerate request</a> – in the <code>retrievalConfiguration</code> field</p> </li> </ul>
1032
+ * @public
1033
+ */
1034
+ export interface KnowledgeBaseRetrievalConfiguration {
1035
+ /**
1036
+ * <p>Contains details about how the results from the vector search should be returned. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html">Query configurations</a>.</p>
1037
+ * @public
1038
+ */
1039
+ vectorSearchConfiguration?: KnowledgeBaseVectorSearchConfiguration | undefined;
1040
+ /**
1041
+ * <p>Contains configurations for managed search. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html">Query configurations</a>.</p>
1042
+ * @public
1043
+ */
1044
+ managedSearchConfiguration?: ManagedSearchConfiguration | undefined;
1045
+ }
1046
+ /**
1047
+ * <p> Details of the knowledge base associated withe inline agent. </p>
1048
+ * @public
1049
+ */
1050
+ export interface KnowledgeBase {
1051
+ /**
1052
+ * <p> The unique identifier for a knowledge base associated with the inline agent. </p>
1053
+ * @public
1054
+ */
1055
+ knowledgeBaseId: string | undefined;
1056
+ /**
1057
+ * <p> The description of the knowledge base associated with the inline agent. </p>
1058
+ * @public
1059
+ */
1060
+ description: string | undefined;
1061
+ /**
1062
+ * <p> 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>. </p>
1063
+ * @public
1064
+ */
1065
+ retrievalConfiguration?: KnowledgeBaseRetrievalConfiguration | undefined;
1066
+ }
1067
+ /**
1068
+ * <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>
1069
+ * @public
1070
+ */
1071
+ export interface KnowledgeBaseConfiguration {
1072
+ /**
1073
+ * <p>The unique identifier for a knowledge base attached to the agent.</p>
1074
+ * @public
1075
+ */
1076
+ knowledgeBaseId: string | undefined;
1077
+ /**
1078
+ * <p>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>.</p>
1079
+ * @public
1080
+ */
1081
+ retrievalConfiguration: KnowledgeBaseRetrievalConfiguration | undefined;
1082
+ }
1083
+ /**
1084
+ * <p>Contains details about the resource being queried.</p> <p>This data type is used in the following API operations:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Retrieve.html#API_agent-runtime_Retrieve_RequestSyntax">Retrieve request</a> – in the <code>knowledgeBaseConfiguration</code> field</p> </li> <li> <p> <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_RetrieveAndGenerate.html#API_agent-runtime_RetrieveAndGenerate_RequestSyntax">RetrieveAndGenerate request</a> – in the <code>knowledgeBaseConfiguration</code> field</p> </li> </ul>
1085
+ * @public
1086
+ */
1087
+ export interface KnowledgeBaseRetrieveAndGenerateConfiguration {
1088
+ /**
1089
+ * <p>The unique identifier of the knowledge base that is queried.</p>
1090
+ * @public
1091
+ */
1092
+ knowledgeBaseId: string | undefined;
1093
+ /**
1094
+ * <p>The ARN of the foundation model or <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/cross-region-inference.html">inference profile</a> used to generate a response.</p>
1095
+ * @public
1096
+ */
1097
+ modelArn: string | undefined;
1098
+ /**
1099
+ * <p>Contains configurations for how to retrieve and return the knowledge base query.</p>
1100
+ * @public
1101
+ */
1102
+ retrievalConfiguration?: KnowledgeBaseRetrievalConfiguration | undefined;
1103
+ /**
1104
+ * <p>Contains configurations for response generation based on the knowledge base query results.</p>
1105
+ * @public
1106
+ */
1107
+ generationConfiguration?: GenerationConfiguration | undefined;
1108
+ /**
1109
+ * <p>Settings for how the model processes the prompt prior to retrieval and generation.</p>
1110
+ * @public
1111
+ */
1112
+ orchestrationConfiguration?: OrchestrationConfiguration | undefined;
1113
+ }
1114
+ /**
1115
+ * @public
1116
+ */
1117
+ export interface RetrieveRequest {
1118
+ /**
1119
+ * <p>The unique identifier of the knowledge base to query.</p>
1120
+ * @public
1121
+ */
1122
+ knowledgeBaseId: string | undefined;
1123
+ /**
1124
+ * <p>Contains the query to send the knowledge base.</p>
1125
+ * @public
1126
+ */
1127
+ retrievalQuery: KnowledgeBaseQuery | undefined;
1128
+ /**
1129
+ * <p>Contains configurations for the knowledge base query and retrieval process. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html">Query configurations</a>.</p>
1130
+ * @public
1131
+ */
1132
+ retrievalConfiguration?: KnowledgeBaseRetrievalConfiguration | undefined;
1133
+ /**
1134
+ * <p>Guardrail settings.</p>
1135
+ * @public
1136
+ */
1137
+ guardrailConfiguration?: GuardrailConfiguration | undefined;
1138
+ /**
1139
+ * <p>If there are more results than can fit in the response, the response returns a <code>nextToken</code>. Use this token in the <code>nextToken</code> field of another request to retrieve the next batch of results.</p>
1140
+ * @public
1141
+ */
1142
+ nextToken?: string | undefined;
1143
+ /**
1144
+ * <p>Contains information about the user making the request. Use this to pass user identity information for access control filtering, so that retrieval results only include documents the user is authorized to access.</p>
1145
+ * @public
1146
+ */
1147
+ userContext?: UserContext | undefined;
1148
+ }
1149
+ /**
1150
+ * <p>Contains details about the resource being queried.</p> <p>This data type is used in the following API operations:</p> <ul> <li> <p> <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_RetrieveAndGenerate.html#API_agent-runtime_RetrieveAndGenerate_RequestSyntax">RetrieveAndGenerate request</a> – in the <code>retrieveAndGenerateConfiguration</code> field</p> </li> </ul>
1151
+ * @public
1152
+ */
1153
+ export interface RetrieveAndGenerateConfiguration {
1154
+ /**
1155
+ * <p>The type of resource that contains your data for retrieving information and generating responses.</p> <note> <p>If you choose to use <code>EXTERNAL_SOURCES</code>, then currently only Anthropic Claude 3 Sonnet models for knowledge bases are supported.</p> </note>
1156
+ * @public
1157
+ */
1158
+ type: RetrieveAndGenerateType | undefined;
1159
+ /**
1160
+ * <p>Contains details about the knowledge base for retrieving information and generating responses.</p>
1161
+ * @public
1162
+ */
1163
+ knowledgeBaseConfiguration?: KnowledgeBaseRetrieveAndGenerateConfiguration | undefined;
1164
+ /**
1165
+ * <p>The configuration for the external source wrapper object in the <code>retrieveAndGenerate</code> function.</p>
1166
+ * @public
1167
+ */
1168
+ externalSourcesConfiguration?: ExternalSourcesRetrieveAndGenerateConfiguration | undefined;
1169
+ }
1170
+ /**
1171
+ * <p> List of inline collaborators. </p>
1172
+ * @public
1173
+ */
1174
+ export interface Collaborator {
1175
+ /**
1176
+ * <p> The Amazon Resource Name (ARN) of the AWS KMS key that encrypts the inline collaborator. </p>
1177
+ * @public
1178
+ */
1179
+ customerEncryptionKeyArn?: string | undefined;
1180
+ /**
1181
+ * <p> The foundation model used by the inline collaborator agent. </p>
1182
+ * @public
1183
+ */
1184
+ foundationModel: string | undefined;
1185
+ /**
1186
+ * <p> Instruction that tell the inline collaborator agent what it should do and how it should interact with users. </p>
1187
+ * @public
1188
+ */
1189
+ instruction: string | undefined;
1190
+ /**
1191
+ * <p> The number of seconds for which the Amazon Bedrock keeps information about the user's conversation with the inline collaborator agent.</p> <p>A user interaction remains active for the amount of time specified. If no conversation occurs during this time, the session expires and Amazon Bedrock deletes any data provided before the timeout. </p>
1192
+ * @public
1193
+ */
1194
+ idleSessionTTLInSeconds?: number | undefined;
1195
+ /**
1196
+ * <p> List of action groups with each action group defining tasks the inline collaborator agent needs to carry out. </p>
1197
+ * @public
1198
+ */
1199
+ actionGroups?: AgentActionGroup[] | undefined;
1200
+ /**
1201
+ * <p> Knowledge base associated with the inline collaborator agent. </p>
1202
+ * @public
1203
+ */
1204
+ knowledgeBases?: KnowledgeBase[] | undefined;
1205
+ /**
1206
+ * <p> Details of the guardwrail associated with the inline collaborator. </p>
1207
+ * @public
1208
+ */
1209
+ guardrailConfiguration?: GuardrailConfigurationWithArn | undefined;
1210
+ /**
1211
+ * <p> Contains configurations to override prompt templates in different parts of an inline collaborator sequence. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html">Advanced prompts</a>. </p>
1212
+ * @public
1213
+ */
1214
+ promptOverrideConfiguration?: PromptOverrideConfiguration | undefined;
1215
+ /**
1216
+ * <p> Defines how the inline supervisor agent handles information across multiple collaborator agents to coordinate a final response. </p>
1217
+ * @public
1218
+ */
1219
+ agentCollaboration?: AgentCollaboration | undefined;
1220
+ /**
1221
+ * <p> Settings of the collaborator agent. </p>
1222
+ * @public
1223
+ */
1224
+ collaboratorConfigurations?: CollaboratorConfiguration[] | undefined;
1225
+ /**
1226
+ * <p> Name of the inline collaborator agent which must be the same name as specified for <code>collaboratorName</code>. </p>
1227
+ * @public
1228
+ */
1229
+ agentName?: string | undefined;
1230
+ }
1231
+ /**
1232
+ * @public
1233
+ */
1234
+ export interface RetrieveAndGenerateRequest {
1235
+ /**
1236
+ * <p>The unique identifier of the session. When you first make a <code>RetrieveAndGenerate</code> request, Amazon Bedrock automatically generates this value. You must reuse this value for all subsequent requests in the same conversational session. This value allows Amazon Bedrock to maintain context and knowledge from previous interactions. You can't explicitly set the <code>sessionId</code> yourself.</p>
1237
+ * @public
1238
+ */
1239
+ sessionId?: string | undefined;
1240
+ /**
1241
+ * <p>Contains the query to be made to the knowledge base.</p>
1242
+ * @public
1243
+ */
1244
+ input: RetrieveAndGenerateInput | undefined;
1245
+ /**
1246
+ * <p>Contains configurations for the knowledge base query and retrieval process. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html">Query configurations</a>.</p>
1247
+ * @public
1248
+ */
1249
+ retrieveAndGenerateConfiguration?: RetrieveAndGenerateConfiguration | undefined;
1250
+ /**
1251
+ * <p>Contains details about the session with the knowledge base.</p>
1252
+ * @public
1253
+ */
1254
+ sessionConfiguration?: RetrieveAndGenerateSessionConfiguration | undefined;
1255
+ /**
1256
+ * <p>Contains information about the user making the request. Use this to pass user identity information for access control filtering, so that retrieval results only include documents the user is authorized to access.</p>
1257
+ * @public
1258
+ */
1259
+ userContext?: UserContext | undefined;
1260
+ }
1261
+ /**
1262
+ * @public
1263
+ */
1264
+ export interface RetrieveAndGenerateStreamRequest {
1265
+ /**
1266
+ * <p>The unique identifier of the session. When you first make a <code>RetrieveAndGenerate</code> request, Amazon Bedrock automatically generates this value. You must reuse this value for all subsequent requests in the same conversational session. This value allows Amazon Bedrock to maintain context and knowledge from previous interactions. You can't explicitly set the <code>sessionId</code> yourself.</p>
1267
+ * @public
1268
+ */
1269
+ sessionId?: string | undefined;
1270
+ /**
1271
+ * <p>Contains the query to be made to the knowledge base.</p>
1272
+ * @public
1273
+ */
1274
+ input: RetrieveAndGenerateInput | undefined;
1275
+ /**
1276
+ * <p>Contains configurations for the knowledge base query and retrieval process. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html">Query configurations</a>.</p>
1277
+ * @public
1278
+ */
1279
+ retrieveAndGenerateConfiguration?: RetrieveAndGenerateConfiguration | undefined;
1280
+ /**
1281
+ * <p>Contains details about the session with the knowledge base.</p>
1282
+ * @public
1283
+ */
1284
+ sessionConfiguration?: RetrieveAndGenerateSessionConfiguration | undefined;
1285
+ /**
1286
+ * <p>Contains information about the user making the request. Use this to pass user identity information for access control filtering, so that retrieval results only include documents the user is authorized to access.</p>
1287
+ * @public
1288
+ */
1289
+ userContext?: UserContext | undefined;
1290
+ }
1291
+ /**
1292
+ * <p>Contains parameters that specify various attributes that persist across a session or prompt. You can define session state 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 <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html">InvokeAgent</a> request. Use session state attributes to control and provide conversational context for your agent and to help customize your agent's behavior. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-session-state.html">Control session context</a>.</p>
1293
+ * @public
1294
+ */
1295
+ export interface SessionState {
1296
+ /**
1297
+ * <p>Contains attributes that persist across a session and the values of those attributes. If <code>sessionAttributes</code> are passed to a supervisor agent in <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-multi-agent-collaboration.html">multi-agent collaboration</a>, it will be forwarded to all agent collaborators.</p>
1298
+ * @public
1299
+ */
1300
+ sessionAttributes?: Record<string, string> | undefined;
1301
+ /**
1302
+ * <p>Contains attributes that persist across a prompt and the values of those attributes. </p> <ul> <li> <p>In orchestration prompt template, these attributes replace the $prompt_session_attributes$ placeholder variable. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-placeholders.html">Prompt template placeholder variables</a>.</p> </li> <li> <p>In <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-multi-agent-collaboration.html">multi-agent collaboration</a>, the <code>promptSessionAttributes</code> will only be used by supervisor agent when $prompt_session_attributes$ is present in prompt template. </p> </li> </ul>
1303
+ * @public
1304
+ */
1305
+ promptSessionAttributes?: Record<string, string> | undefined;
1306
+ /**
1307
+ * <p>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> and <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-session-state.html">Control session context</a>.</p> <note> <p>If you include this field, the <code>inputText</code> field will be ignored.</p> </note>
1308
+ * @public
1309
+ */
1310
+ returnControlInvocationResults?: InvocationResultMember[] | undefined;
1311
+ /**
1312
+ * <p>The identifier of the invocation of an action. This value must match the <code>invocationId</code> returned in the <code>InvokeAgent</code> response for the action 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> and <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-session-state.html">Control session context</a>.</p>
1313
+ * @public
1314
+ */
1315
+ invocationId?: string | undefined;
1316
+ /**
1317
+ * <p>Contains information about the files used by code interpreter.</p>
1318
+ * @public
1319
+ */
1320
+ files?: InputFile[] | undefined;
1321
+ /**
1322
+ * <p>An array of configurations, each of which applies to a knowledge base attached to the agent.</p>
1323
+ * @public
1324
+ */
1325
+ knowledgeBaseConfigurations?: KnowledgeBaseConfiguration[] | undefined;
1326
+ /**
1327
+ * <p>The state's conversation history.</p>
1328
+ * @public
1329
+ */
1330
+ conversationHistory?: ConversationHistory | undefined;
1331
+ }
1332
+ /**
1333
+ * @public
1334
+ */
1335
+ export interface InvokeAgentRequest {
1336
+ /**
1337
+ * <p>Contains parameters that specify various attributes of the session. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/agents-session-state.html">Control session context</a>.</p> <note> <p>If you include <code>returnControlInvocationResults</code> in the <code>sessionState</code> field, the <code>inputText</code> field will be ignored.</p> </note>
1338
+ * @public
1339
+ */
1340
+ sessionState?: SessionState | undefined;
1341
+ /**
1342
+ * <p>The unique identifier of the agent to use.</p>
1343
+ * @public
1344
+ */
1345
+ agentId: string | undefined;
1346
+ /**
1347
+ * <p>The alias of the agent to use.</p>
1348
+ * @public
1349
+ */
1350
+ agentAliasId: string | undefined;
1351
+ /**
1352
+ * <p>The unique identifier of the session. Use the same value across requests to continue the same conversation.</p>
1353
+ * @public
1354
+ */
1355
+ sessionId: string | undefined;
1356
+ /**
1357
+ * <p>Specifies whether to end the session with the agent or not.</p>
1358
+ * @public
1359
+ */
1360
+ endSession?: boolean | undefined;
1361
+ /**
1362
+ * <p>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/agents-test.html#trace-events">Trace enablement</a>.</p>
1363
+ * @public
1364
+ */
1365
+ enableTrace?: boolean | undefined;
1366
+ /**
1367
+ * <p>The prompt text to send the agent.</p> <note> <p>If you include <code>returnControlInvocationResults</code> in the <code>sessionState</code> field, the <code>inputText</code> field will be ignored.</p> </note>
1368
+ * @public
1369
+ */
1370
+ inputText?: string | undefined;
1371
+ /**
1372
+ * <p>The unique identifier of the agent memory.</p>
1373
+ * @public
1374
+ */
1375
+ memoryId?: string | undefined;
1376
+ /**
1377
+ * <p>Model performance settings for the request.</p>
1378
+ * @public
1379
+ */
1380
+ bedrockModelConfigurations?: BedrockModelConfigurations | undefined;
1381
+ /**
1382
+ * <p> Specifies the configurations for streaming. </p> <note> <p>To use agent streaming, you need permissions to perform the <code>bedrock:InvokeModelWithResponseStream</code> action.</p> </note>
1383
+ * @public
1384
+ */
1385
+ streamingConfigurations?: StreamingConfigurations | undefined;
1386
+ /**
1387
+ * <p>Specifies parameters that control how the service populates the agent prompt for an <code>InvokeAgent</code> request. You can control which aspects of previous invocations in the same agent session the service uses to populate the agent prompt. This gives you more granular control over the contextual history that is used to process the current request.</p>
1388
+ * @public
1389
+ */
1390
+ promptCreationConfigurations?: PromptCreationConfigurations | undefined;
1391
+ /**
1392
+ * <p>The ARN of the resource making the request.</p>
1393
+ * @public
1394
+ */
1395
+ sourceArn?: string | undefined;
1396
+ }
3
1397
  /**
4
1398
  * @public
5
1399
  */