@aws-sdk/client-bedrock-agent-runtime 3.461.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 (95) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +229 -0
  3. package/dist-cjs/BedrockAgentRuntime.js +17 -0
  4. package/dist-cjs/BedrockAgentRuntimeClient.js +45 -0
  5. package/dist-cjs/commands/InvokeAgentCommand.js +52 -0
  6. package/dist-cjs/commands/RetrieveAndGenerateCommand.js +52 -0
  7. package/dist-cjs/commands/RetrieveCommand.js +52 -0
  8. package/dist-cjs/commands/index.js +6 -0
  9. package/dist-cjs/endpoint/EndpointParameters.js +12 -0
  10. package/dist-cjs/endpoint/endpointResolver.js +12 -0
  11. package/dist-cjs/endpoint/ruleset.js +7 -0
  12. package/dist-cjs/extensionConfiguration.js +2 -0
  13. package/dist-cjs/index.js +12 -0
  14. package/dist-cjs/models/BedrockAgentRuntimeServiceException.js +12 -0
  15. package/dist-cjs/models/index.js +4 -0
  16. package/dist-cjs/models/models_0.js +439 -0
  17. package/dist-cjs/pagination/Interfaces.js +2 -0
  18. package/dist-cjs/pagination/RetrievePaginator.js +28 -0
  19. package/dist-cjs/pagination/index.js +5 -0
  20. package/dist-cjs/protocols/Aws_restJson1.js +689 -0
  21. package/dist-cjs/runtimeConfig.browser.js +41 -0
  22. package/dist-cjs/runtimeConfig.js +52 -0
  23. package/dist-cjs/runtimeConfig.native.js +15 -0
  24. package/dist-cjs/runtimeConfig.shared.js +24 -0
  25. package/dist-cjs/runtimeExtensions.js +22 -0
  26. package/dist-es/BedrockAgentRuntime.js +13 -0
  27. package/dist-es/BedrockAgentRuntimeClient.js +41 -0
  28. package/dist-es/commands/InvokeAgentCommand.js +48 -0
  29. package/dist-es/commands/RetrieveAndGenerateCommand.js +48 -0
  30. package/dist-es/commands/RetrieveCommand.js +48 -0
  31. package/dist-es/commands/index.js +3 -0
  32. package/dist-es/endpoint/EndpointParameters.js +8 -0
  33. package/dist-es/endpoint/endpointResolver.js +8 -0
  34. package/dist-es/endpoint/ruleset.js +4 -0
  35. package/dist-es/extensionConfiguration.js +1 -0
  36. package/dist-es/index.js +7 -0
  37. package/dist-es/models/BedrockAgentRuntimeServiceException.js +8 -0
  38. package/dist-es/models/index.js +1 -0
  39. package/dist-es/models/models_0.js +396 -0
  40. package/dist-es/pagination/Interfaces.js +1 -0
  41. package/dist-es/pagination/RetrievePaginator.js +24 -0
  42. package/dist-es/pagination/index.js +2 -0
  43. package/dist-es/protocols/Aws_restJson1.js +680 -0
  44. package/dist-es/runtimeConfig.browser.js +36 -0
  45. package/dist-es/runtimeConfig.js +47 -0
  46. package/dist-es/runtimeConfig.native.js +11 -0
  47. package/dist-es/runtimeConfig.shared.js +20 -0
  48. package/dist-es/runtimeExtensions.js +18 -0
  49. package/dist-types/BedrockAgentRuntime.d.ts +31 -0
  50. package/dist-types/BedrockAgentRuntimeClient.d.ts +177 -0
  51. package/dist-types/commands/InvokeAgentCommand.d.ts +321 -0
  52. package/dist-types/commands/RetrieveAndGenerateCommand.d.ts +142 -0
  53. package/dist-types/commands/RetrieveCommand.d.ts +123 -0
  54. package/dist-types/commands/index.d.ts +3 -0
  55. package/dist-types/endpoint/EndpointParameters.d.ts +22 -0
  56. package/dist-types/endpoint/endpointResolver.d.ts +5 -0
  57. package/dist-types/endpoint/ruleset.d.ts +2 -0
  58. package/dist-types/extensionConfiguration.d.ts +8 -0
  59. package/dist-types/index.d.ts +15 -0
  60. package/dist-types/models/BedrockAgentRuntimeServiceException.d.ts +13 -0
  61. package/dist-types/models/index.d.ts +1 -0
  62. package/dist-types/models/models_0.d.ts +1598 -0
  63. package/dist-types/pagination/Interfaces.d.ts +8 -0
  64. package/dist-types/pagination/RetrievePaginator.d.ts +7 -0
  65. package/dist-types/pagination/index.d.ts +2 -0
  66. package/dist-types/protocols/Aws_restJson1.d.ts +29 -0
  67. package/dist-types/runtimeConfig.browser.d.ts +47 -0
  68. package/dist-types/runtimeConfig.d.ts +47 -0
  69. package/dist-types/runtimeConfig.native.d.ts +46 -0
  70. package/dist-types/runtimeConfig.shared.d.ts +19 -0
  71. package/dist-types/runtimeExtensions.d.ts +17 -0
  72. package/dist-types/ts3.4/BedrockAgentRuntime.d.ts +58 -0
  73. package/dist-types/ts3.4/BedrockAgentRuntimeClient.d.ts +147 -0
  74. package/dist-types/ts3.4/commands/InvokeAgentCommand.d.ts +35 -0
  75. package/dist-types/ts3.4/commands/RetrieveAndGenerateCommand.d.ts +39 -0
  76. package/dist-types/ts3.4/commands/RetrieveCommand.d.ts +35 -0
  77. package/dist-types/ts3.4/commands/index.d.ts +3 -0
  78. package/dist-types/ts3.4/endpoint/EndpointParameters.d.ts +33 -0
  79. package/dist-types/ts3.4/endpoint/endpointResolver.d.ts +8 -0
  80. package/dist-types/ts3.4/endpoint/ruleset.d.ts +2 -0
  81. package/dist-types/ts3.4/extensionConfiguration.d.ts +7 -0
  82. package/dist-types/ts3.4/index.d.ts +10 -0
  83. package/dist-types/ts3.4/models/BedrockAgentRuntimeServiceException.d.ts +8 -0
  84. package/dist-types/ts3.4/models/index.d.ts +1 -0
  85. package/dist-types/ts3.4/models/models_0.d.ts +737 -0
  86. package/dist-types/ts3.4/pagination/Interfaces.d.ts +6 -0
  87. package/dist-types/ts3.4/pagination/RetrievePaginator.d.ts +11 -0
  88. package/dist-types/ts3.4/pagination/index.d.ts +2 -0
  89. package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +44 -0
  90. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +100 -0
  91. package/dist-types/ts3.4/runtimeConfig.d.ts +100 -0
  92. package/dist-types/ts3.4/runtimeConfig.native.d.ts +91 -0
  93. package/dist-types/ts3.4/runtimeConfig.shared.d.ts +21 -0
  94. package/dist-types/ts3.4/runtimeExtensions.d.ts +13 -0
  95. package/package.json +105 -0
