Kind: Interface
Source: atloria-monorepo/libs/agent-core/src/context/compaction-types.ts
Smart Compaction Types
Structured schema for model-based context compaction. The CompactionSummary is a persistent, evolving document that captures everything the agent needs to continue working after context compression.
Anchored Iterative Summarization (Factory.ai pattern):
- First compaction: summarize full history into CompactionSummary v1
- Subsequent compactions: merge NEW items into existing summary (delta merge)
- Code snippets are NEVER summarized — preserved verbatim
Properties
| Property | Type |
|---|---|
sessionGoal | string |
progress | `{ |
/** Tasks/steps already completed */ completed: string[]; /** What the agent is currently working on */ inProgress: string; /** Known remaining steps */ remaining: string[]; /** Things preventing progress */ blockers: string[];
}| |fileOperations|Array<{
path: string;
action: 'created' | 'modified' | 'read' | 'deleted';
/** What was done or learned from this file */
keyDetails: string;
}>| |decisions|Array<{
decision: string;
rationale: string;
}>| |errors|Array<{
error: string;
resolved: boolean;
resolution?: string;
}>| |preservedCode|Array<{
file: string;
snippet: string;
why: string;
}>| |domainState|Record<string, string>` |
Was this page helpful?