Skip to content

agent-sessions / Exports / CompactionOrchestrator

Class: CompactionOrchestrator

Table of contents

Constructors

Methods

Constructors

constructor

new CompactionOrchestrator(options): CompactionOrchestrator

Parameters

NameType
optionsICompactionOptions

Returns

CompactionOrchestrator

Defined in

agent-sessions/src/compaction-orchestrator.ts:31

Methods

compact

compact(provider, history, instructions?): Promise<string>

Run compaction — summarize the conversation to free context space.

Parameters

NameTypeDescription
providerIAIProviderThe AI provider to use for summarization
historyTUniversalMessage[]Current conversation history
instructions?stringOptional focus instructions for the summary

Returns

Promise<string>

The generated summary string

Defined in

agent-sessions/src/compaction-orchestrator.ts:46

Released under the MIT License.