fix(v2): sequence write-side N=0/sortedness 단일소스화 — P1 출하율 0/9→8/9 (작업 B)#175
Merged
Conversation
… 모순 해소 (작업 B) int_array 입력형식 prose 가 size_range.min 과 무관하게 'N=0 이면 0 한 줄'을 무조건 방출 → render_constraints 의 N∈[min,max](min≥1)와 정면 충돌해 QA ambiguity reject (loop_accumulate 3/3·binary_search 3/3·lis 3/3 run 실측). graph empty bias 가 size_range.min 을 존중하는 것과 달리 sequence 프로즈만 단일소스화를 못 받은 Phase-1b-for-sequence 갭. - _int_array_format(field): N=0 절을 size_range.min==0 일 때만 방출(단일소스). _FORMAT_TEXT 에서 'int_array' 제거 — 빈 수열 절은 상수가 아니라 size_range 파생. - SORTEDNESS_LABEL/DUPLICATES_LABEL 단일소스: format prose(_sequence_clause)와 narrative DATA(SequenceBackbone.structural_facts)가 같은 라벨 READ → 드리프트 불가. non_decreasing 을 수식형(a[i] ≤ a[i+1])으로 — 평문 '오름차순' 병기가 순증가로 읽혀 '중복 값 가능'과 충돌하던 모호성 제거(binary_search 실측). serializer(_serialize_int_array/_sequence_values) 무수정 = 직렬화 바이트 byte-identical. 게이트: 899 passed/4 skipped, mypy --strict 100, ruff green. code-review APPROVE 0C0H0M.
LsMin124
pushed a commit
that referenced
this pull request
Jun 25, 2026
… 초급 트랙) - meta: main/dev c59244a, tests 768→862 (v1 515 + v2 347 worktree 실측), version '단일 IR 아키텍처 · 초급 트랙' - summary: 단일 ProblemIR 아키텍처 Phase 2~5a 완결(IR validator+순수투영+백본 G0~G2, #172) + 초급 트랙(#174) + sequence 모순해소(#175) - recentPrs #156~175, backlog 출하율 재측정 트랙, NFR-6/stack.pytest 347 - 4 HTML 하드코딩 테스트수 862
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
요약
sequence/array 문제의 write-side 모순 2종을 단일소스화로 해소. graph 가 #169
render_constraints코드파생으로 받은 단일소스화를 sequence 프로즈가 못 받던 Phase-1b-for-sequence 갭.문제 (실측 12 run, 전부 fail_qa)
_FORMAT_TEXT["int_array"]가size_range.min과 무관하게(N=0 이면 '0' 한 줄만)을 무조건 방출 →render_constraints의N∈[min,max](min≥1)와 정면 충돌. QA 리뷰어가 "input_format 은 N=0 허용, constraints 는 N≥1 → 모순" 으로 reject._sequence_clause가 non_decreasing 을비내림차(오름차순) 정렬로 표기 →(오름차순)이 순증가로 읽혀중복 값 가능과 충돌.수선 (write-side 단일소스화)
_int_array_format(field): N=0 절을size_range.min == 0일 때만 방출 (빈/최소 입력 의미를size_range.min단일소스에서 파생 — graph empty bias 와 동형)._FORMAT_TEXT에서int_array제거.SORTEDNESS_LABEL/DUPLICATES_LABEL단일소스: format prose(_sequence_clause) + narrative DATA(SequenceBackbone.structural_facts) 가 같은 라벨 READ → 드리프트 불가. non_decreasing 을 수식형a[i] ≤ a[i+1]으로._serialize_int_array/_sequence_values손대지 않음).측정 (P1, N=3, before 0/0/0)
N=0절 0/9, sortedness format 모호성 0/9.references스칼라 'index' ↔ narrative 'count' 모순 + 난이도 퇴화), 본 fix 무관.게이트
테스트 계획
test_render_int_array_omits_empty_clause_when_min_positive(min≥1 / None → N=0 절 없음)test_render_int_array_states_empty_clause_when_min_zero(min==0 → N=0 절)test_render_int_array_sortedness_is_unambiguous(오름차순 없음,a[i] ≤ a[i+1])test_render_int_array_strictly_increasing_uses_math_formtest_sortedness_label_single_sourced_with_structural_facts