diff --git a/docs/ouroboros/50_tpm_control_protocol.md b/docs/ouroboros/50_tpm_control_protocol.md index 619f6a8..ec52e6d 100644 --- a/docs/ouroboros/50_tpm_control_protocol.md +++ b/docs/ouroboros/50_tpm_control_protocol.md @@ -149,6 +149,7 @@ TPM 티켓 운영 규칙: - TPM은 합의된 변경을 이슈로 등록하고 우선순위(`P0/P1/P2`)를 지정한다. - PR 본문에는 TPM이 지정한 우선순위와 범위가 그대로 반영되어야 한다. - 우선순위 변경은 TPM 제안 + Main Agent 승인으로만 가능하다. +- PM/TPM/Dev/Reviewer/Verifier/Runtime Verifier는 주요 의사결정 시점마다 PR 코멘트를 남겨 결정 근거를 추적 가능 상태로 유지한다. 브랜치 운영 규칙: - TPM은 각 티켓에 대해 `ticket temp branch -> program feature branch` PR 경로를 지정한다. diff --git a/docs/ouroboros/60_repo_enforcement_checklist.md b/docs/ouroboros/60_repo_enforcement_checklist.md index 02f40e9..2573aea 100644 --- a/docs/ouroboros/60_repo_enforcement_checklist.md +++ b/docs/ouroboros/60_repo_enforcement_checklist.md @@ -50,6 +50,7 @@ Updated: 2026-02-26 - PR 본문에 `REQ-*`, `TASK-*`, `TEST-*` 매핑 표 존재 - `src/core/risk_manager.py` 변경 없음 - 주요 의사결정 체크포인트(DCP-01~04) 중 해당 단계 Main Agent 확인 기록 존재 +- 주요 의사결정(리뷰 지적/수정 합의/검증 승인)에 대한 에이전트 PR 코멘트 존재 - 티켓 PR의 base가 `main`이 아닌 program feature branch인지 확인 자동 점검: diff --git a/docs/workflow.md b/docs/workflow.md index f3bb3b0..814fe8c 100644 --- a/docs/workflow.md +++ b/docs/workflow.md @@ -22,6 +22,7 @@ - Ticket-level development happens only on **ticket temp branches** cut from the program feature branch. - Ticket PR merges into program feature branch are allowed after verifier approval. - Until final user sign-off, `main` merge is prohibited. +- 각 에이전트는 주요 의사결정(리뷰 지적, 수정 방향, 검증 승인)마다 PR 코멘트를 적극 작성해 의사결정 과정을 남긴다. ## Gitea CLI Formatting Troubleshooting diff --git a/src/analysis/walk_forward_split.py b/src/analysis/walk_forward_split.py index 2ff7837..2d2a3f4 100644 --- a/src/analysis/walk_forward_split.py +++ b/src/analysis/walk_forward_split.py @@ -68,8 +68,7 @@ def generate_walk_forward_splits( test_indices=list(range(test_start, test_end + 1)), ) ) - - prev_test_end = test_end + prev_test_end = test_end test_start += step return folds diff --git a/tests/test_walk_forward_split.py b/tests/test_walk_forward_split.py index c5003b8..5375798 100644 --- a/tests/test_walk_forward_split.py +++ b/tests/test_walk_forward_split.py @@ -59,6 +59,22 @@ def test_respects_min_train_size_and_returns_empty_when_impossible() -> None: assert folds == [] +def test_embargo_uses_last_accepted_fold_when_intermediate_fold_skips() -> None: + folds = generate_walk_forward_splits( + n_samples=30, + train_size=5, + test_size=3, + step_size=5, + embargo_size=1, + min_train_size=5, + ) + # 1st fold accepted, 2nd skipped by min_train_size, subsequent folds still generated. + assert len(folds) == 3 + assert folds[0].test_indices == [5, 6, 7] + assert folds[1].test_indices == [15, 16, 17] + assert folds[2].test_indices == [25, 26, 27] + + @pytest.mark.parametrize( ("n_samples", "train_size", "test_size"), [