CfnKnowledgeBasePropsMixin
- class aws_cdk.mixins_preview.aws_wisdom.mixins.CfnKnowledgeBasePropsMixin(props, *, strategy=None)
Bases:
MixinSpecifies a knowledge base.
- See:
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-wisdom-knowledgebase.html
- CloudformationResource:
AWS::Wisdom::KnowledgeBase
- Mixin:
true
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview import mixins from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins cfn_knowledge_base_props_mixin = wisdom_mixins.CfnKnowledgeBasePropsMixin(wisdom_mixins.CfnKnowledgeBaseMixinProps( description="description", knowledge_base_type="knowledgeBaseType", name="name", rendering_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.RenderingConfigurationProperty( template_uri="templateUri" ), server_side_encryption_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.ServerSideEncryptionConfigurationProperty( kms_key_id="kmsKeyId" ), source_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.SourceConfigurationProperty( app_integrations=wisdom_mixins.CfnKnowledgeBasePropsMixin.AppIntegrationsConfigurationProperty( app_integration_arn="appIntegrationArn", object_fields=["objectFields"] ), managed_source_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.ManagedSourceConfigurationProperty( web_crawler_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.WebCrawlerConfigurationProperty( crawler_limits=wisdom_mixins.CfnKnowledgeBasePropsMixin.CrawlerLimitsProperty( rate_limit=123 ), exclusion_filters=["exclusionFilters"], inclusion_filters=["inclusionFilters"], scope="scope", url_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.UrlConfigurationProperty( seed_urls=[wisdom_mixins.CfnKnowledgeBasePropsMixin.SeedUrlProperty( url="url" )] ) ) ) ), tags=[CfnTag( key="key", value="value" )], vector_ingestion_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.VectorIngestionConfigurationProperty( chunking_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.ChunkingConfigurationProperty( chunking_strategy="chunkingStrategy", fixed_size_chunking_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.FixedSizeChunkingConfigurationProperty( max_tokens=123, overlap_percentage=123 ), hierarchical_chunking_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.HierarchicalChunkingConfigurationProperty( level_configurations=[wisdom_mixins.CfnKnowledgeBasePropsMixin.HierarchicalChunkingLevelConfigurationProperty( max_tokens=123 )], overlap_tokens=123 ), semantic_chunking_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.SemanticChunkingConfigurationProperty( breakpoint_percentile_threshold=123, buffer_size=123, max_tokens=123 ) ), parsing_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.ParsingConfigurationProperty( bedrock_foundation_model_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.BedrockFoundationModelConfigurationProperty( model_arn="modelArn", parsing_prompt=wisdom_mixins.CfnKnowledgeBasePropsMixin.ParsingPromptProperty( parsing_prompt_text="parsingPromptText" ) ), parsing_strategy="parsingStrategy" ) ) ), strategy=mixins.PropertyMergeStrategy.OVERRIDE )
Create a mixin to apply properties to
AWS::Wisdom::KnowledgeBase.- Parameters:
props (
Union[CfnKnowledgeBaseMixinProps,Dict[str,Any]]) – L1 properties to apply.strategy (
Optional[PropertyMergeStrategy]) – (experimental) Strategy for merging nested properties. Default: - PropertyMergeStrategy.MERGE
Methods
- apply_to(construct)
Apply the mixin properties to the construct.
- Parameters:
construct (
IConstruct)- Return type:
- supports(construct)
Check if this mixin supports the given construct.
- Parameters:
construct (
IConstruct)- Return type:
bool
Attributes
- CFN_PROPERTY_KEYS = ['description', 'knowledgeBaseType', 'name', 'renderingConfiguration', 'serverSideEncryptionConfiguration', 'sourceConfiguration', 'tags', 'vectorIngestionConfiguration']
Static Methods
- classmethod is_mixin(x)
(experimental) Checks if
xis a Mixin.- Parameters:
x (
Any) – Any object.- Return type:
bool- Returns:
true if
xis an object created from a class which extendsMixin.- Stability:
experimental
AppIntegrationsConfigurationProperty
- class CfnKnowledgeBasePropsMixin.AppIntegrationsConfigurationProperty(*, app_integration_arn=None, object_fields=None)
Bases:
objectConfiguration information for Amazon AppIntegrations to automatically ingest content.
- Parameters:
app_integration_arn (
Optional[str]) – The Amazon Resource Name (ARN) of the AppIntegrations DataIntegration to use for ingesting content. - For Salesforce , your AppIntegrations DataIntegration must have an ObjectConfiguration if objectFields is not provided, including at leastId,ArticleNumber,VersionNumber,Title,PublishStatus, andIsDeletedas source fields. - For ServiceNow , your AppIntegrations DataIntegration must have an ObjectConfiguration if objectFields is not provided, including at leastnumber,short_description,sys_mod_count,workflow_state, andactiveas source fields. - For Zendesk , your AppIntegrations DataIntegration must have an ObjectConfiguration ifobjectFieldsis not provided, including at leastid,title,updated_at, anddraftas source fields. - For SharePoint , your AppIntegrations DataIntegration must have a FileConfiguration, including only file extensions that are amongdocx,pdf,html,htm, andtxt. - For Amazon S3 , the ObjectConfiguration and FileConfiguration of your AppIntegrations DataIntegration must be null. TheSourceURIof your DataIntegration must use the following format:s3://your_s3_bucket_name. .. epigraph:: The bucket policy of the corresponding S3 bucket must allow the AWS principalapp-integrations.amazonaws.com.rproxy.govskope.cato performs3:ListBucket,s3:GetObject, ands3:GetBucketLocationagainst the bucket.object_fields (
Optional[Sequence[str]]) –The fields from the source that are made available to your agents in Amazon Q in Connect. Optional if ObjectConfiguration is included in the provided DataIntegration. - For Salesforce , you must include at least
Id,ArticleNumber,VersionNumber,Title,PublishStatus, andIsDeleted. - For ServiceNow , you must include at leastnumber,short_description,sys_mod_count,workflow_state, andactive. - For Zendesk , you must include at leastid,title,updated_at, anddraft. Make sure to include additional fields. These fields are indexed and used to source recommendations.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins app_integrations_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.AppIntegrationsConfigurationProperty( app_integration_arn="appIntegrationArn", object_fields=["objectFields"] )
Attributes
- app_integration_arn
The Amazon Resource Name (ARN) of the AppIntegrations DataIntegration to use for ingesting content.
For Salesforce , your AppIntegrations DataIntegration must have an ObjectConfiguration if objectFields is not provided, including at least
Id,ArticleNumber,VersionNumber,Title,PublishStatus, andIsDeletedas source fields.For ServiceNow , your AppIntegrations DataIntegration must have an ObjectConfiguration if objectFields is not provided, including at least
number,short_description,sys_mod_count,workflow_state, andactiveas source fields.For Zendesk , your AppIntegrations DataIntegration must have an ObjectConfiguration if
objectFieldsis not provided, including at leastid,title,updated_at, anddraftas source fields.For SharePoint , your AppIntegrations DataIntegration must have a FileConfiguration, including only file extensions that are among
docx,pdf,html,htm, andtxt.For Amazon S3 , the ObjectConfiguration and FileConfiguration of your AppIntegrations DataIntegration must be null. The
SourceURIof your DataIntegration must use the following format:s3://your_s3_bucket_name.
The bucket policy of the corresponding S3 bucket must allow the AWS principal
app-integrations.amazonaws.com.rproxy.govskope.cato performs3:ListBucket,s3:GetObject, ands3:GetBucketLocationagainst the bucket.
- object_fields
The fields from the source that are made available to your agents in Amazon Q in Connect.
Optional if ObjectConfiguration is included in the provided DataIntegration.
For Salesforce , you must include at least
Id,ArticleNumber,VersionNumber,Title,PublishStatus, andIsDeleted.For ServiceNow , you must include at least
number,short_description,sys_mod_count,workflow_state, andactive.For Zendesk , you must include at least
id,title,updated_at, anddraft.
Make sure to include additional fields. These fields are indexed and used to source recommendations.
BedrockFoundationModelConfigurationProperty
- class CfnKnowledgeBasePropsMixin.BedrockFoundationModelConfigurationProperty(*, model_arn=None, parsing_prompt=None)
Bases:
objectThe configuration of the Bedrock foundation model.
- Parameters:
model_arn (
Optional[str]) – The model ARN of the Bedrock foundation model.parsing_prompt (
Union[IResolvable,ParsingPromptProperty,Dict[str,Any],None]) – The parsing prompt of the Bedrock foundation model configuration.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins bedrock_foundation_model_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.BedrockFoundationModelConfigurationProperty( model_arn="modelArn", parsing_prompt=wisdom_mixins.CfnKnowledgeBasePropsMixin.ParsingPromptProperty( parsing_prompt_text="parsingPromptText" ) )
Attributes
- model_arn
The model ARN of the Bedrock foundation model.
- parsing_prompt
The parsing prompt of the Bedrock foundation model configuration.
ChunkingConfigurationProperty
- class CfnKnowledgeBasePropsMixin.ChunkingConfigurationProperty(*, chunking_strategy=None, fixed_size_chunking_configuration=None, hierarchical_chunking_configuration=None, semantic_chunking_configuration=None)
Bases:
objectDetails about how to chunk the documents in the data source.
A chunk refers to an excerpt from a data source that is returned when the knowledge base that it belongs to is queried.
- Parameters:
chunking_strategy (
Optional[str]) – Knowledge base can split your source data into chunks. A chunk refers to an excerpt from a data source that is returned when the knowledge base that it belongs to is queried. You have the following options for chunking your data. If you opt forNONE, then you may want to pre-process your files by splitting them up such that each file corresponds to a chunk.fixed_size_chunking_configuration (
Union[IResolvable,FixedSizeChunkingConfigurationProperty,Dict[str,Any],None]) – Configurations for when you choose fixed-size chunking. If you set thechunkingStrategyasNONE, exclude this field.hierarchical_chunking_configuration (
Union[IResolvable,HierarchicalChunkingConfigurationProperty,Dict[str,Any],None]) – Settings for hierarchical document chunking for a data source. Hierarchical chunking splits documents into layers of chunks where the first layer contains large chunks, and the second layer contains smaller chunks derived from the first layer.semantic_chunking_configuration (
Union[IResolvable,SemanticChunkingConfigurationProperty,Dict[str,Any],None]) – Settings for semantic document chunking for a data source. Semantic chunking splits a document into smaller documents based on groups of similar content derived from the text with natural language processing.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins chunking_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.ChunkingConfigurationProperty( chunking_strategy="chunkingStrategy", fixed_size_chunking_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.FixedSizeChunkingConfigurationProperty( max_tokens=123, overlap_percentage=123 ), hierarchical_chunking_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.HierarchicalChunkingConfigurationProperty( level_configurations=[wisdom_mixins.CfnKnowledgeBasePropsMixin.HierarchicalChunkingLevelConfigurationProperty( max_tokens=123 )], overlap_tokens=123 ), semantic_chunking_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.SemanticChunkingConfigurationProperty( breakpoint_percentile_threshold=123, buffer_size=123, max_tokens=123 ) )
Attributes
- chunking_strategy
Knowledge base can split your source data into chunks.
A chunk refers to an excerpt from a data source that is returned when the knowledge base that it belongs to is queried. You have the following options for chunking your data. If you opt for
NONE, then you may want to pre-process your files by splitting them up such that each file corresponds to a chunk.
- fixed_size_chunking_configuration
Configurations for when you choose fixed-size chunking.
If you set the
chunkingStrategyasNONE, exclude this field.
- hierarchical_chunking_configuration
Settings for hierarchical document chunking for a data source.
Hierarchical chunking splits documents into layers of chunks where the first layer contains large chunks, and the second layer contains smaller chunks derived from the first layer.
- semantic_chunking_configuration
Settings for semantic document chunking for a data source.
Semantic chunking splits a document into smaller documents based on groups of similar content derived from the text with natural language processing.
CrawlerLimitsProperty
- class CfnKnowledgeBasePropsMixin.CrawlerLimitsProperty(*, rate_limit=None)
Bases:
objectThe limits of the crawler.
- Parameters:
rate_limit (
Union[int,float,None]) – The limit rate at which the crawler is configured.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins crawler_limits_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.CrawlerLimitsProperty( rate_limit=123 )
Attributes
- rate_limit
The limit rate at which the crawler is configured.
FixedSizeChunkingConfigurationProperty
- class CfnKnowledgeBasePropsMixin.FixedSizeChunkingConfigurationProperty(*, max_tokens=None, overlap_percentage=None)
Bases:
objectConfigurations for when you choose fixed-size chunking.
If you set the
chunkingStrategyasNONE, exclude this field.- Parameters:
max_tokens (
Union[int,float,None]) – The maximum number of tokens to include in a chunk.overlap_percentage (
Union[int,float,None]) – The percentage of overlap between adjacent chunks of a data source.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins fixed_size_chunking_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.FixedSizeChunkingConfigurationProperty( max_tokens=123, overlap_percentage=123 )
Attributes
- max_tokens
The maximum number of tokens to include in a chunk.
- overlap_percentage
The percentage of overlap between adjacent chunks of a data source.
HierarchicalChunkingConfigurationProperty
- class CfnKnowledgeBasePropsMixin.HierarchicalChunkingConfigurationProperty(*, level_configurations=None, overlap_tokens=None)
Bases:
objectSettings for hierarchical document chunking for a data source.
Hierarchical chunking splits documents into layers of chunks where the first layer contains large chunks, and the second layer contains smaller chunks derived from the first layer.
- Parameters:
level_configurations (
Union[IResolvable,Sequence[Union[IResolvable,HierarchicalChunkingLevelConfigurationProperty,Dict[str,Any]]],None]) – Token settings for each layer.overlap_tokens (
Union[int,float,None]) – The number of tokens to repeat across chunks in the same layer.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins hierarchical_chunking_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.HierarchicalChunkingConfigurationProperty( level_configurations=[wisdom_mixins.CfnKnowledgeBasePropsMixin.HierarchicalChunkingLevelConfigurationProperty( max_tokens=123 )], overlap_tokens=123 )
Attributes
- level_configurations
Token settings for each layer.
- overlap_tokens
The number of tokens to repeat across chunks in the same layer.
HierarchicalChunkingLevelConfigurationProperty
- class CfnKnowledgeBasePropsMixin.HierarchicalChunkingLevelConfigurationProperty(*, max_tokens=None)
Bases:
objectToken settings for each layer.
- Parameters:
max_tokens (
Union[int,float,None]) – The maximum number of tokens that a chunk can contain in this layer.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins hierarchical_chunking_level_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.HierarchicalChunkingLevelConfigurationProperty( max_tokens=123 )
Attributes
- max_tokens
The maximum number of tokens that a chunk can contain in this layer.
ManagedSourceConfigurationProperty
- class CfnKnowledgeBasePropsMixin.ManagedSourceConfigurationProperty(*, web_crawler_configuration=None)
Bases:
objectSource configuration for managed resources.
- Parameters:
web_crawler_configuration (
Union[IResolvable,WebCrawlerConfigurationProperty,Dict[str,Any],None]) – Configuration data for web crawler data source.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins managed_source_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.ManagedSourceConfigurationProperty( web_crawler_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.WebCrawlerConfigurationProperty( crawler_limits=wisdom_mixins.CfnKnowledgeBasePropsMixin.CrawlerLimitsProperty( rate_limit=123 ), exclusion_filters=["exclusionFilters"], inclusion_filters=["inclusionFilters"], scope="scope", url_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.UrlConfigurationProperty( seed_urls=[wisdom_mixins.CfnKnowledgeBasePropsMixin.SeedUrlProperty( url="url" )] ) ) )
Attributes
- web_crawler_configuration
Configuration data for web crawler data source.
ParsingConfigurationProperty
- class CfnKnowledgeBasePropsMixin.ParsingConfigurationProperty(*, bedrock_foundation_model_configuration=None, parsing_strategy=None)
Bases:
objectSettings for parsing document contents.
By default, the service converts the contents of each document into text before splitting it into chunks. To improve processing of PDF files with tables and images, you can configure the data source to convert the pages of text into images and use a model to describe the contents of each page.
- Parameters:
bedrock_foundation_model_configuration (
Union[IResolvable,BedrockFoundationModelConfigurationProperty,Dict[str,Any],None]) – Settings for a foundation model used to parse documents for a data source.parsing_strategy (
Optional[str]) – The parsing strategy for the data source.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins parsing_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.ParsingConfigurationProperty( bedrock_foundation_model_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.BedrockFoundationModelConfigurationProperty( model_arn="modelArn", parsing_prompt=wisdom_mixins.CfnKnowledgeBasePropsMixin.ParsingPromptProperty( parsing_prompt_text="parsingPromptText" ) ), parsing_strategy="parsingStrategy" )
Attributes
- bedrock_foundation_model_configuration
Settings for a foundation model used to parse documents for a data source.
- parsing_strategy
The parsing strategy for the data source.
ParsingPromptProperty
- class CfnKnowledgeBasePropsMixin.ParsingPromptProperty(*, parsing_prompt_text=None)
Bases:
objectInstructions for interpreting the contents of a document.
- Parameters:
parsing_prompt_text (
Optional[str]) – Instructions for interpreting the contents of a document.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins parsing_prompt_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.ParsingPromptProperty( parsing_prompt_text="parsingPromptText" )
Attributes
- parsing_prompt_text
Instructions for interpreting the contents of a document.
RenderingConfigurationProperty
- class CfnKnowledgeBasePropsMixin.RenderingConfigurationProperty(*, template_uri=None)
Bases:
objectInformation about how to render the content.
- Parameters:
template_uri (
Optional[str]) – A URI template containing exactly one variable in${variableName}format. This can only be set forEXTERNALknowledge bases. For Salesforce, ServiceNow, and Zendesk, the variable must be one of the following: - Salesforce:Id,ArticleNumber,VersionNumber,Title,PublishStatus, orIsDeleted- ServiceNow:number,short_description,sys_mod_count,workflow_state, oractive- Zendesk:id,title,updated_at, ordraftThe variable is replaced with the actual value for a piece of content when calling GetContent .- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins rendering_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.RenderingConfigurationProperty( template_uri="templateUri" )
Attributes
- template_uri
A URI template containing exactly one variable in
${variableName}format.This can only be set for
EXTERNALknowledge bases. For Salesforce, ServiceNow, and Zendesk, the variable must be one of the following:Salesforce:
Id,ArticleNumber,VersionNumber,Title,PublishStatus, orIsDeletedServiceNow:
number,short_description,sys_mod_count,workflow_state, oractiveZendesk:
id,title,updated_at, ordraft
The variable is replaced with the actual value for a piece of content when calling GetContent .
SeedUrlProperty
- class CfnKnowledgeBasePropsMixin.SeedUrlProperty(*, url=None)
Bases:
objectA URL for crawling.
- Parameters:
url (
Optional[str]) – URL for crawling.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins seed_url_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.SeedUrlProperty( url="url" )
Attributes
SemanticChunkingConfigurationProperty
- class CfnKnowledgeBasePropsMixin.SemanticChunkingConfigurationProperty(*, breakpoint_percentile_threshold=None, buffer_size=None, max_tokens=None)
Bases:
objectSettings for semantic document chunking for a data source.
Semantic chunking splits a document into smaller documents based on groups of similar content derived from the text with natural language processing.
- Parameters:
breakpoint_percentile_threshold (
Union[int,float,None]) – The dissimilarity threshold for splitting chunks.buffer_size (
Union[int,float,None]) – The buffer size.max_tokens (
Union[int,float,None]) – The maximum number of tokens that a chunk can contain.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins semantic_chunking_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.SemanticChunkingConfigurationProperty( breakpoint_percentile_threshold=123, buffer_size=123, max_tokens=123 )
Attributes
- breakpoint_percentile_threshold
The dissimilarity threshold for splitting chunks.
- buffer_size
The buffer size.
- max_tokens
The maximum number of tokens that a chunk can contain.
ServerSideEncryptionConfigurationProperty
- class CfnKnowledgeBasePropsMixin.ServerSideEncryptionConfigurationProperty(*, kms_key_id=None)
Bases:
objectThe configuration information for the customer managed key used for encryption.
- Parameters:
kms_key_id (
Optional[str]) – The customer managed key used for encryption. This customer managed key must have a policy that allowskms:CreateGrantandkms:DescribeKeypermissions to the IAM identity using the key to invoke Wisdom. For more information about setting up a customer managed key for Wisdom, see Enable Amazon Connect Wisdom for your instance . For information about valid ID values, see Key identifiers (KeyId) .- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins server_side_encryption_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.ServerSideEncryptionConfigurationProperty( kms_key_id="kmsKeyId" )
Attributes
- kms_key_id
The customer managed key used for encryption.
This customer managed key must have a policy that allows
kms:CreateGrantandkms:DescribeKeypermissions to the IAM identity using the key to invoke Wisdom.For more information about setting up a customer managed key for Wisdom, see Enable Amazon Connect Wisdom for your instance . For information about valid ID values, see Key identifiers (KeyId) .
SourceConfigurationProperty
- class CfnKnowledgeBasePropsMixin.SourceConfigurationProperty(*, app_integrations=None, managed_source_configuration=None)
Bases:
objectConfiguration information about the external data source.
- Parameters:
app_integrations (
Union[IResolvable,AppIntegrationsConfigurationProperty,Dict[str,Any],None]) – Configuration information for Amazon AppIntegrations to automatically ingest content.managed_source_configuration (
Union[IResolvable,ManagedSourceConfigurationProperty,Dict[str,Any],None]) – Source configuration for managed resources.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins source_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.SourceConfigurationProperty( app_integrations=wisdom_mixins.CfnKnowledgeBasePropsMixin.AppIntegrationsConfigurationProperty( app_integration_arn="appIntegrationArn", object_fields=["objectFields"] ), managed_source_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.ManagedSourceConfigurationProperty( web_crawler_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.WebCrawlerConfigurationProperty( crawler_limits=wisdom_mixins.CfnKnowledgeBasePropsMixin.CrawlerLimitsProperty( rate_limit=123 ), exclusion_filters=["exclusionFilters"], inclusion_filters=["inclusionFilters"], scope="scope", url_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.UrlConfigurationProperty( seed_urls=[wisdom_mixins.CfnKnowledgeBasePropsMixin.SeedUrlProperty( url="url" )] ) ) ) )
Attributes
- app_integrations
Configuration information for Amazon AppIntegrations to automatically ingest content.
- managed_source_configuration
Source configuration for managed resources.
UrlConfigurationProperty
- class CfnKnowledgeBasePropsMixin.UrlConfigurationProperty(*, seed_urls=None)
Bases:
objectThe configuration of the URL/URLs for the web content that you want to crawl.
You should be authorized to crawl the URLs.
- Parameters:
seed_urls (
Union[IResolvable,Sequence[Union[IResolvable,SeedUrlProperty,Dict[str,Any]]],None]) – List of URLs for crawling.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins url_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.UrlConfigurationProperty( seed_urls=[wisdom_mixins.CfnKnowledgeBasePropsMixin.SeedUrlProperty( url="url" )] )
Attributes
VectorIngestionConfigurationProperty
- class CfnKnowledgeBasePropsMixin.VectorIngestionConfigurationProperty(*, chunking_configuration=None, parsing_configuration=None)
Bases:
objectContains details about how to ingest the documents in a data source.
- Parameters:
chunking_configuration (
Union[IResolvable,ChunkingConfigurationProperty,Dict[str,Any],None]) – Details about how to chunk the documents in the data source. A chunk refers to an excerpt from a data source that is returned when the knowledge base that it belongs to is queried.parsing_configuration (
Union[IResolvable,ParsingConfigurationProperty,Dict[str,Any],None]) – A custom parser for data source documents.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins vector_ingestion_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.VectorIngestionConfigurationProperty( chunking_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.ChunkingConfigurationProperty( chunking_strategy="chunkingStrategy", fixed_size_chunking_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.FixedSizeChunkingConfigurationProperty( max_tokens=123, overlap_percentage=123 ), hierarchical_chunking_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.HierarchicalChunkingConfigurationProperty( level_configurations=[wisdom_mixins.CfnKnowledgeBasePropsMixin.HierarchicalChunkingLevelConfigurationProperty( max_tokens=123 )], overlap_tokens=123 ), semantic_chunking_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.SemanticChunkingConfigurationProperty( breakpoint_percentile_threshold=123, buffer_size=123, max_tokens=123 ) ), parsing_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.ParsingConfigurationProperty( bedrock_foundation_model_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.BedrockFoundationModelConfigurationProperty( model_arn="modelArn", parsing_prompt=wisdom_mixins.CfnKnowledgeBasePropsMixin.ParsingPromptProperty( parsing_prompt_text="parsingPromptText" ) ), parsing_strategy="parsingStrategy" ) )
Attributes
- chunking_configuration
Details about how to chunk the documents in the data source.
A chunk refers to an excerpt from a data source that is returned when the knowledge base that it belongs to is queried.
- parsing_configuration
A custom parser for data source documents.
WebCrawlerConfigurationProperty
- class CfnKnowledgeBasePropsMixin.WebCrawlerConfigurationProperty(*, crawler_limits=None, exclusion_filters=None, inclusion_filters=None, scope=None, url_configuration=None)
Bases:
objectThe configuration details for the web data source.
- Parameters:
crawler_limits (
Union[IResolvable,CrawlerLimitsProperty,Dict[str,Any],None]) – The configuration of crawl limits for the web URLs.exclusion_filters (
Optional[Sequence[str]]) – A list of one or more exclusion regular expression patterns to exclude certain URLs. If you specify an inclusion and exclusion filter/pattern and both match a URL, the exclusion filter takes precedence and the web content of the URL isn’t crawled.inclusion_filters (
Optional[Sequence[str]]) – A list of one or more inclusion regular expression patterns to include certain URLs. If you specify an inclusion and exclusion filter/pattern and both match a URL, the exclusion filter takes precedence and the web content of the URL isn’t crawled.scope (
Optional[str]) – The scope of what is crawled for your URLs. You can choose to crawl only web pages that belong to the same host or primary domain. For example, only web pages that contain the seed URLhttps://docs.aws.amazon.com/bedrock/latest/userguide/and no other domains. You can choose to include sub domains in addition to the host or primary domain. For example, web pages that containaws.amazon.com.rproxy.govskope.cacan also include sub domaindocs---aws.amazon.com.rproxy.govskope.ca.url_configuration (
Union[IResolvable,UrlConfigurationProperty,Dict[str,Any],None]) – The configuration of the URL/URLs for the web content that you want to crawl. You should be authorized to crawl the URLs.
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_wisdom import mixins as wisdom_mixins web_crawler_configuration_property = wisdom_mixins.CfnKnowledgeBasePropsMixin.WebCrawlerConfigurationProperty( crawler_limits=wisdom_mixins.CfnKnowledgeBasePropsMixin.CrawlerLimitsProperty( rate_limit=123 ), exclusion_filters=["exclusionFilters"], inclusion_filters=["inclusionFilters"], scope="scope", url_configuration=wisdom_mixins.CfnKnowledgeBasePropsMixin.UrlConfigurationProperty( seed_urls=[wisdom_mixins.CfnKnowledgeBasePropsMixin.SeedUrlProperty( url="url" )] ) )
Attributes
- crawler_limits
The configuration of crawl limits for the web URLs.
- exclusion_filters
A list of one or more exclusion regular expression patterns to exclude certain URLs.
If you specify an inclusion and exclusion filter/pattern and both match a URL, the exclusion filter takes precedence and the web content of the URL isn’t crawled.
- inclusion_filters
A list of one or more inclusion regular expression patterns to include certain URLs.
If you specify an inclusion and exclusion filter/pattern and both match a URL, the exclusion filter takes precedence and the web content of the URL isn’t crawled.
- scope
The scope of what is crawled for your URLs.
You can choose to crawl only web pages that belong to the same host or primary domain. For example, only web pages that contain the seed URL
https://docs.aws.amazon.com/bedrock/latest/userguide/and no other domains. You can choose to include sub domains in addition to the host or primary domain. For example, web pages that containaws.amazon.com.rproxy.govskope.cacan also include sub domaindocs.aws.amazon.com.
- url_configuration
The configuration of the URL/URLs for the web content that you want to crawl.
You should be authorized to crawl the URLs.