precompact-hook-5-section-structure-prevents-artifact-loss

PreCompact hook should inject a 5-section structured self-summary before compaction: Task State, Decisions, Artifact Trail (verbatim index of file paths/function names/error codes), Observation Masking candidates, and Merge Directive. The Artifact Trail must be a separate verbatim index — not embedded in prose — because all compression methods score 2.2-2.5/5.0 on artifact preservation, making it the weakest dimension universally. Full prose summaries cause artifact loss on every compaction cycle.