pub fn plan_compaction(
messages: &[AgentMessage],
keep_recent_tokens: u64,
) -> CompactionPlanExpand description
Choose the cut point: walk back from the newest message accumulating
estimates until keep_recent_tokens, then snap to a turn boundary.