@@ -0,0 +1,737 @@
1
+ import { ExceptionOptionType as __ExceptionOptionType } from "@smithy/smithy-client";
2
+ import { BedrockAgentRuntimeServiceException as __BaseException } from "./BedrockAgentRuntimeServiceException";
3
+ export declare class AccessDeniedException extends __BaseException {
4
+ readonly name: "AccessDeniedException";
5
+ readonly $fault: "client";
6
+ constructor(
7
+ opts: __ExceptionOptionType<AccessDeniedException, __BaseException>
8
+ );
9
+ }
10
+ export interface Parameter {
11
+ name?: string;
12
+ type?: string;
13
+ value?: string;
14
+ }
15
+ export interface RequestBody {
16
+ content?: Record<string, Parameter[]>;
17
+ }
18
+ export interface ActionGroupInvocationInput {
19
+ actionGroupName?: string;
20
+ verb?: string;
21
+ apiPath?: string;
22
+ parameters?: Parameter[];
23
+ requestBody?: RequestBody;
24
+ }
25
+ export interface ActionGroupInvocationOutput {
26
+ text?: string;
27
+ }
28
+ export declare class BadGatewayException extends __BaseException {
29
+ readonly name: "BadGatewayException";
30
+ readonly $fault: "server";
31
+ resourceName?: string;
32
+ constructor(
33
+ opts: __ExceptionOptionType<BadGatewayException, __BaseException>
34
+ );
35
+ }
36
+ export declare class ConflictException extends __BaseException {
37
+ readonly name: "ConflictException";
38
+ readonly $fault: "client";
39
+ constructor(opts: __ExceptionOptionType<ConflictException, __BaseException>);
40
+ }
41
+ export declare class DependencyFailedException extends __BaseException {
42
+ readonly name: "DependencyFailedException";
43
+ readonly $fault: "client";
44
+ resourceName?: string;
45
+ constructor(
46
+ opts: __ExceptionOptionType<DependencyFailedException, __BaseException>
47
+ );
48
+ }
49
+ export declare class InternalServerException extends __BaseException {
50
+ readonly name: "InternalServerException";
51
+ readonly $fault: "server";
52
+ constructor(
53
+ opts: __ExceptionOptionType<InternalServerException, __BaseException>
54
+ );
55
+ }
56
+ export interface SessionState {
57
+ sessionAttributes?: Record<string, string>;
58
+ promptSessionAttributes?: Record<string, string>;
59
+ }
60
+ export interface InvokeAgentRequest {
61
+ sessionState?: SessionState;
62
+ agentId: string | undefined;
63
+ agentAliasId: string | undefined;
64
+ sessionId: string | undefined;
65
+ endSession?: boolean;
66
+ enableTrace?: boolean;
67
+ inputText: string | undefined;
68
+ }
69
+ export interface Span {
70
+ start?: number;
71
+ end?: number;
72
+ }
73
+ export interface TextResponsePart {
74
+ text?: string;
75
+ span?: Span;
76
+ }
77
+ export interface GeneratedResponsePart {
78
+ textResponsePart?: TextResponsePart;
79
+ }
80
+ export interface RetrievalResultContent {
81
+ text: string | undefined;
82
+ }
83
+ export interface RetrievalResultS3Location {
84
+ uri?: string;
85
+ }
86
+ export declare const RetrievalResultLocationType: {
87
+ readonly S3: "S3";
88
+ };
89
+ export type RetrievalResultLocationType =
90
+ (typeof RetrievalResultLocationType)[keyof typeof RetrievalResultLocationType];
91
+ export interface RetrievalResultLocation {
92
+ type: RetrievalResultLocationType | undefined;
93
+ s3Location?: RetrievalResultS3Location;
94
+ }
95
+ export interface RetrievedReference {
96
+ content?: RetrievalResultContent;
97
+ location?: RetrievalResultLocation;
98
+ }
99
+ export interface Citation {
100
+ generatedResponsePart?: GeneratedResponsePart;
101
+ retrievedReferences?: RetrievedReference[];
102
+ }
103
+ export interface Attribution {
104
+ citations?: Citation[];
105
+ }
106
+ export interface PayloadPart {
107
+ bytes?: Uint8Array;
108
+ attribution?: Attribution;
109
+ }
110
+ export declare class ResourceNotFoundException extends __BaseException {
111
+ readonly name: "ResourceNotFoundException";
112
+ readonly $fault: "client";
113
+ constructor(
114
+ opts: __ExceptionOptionType<ResourceNotFoundException, __BaseException>
115
+ );
116
+ }
117
+ export declare class ServiceQuotaExceededException extends __BaseException {
118
+ readonly name: "ServiceQuotaExceededException";
119
+ readonly $fault: "client";
120
+ constructor(
121
+ opts: __ExceptionOptionType<ServiceQuotaExceededException, __BaseException>
122
+ );
123
+ }
124
+ export declare class ThrottlingException extends __BaseException {
125
+ readonly name: "ThrottlingException";
126
+ readonly $fault: "client";
127
+ constructor(
128
+ opts: __ExceptionOptionType<ThrottlingException, __BaseException>
129
+ );
130
+ }
131
+ export interface FailureTrace {
132
+ traceId?: string;
133
+ failureReason?: string;
134
+ }
135
+ export declare const InvocationType: {
136
+ readonly ACTION_GROUP: "ACTION_GROUP";
137
+ readonly FINISH: "FINISH";
138
+ readonly KNOWLEDGE_BASE: "KNOWLEDGE_BASE";
139
+ };
140
+ export type InvocationType =
141
+ (typeof InvocationType)[keyof typeof InvocationType];
142
+ export interface KnowledgeBaseLookupInput {
143
+ text?: string;
144
+ knowledgeBaseId?: string;
145
+ }
146
+ export interface InvocationInput {
147
+ traceId?: string;
148
+ invocationType?: InvocationType;
149
+ actionGroupInvocationInput?: ActionGroupInvocationInput;
150
+ knowledgeBaseLookupInput?: KnowledgeBaseLookupInput;
151
+ }
152
+ export interface InferenceConfiguration {
153
+ temperature?: number;
154
+ topP?: number;
155
+ topK?: number;
156
+ maximumLength?: number;
157
+ stopSequences?: string[];
158
+ }
159
+ export declare const CreationMode: {
160
+ readonly DEFAULT: "DEFAULT";
161
+ readonly OVERRIDDEN: "OVERRIDDEN";
162
+ };
163
+ export type CreationMode = (typeof CreationMode)[keyof typeof CreationMode];
164
+ export declare const PromptType: {
165
+ readonly KNOWLEDGE_BASE_RESPONSE_GENERATION: "KNOWLEDGE_BASE_RESPONSE_GENERATION";
166
+ readonly ORCHESTRATION: "ORCHESTRATION";
167
+ readonly POST_PROCESSING: "POST_PROCESSING";
168
+ readonly PRE_PROCESSING: "PRE_PROCESSING";
169
+ };
170
+ export type PromptType = (typeof PromptType)[keyof typeof PromptType];
171
+ export interface ModelInvocationInput {
172
+ traceId?: string;
173
+ text?: string;
174
+ type?: PromptType;
175
+ inferenceConfiguration?: InferenceConfiguration;
176
+ overrideLambda?: string;
177
+ promptCreationMode?: CreationMode;
178
+ parserMode?: CreationMode;
179
+ }
180
+ export interface FinalResponse {
181
+ text?: string;
182
+ }
183
+ export interface KnowledgeBaseLookupOutput {
184
+ retrievedReferences?: RetrievedReference[];
185
+ }
186
+ export declare const Source: {
187
+ readonly ACTION_GROUP: "ACTION_GROUP";
188
+ readonly KNOWLEDGE_BASE: "KNOWLEDGE_BASE";
189
+ readonly PARSER: "PARSER";
190
+ };
191
+ export type Source = (typeof Source)[keyof typeof Source];
192
+ export interface RepromptResponse {
193
+ text?: string;
194
+ source?: Source;
195
+ }
196
+ export declare const Type: {
197
+ readonly ACTION_GROUP: "ACTION_GROUP";
198
+ readonly ASK_USER: "ASK_USER";
199
+ readonly FINISH: "FINISH";
200
+ readonly KNOWLEDGE_BASE: "KNOWLEDGE_BASE";
201
+ readonly REPROMPT: "REPROMPT";
202
+ };
203
+ export type Type = (typeof Type)[keyof typeof Type];
204
+ export interface Observation {
205
+ traceId?: string;
206
+ type?: Type;
207
+ actionGroupInvocationOutput?: ActionGroupInvocationOutput;
208
+ knowledgeBaseLookupOutput?: KnowledgeBaseLookupOutput;
209
+ finalResponse?: FinalResponse;
210
+ repromptResponse?: RepromptResponse;
211
+ }
212
+ export interface Rationale {
213
+ traceId?: string;
214
+ text?: string;
215
+ }
216
+ export type OrchestrationTrace =
217
+ | OrchestrationTrace.InvocationInputMember
218
+ | OrchestrationTrace.ModelInvocationInputMember
219
+ | OrchestrationTrace.ObservationMember
220
+ | OrchestrationTrace.RationaleMember
221
+ | OrchestrationTrace.$UnknownMember;
222
+ export declare namespace OrchestrationTrace {
223
+ interface RationaleMember {
224
+ rationale: Rationale;
225
+ invocationInput?: never;
226
+ observation?: never;
227
+ modelInvocationInput?: never;
228
+ $unknown?: never;
229
+ }
230
+ interface InvocationInputMember {
231
+ rationale?: never;
232
+ invocationInput: InvocationInput;
233
+ observation?: never;
234
+ modelInvocationInput?: never;
235
+ $unknown?: never;
236
+ }
237
+ interface ObservationMember {
238
+ rationale?: never;
239
+ invocationInput?: never;
240
+ observation: Observation;
241
+ modelInvocationInput?: never;
242
+ $unknown?: never;
243
+ }
244
+ interface ModelInvocationInputMember {
245
+ rationale?: never;
246
+ invocationInput?: never;
247
+ observation?: never;
248
+ modelInvocationInput: ModelInvocationInput;
249
+ $unknown?: never;
250
+ }
251
+ interface $UnknownMember {
252
+ rationale?: never;
253
+ invocationInput?: never;
254
+ observation?: never;
255
+ modelInvocationInput?: never;
256
+ $unknown: [string, any];
257
+ }
258
+ interface Visitor<T> {
259
+ rationale: (value: Rationale) => T;
260
+ invocationInput: (value: InvocationInput) => T;
261
+ observation: (value: Observation) => T;
262
+ modelInvocationInput: (value: ModelInvocationInput) => T;
263
+ _: (name: string, value: any) => T;
264
+ }
265
+ const visit: <T>(value: OrchestrationTrace, visitor: Visitor<T>) => T;
266
+ }
267
+ export interface PostProcessingParsedResponse {
268
+ text?: string;
269
+ }
270
+ export interface PostProcessingModelInvocationOutput {
271
+ traceId?: string;
272
+ parsedResponse?: PostProcessingParsedResponse;
273
+ }
274
+ export type PostProcessingTrace =
275
+ | PostProcessingTrace.ModelInvocationInputMember
276
+ | PostProcessingTrace.ModelInvocationOutputMember
277
+ | PostProcessingTrace.$UnknownMember;
278
+ export declare namespace PostProcessingTrace {
279
+ interface ModelInvocationInputMember {
280
+ modelInvocationInput: ModelInvocationInput;
281
+ modelInvocationOutput?: never;
282
+ $unknown?: never;
283
+ }
284
+ interface ModelInvocationOutputMember {
285
+ modelInvocationInput?: never;
286
+ modelInvocationOutput: PostProcessingModelInvocationOutput;
287
+ $unknown?: never;
288
+ }
289
+ interface $UnknownMember {
290
+ modelInvocationInput?: never;
291
+ modelInvocationOutput?: never;
292
+ $unknown: [string, any];
293
+ }
294
+ interface Visitor<T> {
295
+ modelInvocationInput: (value: ModelInvocationInput) => T;
296
+ modelInvocationOutput: (value: PostProcessingModelInvocationOutput) => T;
297
+ _: (name: string, value: any) => T;
298
+ }
299
+ const visit: <T>(value: PostProcessingTrace, visitor: Visitor<T>) => T;
300
+ }
301
+ export interface PreProcessingParsedResponse {
302
+ rationale?: string;
303
+ isValid?: boolean;
304
+ }
305
+ export interface PreProcessingModelInvocationOutput {
306
+ traceId?: string;
307
+ parsedResponse?: PreProcessingParsedResponse;
308
+ }
309
+ export type PreProcessingTrace =
310
+ | PreProcessingTrace.ModelInvocationInputMember
311
+ | PreProcessingTrace.ModelInvocationOutputMember
312
+ | PreProcessingTrace.$UnknownMember;
313
+ export declare namespace PreProcessingTrace {
314
+ interface ModelInvocationInputMember {
315
+ modelInvocationInput: ModelInvocationInput;
316
+ modelInvocationOutput?: never;
317
+ $unknown?: never;
318
+ }
319
+ interface ModelInvocationOutputMember {
320
+ modelInvocationInput?: never;
321
+ modelInvocationOutput: PreProcessingModelInvocationOutput;
322
+ $unknown?: never;
323
+ }
324
+ interface $UnknownMember {
325
+ modelInvocationInput?: never;
326
+ modelInvocationOutput?: never;
327
+ $unknown: [string, any];
328
+ }
329
+ interface Visitor<T> {
330
+ modelInvocationInput: (value: ModelInvocationInput) => T;
331
+ modelInvocationOutput: (value: PreProcessingModelInvocationOutput) => T;
332
+ _: (name: string, value: any) => T;
333
+ }
334
+ const visit: <T>(value: PreProcessingTrace, visitor: Visitor<T>) => T;
335
+ }
336
+ export type Trace =
337
+ | Trace.FailureTraceMember
338
+ | Trace.OrchestrationTraceMember
339
+ | Trace.PostProcessingTraceMember
340
+ | Trace.PreProcessingTraceMember
341
+ | Trace.$UnknownMember;
342
+ export declare namespace Trace {
343
+ interface PreProcessingTraceMember {
344
+ preProcessingTrace: PreProcessingTrace;
345
+ orchestrationTrace?: never;
346
+ postProcessingTrace?: never;
347
+ failureTrace?: never;
348
+ $unknown?: never;
349
+ }
350
+ interface OrchestrationTraceMember {
351
+ preProcessingTrace?: never;
352
+ orchestrationTrace: OrchestrationTrace;
353
+ postProcessingTrace?: never;
354
+ failureTrace?: never;
355
+ $unknown?: never;
356
+ }
357
+ interface PostProcessingTraceMember {
358
+ preProcessingTrace?: never;
359
+ orchestrationTrace?: never;
360
+ postProcessingTrace: PostProcessingTrace;
361
+ failureTrace?: never;
362
+ $unknown?: never;
363
+ }
364
+ interface FailureTraceMember {
365
+ preProcessingTrace?: never;
366
+ orchestrationTrace?: never;
367
+ postProcessingTrace?: never;
368
+ failureTrace: FailureTrace;
369
+ $unknown?: never;
370
+ }
371
+ interface $UnknownMember {
372
+ preProcessingTrace?: never;
373
+ orchestrationTrace?: never;
374
+ postProcessingTrace?: never;
375
+ failureTrace?: never;
376
+ $unknown: [string, any];
377
+ }
378
+ interface Visitor<T> {
379
+ preProcessingTrace: (value: PreProcessingTrace) => T;
380
+ orchestrationTrace: (value: OrchestrationTrace) => T;
381
+ postProcessingTrace: (value: PostProcessingTrace) => T;
382
+ failureTrace: (value: FailureTrace) => T;
383
+ _: (name: string, value: any) => T;
384
+ }
385
+ const visit: <T>(value: Trace, visitor: Visitor<T>) => T;
386
+ }
387
+ export interface TracePart {
388
+ agentId?: string;
389
+ agentAliasId?: string;
390
+ sessionId?: string;
391
+ trace?: Trace;
392
+ }
393
+ export declare class ValidationException extends __BaseException {
394
+ readonly name: "ValidationException";
395
+ readonly $fault: "client";
396
+ constructor(
397
+ opts: __ExceptionOptionType<ValidationException, __BaseException>
398
+ );
399
+ }
400
+ export type ResponseStream =
401
+ | ResponseStream.AccessDeniedExceptionMember
402
+ | ResponseStream.BadGatewayExceptionMember
403
+ | ResponseStream.ChunkMember
404
+ | ResponseStream.ConflictExceptionMember
405
+ | ResponseStream.DependencyFailedExceptionMember
406
+ | ResponseStream.InternalServerExceptionMember
407
+ | ResponseStream.ResourceNotFoundExceptionMember
408
+ | ResponseStream.ServiceQuotaExceededExceptionMember
409
+ | ResponseStream.ThrottlingExceptionMember
410
+ | ResponseStream.TraceMember
411
+ | ResponseStream.ValidationExceptionMember
412
+ | ResponseStream.$UnknownMember;
413
+ export declare namespace ResponseStream {
414
+ interface ChunkMember {
415
+ chunk: PayloadPart;
416
+ trace?: never;
417
+ internalServerException?: never;
418
+ validationException?: never;
419
+ resourceNotFoundException?: never;
420
+ serviceQuotaExceededException?: never;
421
+ throttlingException?: never;
422
+ accessDeniedException?: never;
423
+ conflictException?: never;
424
+ dependencyFailedException?: never;
425
+ badGatewayException?: never;
426
+ $unknown?: never;
427
+ }
428
+ interface TraceMember {
429
+ chunk?: never;
430
+ trace: TracePart;
431
+ internalServerException?: never;
432
+ validationException?: never;
433
+ resourceNotFoundException?: never;
434
+ serviceQuotaExceededException?: never;
435
+ throttlingException?: never;
436
+ accessDeniedException?: never;
437
+ conflictException?: never;
438
+ dependencyFailedException?: never;
439
+ badGatewayException?: never;
440
+ $unknown?: never;
441
+ }
442
+ interface InternalServerExceptionMember {
443
+ chunk?: never;
444
+ trace?: never;
445
+ internalServerException: InternalServerException;
446
+ validationException?: never;
447
+ resourceNotFoundException?: never;
448
+ serviceQuotaExceededException?: never;
449
+ throttlingException?: never;
450
+ accessDeniedException?: never;
451
+ conflictException?: never;
452
+ dependencyFailedException?: never;
453
+ badGatewayException?: never;
454
+ $unknown?: never;
455
+ }
456
+ interface ValidationExceptionMember {
457
+ chunk?: never;
458
+ trace?: never;
459
+ internalServerException?: never;
460
+ validationException: ValidationException;
461
+ resourceNotFoundException?: never;
462
+ serviceQuotaExceededException?: never;
463
+ throttlingException?: never;
464
+ accessDeniedException?: never;
465
+ conflictException?: never;
466
+ dependencyFailedException?: never;
467
+ badGatewayException?: never;
468
+ $unknown?: never;
469
+ }
470
+ interface ResourceNotFoundExceptionMember {
471
+ chunk?: never;
472
+ trace?: never;
473
+ internalServerException?: never;
474
+ validationException?: never;
475
+ resourceNotFoundException: ResourceNotFoundException;
476
+ serviceQuotaExceededException?: never;
477
+ throttlingException?: never;
478
+ accessDeniedException?: never;
479
+ conflictException?: never;
480
+ dependencyFailedException?: never;
481
+ badGatewayException?: never;
482
+ $unknown?: never;
483
+ }
484
+ interface ServiceQuotaExceededExceptionMember {
485
+ chunk?: never;
486
+ trace?: never;
487
+ internalServerException?: never;
488
+ validationException?: never;
489
+ resourceNotFoundException?: never;
490
+ serviceQuotaExceededException: ServiceQuotaExceededException;
491
+ throttlingException?: never;
492
+ accessDeniedException?: never;
493
+ conflictException?: never;
494
+ dependencyFailedException?: never;
495
+ badGatewayException?: never;
496
+ $unknown?: never;
497
+ }
498
+ interface ThrottlingExceptionMember {
499
+ chunk?: never;
500
+ trace?: never;
501
+ internalServerException?: never;
502
+ validationException?: never;
503
+ resourceNotFoundException?: never;
504
+ serviceQuotaExceededException?: never;
505
+ throttlingException: ThrottlingException;
506
+ accessDeniedException?: never;
507
+ conflictException?: never;
508
+ dependencyFailedException?: never;
509
+ badGatewayException?: never;
510
+ $unknown?: never;
511
+ }
512
+ interface AccessDeniedExceptionMember {
513
+ chunk?: never;
514
+ trace?: never;
515
+ internalServerException?: never;
516
+ validationException?: never;
517
+ resourceNotFoundException?: never;
518
+ serviceQuotaExceededException?: never;
519
+ throttlingException?: never;
520
+ accessDeniedException: AccessDeniedException;
521
+ conflictException?: never;
522
+ dependencyFailedException?: never;
523
+ badGatewayException?: never;
524
+ $unknown?: never;
525
+ }
526
+ interface ConflictExceptionMember {
527
+ chunk?: never;
528
+ trace?: never;
529
+ internalServerException?: never;
530
+ validationException?: never;
531
+ resourceNotFoundException?: never;
532
+ serviceQuotaExceededException?: never;
533
+ throttlingException?: never;
534
+ accessDeniedException?: never;
535
+ conflictException: ConflictException;
536
+ dependencyFailedException?: never;
537
+ badGatewayException?: never;
538
+ $unknown?: never;
539
+ }
540
+ interface DependencyFailedExceptionMember {
541
+ chunk?: never;
542
+ trace?: never;
543
+ internalServerException?: never;
544
+ validationException?: never;
545
+ resourceNotFoundException?: never;
546
+ serviceQuotaExceededException?: never;
547
+ throttlingException?: never;
548
+ accessDeniedException?: never;
549
+ conflictException?: never;
550
+ dependencyFailedException: DependencyFailedException;
551
+ badGatewayException?: never;
552
+ $unknown?: never;
553
+ }
554
+ interface BadGatewayExceptionMember {
555
+ chunk?: never;
556
+ trace?: never;
557
+ internalServerException?: never;
558
+ validationException?: never;
559
+ resourceNotFoundException?: never;
560
+ serviceQuotaExceededException?: never;
561
+ throttlingException?: never;
562
+ accessDeniedException?: never;
563
+ conflictException?: never;
564
+ dependencyFailedException?: never;
565
+ badGatewayException: BadGatewayException;
566
+ $unknown?: never;
567
+ }
568
+ interface $UnknownMember {
569
+ chunk?: never;
570
+ trace?: never;
571
+ internalServerException?: never;
572
+ validationException?: never;
573
+ resourceNotFoundException?: never;
574
+ serviceQuotaExceededException?: never;
575
+ throttlingException?: never;
576
+ accessDeniedException?: never;
577
+ conflictException?: never;
578
+ dependencyFailedException?: never;
579
+ badGatewayException?: never;
580
+ $unknown: [string, any];
581
+ }
582
+ interface Visitor<T> {
583
+ chunk: (value: PayloadPart) => T;
584
+ trace: (value: TracePart) => T;
585
+ internalServerException: (value: InternalServerException) => T;
586
+ validationException: (value: ValidationException) => T;
587
+ resourceNotFoundException: (value: ResourceNotFoundException) => T;
588
+ serviceQuotaExceededException: (value: ServiceQuotaExceededException) => T;
589
+ throttlingException: (value: ThrottlingException) => T;
590
+ accessDeniedException: (value: AccessDeniedException) => T;
591
+ conflictException: (value: ConflictException) => T;
592
+ dependencyFailedException: (value: DependencyFailedException) => T;
593
+ badGatewayException: (value: BadGatewayException) => T;
594
+ _: (name: string, value: any) => T;
595
+ }
596
+ const visit: <T>(value: ResponseStream, visitor: Visitor<T>) => T;
597
+ }
598
+ export interface InvokeAgentResponse {
599
+ completion: AsyncIterable<ResponseStream> | undefined;
600
+ contentType: string | undefined;
601
+ sessionId: string | undefined;
602
+ }
603
+ export interface RetrieveAndGenerateInput {
604
+ text: string | undefined;
605
+ }
606
+ export interface KnowledgeBaseRetrieveAndGenerateConfiguration {
607
+ knowledgeBaseId: string | undefined;
608
+ modelArn: string | undefined;
609
+ }
610
+ export declare const RetrieveAndGenerateType: {
611
+ readonly KNOWLEDGE_BASE: "KNOWLEDGE_BASE";
612
+ };
613
+ export type RetrieveAndGenerateType =
614
+ (typeof RetrieveAndGenerateType)[keyof typeof RetrieveAndGenerateType];
615
+ export interface RetrieveAndGenerateConfiguration {
616
+ type: RetrieveAndGenerateType | undefined;
617
+ knowledgeBaseConfiguration?: KnowledgeBaseRetrieveAndGenerateConfiguration;
618
+ }
619
+ export interface RetrieveAndGenerateSessionConfiguration {
620
+ kmsKeyArn: string | undefined;
621
+ }
622
+ export interface RetrieveAndGenerateRequest {
623
+ sessionId?: string;
624
+ input: RetrieveAndGenerateInput | undefined;
625
+ retrieveAndGenerateConfiguration?: RetrieveAndGenerateConfiguration;
626
+ sessionConfiguration?: RetrieveAndGenerateSessionConfiguration;
627
+ }
628
+ export interface RetrieveAndGenerateOutput {
629
+ text: string | undefined;
630
+ }
631
+ export interface RetrieveAndGenerateResponse {
632
+ sessionId: string | undefined;
633
+ output: RetrieveAndGenerateOutput | undefined;
634
+ citations?: Citation[];
635
+ }
636
+ export interface KnowledgeBaseVectorSearchConfiguration {
637
+ numberOfResults: number | undefined;
638
+ }
639
+ export interface KnowledgeBaseRetrievalConfiguration {
640
+ vectorSearchConfiguration: KnowledgeBaseVectorSearchConfiguration | undefined;
641
+ }
642
+ export interface KnowledgeBaseQuery {
643
+ text: string | undefined;
644
+ }
645
+ export interface RetrieveRequest {
646
+ knowledgeBaseId: string | undefined;
647
+ retrievalQuery: KnowledgeBaseQuery | undefined;
648
+ retrievalConfiguration?: KnowledgeBaseRetrievalConfiguration;
649
+ nextToken?: string;
650
+ }
651
+ export interface KnowledgeBaseRetrievalResult {
652
+ content: RetrievalResultContent | undefined;
653
+ location?: RetrievalResultLocation;
654
+ score?: number;
655
+ }
656
+ export interface RetrieveResponse {
657
+ retrievalResults: KnowledgeBaseRetrievalResult[] | undefined;
658
+ nextToken?: string;
659
+ }
660
+ export declare const ActionGroupInvocationInputFilterSensitiveLog: (
661
+ obj: ActionGroupInvocationInput
662
+ ) => any;
663
+ export declare const ActionGroupInvocationOutputFilterSensitiveLog: (
664
+ obj: ActionGroupInvocationOutput
665
+ ) => any;
666
+ export declare const InvokeAgentRequestFilterSensitiveLog: (
667
+ obj: InvokeAgentRequest
668
+ ) => any;
669
+ export declare const PayloadPartFilterSensitiveLog: (obj: PayloadPart) => any;
670
+ export declare const FailureTraceFilterSensitiveLog: (obj: FailureTrace) => any;
671
+ export declare const KnowledgeBaseLookupInputFilterSensitiveLog: (
672
+ obj: KnowledgeBaseLookupInput
673
+ ) => any;
674
+ export declare const InvocationInputFilterSensitiveLog: (
675
+ obj: InvocationInput
676
+ ) => any;
677
+ export declare const ModelInvocationInputFilterSensitiveLog: (
678
+ obj: ModelInvocationInput
679
+ ) => any;
680
+ export declare const FinalResponseFilterSensitiveLog: (
681
+ obj: FinalResponse
682
+ ) => any;
683
+ export declare const RepromptResponseFilterSensitiveLog: (
684
+ obj: RepromptResponse
685
+ ) => any;
686
+ export declare const ObservationFilterSensitiveLog: (obj: Observation) => any;
687
+ export declare const RationaleFilterSensitiveLog: (obj: Rationale) => any;
688
+ export declare const OrchestrationTraceFilterSensitiveLog: (
689
+ obj: OrchestrationTrace
690
+ ) => any;
691
+ export declare const PostProcessingParsedResponseFilterSensitiveLog: (
692
+ obj: PostProcessingParsedResponse
693
+ ) => any;
694
+ export declare const PostProcessingModelInvocationOutputFilterSensitiveLog: (
695
+ obj: PostProcessingModelInvocationOutput
696
+ ) => any;
697
+ export declare const PostProcessingTraceFilterSensitiveLog: (
698
+ obj: PostProcessingTrace
699
+ ) => any;
700
+ export declare const PreProcessingParsedResponseFilterSensitiveLog: (
701
+ obj: PreProcessingParsedResponse
702
+ ) => any;
703
+ export declare const PreProcessingModelInvocationOutputFilterSensitiveLog: (
704
+ obj: PreProcessingModelInvocationOutput
705
+ ) => any;
706
+ export declare const PreProcessingTraceFilterSensitiveLog: (
707
+ obj: PreProcessingTrace
708
+ ) => any;
709
+ export declare const TraceFilterSensitiveLog: (obj: Trace) => any;
710
+ export declare const TracePartFilterSensitiveLog: (obj: TracePart) => any;
711
+ export declare const ResponseStreamFilterSensitiveLog: (
712
+ obj: ResponseStream
713
+ ) => any;
714
+ export declare const InvokeAgentResponseFilterSensitiveLog: (
715
+ obj: InvokeAgentResponse
716
+ ) => any;
717
+ export declare const RetrieveAndGenerateInputFilterSensitiveLog: (
718
+ obj: RetrieveAndGenerateInput
719
+ ) => any;
720
+ export declare const RetrieveAndGenerateRequestFilterSensitiveLog: (
721
+ obj: RetrieveAndGenerateRequest
722
+ ) => any;
723
+ export declare const RetrieveAndGenerateOutputFilterSensitiveLog: (
724
+ obj: RetrieveAndGenerateOutput
725
+ ) => any;
726
+ export declare const RetrieveAndGenerateResponseFilterSensitiveLog: (
727
+ obj: RetrieveAndGenerateResponse
728
+ ) => any;
729
+ export declare const KnowledgeBaseQueryFilterSensitiveLog: (
730
+ obj: KnowledgeBaseQuery
731
+ ) => any;
732
+ export declare const RetrieveRequestFilterSensitiveLog: (
733
+ obj: RetrieveRequest
734
+ ) => any;
735
+ export declare const RetrieveResponseFilterSensitiveLog: (
736
+ obj: RetrieveResponse
737
+ ) => any;