Repository navigation
Description
Machine-Readable Contract
contract_schema_version: v1
issue_kind: parent
goal_ref: "OPEN Issue間のsemantic relation(重複・依存順・実装優先順位)判定をissue-refinement-loopの唯一のauthorityに一元化し、downstream skill(impl-review-loop・issue-contract-review・implement-issue・open-pr)はsemantic reclassificationを行わず、handoff artifactのfreshnessとGit/PRの実観測(commit生成後のpairwise merge競合、target PRのGitHub mergeability)だけを検証する設計へ揃える"
change_kind: workflow
parent_mode: "delivery-rollup"
closure_mode: "child-complete"Summary
現状、OPEN Issue間の「重複」「依存順」「実装優先順位」の判定責務が issue-refinement-loop(scope rollup preflight)・impl-review-loop(preparation Step 2.5 の scope-rollup-runner 再実行)・implement-issue(check_implementation_overlap.py による OPEN Issue全件再検査)・issue-contract-review(#387 の重複分類)に分散している。この結果、人間が impl-review-loopで対象Issueの実装を明示指示した後になって、downstream側が「他のIssueと実装領域が被っている」「どちらを先に実行すべきか」を改めて言い出す構造になっており、人間から見て指示した実装が始まらない・後退する体験になっている。本Issueは、この判定責務の再集約を行う delivery-rollup parent trackerである。
初版(2026-07-23 起票)は OWNER レビュー(anchor comment、2026-07-23、REQUEST_CHANGES)により、「意味的な計画判断の一元化」「判断結果のfreshness再検証」「Git/PR上の実競合観測」の3つを混同していると指摘された。本改訂はその指摘(P0-1〜P0-5、P1-1〜P1-4、P2-1〜P2-3)を反映する。
Goal
- issue-refinement-loopを、OPEN Issue間のsemantic relation(重複・吸収候補・依存順・実装優先順位)判定の唯一のauthority(planning SSOT)にする。impl-review-loop開始前にこの判定は完了している前提とする
- downstreamはsemantic relationを再分類しない。ただし、downstreamは各実行地点で以下をfreshに検証する責務を持つ:
- handoff artifactのfreshness(body hash・updated_at・base SHA・policy version・source completeness・digest)
- commit生成後のpairwise Git merge競合(
git merge-tree相当の3-way merge simulation。changed-file名の重複ではない) - target PRのGitHub mergeability(
mergeable/mergeStateStatusを正しく区別)
- drift・stale・not_evaluable・unknown を検知した場合、downstreamは独自判断でcontinueせず、issue-refinement-loopへrerouteする
- one decision authority(issue-refinement-loop), multiple freshness/safety observers(downstream各skill) という責務分離を確立する
Desired Destination
ISSUE_EXECUTION_DECISION_V1(下記 schema 参照)が、Issue relationをversioned graphとして表現し、issue-refinement-loopのplannerからLOOP_STATE・handoff・termination reportまで同一digestで到達している状態- docs/dev/scope-rollup-policy.md または同等のSSOT docsと docs/dev/workflow.md が、「semantic relation判定はissue-refinement-loopが唯一のauthority」「downstreamはfreshness/実観測のみ検証」という方針を明記した状態
- issue-contract-review が fresh structural gate(テンプレート・Allowed Paths・VC・dependency・worktree・branch命名衝突・artifact freshness確認)に縮小され、実装: issue-contract-review に scope_collision_check を JSON / script-first で追加する #387 のsemantic分類ロジックが supersede されているか issue-refinement-loop側 producer へ rehome されている状態
- impl-review-loop の Step 2.5(scope-rollup-runner経由の重複再判定)が撤去され、issue-refinement-loopのhandoff判定をconsumeするだけになっている状態(PR feat(codex): scope-rollup-runner native agentを追加 (#1671) #1685 の Codex scope-rollup-runner dispatch 機能の扱いが明示決定されている前提)
- implement-issue の check_implementation_overlap.py によるOPEN Issue全件再検査が撤去され、target-issue executorへ縮小されている状態(実装: overlap preflight の共有スキーマ誤検知を防止する #1652 のprovenance/classifier改善が新producerへ移植されているか、#1652自体がsupersedeされている前提)
- open-pr の hard gate(overlap evidence必須・digest検証・オンライン再実行・fail-closed)が、旧evidenceから新
ISSUE_EXECUTION_DECISION_V1へ dual-write → dual-read → cutover → cleanup の順で移行され、移行期間中もPR publicationが意図せず停止・bypassされない状態 - 対象branch/head が未作成の contract-review 時点では
declared_path_overlap(advisory)、commit/PR時点の実Git競合はpairwise_merge_conflict(blocking)として明確に二層化されている状態
Current Validated Scope
対象スキルとその該当箇所は repo 内に実在することを確認済み:
- .claude/skills/issue-refinement-loop/scripts/plan_issue_scope_rollup.py(ISSUE_SCOPE_ROLLUP_DECISION_V2を記録するscope rollup preflight)
- .claude/skills/issue-refinement-loop/scripts/run_refinement_preflight.py(target Issue snapshot・planner input・refinement resultのみ永続化。scope-rollup artifactの明示フィールドを持たない)
- .claude/skills/issue-refinement-loop/scripts/build_loop_state.py・schemas/loop_state.schema.json(
additionalProperties: false、現行4種のdecisionのみ投影) - .claude/skills/impl-review-loop/steps/preparation.md(Step 2.5のscope-rollup-runner経由preflight再実行)
- .claude/skills/implement-issue/(check_implementation_overlap.pyによるOPEN Issue全件検査)
- .claude/skills/issue-contract-review/(template・Allowed Paths・VC・dependency・worktree・branch collisionチェック。#387のsemantic分類ロジックを含む)
- .claude/skills/open-pr/scripts/open_pr.py 相当(linked Issueがphase/implementationならoverlap evidence必須・digest検証・check_implementation_overlap.pyオンライン再実行・fail-closed のproduction hard gate)
本parent Issue自体は実装変更を行わない。実装・docs変更はすべて子Issueで行う。
Decisions Fixed
- 2026-07-23: OPEN Issue間のsemantic relation判定はissue-refinement-loopに一元化し、downstream skillはこの判定を再分類しない方針を確定
- 2026-07-23(改訂): downstreamの停止条件を「Allowed Paths・ファイルの単純な重複」から「commit生成後のpairwise Git merge競合(
git merge-tree相当の3-way merge simulationで検出。changed-file名の重複ではない)」または「target PRのmergeable == CONFLICTINGもしくはmerge_state_status == DIRTY(両者は別フィールドであり混同しない。UNKNOWN/null はfail-closedでbounded retry後にindeterminateまたはhuman escalationへ倒す)」に限定する方針を確定 - 2026-07-23(改訂): 「semantic relationの再分類禁止」と「handoff artifactのfreshness検証」は別責務であり、downstreamはfreshness検証を省略しない方針を確定(P1-1対応)
- 2026-07-23(改訂): 実装: issue-contract-review に scope_collision_check を JSON / script-first で追加する #387 は 導入: OPEN Issue 重複・依存順・実装優先順位判定を issue-refinement-loop に一元化する #1674 へ supersede してクローズするか、classifier/provenanceロジックをissue-refinement-loop側producerへrehomeするかのいずれかとし、issue-contract-reviewを第二のplanning authorityにしない方針を確定(P0-5対応。具体的選択は子Issue 実装: issue-contract-review を fresh structural gate に縮小し、OPEN PR の実編集競合のときだけ停止させる #1680 で決定する)
- 2026-07-23(改訂): 実装: implement-issue / open-pr の production path から peer OPEN Issue overlap preflight を撤去する #1679(check_implementation_overlap.py撤去)は open-pr のproduction hard gateとのdual-write/dual-read/cutover/cleanup migrationを含めることを確定し、checker単純削除・no-op化のいずれも不採用とする(P0-4対応)
- 2026-07-23(改訂): 実装: overlap preflight の共有スキーマ誤検知を防止する #1652(check_implementation_overlap.pyの改善Issue)は、そのprovenance/classifier部分を新upstream producerへ移植するか、#1674へsupersedeするかのいずれかとし、「精度を上げてから削除」という無駄な系列は採用しない(P1-3対応)
- 2026-07-23(改訂): OPEN Draft PR feat(codex): scope-rollup-runner native agentを追加 (#1671) #1685(#1676が削除対象とするStep 2.5にCodex custom named agent dispatchを追加中)の扱い(先にマージ/別stepへ移設/supersede/capability保持)を 実装: impl-review-loop preparation から scope rollup preflight(Step 2.5)を除去し、issue-refinement-loop の判定を再実行しない #1676 着手前に明示決定する方針を確定(P1-2対応)
- 2026-07-23(改訂): 子Issueの実装順序は docs-first ではなく、schema定義 → producer/dual-write → consumer移行/dual-read → 実競合detector導入 → legacy cleanup の Phase A〜E順で行う方針を確定(P1-4対応)
- 2026-07-23: scope rollup preflightの実行エンジンそのものの書き換え、およびOPEN PR間のマージ順序自動化は本Issueの非ゴールとする
Quality Decision Record
- Status: N/A
- Decision Date: 未記録
- Does this prove the parent goal complete?: N/A
- Reason: delivery-rollup parentのためchild issue rollup完了で判定する(quality-gateではない)
- Evidence: N/A
- Next Action: 子Issue(Child Issuesセクション参照)のPhase A〜E順での改訂・起票・実装・マージ
Parent Closure Rule
- delivery-rollup: Child Issuesセクションに列挙するすべての子Issueがクローズ(実装Issueはマージ済みPRでクローズ)され、かつ Acceptance Criteria の end-to-end AC(AC5〜AC9)がmain上でPASSした時点で本parent Issueをクローズする
- quality-gate: N/A(本parentはquality-gateではない)
- routing-map: N/A(本parentはrouting-mapではない)
- decision-log: N/A(本parentはdecision-logではない)
- quality-gate parentではないためQuality Decision Recordはクローズ判定の必須材料にしない
Child Issues
Phase A — 契約固定(着手済み子Issue全件の再改訂が前提)
- 実装: scope-rollup-policy を停止系SSOTから実行優先順位を選ぶplanning SSOTへ再定義する #1675 SSOT(scope-rollup-policy.mdおよびdocs/dev/workflow.md)を「停止系」から「実行優先順位を選ぶplanning SSOT」へ再定義する(
ISSUE_EXECUTION_DECISION_V1schema・実装: issue-contract-review に scope_collision_check を JSON / script-first で追加する #387/実装: overlap preflight の共有スキーマ誤検知を防止する #1652/PR #1685の吸収方針をdocsに反映するよう改訂が必要)
Phase B — producerとhandoff
- 実装: issue-refinement-loop planner に execution_priority と relation_summary を追加する #1677 issue-refinement-loopのplannerに
ISSUE_EXECUTION_DECISION_V1(relationをversioned graph化。単数のrelation_summary/selected_predecessorから変更)を追加し、run_refinement_preflight.py・build_loop_state.py・loop_state.schema.json・LOOP_HANDOFF_RESULT_V1・termination report producer/parser・downstream consumer inventoryをAllowed Pathsに含めるよう改訂が必要(1に依存。P0-3対応)
Phase C — consumer migration
- 実装: issue-contract-review を fresh structural gate に縮小し、OPEN PR の実編集競合のときだけ停止させる #1680 issue-contract-reviewを
declared_path_overlap(advisory、issue/contract時点)とpairwise_merge_conflict(blocking、git merge-tree相当の3-way merge simulationによるcommit/PR時点判定)の二層に分割し、OPEN PR inventoryの完全性契約(--state open・base branch明示・draft policy・fork PR識別・pagination/limit/totalCount照合・complete flag・inventory digest・fail-closed)を追加するよう改訂が必要(1・2に依存。P0-1・P2-1対応) - 実装: impl-review-loop preparation から scope rollup preflight(Step 2.5)を除去し、issue-refinement-loop の判定を再実行しない #1676 impl-review-loop preparationのStep 2.5(scope rollup preflight再実行)を撤去し、issue-refinement-loopのhandoff判定をconsumeするだけにする。PR feat(codex): scope-rollup-runner native agentを追加 (#1671) #1685 の Codex scope-rollup-runner dispatch 機能の migration decision(マージ順・移設先)を明示するよう改訂が必要(1・2・3に依存。P1-2対応)
- 実装: implement-issue / open-pr の production path から peer OPEN Issue overlap preflight を撤去する #1679 implement-issueのcheck_implementation_overlap.pyによるOPEN Issue全件再検査を撤去し、target-issue executorへ縮小する。open-pr のdual-write/dual-read/cutover/cleanup migrationをAllowed Pathsに含め、実装: overlap preflight の共有スキーマ誤検知を防止する #1652 のprovenance/classifier部分の移植またはsupersede方針を明示するよう改訂が必要(1・2・3に依存。P0-4・P1-3対応)
Phase D — 実競合detector(新規子Issueが必要。起票は Phase A〜C の契約確定後)
- (未起票)target head生成後のpairwise merge simulation・head/base SHA binding・rename/delete/file-directory conflict fixture・
mergeable/mergeStateStatusのfail-closed retry routing を実装する子Issueを、Phase A〜C の契約確定後に起票する
Phase E — cleanup(新規子Issueが必要。Phase D完了後)
- (未起票)legacy OPEN Issue enumerationの削除・old evidence schemaの廃止・docsの最終authority切替・end-to-end regressionを実施する子Issueを、Phase D完了後に起票する
Remaining Parent Gaps
- Phase D(実競合detector)・Phase E(cleanup)の子Issueは未起票。Phase A〜Cの契約確定後に起票する
- 実装: issue-contract-review に scope_collision_check を JSON / script-first で追加する #387・実装: overlap preflight の共有スキーマ誤検知を防止する #1652・PR feat(codex): scope-rollup-runner native agentを追加 (#1671) #1685 の具体的な処置(supersede/rehome/migration先)は 実装: issue-contract-review を fresh structural gate に縮小し、OPEN PR の実編集競合のときだけ停止させる #1680・実装: implement-issue / open-pr の production path から peer OPEN Issue overlap preflight を撤去する #1679・実装: impl-review-loop preparation から scope rollup preflight(Step 2.5)を除去し、issue-refinement-loop の判定を再実行しない #1676 の改訂内でそれぞれ確定する
- scope rollup preflightの実行エンジンそのものの書き換え(本Issueの非ゴール。必要になれば別Issueで扱う)
- OPEN PR間のマージ順序自動化(本Issueの非ゴール。「いつ止めるか」の判定基準整理のみが本Issueの範囲)
Phase Handoff Contract
- Desired Destination: 本IssueのDesired Destinationをそのまま各子IssueのBackgroundに転記する
- Current Validated Scope: 各子Issueが対象とするskill・docsパスのみをindividual child issueのIn Scopeにnarrowする(Phase B以降はAllowed Pathsを downstream配線ファイル群まで拡張する)
- Remaining Parent Gaps: 本IssueのRemaining Parent Gapsを参照し、子Issue完了後も残るgapを明記する
- Current Objective: 子IssueごとのOutcomeに記載
- Bounded Current Context: 本IssueのSummary・Goal・Decisions Fixedを子IssueのBackgroundに要約引用
- Normative References: docs/dev/scope-rollup-policy.mdまたは実在パス・docs/dev/workflow.md・.claude/skills/issue-refinement-loop/SKILL.md・.claude/skills/impl-review-loop/steps/preparation.md・.claude/skills/issue-contract-review/SKILL.md・.claude/skills/implement-issue/・.claude/skills/open-pr/
- Allowed Paths: 各子Issueが対象とするskill・docsの完全パスに限定
- Required Skills: 子Issue起票時に該当ドメイン知識スキルのみ記載(ワークフローskillは記載しない)
- Validation Commands: 子Issueごとにrg・pytest等の単一コマンドで記載
- Stop Conditions: implementation.ymlの6定型項目を子Issueごとに具体化
- Open Questions: 実装: issue-contract-review に scope_collision_check を JSON / script-first で追加する #387/実装: overlap preflight の共有スキーマ誤検知を防止する #1652/PR #1685の処置は各該当子Issueで確定するまでOpen(Notes for Reviewer参照)
- Next Action: 各子Issueの改訂・起票・実装・マージ(Phase A〜E順)
- Artifact Refs: 本parent Issue URL
- Handoff Prompt Draft: 子Issue起票時にimpl-review-loopを人間が発火する想定を明記
- Linked PR: 各実装子Issueのマージ済みPR
Allowed Paths
本 parent issue は Allowed Paths を持たない。実装・docs 変更はすべて子Issue(Child Issues 参照)側の Allowed Paths に従う。
Acceptance Criteria
- AC1: Child Issuesセクション(Phase A〜C の既起票5件)が、本改訂の反映要求(P0-1〜P0-5対応)を含む形で改訂され、本Issue本文からIssue番号でリンクされている
- AC2: 本Issue本文のDecisions Fixedに「semantic relationの再分類禁止」と「handoff artifact freshness / pairwise Git merge競合 / GitHub mergeability(mergeableとmergeStateStatusを区別)の各observer責務」が明記されている
- AC3: 各子Issueが本Issueへのdepends on関係で本Issueと相互リンクされている(子Issue本文側で確認)
- AC4: 実装: issue-contract-review に scope_collision_check を JSON / script-first で追加する #387・実装: overlap preflight の共有スキーマ誤検知を防止する #1652・PR feat(codex): scope-rollup-runner native agentを追加 (#1671) #1685 の処置(supersede/rehome/migration先)が該当子Issue本文に機械可読な形で記録されている
- AC5:
ISSUE_EXECUTION_DECISION_V1artifactが、refinement producerからLOOP_STATE・handoff・impl-review-loop・implement-issue・open-prまで同一digestで到達することがproduction testで確認されている(Phase B〜C完了後) - AC6: downstreamがOPEN Issue一覧を取得してrelationを再分類しないことがproduction testで確認されている(Phase C完了後)
- AC7: Issue body更新・新規dependency・新規OPEN Issue/PR・PR force-push・base SHA更新の各ケースでartifactがstaleになりrefinementへrerouteされることが確認されている(Phase C完了後)
- AC8: 同一ファイルの別hunkを変更するPRがchanged-file overlapだけでhard blockされないこと、rename/delete/binary/file-directory conflictがmerge simulationで正しくblockされることがfixtureで確認されている(Phase D完了後)
- AC9: legacy期間中もPR publicationが意図せず停止・bypassされないことがopen-pr側のdual-write/dual-read移行テストで確認されている(Phase C〜E)
- AC10: Phase D・E の子Issueが起票され、本Issue Child Issuesセクションに追記されている
- AC11: 5件(Phase A〜C)+Phase D・E の全子Issueがクローズ(実装Issueはマージ済みPRでクローズ)され、AC5〜AC9のend-to-end scenarioがmain上でPASSした時点で本parent Issueがクローズ可能な状態になっている
Verification Commands
parent tracker のため各 VC は field 出力を human/reviewer が目視確認する placeholder とする。
# AC1
# baseline-expect: pass
# preflight-scope: pr_review_only
$ gh issue view 1674 --repo squne121/loop-protocol --json body --jq '.body'# AC2
# baseline-expect: pass
# preflight-scope: pr_review_only
$ gh issue view 1674 --repo squne121/loop-protocol --json body --jq '.body'# AC3
# baseline-expect: pass
# preflight-scope: pr_review_only
$ gh issue view 1675 --repo squne121/loop-protocol --json body --jq '.body'# AC4
# baseline-expect: fail
# preflight-scope: pr_review_only
$ gh issue view 1680 --repo squne121/loop-protocol --json body --jq '.body'# AC10
# baseline-expect: fail
# preflight-scope: pr_review_only
$ gh issue view 1674 --repo squne121/loop-protocol --json body --jq '.body'# AC11
# baseline-expect: fail
# preflight-scope: pr_review_only
$ gh issue view 1674 --repo squne121/loop-protocol --json state --jq '.state'Notes
停止条件(本Issue自体は実装を行わないため子Issue起票・改訂時の停止条件を記録する):
- 子Issueのスコープ分割が技術的に成立しない(1つのスキルへの変更が他スキルの契約を同時に壊すため分離不能)と判明した場合は、統合案を人間に提示してから起票する
- 子Issue改訂・起票中に既存OPEN Issueとの重複が検出された場合は、重複統合の3択(追記・統合しクローズ・scopeが異なるため新規起票)を人間に提示してから進める
- 子Issueの実装がSSOTの他docs(docs/dev/workflow.md等)の既存契約と矛盾する場合は、矛盾解消の方針を人間に確認してから実装を進める
- 子IssueのAC・VCが曖昧化し検証不能になる場合は起票を中止し、具体化案を提示する
- 5件(Phase A〜C)のうち1件でもhuman_judgment・needs_fixのcontract review結果が反復して解消しない場合は、人間に判断を仰ぐ
- 実装: issue-contract-review に scope_collision_check を JSON / script-first で追加する #387・実装: overlap preflight の共有スキーマ誤検知を防止する #1652・PR feat(codex): scope-rollup-runner native agentを追加 (#1671) #1685 の処置方針が該当子Issueで確定しないまま Phase D・E の子Issueを起票しない
Notes for Reviewer:
- 本改訂は OWNER anchor comment(2026-07-23、REQUEST_CHANGES)の P0-1〜P0-5・P1-1〜P1-4・P2-1〜P2-3 を反映したものである。実装: scope-rollup-policy を停止系SSOTから実行優先順位を選ぶplanning SSOTへ再定義する #1675・実装: impl-review-loop preparation から scope rollup preflight(Step 2.5)を除去し、issue-refinement-loop の判定を再実行しない #1676・実装: issue-refinement-loop planner に execution_priority と relation_summary を追加する #1677・実装: implement-issue / open-pr の production path から peer OPEN Issue overlap preflight を撤去する #1679・実装: issue-contract-review を fresh structural gate に縮小し、OPEN PR の実編集競合のときだけ停止させる #1680 の各子Issue本文はまだ未改訂であり、本Issueの改訂内容(Allowed Paths拡張・二層設計・schema変更・migration方針)を反映する追加改訂が別途必要。
- #1680の作成transactionで
phase/contract-reviewlabelが欠落しtriage-requiredのままである taxonomy drift(P2-3)も、#1680改訂時にあわせて解消する。
Activity
squne121 commentedon Jul 23, 2026
判定
REQUEST_CHANGES — 方向性は妥当ですが、現行契約のままでは実装開始不可です。
「OPEN Issue間の意味的な重複・依存順・優先順位を一度だけ決める」という設計は正しいです。しかし #1674 は、次の三つを混同しています。
結果として、既存のfail-closed gateを先に撤去し、代替artifactが後続skillへ届かない設計になっています。さらに「実編集競合」の検出方法が実際にはchanged-file名の重複であり、Gitのmerge conflict判定ではありません。親Issue自体にはコメントがなく、この設計上の未決事項に対するOWNER判断も記録されていません。
重大な指摘
P0-1: #1680 の「実編集競合」は、実際にはファイル名の重複判定です
#1680 は、対象IssueのAllowed PathsとOPEN PRのchanged filesが重なれば
parallel_change_conflictとして停止する設計です。しかし、想定されているgh pr diff --name-onlyはdiffから変更ファイル名を列挙するだけです。GitHub CLIの実装も、raw diffのdiff --githeaderを正規表現で抽出しているだけで、3-way merge、hunk競合、rename/delete競合などは評価しません。この判定には、少なくとも次の誤りがあります。
Gitの実競合を判定するなら、対象branchにcommitが存在した後、合意したbase/head SHAを固定して
git merge-tree --write-tree相当の3-way mergeを実行する必要があります。このコマンドは実際のmergeと同様にcontent merge、rename detection、file/directory conflict、複数merge-base処理を行い、clean/conflictingをexit statusで区別します。したがって #1680 は、次の二層に分割すべきです。
declared_path_overlap。planning evidenceであり、単独ではblockingにしないpairwise_merge_conflict。対象head・相手head・merge baseを固定したGit merge simulation現在の #1680 のAC3は、「実編集競合」という名称に反してchanged-path overlapしか証明しません。
P0-2:
CONFLICTINGとDIRTYは同一フィールドの値ではありません#1674、#1675、#1676は「PRのmergeable状態がCONFLICTINGまたはDIRTY」と記述しています。しかしGitHubのデータモデルでは別フィールドです。
mergeable:MERGEABLE | CONFLICTING | UNKNOWNmergeStateStatus:CLEAN | DIRTY | BEHIND | BLOCKED | DRAFT | HAS_HOOKS | UNSTABLE | UNKNOWNリポジトリ内の
LOOP_VERDICT_V2schema自体はこの区別を正しく持っています。ところがStep 5の表とproduction routerは、CONFLICTINGをmerge_state_statusの値としても受け入れており、既にsplit-brainが存在します。GitHub公式のenumも両者を明確に分離しています。さらにREST APIの
mergeableは計算中にnullを返し、その場合は再取得が必要です。 ([GitHub Docs]1)正しい契約は次です。
加えて、
UNKNOWN/ RESTのnullはcleanとして扱わず、bounded retry後にindeterminateまたはhuman escalationへ倒す必要があります。より重要なのは、あるOPEN PRが自身のbase branchに対して
CONFLICTING/DIRTYであることは、そのPRと未来の対象branchが互いに競合する証明ではないことです。GitHubのmergeabilityは各PRとそのbaseのtest mergeを評価するものであり、任意の二つのOPEN PR間のpairwise conflictではありません。 ([GitHub Docs]2)P0-3: #1677 の出力は downstream handoff まで到達しません
#1677 は
plan_refinement_loop.pyに以下を追加するとしています。relation_summaryexecution_priorityselected_predecessordefer_reasonimpl_execution_policyしかし現行の実行経路には、scope-rollup出力をrefinement plannerへ自動的に結合するproducer/joinがありません。
run_refinement_preflight.pyが永続化するのは、target Issue snapshot、planner input、refinement resultだけです。fixture input schemaもIssue、comments、任意のknown_contextまでで、完全取得したOPEN Issue/PR inventoryやscope-rollup artifactの明示フィールドを持ちません。その後の経路も未対応です。
build_loop_state.pyは現行4種のdecisionだけを必須化・投影するLOOP_STATE_V1はadditionalProperties: falseLOOP_HANDOFF_RESULT_V1もstrict schemaしたがってplanner JSONにフィールドを足すだけでは、後続skillが読むartifactには入りません。
#1677 のAllowed Pathsには、少なくとも次が不足しています。
run_refinement_preflight.pybuild_loop_state.pyloop_state.schema.jsonの明示的変更loop_handoff_result_v1.jsonまた、
relation_summaryとselected_predecessorが単数なのも不十分です。一つのIssueは複数Issueに対して異なるrelationを持ち、複数predecessor、cycle、coordination edgeを持ち得ます。必要なのは単数のsummaryではなく、versioned relation graphです。P0-4: #1679 は
open-prのhard gateを破壊します#1679 は
check_implementation_overlap.pyの呼び出しを削除またはno-op化しますが、open-prskillとの契約修正を明示的にOut of Scopeにしています。一方、現行
open_pr.pyは次を強制しています。phase/implementationならoverlap evidenceを省略不可check_implementation_overlap.pyをオンラインで再実行decision_inputs_sha256とstored valueを比較これは単なる文書上のconsumerではなく、PR作成直前のproduction hard gateです。
したがって #1679 だけを実装すると、二択になります。
どちらも受け入れ不能です。#1679には
open-prmigrationを含める必要があります。少なくとも移行期間は次の順序が必要です。ISSUE_EXECUTION_DECISION_V1をupstreamでdual-writeopen-prを旧evidence/new artifactのdual-readにするcheck_implementation_overlap.pyの全件列挙を削除P0-5: #387 を残すと、issue-contract-reviewが第二のplanning authorityになります
#387 は、issue-contract-review内でOPEN implementation Issueを列挙し、Allowed Paths overlap、dependency relation、C0/C2a/C2b等を分類し、その結果を
CONTRACT_REVIEW_RESULT_V1とstatus判定に組み込む設計です。過去の敵対的レビューでも、「standalone helperではなくpreflight gateへmaterializeすべき」と明示されています。#1680 は、#387とはデータソースが異なるため統合せず、#387のマージ状況を確認して直列化するとしています。これは #1674 の「relation/priority判定はissue-refinement-loopだけ」というGoalと両立しません。
#387は次のどちらかにすべきです。
#387をそのままマージしてから #1680 で「OPEN Issue重複は見ない」と変更するのは、短期間に同じskillへ相反するauthorityを導入・撤去する無駄な系列です。
追加のrelease blocker
P1-1: 「再判定禁止」と「freshness検証禁止」を混同しています
semantic relationの再分類をdownstreamで禁止するのは妥当です。しかし、upstream artifactが現在も有効かどうかはdownstreamで検証しなければなりません。
既存の
open-prhard gateは、Issue body、label、候補Issue、dependencyがevidence収集後に変化するTOCTOUを受けて追加されています。#1458は、これをatomic保証ではなく「mutation直前のbounded freshness gate」と明確に位置づけています。PR #1467もcallerによる省略を許さないhard gateとして実装しました。正しい責務分離は次です。
つまり、one decision authority, multiple freshness/safety observers が必要です。
P1-2: 現在OPENのPR #1685が、#1676の停止基準の反例になっています
OPEN Draft PR #1685は、#1676が削除対象とする
preparation.mdのStep 2.5に、Codex custom named agent dispatchを追加しています。PRは現在open、draft、mergeableです。#1676はそのStep 2.5全体を削除・consume-only化します。
これは重要な反例です。
mergeable: trueCONFLICTING/DIRTYだけではsemantic/destructive coordination conflictを検出できない#1676には、少なくとも #1671 / PR #1685とのmachine-readable dependencyとmigration decisionが必要です。
現在の #1676 にはこの判断がありません。
P1-3: #1652を完成させた後にcheckerを削除する計画は、作業を無駄にします
#1652は
check_implementation_overlap.pyのschema token provenance、false-positive抑制、true-positive recall、固定fixtureを改善するIssueです。詳細レビューではconsumer inventoryとadditive evidence fieldsまで要求されています。一方、#1679は「#1652を先にマージした後、同checkerによる全件再検査を撤去する」としています。
妥当な選択肢は二つだけです。
「精度を上げてから削除」は避けるべきです。
P1-4: 子Issueの分割順序では一時的なsplit-brainが必ず発生します
現在の順序は概ね次です。
しかし、各PRを単独でmerge可能にするcompatibility contractがありません。
#1677自身も、#1675への依存を「望ましいが並行可能」としており、親Issueの順序契約と一致しません。さらに、24件のOPEN IssueとのAllowed Paths overlapを「関心事が別」とだけ判断し、実際のOPEN PR/head/patchとの照合を行っていません。
docs-firstではなく、schema・dual-write・dual-read・cutover・cleanup の順に変更すべきです。
品質・運用上の不足
P2-1: OPEN PR inventoryの完全性契約がありません
#1680は
gh pr list相当を想定していますが、取得件数、base filter、pagination、draft、fork、current/target PRの除外、totalCount照合をACに持ちません。gh pr listの既定limitは30件です。--limitを明示しない実装は、31件目以降のOPEN PRを黙って見落とします。 ([GitHub CLI]3)exact executorには最低限、次が必要です。
--state opencomplete: true|falseP2-2: Acceptance Criteriaがintegrationを証明していません
親Issueのclosureは、5子Issueがcloseされたことしか要求しません。したがって、各PRが個別にmergeされてもartifactが一度もend-to-endでconsumedされていない状態で親をcloseできます。
個別にも不足があります。
#1675はgrepによる文言存在確認だけ
#1680は「テストで確認」としつつVerification Commandsはほぼ
rg#1680は
CONTRACT_REVIEW_RESULT_V1.checksへのfield追加をIn Scopeにしながら、schema/key変更が必要ならStop Conditionという自己矛盾を持つ#1676は文言不在確認中心で、既存artifact consumerが壊れないことを検証しない
#1679はopen-pr pathがAllowed Paths外
P2-3: workflow metadataが既にdriftしています
#1680の作成transactionでは
phase/contract-reviewlabelが存在せず、label適用がpartial failureになっています。現在のIssueはtriage-requiredを持ったままです。phase labelやIssue kindをcandidate selectionに使う設計である以上、このtaxonomy driftは先に解消すべきです。推奨する再設計
1. planning decisionとruntime observationを分離する
Planning artifact
Runtime observations
git merge-treeresultmergeable/mergeStateStatusIssue relationはupstreamだけが決めますが、runtime observationsは各実行地点でfreshに取得します。
2. 子Issueを次の順序に変更する
Phase A — 契約固定
ISSUE_EXECUTION_DECISION_V1を定義Phase B — producerとhandoff
Phase C — consumer migration
Phase D — 実競合detector
Phase E — cleanup
#1675のdocs authority切替はPhase Aの「将来契約記載」か、Phase Eのproduction cutover時に移すべきです。
親Issueに追加すべき必須AC
少なくとも以下を親closure gateに追加すべきです。
Artifact propagation: refinement producerが出したexecution decisionが、LOOP_STATE、handoff、impl-review-loop、implement-issue、open-prまで同一digestで到達する。
No semantic reclassification: downstreamがOPEN Issue一覧を取得してrelationを再分類しないことをproduction testで確認する。
Freshness: Issue body更新、新規dependency、新規OPEN Issue、新規OPEN PR、PR force-push、base SHA更新の各ケースでartifactがstaleになり、refinementへrerouteされる。
Same-file non-conflict: 同一ファイルの別hunkを変更するPRはchanged-file overlapだけでhard blockしない。
Real Git conflicts: rename/delete、binary、file/directory conflictがmerge simulationでblockされる。
Not evaluable: 対象branch/head未作成時は
cleanではなくnot_evaluableとし、declared overlapをadvisoryに限定する。GitHub mergeability:
mergeable=UNKNOWN、RESTmergeable=null、mergeStateStatus=UNKNOWNがretry後にfail-closedとなる。Inventory completeness: 31件以上のOPEN PR fixtureでも完全取得を証明する。
Open-pr compatibility: legacy gateが存在する期間、新旧いずれの経路でもPR publicationが意図せず停止・bypassされない。
feat(codex): scope-rollup-runner native agentを追加 (#1671) #1685 migration: Codex scope-rollup-runner capabilityを削除するのか移設するのかが明示され、対応するfixture/E2E testがある。
Parent closure: 子Issueのcloseだけでなく、上記end-to-end scenarioがmain上でPASSしたことを必須化する。
最終結論
#1674の中心思想は採用できます。
ただし、停止条件は次のように修正すべきです。
現状のままでは、#1680がfalse-positive detectorになり、#1677のdecisionがhandoffに届かず、#1679がopen-pr hard gateを破壊し、#387が第二のplanning authorityとして残ります。
#1675のdocs変更や#1679のchecker撤去には着手せず、まず親Issue、#1677、#1680、#1679の契約を改訂し、#387・#1652・PR #1685の処置をmachine-readableに確定するべきです。
fix: hooks 全面削除を local_main_branch_guard/worktree_scope_guard の2件のみに縮小する
chore: PR body/title 更新を反映するため CI trigger を再送する
chore: PR body 修正版で Japanese Check を再送する
test: local_main_branch_guard/worktree_scope_guard 削除後の期待値を#1690前提へ更新する
ci: tests/test_hook_boundaries_doc.py を python-test-plan.json の targe…
test: serial lane argv の期待値に#1690 deselect追加分を反映する
chore: local_main_branch_guard / worktree_scope_guard の2 hook を緊急停止する (…
squne121 commentedon Jul 30, 2026
#1860 の owner decision(2026-07-30)により、semantic planning・overlap・contract artifactを通常作業のblocking authorityから撤去する方針が確定しました。本Issueの「semantic relationをissue-refinement-loopの唯一のauthorityにする」方向はこの方針と逆行するため、実装child #1869(Part of #1860)の完了後に close/supersede を判断します。
Part of #1860 / see also #1869
squne121 commentedon Jul 30, 2026
実装child #1869 の PR #1871 が merge-ready になりました(CI全green、独立レビューAPPROVE)。本Issueの close/supersede 判断は #1871 マージ後に行います。
Part of #1860 / see #1871
squne121 commentedon Jul 30, 2026
実装child #1869 のPR #1871(Closes #1869)の状態を更新します。
現状(2026-07-30 時点): head
fa1fe901f405520c92331e2dce65b8b8624b7f7c、CI 16/16 pass、mergeable: MERGEABLE、mergeStateStatus: CLEAN、独立レビュー APPROVE・merge_ready: true(Draft のまま、人間マージ待ち)。過去のコメントで参照していた head
cc756328は初回実装時点のものです。その後、人間レビューで REQUEST_CHANGES(production router のmergeable/merge_state_status分離不足等)を受けて fix_delta を適用し、途中で main 進行による実 Git conflict(route_loop_verdict_v2.py、Issue #1856 由来)を通常のマージで解消した上で、現在の head に至ります。本 Issue の scope 判定は PR #1871 の「Related / superseded Issues」節を正とします(詳細は #1871 参照)。PR merge 後、残存 scope の有無を再確認した上で close 可否を判断してください。
squne121 commentedon Jul 31, 2026
実装child #1869(PR #1871, MERGED, merge commit
c3cbc0dd, 2026-07-31T10:56:41Z)により、本Issueが要求していた「OPEN Issue間のsemantic relation判定をissue-refinement-loopの唯一のauthorityへ一元化する」方向は、#1860 owner decision(意味判断・計画順序を新たな閉じた状態機械へ変換しない)と逆行するため、その通りには実装されませんでした。代わりにPR #1871は、semantic planning/scope-rollup/overlap判定の blocking authority を全面的に撤去し、実Git conflict・target PR mergeability(mergeable==CONFLICTINGまたはmerge_state_status==DIRTY)のみをhard stopとして残す方向で確定しています。native sub-issueの処理状況:
全descendantのdispositionが確定したため、本Issue自体を「semantic planning authorityの一元化」という元の目的がowner decisionと逆行することを理由にsuperseded closeします。#1679の残存scopeは本Issueのclose後も独立Issueとして引き続き追跡されます。#1860 Closure Matrix参照。