CompactionResult
Defined in: agent/compaction/strategy.ts:35
Result of a compaction operation.
Properties
Section titled “Properties”messages
Section titled “messages”messages:
LLMMessage[]
Defined in: agent/compaction/strategy.ts:37
Compacted messages to replace history with
metadata
Section titled “metadata”metadata:
object
Defined in: agent/compaction/strategy.ts:43
Metadata about the compaction
compactedCount
Section titled “compactedCount”compactedCount:
number
Number of messages after compaction
originalCount
Section titled “originalCount”originalCount:
number
Number of messages before compaction
tokensAfter
Section titled “tokensAfter”tokensAfter:
number
Estimated tokens after compaction
tokensBefore
Section titled “tokensBefore”tokensBefore:
number
Estimated tokens before compaction
strategyName
Section titled “strategyName”strategyName:
string
Defined in: agent/compaction/strategy.ts:41
The name of the strategy that was ultimately executed
summary?
Section titled “summary?”
optionalsummary:string
Defined in: agent/compaction/strategy.ts:39
Summary text if summarization was used