ACP v2 (Preview) TypeScript SDK — UNSTABLE - v2.12.1
    Preparing search index...

    Type Alias CompactionUpdate

    A context compaction upsert. The first notification fixes the compaction's timeline position. Later updates with the same ID patch that entity in place.

    Only compactionId is required. status, summary, error, and _meta have patch semantics: omission leaves the stored value unchanged, null clears it or resets it to its default, and a concrete value replaces it. summary: [] also clears the summary. A concrete _meta object patches the stored metadata by top-level key instead of replacing it.

    type CompactionUpdate = {
        compactionId: CompactionId;
        status?: CompactionStatus | null;
        summary?: ContentBlock[] | null;
        error?: string | null;
        _meta?: { [key: string]: unknown } | null;
    }
    Index
    compactionId: CompactionId

    The Agent-owned ID of this compaction, unique within the session.

    status?: CompactionStatus | null

    Current lifecycle status.

    Omission leaves the status unchanged, null resets it to in_progress, and a value replaces it. A new compaction starts as in_progress.

    summary?: ContentBlock[] | null

    Complete replacement user-displayable summary content for the compaction.

    error?: string | null

    Human-readable details of a compaction error, in plain text.

    _meta?: { [key: string]: unknown } | null

    The _meta property is reserved by ACP to allow Clients and Agents to attach additional metadata to their interactions. Omitted leaves the stored metadata unchanged. null clears it. An object patches the stored metadata by top-level key: keys it omits are unchanged, a key set to null is removed, and any other value replaces that key's stored value without merging nested objects. Beyond this patch rule, implementations MUST NOT assign meaning to keys they do not recognize.

    See protocol docs: Metadata Patches