MemoryProps
- class aws_cdk.aws_bedrock_agentcore_alpha.MemoryProps(*, description=None, execution_role=None, expiration_duration=None, kms_key=None, memory_name=None, memory_strategies=None, tags=None)
Bases:
object(experimental) Properties for creating a Memory resource.
- Parameters:
description (
Optional[str]) – (experimental) Optional description for the memory Valid characters are a-z, A-Z, 0-9, _ (underscore), - (hyphen) and spaces The description can have up to 200 characters. Default: - No descriptionexecution_role (
Optional[IRole]) – (experimental) The IAM role that provides permissions for the memory to access AWS services when using custom strategies. Default: - A new role will be created.expiration_duration (
Optional[Duration]) – (experimental) Short-term memory expiration in days (between 7 and 365). Sets the short-term (raw event) memory retention. Events older than the specified duration will expire and no longer be stored. Default: - 90 dayskms_key (
Optional[IKey]) – (experimental) Custom KMS key to use for encryption. Default: - Your data is encrypted with a key that AWS owns and manages for youmemory_name (
Optional[str]) – (experimental) The name of the memory Valid characters are a-z, A-Z, 0-9, _ (underscore) The name must start with a letter and can be up to 48 characters long Pattern: [a-zA-Z][a-zA-Z0-9_]{0,47}. Default: - auto generatememory_strategies (
Optional[Sequence[IMemoryStrategy]]) – (experimental) If you need long-term memory for context recall across sessions, you can setup memory extraction strategies to extract the relevant memory from the raw events. Default: - No extraction strategies (short term memory only)tags (
Optional[Mapping[str,str]]) – (experimental) Tags (optional) A list of key:value pairs of tags to apply to this memory resource. Default: - no tags
- Stability:
experimental
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. import aws_cdk.aws_bedrock_agentcore_alpha as bedrock_agentcore_alpha import aws_cdk as cdk from aws_cdk import aws_iam as iam from aws_cdk import aws_kms as kms # key: kms.Key # memory_strategy: bedrock_agentcore_alpha.IMemoryStrategy # role: iam.Role memory_props = bedrock_agentcore_alpha.MemoryProps( description="description", execution_role=role, expiration_duration=cdk.Duration.minutes(30), kms_key=key, memory_name="memoryName", memory_strategies=[memory_strategy], tags={ "tags_key": "tags" } )
Attributes
- description
(experimental) Optional description for the memory Valid characters are a-z, A-Z, 0-9, _ (underscore), - (hyphen) and spaces The description can have up to 200 characters.
- Default:
No description
- Stability:
experimental
- execution_role
(experimental) The IAM role that provides permissions for the memory to access AWS services when using custom strategies.
- Default:
A new role will be created.
- Stability:
experimental
- expiration_duration
(experimental) Short-term memory expiration in days (between 7 and 365).
Sets the short-term (raw event) memory retention. Events older than the specified duration will expire and no longer be stored.
- Default:
90 days
- Stability:
experimental
- kms_key
(experimental) Custom KMS key to use for encryption.
- Default:
Your data is encrypted with a key that AWS owns and manages for you
- Stability:
experimental
- memory_name
[a-zA-Z][a-zA-Z0-9_]{0,47}.
- Default:
auto generate
- Stability:
experimental
- Type:
(experimental) The name of the memory Valid characters are a-z, A-Z, 0-9, _ (underscore) The name must start with a letter and can be up to 48 characters long Pattern
- memory_strategies
(experimental) If you need long-term memory for context recall across sessions, you can setup memory extraction strategies to extract the relevant memory from the raw events.
- Default:
No extraction strategies (short term memory only)
- Stability:
experimental