@aws-sdk/client-kendra 3.430.0 → 3.431.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.
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ruleSet = void 0;
4
- const q = "required", r = "fn", s = "argv", t = "ref";
5
- const a = "isSet", b = "tree", c = "error", d = "endpoint", e = "PartitionResult", f = { [q]: false, "type": "String" }, g = { [q]: true, "default": false, "type": "Boolean" }, h = { [t]: "Endpoint" }, i = { [r]: "booleanEquals", [s]: [{ [t]: "UseFIPS" }, true] }, j = { [r]: "booleanEquals", [s]: [{ [t]: "UseDualStack" }, true] }, k = {}, l = { [r]: "booleanEquals", [s]: [true, { [r]: "getAttr", [s]: [{ [t]: e }, "supportsFIPS"] }] }, m = { [r]: "booleanEquals", [s]: [true, { [r]: "getAttr", [s]: [{ [t]: e }, "supportsDualStack"] }] }, n = [i], o = [j], p = [{ [t]: "Region" }];
6
- const _data = { version: "1.0", parameters: { Region: f, UseDualStack: g, UseFIPS: g, Endpoint: f }, rules: [{ conditions: [{ [r]: a, [s]: [h] }], type: b, rules: [{ conditions: n, error: "Invalid Configuration: FIPS and custom endpoint are not supported", type: c }, { conditions: o, error: "Invalid Configuration: Dualstack and custom endpoint are not supported", type: c }, { endpoint: { url: h, properties: k, headers: k }, type: d }] }, { conditions: [{ [r]: a, [s]: p }], type: b, rules: [{ conditions: [{ [r]: "aws.partition", [s]: p, assign: e }], type: b, rules: [{ conditions: [i, j], type: b, rules: [{ conditions: [l, m], type: b, rules: [{ endpoint: { url: "https://kendra-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", properties: k, headers: k }, type: d }] }, { error: "FIPS and DualStack are enabled, but this partition does not support one or both", type: c }] }, { conditions: n, type: b, rules: [{ conditions: [l], type: b, rules: [{ endpoint: { url: "https://kendra-fips.{Region}.{PartitionResult#dnsSuffix}", properties: k, headers: k }, type: d }] }, { error: "FIPS is enabled but this partition does not support FIPS", type: c }] }, { conditions: o, type: b, rules: [{ conditions: [m], type: b, rules: [{ endpoint: { url: "https://kendra.{Region}.{PartitionResult#dualStackDnsSuffix}", properties: k, headers: k }, type: d }] }, { error: "DualStack is enabled but this partition does not support DualStack", type: c }] }, { endpoint: { url: "https://kendra.{Region}.{PartitionResult#dnsSuffix}", properties: k, headers: k }, type: d }] }] }, { error: "Invalid Configuration: Missing Region", type: c }] };
4
+ const s = "required", t = "fn", u = "argv", v = "ref";
5
+ const a = true, b = "isSet", c = "booleanEquals", d = "error", e = "endpoint", f = "tree", g = "PartitionResult", h = { [s]: false, "type": "String" }, i = { [s]: true, "default": false, "type": "Boolean" }, j = { [v]: "Endpoint" }, k = { [t]: c, [u]: [{ [v]: "UseFIPS" }, true] }, l = { [t]: c, [u]: [{ [v]: "UseDualStack" }, true] }, m = {}, n = { [t]: "getAttr", [u]: [{ [v]: g }, "supportsFIPS"] }, o = { [t]: c, [u]: [true, { [t]: "getAttr", [u]: [{ [v]: g }, "supportsDualStack"] }] }, p = [k], q = [l], r = [{ [v]: "Region" }];
6
+ const _data = { version: "1.0", parameters: { Region: h, UseDualStack: i, UseFIPS: i, Endpoint: h }, rules: [{ conditions: [{ [t]: b, [u]: [j] }], rules: [{ conditions: p, error: "Invalid Configuration: FIPS and custom endpoint are not supported", type: d }, { conditions: q, error: "Invalid Configuration: Dualstack and custom endpoint are not supported", type: d }, { endpoint: { url: j, properties: m, headers: m }, type: e }], type: f }, { conditions: [{ [t]: b, [u]: r }], rules: [{ conditions: [{ [t]: "aws.partition", [u]: r, assign: g }], rules: [{ conditions: [k, l], rules: [{ conditions: [{ [t]: c, [u]: [a, n] }, o], rules: [{ endpoint: { url: "https://kendra-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", properties: m, headers: m }, type: e }], type: f }, { error: "FIPS and DualStack are enabled, but this partition does not support one or both", type: d }], type: f }, { conditions: p, rules: [{ conditions: [{ [t]: c, [u]: [n, a] }], rules: [{ endpoint: { url: "https://kendra-fips.{Region}.{PartitionResult#dnsSuffix}", properties: m, headers: m }, type: e }], type: f }, { error: "FIPS is enabled but this partition does not support FIPS", type: d }], type: f }, { conditions: q, rules: [{ conditions: [o], rules: [{ endpoint: { url: "https://kendra.{Region}.{PartitionResult#dualStackDnsSuffix}", properties: m, headers: m }, type: e }], type: f }, { error: "DualStack is enabled but this partition does not support DualStack", type: d }], type: f }, { endpoint: { url: "https://kendra.{Region}.{PartitionResult#dnsSuffix}", properties: m, headers: m }, type: e }], type: f }], type: f }, { error: "Invalid Configuration: Missing Region", type: d }] };
7
7
  exports.ruleSet = _data;
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.EndpointType = exports.DataSourceStatus = exports.KeyLocation = exports.UserGroupResolutionMode = exports.UserContextPolicy = exports.IndexEdition = exports.FeaturedResultsConflictException = exports.FeaturedResultsSetStatus = exports.FaqFileFormat = exports.DataSourceType = exports.WebCrawlerMode = exports.SlackEntity = exports.SharePointVersion = exports.SharePointOnlineAuthenticationType = exports.ServiceNowBuildVersionType = exports.ServiceNowAuthenticationType = exports.SalesforceStandardObjectName = exports.SalesforceKnowledgeArticleState = exports.SalesforceChatterFeedIncludeFilterType = exports.IssueSubEntity = exports.Type = exports.FsxFileSystemType = exports.QueryIdentifiersEnclosingOption = exports.DatabaseEngineType = exports.ConfluenceVersion = exports.ConfluenceSpaceFieldName = exports.ConfluencePageFieldName = exports.ConfluenceBlogFieldName = exports.ConfluenceAuthenticationType = exports.ConfluenceAttachmentFieldName = exports.ServiceQuotaExceededException = exports.ContentType = exports.PrincipalType = exports.ReadAccessType = exports.ConditionOperator = exports.DocumentStatus = exports.ConflictException = exports.ErrorCode = exports.AttributeSuggestionsMode = exports.Persona = exports.ValidationException = exports.ThrottlingException = exports.ResourceNotFoundException = exports.ResourceAlreadyExistException = exports.InternalServerException = exports.EntityType = exports.AlfrescoEntity = exports.AdditionalResultAttributeValueType = exports.HighlightType = exports.AccessDeniedException = void 0;
4
- exports.ListExperienceEntitiesResponseFilterSensitiveLog = exports.ExperienceEntitiesSummaryFilterSensitiveLog = exports.EntityDisplayDataFilterSensitiveLog = exports.DescribeIndexResponseFilterSensitiveLog = exports.CreateIndexRequestFilterSensitiveLog = exports.ServerSideEncryptionConfigurationFilterSensitiveLog = exports.ScoreConfidence = exports.QueryResultFormat = exports.SortOrder = exports.QueryResultType = exports.ResourceUnavailableException = exports.DataSourceSyncJobStatus = exports.InvalidRequestException = exports.MetricType = exports.Interval = exports.SuggestionType = exports.ThesaurusStatus = exports.QuerySuggestionsStatus = exports.Mode = exports.QuerySuggestionsBlockListStatus = exports.PrincipalMappingStatus = exports.IndexStatus = exports.DocumentAttributeValueType = exports.Order = exports.FaqStatus = exports.ExperienceStatus = void 0;
4
+ exports.ListExperienceEntitiesResponseFilterSensitiveLog = exports.ExperienceEntitiesSummaryFilterSensitiveLog = exports.EntityDisplayDataFilterSensitiveLog = exports.DescribeIndexResponseFilterSensitiveLog = exports.CreateIndexRequestFilterSensitiveLog = exports.ServerSideEncryptionConfigurationFilterSensitiveLog = exports.QueryResultFormat = exports.QueryResultType = exports.SortOrder = exports.MissingAttributeKeyStrategy = exports.ResourceUnavailableException = exports.DataSourceSyncJobStatus = exports.InvalidRequestException = exports.MetricType = exports.Interval = exports.SuggestionType = exports.ThesaurusStatus = exports.QuerySuggestionsStatus = exports.Mode = exports.QuerySuggestionsBlockListStatus = exports.PrincipalMappingStatus = exports.IndexStatus = exports.DocumentAttributeValueType = exports.Order = exports.FaqStatus = exports.ExperienceStatus = void 0;
5
5
  const smithy_client_1 = require("@smithy/smithy-client");
