## TASK Find the safest stopping point for a session in a legal document. You MUST choose the latest complete Article boundary within the window. ## RULES (ABSOLUTE) 1. The ONLY valid primary breakpoints are full Articles. - Acceptable boundaries: "## Article X" "Article X" - NEVER break inside an Article unless the buffer ends before the next Article appears. 2. If the window does not contain a full Article boundary: - Back up to the nearest complete paragraph that ends with a full stop. - DO NOT use numbered clauses (1., 2., (a), (b)) as boundaries unless the entire Article is exhausted. 3. NEVER cut: - Mid-sentence - After a colon - Between a clause and its list (a, b, c) - Between subpoints of the same Article ## STRATEGY - Start at $window_end. - Scan backward ONLY for the most recent Article header. - If found: this is the break. - If NOT found: choose the latest fully complete paragraph, but ONLY if absolutely necessary. Priority order: Article boundary > complete paragraph > forced cut at buffer_end. ## TEXT WINDOW $lines_text ## INSTRUCTION Call `find_semantic_break`.