Package com.tnsai.memory.strategy
Class HybridStrategy.Builder
java.lang.Object
com.tnsai.memory.strategy.HybridStrategy.Builder
- Enclosing class:
HybridStrategy
Builder for HybridStrategy.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()preserveSystemPrompt(boolean preserve) Whether to preserve system prompts.recentWindowSize(int size) Number of recent messages to keep in full.slidingWindowStrategy(SlidingWindowStrategy strategy) The sliding window strategy to use for recent messages.summarizeThreshold(int threshold) Minimum messages before summarization kicks in.summaryStrategy(SummaryStrategy strategy) The summary strategy to use for old messages.
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
recentWindowSize
Number of recent messages to keep in full. Default: 6 -
summaryStrategy
The summary strategy to use for old messages. -
slidingWindowStrategy
The sliding window strategy to use for recent messages. -
preserveSystemPrompt
Whether to preserve system prompts. Default: true -
summarizeThreshold
Minimum messages before summarization kicks in. Default: 8 -
build
-