Skip to content

PostCompactionHook

reference
1 min readUpdated

Kind: Type

Source: atloria-monorepo/libs/agent-core/src/session/types.ts

Callback invoked after context compaction. Receives recently accessed file paths. Returns file contents to inject as synthetic context items. This enables "hard rehydration" — automatically restoring working context after compaction, matching Claude Code's behavior.

Definition

ts
(recentFiles: string[]) => Promise<RehydrationItem[]> | RehydrationItem[]

Was this page helpful?

Download as PDF