Interface ManagedStrategyProps

All Superinterfaces:
software.amazon.jsii.JsiiSerializable, MemoryStrategyCommonProps
All Known Implementing Classes:
ManagedStrategyProps.Jsii$Proxy

@Generated(value="jsii-pacmak/1.129.0 (build eaca441)", date="2026-05-19T08:18:44.458Z") @Stability(Stable) public interface ManagedStrategyProps extends software.amazon.jsii.JsiiSerializable, MemoryStrategyCommonProps
Configuration parameters for a memory strategy that can override existing built-in default prompts/models.

Example:

 // Create memory with custom strategies
 Memory memory = Memory.Builder.create(this, "MyMemory")
         .memoryName("my_memory")
         .description("Memory with custom strategies")
         .expirationDuration(Duration.days(90))
         .memoryStrategies(List.of(MemoryStrategy.usingUserPreference(ManagedStrategyProps.builder()
                 .strategyName("CustomerPreferences")
                 .namespaces(List.of("support/customer/{actorId}/preferences"))
                 .build()), MemoryStrategy.usingSemantic(ManagedStrategyProps.builder()
                 .strategyName("CustomerSupportSemantic")
                 .namespaces(List.of("support/customer/{actorId}/semantic"))
                 .build()), MemoryStrategy.usingEpisodic(ManagedStrategyProps.builder()
                 .strategyName("customerJourneyEpisodic")
                 .namespaces(List.of("/journey/customer/{actorId}/episodes"))
                 .reflectionConfiguration(EpisodicReflectionConfiguration.builder()
                         .namespaces(List.of("/journey/customer/{actorId}/reflections"))
                         .build())
                 .build())))
         .build();
 
  • Method Details

    • getNamespaces

      @Stability(Stable) @NotNull List<String> getNamespaces()
      The namespaces for the strategy Represents a namespace for organizing memory data Use a hierarchical format separated by forward slashes (/).

      Use a hierarchical format separated by forward slashes (/) to organize namespaces logically. You can include these defined variables:

      • {sessionId} - the user identifier to be created in the CreateEvent API
      • {memoryStrategyId} - an identifier for an extraction strategy
      • {sessionId} - an identifier for each session

      Example namespace path: /strategies/{memoryStrategyId}/actions/{actionId}/sessions/{sessionId}

      After memory creation, this namespace might look like: /actor/actor-3afc5aa8fef9/strategy/summarization-fy5c5fwc7/session/session-qj7tpd1kvr8

    • getCustomConsolidation

      @Stability(Stable) @Nullable default OverrideConfig getCustomConsolidation()
      The configuration for the custom consolidation.

      This configuration provides customization to how the model identifies and extracts relevant information for memory storage.

      Default: - No custom extraction

    • getCustomExtraction

      @Stability(Stable) @Nullable default OverrideConfig getCustomExtraction()
      The configuration for the custom extraction.

      This configuration provides customization to how the model identifies and extracts relevant information for memory storage.

      Default: - No custom extraction

    • getReflectionConfiguration

      @Stability(Stable) @Nullable default EpisodicReflectionConfiguration getReflectionConfiguration()
      Configuration for episodic memory reflection (only applicable for EPISODIC strategy type) Defines additional namespaces for reflection-based episodic recall.

      Default: - No reflection configuration

    • builder

      @Stability(Stable) static ManagedStrategyProps.Builder builder()
      Returns:
      a ManagedStrategyProps.Builder of ManagedStrategyProps