Mind · Memory

ChunkMerge

Hierarchical context management

Definition

Mechanism

Cognitive Compression: Group related items into named chunks. Treat chunk as single unit in working memory. Hierarchy of chunks enables handling complexity beyond raw capacity. Merge when patterns repeat; split when chunk becomes unwieldy. It applies Aggregate to Compress multiple working memory items into a single labeled unit.

Preconditions

  1. Input chunks share semantic topic

Invariants

  1. The chunk's name states the criterion by which its items were grouped.
  2. The merged chunk retains a retrieval hook for each part.
  3. The merged chunk fits within `max_chunk_size`.

Risks

Failure modes

  1. Lossy Compression

    Discarding critical low-level details (e.g., specific ID numbers) during the merge process.

Relationships

Builds on

References

Infrastructure

Aggregate

Reduce a set to a summary statistic

Infrastructure

Compress

Lossy or lossless reduction

Infrastructure

Hierarchy

Vertical rank ordering with Upper/Lower relations, inheritance, and authority

Used by

References

Reference

Parameters

max_chunk_size PositiveInteger, unspecified
Largest merged chunk permitted, in the units the caller measures context by.

Identity

Ref
ChunkMerge#a7a3
Sema ID
sema:ChunkMerge#mh:SHA-256:a7a32d00372fcda30401ab77dbcb3a3b53fd3c4f013a2c9a5346e8b49ed76285
Ring
2
Tier
1
Updated
2026-11-11
Supersedes
  • sema:ChunkMerge#mh:SHA-256:ded6bbc1fcb067eaef0990ace28b3db2e0337744edac4e75c1da2ee1bbe3c351
  • sema:ChunkMerge#mh:SHA-256:e147d7618ec5f0a810d55c1671aefeda6a5ea31f0f33642660e715dd86404c68
  • sema:ChunkMerge#mh:SHA-256:2a85510f0a4d2505b0c577817b3e116dc203db4a2ff2755778ec9000c8e3cefc