Optional llmInvoker: ((prompt) => Promise<string>)Collapse the chain if it exceeds the token budget. Merges the oldest leaf nodes into a higher-level summary. Returns any newly created parent nodes.
Get the active chain — top-level nodes without parents, sorted by turn range.
Get all nodes (including absorbed children, for audit/UI).
Add new leaf nodes from a compaction.