6
6
  const KendraServiceException_1 = require("./KendraServiceException");
7
7
  class AccessDeniedException extends KendraServiceException_1.KendraServiceException {
@@ -508,26 +508,24 @@ class ResourceUnavailableException extends KendraServiceException_1.KendraServic
508
508
  }
509
509
  }
510
510
  exports.ResourceUnavailableException = ResourceUnavailableException;
511
- exports.QueryResultType = {
512
- ANSWER: "ANSWER",
513
- DOCUMENT: "DOCUMENT",
514
- QUESTION_ANSWER: "QUESTION_ANSWER",
511
+ exports.MissingAttributeKeyStrategy = {
512
+ COLLAPSE: "COLLAPSE",
513
+ EXPAND: "EXPAND",
514
+ IGNORE: "IGNORE",
515
515
  };
516
516
  exports.SortOrder = {
517
517
  ASC: "ASC",
518
518
  DESC: "DESC",
519
519
  };
520
+ exports.QueryResultType = {
521
+ ANSWER: "ANSWER",
522
+ DOCUMENT: "DOCUMENT",
523
+ QUESTION_ANSWER: "QUESTION_ANSWER",
524
+ };
520
525
  exports.QueryResultFormat = {
521
526
  TABLE: "TABLE",
522
527
  TEXT: "TEXT",
523
528
  };
524
- exports.ScoreConfidence = {
525
- HIGH: "HIGH",
526
- LOW: "LOW",
527
- MEDIUM: "MEDIUM",
528
- NOT_AVAILABLE: "NOT_AVAILABLE",
529
- VERY_HIGH: "VERY_HIGH",
530
- };
531
529
  const ServerSideEncryptionConfigurationFilterSensitiveLog = (obj) => ({
532
530
  ...obj,
533
531
  ...(obj.KmsKeyId && { KmsKeyId: smithy_client_1.SENSITIVE_STRING }),
@@ -1,7 +1,14 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.RelevanceType = exports.ResourceInUseException = exports.WarningCode = void 0;
3
+ exports.RelevanceType = exports.ResourceInUseException = exports.WarningCode = exports.ScoreConfidence = void 0;
4
4
  const KendraServiceException_1 = require("./KendraServiceException");
5
+ exports.ScoreConfidence = {
6
+ HIGH: "HIGH",
7
+ LOW: "LOW",
8
+ MEDIUM: "MEDIUM",
9
+ NOT_AVAILABLE: "NOT_AVAILABLE",
10
+ VERY_HIGH: "VERY_HIGH",
11
+ };
5
12
  exports.WarningCode = {
6
13
  QUERY_LANGUAGE_INVALID_SYNTAX: "QUERY_LANGUAGE_INVALID_SYNTAX",
7
14
  };
@@ -3956,6 +3956,7 @@ const se_ListDataSourceSyncJobsRequest = (input, context) => {
3956
3956
  const se_QueryRequest = (input, context) => {
3957
3957
  return (0, smithy_client_1.take)(input, {
3958
3958
  AttributeFilter: (_) => se_AttributeFilter(_, context),
3959
+ CollapseConfiguration: smithy_client_1._json,
3959
3960
  DocumentRelevanceOverrideConfigurations: smithy_client_1._json,
3960
3961
  Facets: (_) => se_FacetList(_, context),
3961
3962
  IndexId: [],
@@ -3965,6 +3966,7 @@ const se_QueryRequest = (input, context) => {
3965
3966
  QueryText: [],
3966
3967
  RequestedDocumentAttributes: smithy_client_1._json,
3967
3968
  SortingConfiguration: smithy_client_1._json,
3969
+ SortingConfigurations: smithy_client_1._json,
3968
3970
  SpellCorrectionConfiguration: smithy_client_1._json,
3969
3971
  UserContext: smithy_client_1._json,
3970
3972
  VisitorId: [],
@@ -4031,6 +4033,12 @@ const se_WebCrawlerConfiguration = (input, context) => {
4031
4033
  Urls: smithy_client_1._json,
4032
4034
  });
4033
4035
  };
4036
+ const de_CollapsedResultDetail = (output, context) => {
4037
+ return (0, smithy_client_1.take)(output, {
4038
+ DocumentAttribute: (_) => de_DocumentAttribute(_, context),
4039
+ ExpandedResults: (_) => de_ExpandedResultList(_, context),
4040
+ });
4041
+ };
4034
4042
  const de_CustomDocumentEnrichmentConfiguration = (output, context) => {
4035
4043
  return (0, smithy_client_1.take)(output, {
4036
4044
  InlineConfigurations: (_) => de_InlineCustomDocumentEnrichmentConfigurationList(_, context),
@@ -4276,6 +4284,24 @@ const de_DocumentAttributeValueCountPairList = (output, context) => {
4276
4284
  });
4277
4285
  return retVal;
4278
4286
  };
4287
+ const de_ExpandedResultItem = (output, context) => {
4288
+ return (0, smithy_client_1.take)(output, {
4289
+ DocumentAttributes: (_) => de_DocumentAttributeList(_, context),
4290
+ DocumentExcerpt: smithy_client_1._json,
4291
+ DocumentId: smithy_client_1.expectString,
4292
+ DocumentTitle: smithy_client_1._json,
4293
+ DocumentURI: smithy_client_1.expectString,
4294
+ Id: smithy_client_1.expectString,
4295
+ });
4296
+ };
4297
+ const de_ExpandedResultList = (output, context) => {
4298
+ const retVal = (output || [])
4299
+ .filter((e) => e != null)
4300
+ .map((entry) => {
4301
+ return de_ExpandedResultItem(entry, context);
4302
+ });
4303
+ return retVal;
4304
+ };
4279
4305
  const de_ExperiencesSummary = (output, context) => {
4280
4306
  return (0, smithy_client_1.take)(output, {
4281
4307
  CreatedAt: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
@@ -4497,6 +4523,7 @@ const de_QueryResult = (output, context) => {
4497
4523
  const de_QueryResultItem = (output, context) => {
4498
4524
  return (0, smithy_client_1.take)(output, {
4499
4525
  AdditionalAttributes: smithy_client_1._json,
4526
+ CollapsedResultDetail: (_) => de_CollapsedResultDetail(_, context),
4500
4527
  DocumentAttributes: (_) => de_DocumentAttributeList(_, context),
4501
4528
  DocumentExcerpt: smithy_client_1._json,
4502
4529
  DocumentId: smithy_client_1.expectString,
@@ -1,4 +1,4 @@
1
- const q = "required", r = "fn", s = "argv", t = "ref";
2
- const a = "isSet", b = "tree", c = "error", d = "endpoint", e = "PartitionResult", f = { [q]: false, "type": "String" }, g = { [q]: true, "default": false, "type": "Boolean" }, h = { [t]: "Endpoint" }, i = { [r]: "booleanEquals", [s]: [{ [t]: "UseFIPS" }, true] }, j = { [r]: "booleanEquals", [s]: [{ [t]: "UseDualStack" }, true] }, k = {}, l = { [r]: "booleanEquals", [s]: [true, { [r]: "getAttr", [s]: [{ [t]: e }, "supportsFIPS"] }] }, m = { [r]: "booleanEquals", [s]: [true, { [r]: "getAttr", [s]: [{ [t]: e }, "supportsDualStack"] }] }, n = [i], o = [j], p = [{ [t]: "Region" }];
3
- const _data = { version: "1.0", parameters: { Region: f, UseDualStack: g, UseFIPS: g, Endpoint: f }, rules: [{ conditions: [{ [r]: a, [s]: [h] }], type: b, rules: [{ conditions: n, error: "Invalid Configuration: FIPS and custom endpoint are not supported", type: c }, { conditions: o, error: "Invalid Configuration: Dualstack and custom endpoint are not supported", type: c }, { endpoint: { url: h, properties: k, headers: k }, type: d }] }, { conditions: [{ [r]: a, [s]: p }], type: b, rules: [{ conditions: [{ [r]: "aws.partition", [s]: p, assign: e }], type: b, rules: [{ conditions: [i, j], type: b, rules: [{ conditions: [l, m], type: b, rules: [{ endpoint: { url: "https://kendra-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", properties: k, headers: k }, type: d }] }, { error: "FIPS and DualStack are enabled, but this partition does not support one or both", type: c }] }, { conditions: n, type: b, rules: [{ conditions: [l], type: b, rules: [{ endpoint: { url: "https://kendra-fips.{Region}.{PartitionResult#dnsSuffix}", properties: k, headers: k }, type: d }] }, { error: "FIPS is enabled but this partition does not support FIPS", type: c }] }, { conditions: o, type: b, rules: [{ conditions: [m], type: b, rules: [{ endpoint: { url: "https://kendra.{Region}.{PartitionResult#dualStackDnsSuffix}", properties: k, headers: k }, type: d }] }, { error: "DualStack is enabled but this partition does not support DualStack", type: c }] }, { endpoint: { url: "https://kendra.{Region}.{PartitionResult#dnsSuffix}", properties: k, headers: k }, type: d }] }] }, { error: "Invalid Configuration: Missing Region", type: c }] };
1
+ const s = "required", t = "fn", u = "argv", v = "ref";
2
+ const a = true, b = "isSet", c = "booleanEquals", d = "error", e = "endpoint", f = "tree", g = "PartitionResult", h = { [s]: false, "type": "String" }, i = { [s]: true, "default": false, "type": "Boolean" }, j = { [v]: "Endpoint" }, k = { [t]: c, [u]: [{ [v]: "UseFIPS" }, true] }, l = { [t]: c, [u]: [{ [v]: "UseDualStack" }, true] }, m = {}, n = { [t]: "getAttr", [u]: [{ [v]: g }, "supportsFIPS"] }, o = { [t]: c, [u]: [true, { [t]: "getAttr", [u]: [{ [v]: g }, "supportsDualStack"] }] }, p = [k], q = [l], r = [{ [v]: "Region" }];
3
+ const _data = { version: "1.0", parameters: { Region: h, UseDualStack: i, UseFIPS: i, Endpoint: h }, rules: [{ conditions: [{ [t]: b, [u]: [j] }], rules: [{ conditions: p, error: "Invalid Configuration: FIPS and custom endpoint are not supported", type: d }, { conditions: q, error: "Invalid Configuration: Dualstack and custom endpoint are not supported", type: d }, { endpoint: { url: j, properties: m, headers: m }, type: e }], type: f }, { conditions: [{ [t]: b, [u]: r }], rules: [{ conditions: [{ [t]: "aws.partition", [u]: r, assign: g }], rules: [{ conditions: [k, l], rules: [{ conditions: [{ [t]: c, [u]: [a, n] }, o], rules: [{ endpoint: { url: "https://kendra-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", properties: m, headers: m }, type: e }], type: f }, { error: "FIPS and DualStack are enabled, but this partition does not support one or both", type: d }], type: f }, { conditions: p, rules: [{ conditions: [{ [t]: c, [u]: [n, a] }], rules: [{ endpoint: { url: "https://kendra-fips.{Region}.{PartitionResult#dnsSuffix}", properties: m, headers: m }, type: e }], type: f }, { error: "FIPS is enabled but this partition does not support FIPS", type: d }], type: f }, { conditions: q, rules: [{ conditions: [o], rules: [{ endpoint: { url: "https://kendra.{Region}.{PartitionResult#dualStackDnsSuffix}", properties: m, headers: m }, type: e }], type: f }, { error: "DualStack is enabled but this partition does not support DualStack", type: d }], type: f }, { endpoint: { url: "https://kendra.{Region}.{PartitionResult#dnsSuffix}", properties: m, headers: m }, type: e }], type: f }], type: f }, { error: "Invalid Configuration: Missing Region", type: d }] };
4
4
  export const ruleSet = _data;
@@ -493,26 +493,24 @@ export class ResourceUnavailableException extends __BaseException {
493
493
  this.Message = opts.Message;
494
494
  }
495
495
  }
496
- export const QueryResultType = {
497
- ANSWER: "ANSWER",
498
- DOCUMENT: "DOCUMENT",
499
- QUESTION_ANSWER: "QUESTION_ANSWER",
496
+ export const MissingAttributeKeyStrategy = {
497
+ COLLAPSE: "COLLAPSE",
498
+ EXPAND: "EXPAND",
499
+ IGNORE: "IGNORE",
500
500
  };
501
501
  export const SortOrder = {
502
502
  ASC: "ASC",
503
503
  DESC: "DESC",
504
504
  };
505
+ export const QueryResultType = {
506
+ ANSWER: "ANSWER",
507
+ DOCUMENT: "DOCUMENT",
508
+ QUESTION_ANSWER: "QUESTION_ANSWER",
509
+ };
505
510
  export const QueryResultFormat = {
506
511
  TABLE: "TABLE",
507
512
  TEXT: "TEXT",
508
513
  };
509
- export const ScoreConfidence = {
510
- HIGH: "HIGH",
511
- LOW: "LOW",
512
- MEDIUM: "MEDIUM",
513
- NOT_AVAILABLE: "NOT_AVAILABLE",
514
- VERY_HIGH: "VERY_HIGH",
515
- };
516
514
  export const ServerSideEncryptionConfigurationFilterSensitiveLog = (obj) => ({
517
515
  ...obj,
518
516
  ...(obj.KmsKeyId && { KmsKeyId: SENSITIVE_STRING }),
@@ -1,4 +1,11 @@
1
1
  import { KendraServiceException as __BaseException } from "./KendraServiceException";
2
+ export const ScoreConfidence = {
3
+ HIGH: "HIGH",
4
+ LOW: "LOW",
5
+ MEDIUM: "MEDIUM",
6
+ NOT_AVAILABLE: "NOT_AVAILABLE",
7
+ VERY_HIGH: "VERY_HIGH",
8
+ };
2
9
  export const WarningCode = {
3
10
  QUERY_LANGUAGE_INVALID_SYNTAX: "QUERY_LANGUAGE_INVALID_SYNTAX",
4
11
  };
@@ -3819,6 +3819,7 @@ const se_ListDataSourceSyncJobsRequest = (input, context) => {
3819
3819
  const se_QueryRequest = (input, context) => {
3820
3820
  return take(input, {
3821
3821
  AttributeFilter: (_) => se_AttributeFilter(_, context),
3822
+ CollapseConfiguration: _json,
3822
3823
  DocumentRelevanceOverrideConfigurations: _json,
3823
3824
  Facets: (_) => se_FacetList(_, context),
3824
3825
  IndexId: [],
@@ -3828,6 +3829,7 @@ const se_QueryRequest = (input, context) => {
3828
3829
  QueryText: [],
3829
3830
  RequestedDocumentAttributes: _json,
3830
3831
  SortingConfiguration: _json,
3832
+ SortingConfigurations: _json,
3831
3833
  SpellCorrectionConfiguration: _json,
3832
3834
  UserContext: _json,
3833
3835
  VisitorId: [],
@@ -3894,6 +3896,12 @@ const se_WebCrawlerConfiguration = (input, context) => {
3894
3896
  Urls: _json,
3895
3897
  });
3896
3898
  };
3899
+ const de_CollapsedResultDetail = (output, context) => {
3900
+ return take(output, {
3901
+ DocumentAttribute: (_) => de_DocumentAttribute(_, context),
3902
+ ExpandedResults: (_) => de_ExpandedResultList(_, context),
3903
+ });
3904
+ };
3897
3905
  const de_CustomDocumentEnrichmentConfiguration = (output, context) => {
3898
3906
  return take(output, {
3899
3907
  InlineConfigurations: (_) => de_InlineCustomDocumentEnrichmentConfigurationList(_, context),
@@ -4139,6 +4147,24 @@ const de_DocumentAttributeValueCountPairList = (output, context) => {
4139
4147
  });
4140
4148
  return retVal;
4141
4149
  };
4150
+ const de_ExpandedResultItem = (output, context) => {
4151
+ return take(output, {
4152
+ DocumentAttributes: (_) => de_DocumentAttributeList(_, context),
4153
+ DocumentExcerpt: _json,
4154
+ DocumentId: __expectString,
4155
+ DocumentTitle: _json,
4156
+ DocumentURI: __expectString,
4157
+ Id: __expectString,
4158
+ });
4159
+ };
4160
+ const de_ExpandedResultList = (output, context) => {
4161
+ const retVal = (output || [])
4162
+ .filter((e) => e != null)
4163
+ .map((entry) => {
4164
+ return de_ExpandedResultItem(entry, context);
4165
+ });
4166
+ return retVal;
4167
+ };
4142
4168
  const de_ExperiencesSummary = (output, context) => {
4143
4169
  return take(output, {
4144
4170
  CreatedAt: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
@@ -4360,6 +4386,7 @@ const de_QueryResult = (output, context) => {
4360
4386
  const de_QueryResultItem = (output, context) => {
4361
4387
  return take(output, {
4362
4388
  AdditionalAttributes: _json,
4389
+ CollapsedResultDetail: (_) => de_CollapsedResultDetail(_, context),
4363
4390
  DocumentAttributes: (_) => de_DocumentAttributeList(_, context),
4364
4391
  DocumentExcerpt: _json,
4365
4392
  DocumentId: __expectString,
@@ -26,9 +26,11 @@ export interface BatchDeleteDocumentCommandOutput extends BatchDeleteDocumentRes
26
26
  * <p>Removes one or more documents from an index. The documents must have been added with
27
27
  * the <code>BatchPutDocument</code> API.</p>
28
28
  * <p>The documents are deleted asynchronously. You can see the progress of the deletion by
29
- * using Amazon Web Services CloudWatch. Any error messages related to the processing of the
30
- * batch are sent to your Amazon Web Services CloudWatch log. You can also use the
31
- * <code>BatchGetDocumentStatus</code> API to monitor the progress of deleting your documents.</p>
29
+ * using Amazon Web Services
30
+ * CloudWatch. Any error messages related to the processing of the batch are sent to
31
+ * your Amazon Web Services
32
+ * CloudWatch log. You can also use the <code>BatchGetDocumentStatus</code> API to
33
+ * monitor the progress of deleting your documents.</p>
32
34
  * <p>Deleting documents from an index using <code>BatchDeleteDocument</code> could take up
33
35
  * to an hour or more, depending on the number of documents you want to delete.</p>
34
36
  * @example
@@ -29,9 +29,11 @@ export interface BatchPutDocumentCommandOutput extends BatchPutDocumentResponse,
29
29
  * unstructured text into an index, add custom attributes to the documents, and to attach
30
30
  * an access control list to the documents added to the index.</p>
31
31
  * <p>The documents are indexed asynchronously. You can see the progress of the batch using
32
- * Amazon Web Services CloudWatch. Any error messages related to processing the batch
33
- * are sent to your Amazon Web Services CloudWatch log. You can also use the
34
- * <code>BatchGetDocumentStatus</code> API to monitor the progress of indexing your documents.</p>
32
+ * Amazon Web Services
33
+ * CloudWatch. Any error messages related to processing the batch are sent to your
34
+ * Amazon Web Services
35
+ * CloudWatch log. You can also use the <code>BatchGetDocumentStatus</code> API to
36
+ * monitor the progress of indexing your documents.</p>
35
37
  * <p>For an example of ingesting inline documents using Python and Java SDKs, see <a href="https://docs.aws.amazon.com/kendra/latest/dg/in-adding-binary-doc.html">Adding files
36
38
  * directly to an index</a>.</p>
37
39
  * @example
@@ -24,6 +24,12 @@ export interface QueryCommandOutput extends QueryResult, __MetadataBearer {
24
24
  /**
25
25
  * @public
26
26
  * <p>Searches an index given an input query.</p>
27
+ * <note>
28
+ * <p>If you are working with large language models (LLMs) or implementing retrieval
29
+ * augmented generation (RAG) systems, you can use Amazon Kendra's <a href="https://docs.aws.amazon.com/kendra/latest/APIReference/API_Retrieve.html">Retrieve</a> API, which can return longer semantically relevant passages. We
30
+ * recommend using the <code>Retrieve</code> API instead of filing a service limit increase
31
+ * to increase the <code>Query</code> API document excerpt length.</p>
32
+ * </note>
27
33
  * <p>You can configure boosting or relevance tuning at the query level to override boosting
28
34
  * at the index level, filter based on document fields/attributes and faceted search, and
29
35
  * filter based on the user or their group access to documents. You can also include certain
@@ -38,15 +44,15 @@ export interface QueryCommandOutput extends QueryResult, __MetadataBearer {
38
44
  * <p>Matching FAQs or questions-answer from your FAQ file.</p>
39
45
  * </li>
40
46
  * <li>
41
- * <p>Relevant documents. This result type includes an excerpt of the document with
42
- * the document title. The searched terms can be highlighted in the excerpt.</p>
47
+ * <p>Relevant documents. This result type includes an excerpt of the document with the
48
+ * document title. The searched terms can be highlighted in the excerpt.</p>
43
49
  * </li>
44
50
  * </ul>
45
51
  * <p>You can specify that the query return only one type of result using the
46
- * <code>QueryResultTypeFilter</code> parameter. Each query returns the 100
47
- * most relevant results. If you filter result type to only question-answers,
48
- * a maximum of four results are returned. If you filter result type to only
49
- * answers, a maximum of three results are returned.</p>
52
+ * <code>QueryResultTypeFilter</code> parameter. Each query returns the 100 most relevant
53
+ * results. If you filter result type to only question-answers, a maximum of four results are
54
+ * returned. If you filter result type to only answers, a maximum of three results are
55
+ * returned.</p>
50
56
  * @example
51
57
  * Use a bare-bones client and the command you need to make an API call.
52
58
  * ```javascript
@@ -174,6 +180,12 @@ export interface QueryCommandOutput extends QueryResult, __MetadataBearer {
174
180
  * DocumentAttributeKey: "STRING_VALUE", // required
175
181
  * SortOrder: "DESC" || "ASC", // required
176
182
  * },
183
+ * SortingConfigurations: [ // SortingConfigurationList
184
+ * {
185
+ * DocumentAttributeKey: "STRING_VALUE", // required
186
+ * SortOrder: "DESC" || "ASC", // required
187
+ * },
188
+ * ],
177
189
  * UserContext: { // UserContext
178
190
  * Token: "STRING_VALUE",
179
191
  * UserId: "STRING_VALUE",
@@ -191,6 +203,18 @@ export interface QueryCommandOutput extends QueryResult, __MetadataBearer {
191
203
  * SpellCorrectionConfiguration: { // SpellCorrectionConfiguration
192
204
  * IncludeQuerySpellCheckSuggestions: true || false, // required
193
205
  * },
206
+ * CollapseConfiguration: { // CollapseConfiguration
207
+ * DocumentAttributeKey: "STRING_VALUE", // required
208
+ * SortingConfigurations: [
209
+ * "<SortingConfiguration>",
210
+ * ],
211
+ * MissingAttributeKeyStrategy: "IGNORE" || "COLLAPSE" || "EXPAND",
212
+ * Expand: true || false,
213
+ * ExpandConfiguration: { // ExpandConfiguration
214
+ * MaxResultItemsToExpand: Number("int"),
215
+ * MaxExpandedResultsPerItem: Number("int"),
216
+ * },
217
+ * },
194
218
  * };
195
219
  * const command = new QueryCommand(input);
196
220
  * const response = await client.send(command);
@@ -276,6 +300,61 @@ export interface QueryCommandOutput extends QueryResult, __MetadataBearer {
276
300
  * // ],
277
301
  * // TotalNumberOfRows: Number("int"),
278
302
  * // },
303
+ * // CollapsedResultDetail: { // CollapsedResultDetail
304
+ * // DocumentAttribute: {
305
+ * // Key: "STRING_VALUE", // required
306
+ * // Value: {
307
+ * // StringValue: "STRING_VALUE",
308
+ * // StringListValue: [
309
+ * // "STRING_VALUE",
310
+ * // ],
311
+ * // LongValue: Number("long"),
312
+ * // DateValue: new Date("TIMESTAMP"),
313
+ * // },
314
+ * // },
315
+ * // ExpandedResults: [ // ExpandedResultList
316
+ * // { // ExpandedResultItem
317
+ * // Id: "STRING_VALUE",
318
+ * // DocumentId: "STRING_VALUE",
319
+ * // DocumentTitle: {
320
+ * // Text: "STRING_VALUE",
321
+ * // Highlights: [
322
+ * // {
323
+ * // BeginOffset: Number("int"), // required
324
+ * // EndOffset: Number("int"), // required
325
+ * // TopAnswer: true || false,
326
+ * // Type: "STANDARD" || "THESAURUS_SYNONYM",
327
+ * // },
328
+ * // ],
329
+ * // },
330
+ * // DocumentExcerpt: {
331
+ * // Text: "STRING_VALUE",
332
+ * // Highlights: [
333
+ * // {
334
+ * // BeginOffset: Number("int"), // required
335
+ * // EndOffset: Number("int"), // required
336
+ * // TopAnswer: true || false,
337
+ * // Type: "STANDARD" || "THESAURUS_SYNONYM",
338
+ * // },
339
+ * // ],
340
+ * // },
341
+ * // DocumentURI: "STRING_VALUE",
342
+ * // DocumentAttributes: [
343
+ * // {
344
+ * // Key: "STRING_VALUE", // required
345
+ * // Value: {
346
+ * // StringValue: "STRING_VALUE",
347
+ * // StringListValue: [
348
+ * // "STRING_VALUE",
349
+ * // ],
350
+ * // LongValue: Number("long"),
351
+ * // DateValue: new Date("TIMESTAMP"),
352
+ * // },
353
+ * // },
354
+ * // ],
355
+ * // },
356
+ * // ],
357
+ * // },
279
358
  * // },
280
359
  * // ],
281
360
  * // FacetResults: [ // FacetResultList
@@ -299,14 +378,7 @@ export interface QueryCommandOutput extends QueryResult, __MetadataBearer {
299
378
  * // DocumentAttributeValueType: "STRING_VALUE" || "STRING_LIST_VALUE" || "LONG_VALUE" || "DATE_VALUE",
300
379
  * // DocumentAttributeValueCountPairs: [
301
380
  * // {
302
- * // DocumentAttributeValue: {
303
- * // StringValue: "STRING_VALUE",
304
- * // StringListValue: [
305
- * // "STRING_VALUE",
306
- * // ],
307
- * // LongValue: Number("long"),
308
- * // DateValue: new Date("TIMESTAMP"),
309
- * // },
381
+ * // DocumentAttributeValue: "<DocumentAttributeValue>",
310
382
  * // Count: Number("int"),
311
383
  * // FacetResults: "<FacetResultList>",
312
384
  * // },
@@ -346,45 +418,18 @@ export interface QueryCommandOutput extends QueryResult, __MetadataBearer {
346
418
  * // Key: "STRING_VALUE", // required
347
419
  * // ValueType: "TEXT_WITH_HIGHLIGHTS_VALUE", // required
348
420
  * // Value: {
349
- * // TextWithHighlightsValue: {
350
- * // Text: "STRING_VALUE",
351
- * // Highlights: [
352
- * // {
353
- * // BeginOffset: Number("int"), // required
354
- * // EndOffset: Number("int"), // required
355
- * // TopAnswer: true || false,
356
- * // Type: "STANDARD" || "THESAURUS_SYNONYM",
357
- * // },
358
- * // ],
359
- * // },
421
+ * // TextWithHighlightsValue: "<TextWithHighlights>",
360
422
  * // },
361
423
  * // },
362
424
  * // ],
363
425
  * // DocumentId: "STRING_VALUE",
364
- * // DocumentTitle: {
365
- * // Text: "STRING_VALUE",
366
- * // Highlights: [
367
- * // {
368
- * // BeginOffset: Number("int"), // required
369
- * // EndOffset: Number("int"), // required
370
- * // TopAnswer: true || false,
371
- * // Type: "STANDARD" || "THESAURUS_SYNONYM",
372
- * // },
373
- * // ],
374
- * // },
426
+ * // DocumentTitle: "<TextWithHighlights>",
375
427
  * // DocumentExcerpt: "<TextWithHighlights>",
376
428
  * // DocumentURI: "STRING_VALUE",
377
429
  * // DocumentAttributes: [
378
430
  * // {
379
431
  * // Key: "STRING_VALUE", // required
380
- * // Value: {
381
- * // StringValue: "STRING_VALUE",
382
- * // StringListValue: [
383
- * // "STRING_VALUE",
384
- * // ],
385
- * // LongValue: Number("long"),
386
- * // DateValue: new Date("TIMESTAMP"),
387
- * // },
432
+ * // Value: "<DocumentAttributeValue>", // required
388
433
  * // },
389
434
  * // ],
390
435
  * // FeedbackToken: "STRING_VALUE",
@@ -24,16 +24,15 @@ export interface RetrieveCommandOutput extends RetrieveResult, __MetadataBearer
24
24
  /**
25
25
  * @public
26
26
  * <p>Retrieves relevant passages or text excerpts given an input query.</p>
27
- * <p>This API is similar to the <a href="https://docs.aws.amazon.com/kendra/latest/APIReference/API_Query.html">Query</a>
28
- * API. However, by default, the <code>Query</code> API only
29
- * returns excerpt passages of up to 100 token words. With the
30
- * <code>Retrieve</code> API, you can retrieve longer passages of up to
31
- * 200 token words and up to 100 semantically relevant passages. This doesn't
32
- * include question-answer or FAQ type responses from your index. The passages
33
- * are text excerpts that can be semantically extracted from multiple documents
34
- * and multiple parts of the same document. If in extreme cases your documents
35
- * produce zero passages using the <code>Retrieve</code> API, you can alternatively
36
- * use the <code>Query</code> API and its types of responses.</p>
27
+ * <p>This API is similar to the <a href="https://docs.aws.amazon.com/kendra/latest/APIReference/API_Query.html">Query</a> API. However, by
28
+ * default, the <code>Query</code> API only returns excerpt passages of up to 100 token
29
+ * words. With the <code>Retrieve</code> API, you can retrieve longer passages of up to 200
30
+ * token words and up to 100 semantically relevant passages. This doesn't include
31
+ * question-answer or FAQ type responses from your index. The passages are text excerpts
32
+ * that can be semantically extracted from multiple documents and multiple parts of the
33
+ * same document. If in extreme cases your documents produce zero passages using the
34
+ * <code>Retrieve</code> API, you can alternatively use the <code>Query</code> API and
35
+ * its types of responses.</p>
37
36
  * <p>You can also do the following:</p>
38
37
  * <ul>
39
38
  * <li>
@@ -45,12 +44,20 @@ export interface RetrieveCommandOutput extends RetrieveResult, __MetadataBearer
45
44
  * <li>
46
45
  * <p>Filter based on the user or their group access to documents</p>
47
46
  * </li>
47
+ * <li>
48
+ * <p>View the confidence score bucket for a retrieved passage result. The
49
+ * confidence bucket provides a relative ranking that indicates how confident
50
+ * Amazon Kendra is that the response is relevant to the query.</p>
51
+ * <note>
52
+ * <p>Confidence score buckets are currently available only for English.</p>
53
+ * </note>
54
+ * </li>
48
55
  * </ul>
49
56
  * <p>You can also include certain fields in the response that might provide useful
50
57
  * additional information.</p>
51
58
  * <p>The <code>Retrieve</code> API shares the number of <a href="https://docs.aws.amazon.com/kendra/latest/APIReference/API_CapacityUnitsConfiguration.html">query capacity
52
- * units</a> that you set for your index. For more information on what's included in
53
- * a single capacity unit and the default base capacity for an index, see <a href="https://docs.aws.amazon.com/kendra/latest/dg/adjusting-capacity.html">Adjusting
59
+ * units</a> that you set for your index. For more information on what's included
60
+ * in a single capacity unit and the default base capacity for an index, see <a href="https://docs.aws.amazon.com/kendra/latest/dg/adjusting-capacity.html">Adjusting
54
61
  * capacity</a>.</p>
55
62
  * @example
56
63
  * Use a bare-bones client and the command you need to make an API call.