Skip to content

実装: review/refinementのreplay・envelope・custom publisherをbounded loopへ置換する #1873

Closed

Description

@squne121

Machine-Readable Contract

contract_schema_version: v1
issue_kind: implementation
parent_issue: "#1860"
goal_ref: "review/refinementの通常経路をnative subagentのbounded loopと最小結果conventionへ簡素化し、replay arbitration、parent binding digest、永続state store、review/termination専用publisherをproduction authorityから撤去する"
change_kind: workflow

Parent Issue

#1860

Parent Goal Ref

  • Goal: AIエージェント運用をminimal harnessへ縮退し、過剰なcontrol-planeを廃止する。
  • Desired Destination: live Issue/PR、canonical worktree、実diff、実テスト、current-head CI、独立レビューを正本とし、workflow artifactの存在・freshness・digest一致を通常作業の認可条件にしない。

Current Validated Scope

2026-07-31時点でcurrent main(22e6f4d81fc91c3031b9135f35b30712f6dbd324)をlive調査した結果。

issue-refinement-loop の production replay/envelope/state authority

  • .claude/skills/issue-refinement-loop/scripts/reviewer_claim_replay.py — replay taxonomy producer
  • .claude/skills/issue-refinement-loop/scripts/reviewer_claim_replay_state_store.py — replay state永続store
  • .claude/skills/issue-refinement-loop/scripts/parent_replay_binding.py — parent binding digest producer
  • .claude/skills/issue-refinement-loop/scripts/emit_parent_review_envelope_v2.py — review envelope emitter
  • .claude/skills/issue-refinement-loop/scripts/compact_review_result.py — REVIEW_COMPACT V2 producer
  • .claude/skills/issue-refinement-loop/scripts/validate_review_compact_output.py — compact output validator
  • .claude/skills/issue-refinement-loop/scripts/build_loop_state.py — LOOP_STATE builder
  • .claude/skills/issue-refinement-loop/scripts/build_refinement_phase_state.py — phase state builder
  • .claude/skills/issue-refinement-loop/scripts/decide_next_loop_action.py — replay-state依存のnext-action decision
  • .claude/skills/issue-refinement-loop/scripts/validate_issue_execution_decision.py — ISSUE_EXECUTION_DECISION validator
  • .claude/skills/issue-refinement-loop/scripts/publish_termination_report.py — termination publisher呼び出し
  • .claude/skills/issue-refinement-loop/scripts/render_termination_report.py — termination envelope renderer
  • .claude/skills/issue-refinement-loop/scripts/plan_refinement_loop.py — loop entrypoint(REFINEMENT_LOOP_PLAN_V1生成、上記producerをdispatch)
  • .claude/skills/issue-refinement-loop/scripts/command_registry.py — command ID registry(termination_report.publish等を含む)
  • .claude/skills/issue-refinement-loop/schemas/loop_handoff_result_v1.json
  • .claude/skills/issue-refinement-loop/schemas/loop_state.schema.json
  • .claude/skills/issue-refinement-loop/schemas/loop_state_build_result.schema.json
  • .claude/skills/issue-refinement-loop/references/loop-state.md
  • .claude/skills/issue-refinement-loop/references/refinement-loop-plan-output.md
  • .claude/skills/issue-refinement-loop/references/termination-policy.md
  • .claude/skills/issue-refinement-loop/references/follow-up-materialization.md(実装: termination report に全 termination reason で FOLLOW_UP_MATERIALIZATION_RESULT_V1 を出力する #1321/PR #1832と関係)
  • .claude/skills/issue-refinement-loop/SKILL.md
  • .claude/skills/issue-refinement-loop/fixtures/golden/issue_985_runtime_expansion.json
  • .claude/hooks/save_loop_state_before_compaction.sh — compaction前にLOOP_STATEをsnapshotするhook(永続state store依存の中核)

Out of scope(#1869側): plan_issue_scope_rollup.py、scope-rollup関連referenceは#1869のscopeであり、本Issueでは変更しない。

2026-07-31 実装中に追加判明した依存: .claude/skills/issue-refinement-loop/schemas/loop_state.schema.json の definitions.anchor_comment フラグメントを、.claude/skills/issue-refinement-loop/scripts/run_refinement_preflight.py の ANCHOR_SCOPE_REFRAME_V1 anchor-comment validation(_load_loop_state_schema().get("definitions", {}).get("anchor_comment", {}))が消費している。これは#1869/anchor-reframe scopeの保護対象ロジックであり、loop_state.schema.json を単純削除すると壊れる。削除前に anchor_comment フラグメントを独立ファイル(例: schemas/anchor_comment.schema.json)へ抽出し、run_refinement_preflight.py の参照先を切り替えてから、残りの loop_state.schema.json を削除すること。

impl-review-loop の production LOOP_VERDICT_V2 authority

  • .claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py — LOOP_VERDICT_V2 router
  • .claude/skills/impl-review-loop/scripts/validate_autonomy_policy_result.py
  • .claude/skills/impl-review-loop/SKILL.md
  • .claude/skills/impl-review-loop/steps/preparation.md
  • .claude/skills/impl-review-loop/steps/step-1-implementation.md
  • .claude/skills/impl-review-loop/steps/step-2-verification.md
  • .claude/skills/impl-review-loop/steps/step-4-pr-review.md
  • .claude/skills/impl-review-loop/steps/step-5-feedback-and-termination.md
  • .claude/skills/impl-review-loop/steps/step-5-mergeability-handling.md(#1869で変更中。PR #1871の内容をrevertしない)
  • .claude/skills/impl-review-loop/steps/context-protocol-and-guardrails.md
  • .claude/skills/impl-review-loop/steps/conflicting-pr-escalation-runbook.md

pr-review-judge の production LOOP_VERDICT_V2 output

  • .claude/skills/pr-review-judge/SKILL.md
  • .claude/skills/pr-review-judge/references/loop-verdict-v2-schema.md
  • .claude/skills/pr-review-judge/references/allowed-paths-gate.md
  • .claude/skills/pr-review-judge/references/verdict-output-template.md

Agent定義(read-only reviewer/workerのthin化)

  • .claude/agents/issue-reviewer.md
  • .claude/agents/pr-reviewer.md
  • .claude/agents/implementation-worker.md
  • .codex/agents/issue-reviewer.toml
  • .codex/agents/pr-reviewer.toml

controlled mutation policy(pr_review.publish / termination_report.publish command固有branch)

  • scripts/agent-guards/controlled_skill_mutation_policy.py — COMMAND_ID_PUBLISH = "termination_report.publish"、COMMAND_ID_PR_REVIEW_PUBLISH = "pr_review.publish" を含む汎用command registry。framework全体は削除せず、consumer消滅後にこの2 command固有branchのみ除去する。
  • scripts/agent-guards/controlled_skill_mutation_exec.py
  • scripts/agent-guards/pretool_fastpath_classifier.py
  • scripts/agent-ops/pr_review_marker_archive_exec.py
  • scripts/agent_ops_inventory.py

schema catalog

  • schemas/catalog.yaml — 撤去対象schemaのderegistration

docs

  • docs/dev/workflow.md
  • docs/dev/agent-skill-boundaries.md
  • docs/dev/schema-governance.md
  • docs/dev/workflows/issue-refinement-loop-design.md
  • docs/dev/workflows/impl-review-loop-design.md
  • docs/dev/workflows/README.md
  • docs/dev/hook-boundaries.md
  • docs/dev/github-ops.md
  • docs/dev/autonomy-policy.md

2026-07-31 PR #1875 conflict resolution時に追加判明した依存: origin/main との merge conflict 解消と敵対的レビュー対応の過程で、.claude/skills/pr-review-judge/scripts/allowed_paths_review_gate.py(contract snapshot/fingerprint を advisory 化)と、それに伴う .claude/settings.json / .codex/rules/default.rules / pyproject.toml / 各種 test ファイルへの整合修正が追加で必要と判明した。詳細は Allowed Paths セクションの追記(PR #1875 conflict resolution 由来の注記付きエントリ)を参照。

関連Issue/PRとのscope関係(live確認済み)

Outcome

issue-refinement-loopとimpl-review-loopが、live GitHub stateとnative subagent resultだけで最大3回のbounded loopを実行できる状態にする。

PR reviewの内部返却convention:

verdict: APPROVE | REQUEST_CHANGES | HUMAN_REVIEW_REQUIRED
reviewed_head_sha: "<current PR head SHA>"
blockers:
  - "<具体的なblocker>"
warnings:
  - "<任意>"

Issue reviewの内部返却convention:

verdict: APPROVE | REQUEST_CHANGES | HUMAN_REVIEW_REQUIRED
reviewed_body_sha256: "<reviewed live bodyのsha256>"
blockers:
  - "<具体的なblocker>"
warnings:
  - "<任意>"

これらは新規公開schema、catalog entry、artifact formatにせず、main threadとsubagent間の一時的な最小conventionとして扱う。

main threadが所有する情報:

  • target Issue/PR
  • current bodyまたはPR head
  • iterationと最大iteration
  • unresolved blockers
  • current tests/CI
  • next action

compaction、resume、session再開後はstate artifactをreplayせず、Issue/PR/current diff/CIを再取得する。

Required Behavior

  • default maximum iterationは3
  • 明示入力でのみ上限変更可能
  • iteration間の継続はlive stateとfresh subagent resultから判断する
  • stale reviewed_head_shaはAPPROVEとして利用せず、current headで再レビューする
  • stale reviewed_body_sha256はhuman escalationにせず、bodyをrefetchして再レビューする
  • parser failureはIssue更新、implementation、Draft PR作成を止めない
  • 最小形式をparseできない場合は一度だけ再出力を求め、その後は人間可読blockerへfallbackする
  • max iteration到達時はPR/Issueを残したままHUMAN_REVIEW_REQUIREDへ移行する
  • 通常のGitHub client/connector/gh issue comment --body-file/gh pr comment --body-fileを使用する
  • semantic result専用publisherを使用しない
  • GitHub mutation前後にrepository、target番号、current headをreadbackする
  • review criteria自体は変更せず、transport/orchestrationだけを簡素化する

In Scope

Current Validated Scopeで列挙したexact filesに限定する。

機能scope:

  • issue-refinement-loopの通常review/rewrite loop
  • impl-review-loopのimplementation/verification/PR review loop
  • issue-reviewer/pr-reviewerのminimal result handoff
  • replay arbitrationのproduction経路撤去
  • parent binding digestの撤去
  • review compact V2/termination envelopeの撤去
  • persistent loop state storeの撤去(save_loop_state_before_compaction.sh含む)
  • LOOP_VERDICT_V2 production contractの最小conventionへの置換
  • dedicated review/termination publisherの撤去
  • dead command registry/policy branch/schema catalog entryの削除
  • docs、tests、fixturesの同期
  • normal GitHub mutation経路への移行
  • resume時のlive refetch
  • stale-head/stale-body negative tests

Out of Scope

Migration and Deletion Rule

  1. consumerから旧authority依存を外す。
  2. minimal bounded loopをproduction pathへ接続する。
  3. testsでreplacement behaviorを確認する。
  4. production consumerが0件になったproducer、validator、state store、schema、registry entry、fixtureを削除する。
  5. docsとcatalogを同期する。
  6. temporary compatibility codeを残さない。

directory単位で一括削除せず、各fileのconsumerを確認する。

generic controlled mutation frameworkを他command IDが使用している場合、framework全体は削除しない。pr_review.publish/termination_report.publish固有のbranch、policy、testsだけをconsumer消滅後に除去する。

Safety Invariants

  • live Issue本文からAllowed Pathsを取得し、実changed filesと照合する
  • contract snapshotやfingerprintをAllowed Pathsの正本にしない
  • current PR head以外のCI/reviewを利用しない
  • review投稿前後にPR headをreadbackする
  • 投稿後にheadが変化していた場合、その投稿はstale noteとして扱いfresh reviewを実行する
  • wrong repository、wrong Issue/PR、protected path、secret、force push、main直接pushは拒否する
  • actual 3-way conflictまたはGitHubのCONFLICTING/DIRTYは自動解消せず停止する
  • UNKNOWN、BLOCKED、BEHIND、UNSTABLE、DRAFT、HAS_HOOKSをGit conflictとして扱わない
  • human final mergeを維持する

Acceptance Criteria

  • AC1: replay envelope、parent binding artifact、state storeがなくてもfresh Issue reviewを開始できる
  • AC2: issue-refinement-loopがdefault最大3回でreview→rewrite→reviewを実行し、無限replayしない
  • AC3: impl-review-loopがdefault最大3回でimplementation→verification→PR reviewを実行し、永続LOOP_STATEを必須にしない
  • AC4: Issue review結果がverdict、reviewed_body_sha256、blockers、optional warnings程度に縮小される
  • AC5: PR review結果がverdict、reviewed_head_sha、blockers、optional warnings程度に縮小される
  • AC6: stale reviewed bodyはrefetch/rereviewされ、artifact mismatchによるhuman escalationにならない
  • AC7: stale reviewed headはAPPROVEとして消費されず、current headで再レビューされる
  • AC8: 旧compact result、replay、binding、state、publisher artifactのmissing/malformed/staleでIssue更新やDraft PR作成が停止しない
  • AC9: max iteration到達時はHUMAN_REVIEW_REQUIREDへ移行し、Issue/PRとblocker summaryを残す
  • AC10: routine review/termination投稿が通常GitHub operationで行われ、専用semantic publisherを使用しない
  • AC11: mutation前後のrepository/IssueまたはPR/head readbackが維持される
  • AC12: dead replay/binding/state-store/publisher consumerとschema catalog entryがproduction pathから除去される
  • AC13: 同等機能を持つ新schema、digest、receipt、publisher、state machineが追加されていない
  • AC14: canonical repository、live Allowed Paths、protected path、secret、Git safety、実テスト、current-head CI、branch protection、人間mergeが維持される
  • AC15: compaction/resume後にartifact replayではなくlive Issue/PR/diff/CIを再取得するテストまたはruntime smokeが存在する
  • AC16: 実装: LOOP_VERDICT_V2 契約の producer/consumer/publisher atomic cutover を行う #1857、実装: termination report に全 termination reason で FOLLOW_UP_MATERIALIZATION_RESULT_V1 を出力する #1321/PR fix(refinement): 全終端理由で follow-up materialization 結果を出力 (#1321) #1832、#1867のscope dispositionがlive stateに基づいて記録される
  • AC17: PR #1871の変更をrevertせず、actual conflict以外を着手blockerにしていない
  • AC18: relevant test suites、lint、typecheck、build、git diff --checkがcurrent headでpassする

Verification Commands

uv run --locked pytest .claude/skills/issue-refinement-loop/tests/ -q
uv run --locked pytest .claude/skills/issue-refinement-loop/scripts/tests/ -q
uv run --locked pytest .claude/skills/impl-review-loop/tests/ -q
uv run --locked pytest .claude/skills/pr-review-judge/scripts/tests/ -q
uv run --locked pytest scripts/agent-guards/tests/test_controlled_skill_mutation_policy.py scripts/agent-guards/tests/test_controlled_skill_mutation_exec.py scripts/agent-guards/tests/test_controlled_pr_review_publish_exec.py scripts/agent-guards/tests/test_pr_review_publish_pr_number_separation.py scripts/agent-guards/tests/test_isolation_issue_comment_publish_bridge.py -q
uv run --locked pytest scripts/agent-ops/tests/test_pr_review_marker_archive_exec.py -q
uv run --locked pytest .claude/hooks/tests/test_issue1215_publish_resume.py .claude/hooks/tests/test_pr_review_publish_hookchain.py -q
uv run --locked pytest tests/test_agent_parity.py -q
uv run --locked ruff check .claude/skills scripts tests .claude/hooks
pnpm typecheck
pnpm lint
pnpm test
pnpm build
git diff --check

production dangling reference check(historical docs/migration noteの残存語と区別し、production consumerのみを対象とする):

rg -n \
  -e 'parent_replay_binding' \
  -e 'reviewer_claim_replay_state_store' \
  -e 'ISSUE_REVIEW_RESULT_COMPACT' \
  -e 'REPLAY_PARENT_BINDING_DIGEST' \
  -e 'emit_parent_review_envelope' \
  -e 'LOOP_VERDICT_V2' \
  -e 'PR_REVIEW_PUBLISH_REQUEST_V1' \
  .claude/skills/issue-refinement-loop/scripts .claude/skills/impl-review-loop/scripts .claude/skills/pr-review-judge/scripts .claude/agents .codex/agents

negative tests:

  • stale PR head
  • stale Issue body
  • wrong repository
  • wrong PR/Issue number
  • Allowed Paths violation
  • protected path/secret
  • failed tests
  • failed current-head CI
  • max iteration
  • parser failure fallback
  • normal GitHub comment pathのpre/post readback
  • 旧artifactなしでのfresh start

Allowed Paths

.claude/skills/issue-refinement-loop/scripts/reviewer_claim_replay.py(削除)
.claude/skills/issue-refinement-loop/scripts/reviewer_claim_replay_state_store.py(削除)
.claude/skills/issue-refinement-loop/scripts/parent_replay_binding.py(削除)
.claude/skills/issue-refinement-loop/scripts/emit_parent_review_envelope_v2.py(削除)
.claude/skills/issue-refinement-loop/scripts/compact_review_result.py(削除または最小convention化)
.claude/skills/issue-refinement-loop/scripts/validate_review_compact_output.py(削除)
.claude/skills/issue-refinement-loop/scripts/build_loop_state.py(削除)
.claude/skills/issue-refinement-loop/scripts/build_refinement_phase_state.py(削除)
.claude/skills/issue-refinement-loop/scripts/decide_next_loop_action.py(bounded loop判断へ縮小)
.claude/skills/issue-refinement-loop/scripts/validate_issue_execution_decision.py(削除)
.claude/skills/issue-refinement-loop/scripts/publish_termination_report.py(通常comment投稿へ縮小)
.claude/skills/issue-refinement-loop/scripts/render_termination_report.py(plain markdown化)
.claude/skills/issue-refinement-loop/scripts/plan_refinement_loop.py(bounded loop entrypoint化)
.claude/skills/issue-refinement-loop/scripts/command_registry.py(dead command ID削除)
.claude/skills/issue-refinement-loop/schemas/loop_handoff_result_v1.json(削除)
.claude/skills/issue-refinement-loop/schemas/anchor_comment.schema.json(新規、loop_state.schema.jsonから抽出)
.claude/skills/issue-refinement-loop/schemas/loop_state.schema.json(削除)
.claude/skills/issue-refinement-loop/schemas/loop_state_build_result.schema.json(削除)
.claude/skills/issue-refinement-loop/references/loop-state.md(削除または最小convention記述へ置換)
.claude/skills/issue-refinement-loop/references/refinement-loop-plan-output.md(更新)
.claude/skills/issue-refinement-loop/references/termination-policy.md(更新)
.claude/skills/issue-refinement-loop/references/follow-up-materialization.md(更新、#1321整合)
.claude/skills/issue-refinement-loop/SKILL.md(更新)
.claude/skills/issue-refinement-loop/fixtures/golden/issue_985_runtime_expansion.json(必要なら更新)
.claude/skills/issue-refinement-loop/tests/(旧producer対応testの削除・新bounded loop testの追加)
.claude/skills/issue-refinement-loop/scripts/tests/test_producer_fail_closed.py(更新)
.claude/hooks/save_loop_state_before_compaction.sh(削除)
.claude/hooks/tests/test_issue1215_publish_resume.py(更新)
.claude/hooks/tests/test_pr_review_publish_hookchain.py(更新)
.claude/hooks/tests/test_local_main_branch_guard.py(要確認、無関係なら不変更)
.claude/skills/impl-review-loop/scripts/route_loop_verdict_v2.py(最小convention routerへ縮小)
.claude/skills/impl-review-loop/scripts/validate_autonomy_policy_result.py(要確認・整合)
.claude/skills/impl-review-loop/SKILL.md(更新)
.claude/skills/impl-review-loop/steps/preparation.md(更新、#1869差分を尊重)
.claude/skills/impl-review-loop/steps/step-1-implementation.md(更新)
.claude/skills/impl-review-loop/steps/step-2-verification.md(更新)
.claude/skills/impl-review-loop/steps/step-4-pr-review.md(更新)
.claude/skills/impl-review-loop/steps/step-5-feedback-and-termination.md(更新)
.claude/skills/impl-review-loop/steps/step-5-mergeability-handling.md(#1869内容を維持しつつ整合更新)
.claude/skills/impl-review-loop/steps/context-protocol-and-guardrails.md(更新)
.claude/skills/impl-review-loop/steps/conflicting-pr-escalation-runbook.md(要確認)
.claude/skills/impl-review-loop/tests/(旧LOOP_VERDICT_V2 test更新・削除、bounded loop test追加)
.claude/skills/pr-review-judge/SKILL.md(更新)
.claude/skills/pr-review-judge/references/loop-verdict-v2-schema.md(削除または最小convention記述へ置換)
.claude/skills/pr-review-judge/references/allowed-paths-gate.md(更新、allowed_paths_gate自己申告除去)
.claude/skills/pr-review-judge/references/verdict-output-template.md(更新)
.claude/skills/pr-review-judge/scripts/tests/test_loop_verdict_v2.py(更新・削除)
.claude/skills/pr-review-judge/scripts/tests/test_check_pr_review_gates_indeterminate.py(更新)
.claude/agents/issue-reviewer.md(read-only minimal result化)
.claude/agents/pr-reviewer.md(read-only minimal result化)
.claude/agents/implementation-worker.md(要確認・整合)
.codex/agents/issue-reviewer.toml(parity更新)
.codex/agents/pr-reviewer.toml(parity更新)
tests/test_agent_parity.py(更新)
tests/fixtures/agent-parity/ok-codex-issue-reviewer.toml(更新)
tests/fixtures/agent-parity/ok-claude-issue-reviewer.md(更新)
tests/fixtures/agent-parity/drift-claude-schema-mismatch.md(要確認)
tests/fixtures/agent-parity/drift-claude-permission-mismatch.md(要確認)
tests/fixtures/agent-parity/drift-claude-delegation-mismatch.md(要確認)
scripts/agent-guards/controlled_skill_mutation_policy.py(pr_review.publish/termination_report.publish固有branchのみ除去)
scripts/agent-guards/controlled_skill_mutation_exec.py(同上)
scripts/agent-guards/pretool_fastpath_classifier.py(要確認・整合)
scripts/agent-guards/tests/test_controlled_skill_mutation_policy.py(更新)
scripts/agent-guards/tests/test_controlled_skill_mutation_exec.py(更新)
scripts/agent-guards/tests/test_controlled_pr_review_publish_exec.py(更新)
scripts/agent-guards/tests/test_pr_review_publish_pr_number_separation.py(更新)
scripts/agent-guards/tests/test_isolation_issue_comment_publish_bridge.py(更新)
scripts/agent-guards/tests/test_controlled_issue_metadata_exec.py(要確認、無関係なら不変更)
scripts/agent-ops/pr_review_marker_archive_exec.py(要確認・整合)
scripts/agent-ops/tests/test_pr_review_marker_archive_exec.py(更新)
scripts/agent_ops_inventory.py(要確認・整合)
schemas/catalog.yaml(撤去schemaのderegistration)
docs/dev/workflow.md(更新)
docs/dev/agent-skill-boundaries.md(更新)
docs/dev/schema-governance.md(更新)
docs/dev/workflows/issue-refinement-loop-design.md(更新)
docs/dev/workflows/impl-review-loop-design.md(更新)
docs/dev/workflows/README.md(更新)
docs/dev/hook-boundaries.md(更新)
docs/dev/github-ops.md(更新)
docs/dev/autonomy-policy.md(更新)
.claude/hooks/tests/test_hookchain_harness.py(PR #1875 conflict resolution時にconsumer確認のため更新)
.claude/settings.json(PR #1875 conflict resolution時にpermissions/hooks整合のため更新)
.claude/skills/issue-refinement-loop/references/scope-signal-guard.md(PR #1875 conflict resolution時に更新)
.claude/skills/issue-refinement-loop/schemas/refinement_preflight_input.schema.json(PR #1875 conflict resolution時に更新)
.claude/skills/post-merge-cleanup/SKILL.md(PR #1875 conflict resolution時にpr_review.publish撤去の記述整合のため更新)
.claude/skills/pr-review-judge/references/required-auto-actions.md(PR #1875 conflict resolution時に更新)
.claude/skills/pr-review-judge/scripts/allowed_paths_review_gate.py(PR #1875 conflict resolution時にcontract snapshot/fingerprintをadvisory化するため更新)
.claude/skills/pr-review-judge/tests/test_allowed_paths_review_gate.py(PR #1875 conflict resolution時に上記advisory化のtest更新)
.codex/rules/default.rules(PR #1875 conflict resolution時にpr_review.publish撤去の記述整合のため更新)
pyproject.toml(PR #1875 conflict resolution時にconsumer確認のため更新)
scripts/agent-ops/tests/test_pr_review_marker_archive_hookchain.py(PR #1875 conflict resolution時に更新)
tests/agent_guards/test_worktree_scope_guard.py(PR #1875 conflict resolution時に更新)
tests/test_hook_boundaries_doc.py(PR #1875 conflict resolution時に更新)
.claude/skills/issue-refinement-loop/scripts/isolation_issue_comment_bridge.py(PR #1875 conflict resolution時に判明。origin/mainのpublish_termination_report.pyからのC052 extraction。issue_comment.publish経由の既存controlled executor laneを維持したまま切り出した新規production script)
.claude/skills/issue-refinement-loop/scripts/run_refinement_preflight.py(PR #1875 conflict resolution時にAllowed Paths未列挙と判明。anchor_comment schema extraction依存はCurrent Validated Scopeに既述)
scripts/agent-guards/tests/test_pretool_fastpath_classifier.py(PR #1875 conflict resolution時にAllowed Paths未列挙と判明。対応production moduleは既存エントリで許可済み)

実装中に直接consumerが追加で見つかった場合:

  1. live child Issueをrefetchする
  2. Allowed PathsとCurrent Validated Scopeだけをsection-level更新する
  3. readbackする
  4. 作業を継続する

body SHA mismatchだけで停止しない。

Runtime Verification Applicability

decision: immediate
reason: "native subagent result handoff、bounded iteration、stale-head/stale-body rereview、resume時live refetch、通常GitHub mutationのpre/post readbackは実行時挙動である"
applicable_acs:
  - AC2
  - AC3
  - AC6
  - AC7
  - AC9
  - AC10
  - AC11
  - AC15

Stop Conditions

次だけをhard stopとする。

  • canonical repository/target Issue/PRを特定できない
  • repository、worktree、branch identityが一致しない
  • protected path、secret、credential、destructive Gitを弱める必要がある
  • actual 3-way Git conflictがある
  • target PRがlive current headでCONFLICTINGまたはDIRTY
  • #1856または#1869の所有scopeを同一PRで変更しないと成立しない
  • review criteria自体を変更しないと成立しない
  • required testを実行できず、代替なしでPASS扱いする必要がある
  • generic GitHub safety boundaryを削除しないと通常投稿経路を作れない
  • native subagentとsingle-agent fallbackの双方が利用不能

次はhard stopにしない。

  • 旧artifact missing/stale/invalid
  • parser failure
  • body SHA mismatch
  • semantic overlap
  • #1871がOPENであること
  • mergeability UNKNOWN/BLOCKED/BEHIND/UNSTABLE/DRAFT/HAS_HOOKS
  • scope inventoryの警告
  • old publisherが利用不能

Related and Supersession

Delivery Rule

  • 1 Issue = 1 PR
  • dedicated worktree
  • Draft PR
  • Closes #<NEW_ISSUE>
  • Part of #1860
  • human final merge
  • force push禁止

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent/implementerenhancementphase/implementationworkflow

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions