Repository navigation
Description
Background
Issue #1733 / PR #1947 の scripts/check_post_merge_cleanup_boundary.py(--check runtime_smoke_evidence, AC12)は、worktree-agent-runtime-smoke 共有 harness(scripts/agent-ops/run_worktree_agent_runtime_smoke.py)が生成する summary.md から worker identity / 参照 Skill / spawn event 分類 / tested_head を検証するために、以下の構造化フィールドを best-effort で参照する:
tested_headruntime_versionrequested_agent_typeeffective_agent_typeloaded_skillschild_spawn_event_countspawn_events(分類済み)self_restart_event_countorchestration_action_countprompt_sha256
現在の harness は allowlist-only な summary.md(Issue #1921 P1 fix-delta の evidence-hygiene 方針)を書き出しており、上記フィールドを一切出力しない。scripts/agent-ops/run_worktree_agent_runtime_smoke.py は Issue #1733 の Allowed Paths 外だったため、#1733 側では harness 拡張を行わず、チェッカー側を「フィールドが存在すれば厳格検証、存在しなければ warning のみ(fail しない)」という best-effort 設計にした(PR #1947 comment の OWNER レビュー指摘に対する fix_delta)。
この結果、AC12 の genuine PASS は現状 legacy fields(exit_code / timed_out / expected_markers_missing / errors / postcondition_unexpected_changes)のみで成立しており、worker identity / 参照 Skill / spawn event 分類といった本来の semantic 検証は harness 拡張が完了するまで untested のままである。
Outcome
scripts/agent-ops/run_worktree_agent_runtime_smoke.py が summary.md(allowlist-only の evidence hygiene 方針は維持したまま)に、少なくとも以下の構造化フィールドを追加で出力する状態になっている:
tested_head(git rev-parse HEADから独立に導出。呼び出し元の自己申告を信用しない)runtime_versionrequested_agent_type/effective_agent_typeloaded_skills(起動された agent が実際に参照した Skill 名のリスト)child_spawn_event_count/spawn_events(分類済み。raw transcript は保存しない)self_restart_event_countorchestration_action_countprompt_sha256(raw prompt は保存しない。ハッシュのみ)
scripts/check_post_merge_cleanup_boundary.py --check runtime_smoke_evidence の既存 best-effort 検証ロジック(フィールドが存在すれば厳格検証)はそのまま活用でき、上記フィールドの追加により AC12 相当の semantic 検証(worker identity / 参照 Skill / spawn event 分類)が harness レベルで genuine に成立するようになる。
In Scope
scripts/agent-ops/run_worktree_agent_runtime_smoke.pyの evidence 収集ロジック拡張(上記フィールドの追加)。- evidence-hygiene 方針(raw transcript / raw prompt / credential を保存しない)を維持したまま、
spawn_eventsを分類済みの安全な形(種別・件数程度)で出力する設計。 references/evidence-hygiene.mdの更新(新規フィールドの hygiene 境界を明記)。
Out of Scope
scripts/check_post_merge_cleanup_boundary.pyの検証ロジック変更(Issue 実装: post-merge-cleanup の orchestrator と worker executor を分離する #1733 で完了済み。フィールドが出力されるようになれば既存ロジックがそのまま厳格検証する)。- 新規 schema / registry / publisher / ledger の追加。
- evidence hygiene 方針(allowlist-only)自体の緩和。
Verification Commands(案)
# baseline-expect: fail
$ uv run --locked python3 scripts/agent-ops/run_worktree_agent_runtime_smoke.py --runtime codex --mode structured --worktree . --prompt-file tmp/runtime-smoke/codex-structured.md --output-dir artifacts/runtime-smoke/codex-structured --timeout-seconds 180 --require-clean-postcondition
$ grep -q "^- tested_head:" artifacts/runtime-smoke/codex-structured/summary.mdNotes
- Origin: Issue 実装: post-merge-cleanup の orchestrator と worker executor を分離する #1733 / PR feat: separate post-merge-cleanup orchestrator/executor instruction boundary (#1733) #1947(OWNER レビュー comment)の fix_delta(iteration 5, 6, 7)で明示された既知ギャップ。
- 本 Issue のマージ後、Issue 実装: post-merge-cleanup の orchestrator と worker executor を分離する #1733 の AC12 検証は harness 由来の構造化フィールドで genuine に厳格化できる(現在は best-effort・legacy fields のみで PASS している)。
Activity
squne121 commentedon Aug 2, 2026
本 Issue #1971 が提案していた「
worktree-agent-runtime-smokeharness(scripts/agent-ops/run_worktree_agent_runtime_smoke.py)への構造化 telemetry フィールド出力の追加」は、オーナー(squne121)が 2026-08-02 に Issue #1733 の Allowed Paths をこの harness とそのテストへ明示的に拡張することを承認したため、PR #1947(Issue #1733)の fix_delta(iteration 8)で直接実装・解決されました。tested_head/runtime_version/requested_agent_type/effective_agent_type/loaded_skills(静的 frontmatter 由来。loaded_skills_source: static_frontmatterを併記)/spawn_events/child_spawn_event_count/self_restart_event_count/orchestration_action_count/prompt_sha256の10フィールドを genuine に導出・出力するようになりました。scripts/check_post_merge_cleanup_boundary.py::check_runtime_smoke_evidence()はこれらを再び hard-required(欠落・Noneは FAIL)に戻しました。cbc0ea9bf13dd4a12455c378c448532ce1b0ce8cに対して実際に Codex CLI(--agent-type post-merge-cleanup-worker)で再実行し、Issue 実装: post-merge-cleanup の orchestrator と worker executor を分離する #1733 AC12 の文字通りの Verification Command が genuine PASS(exit 0、WARNING なし)することを確認済みです。詳細は PR #1947 本文の
## fix_delta(iteration 8: harness 拡張による AC12 の genuine 解決)と## Runtime Verification Evidenceを参照してください。本 PR がマージされ次第、本 Issue #1971 はクローズ候補としてレビューしていただくことを推奨します(クローズ判断自体は control-plane / 人間の判断に委ねます。本コメントでは実行しません)。
squne121 commentedon Aug 2, 2026
この Issue が求めていた
worktree-agent-runtime-smokeharness(scripts/agent-ops/run_worktree_agent_runtime_smoke.py)への構造化 telemetry フィールド追加は、当初の想定(別 follow-up PR)ではなく、オーナー(squne121)の明示承認により Issue #1733 / PR #1947 のスコープ内(Allowed Paths 拡張)で直接実装されました。実装内容:
tested_head/runtime_version/requested_agent_type/effective_agent_type/loaded_skills/spawn_events/child_spawn_event_count/self_restart_event_count/orchestration_action_count/prompt_sha256の10フィールドを harness が実出力するようになり、scripts/check_post_merge_cleanup_boundary.pyの AC12 検証が再び必須フィールド検証(best-effort ではなく hard-required)に戻されました。pr-review-judge の最終レビューでも独立に harness 実装の妥当性を確認済みです。本 Issue は PR #1947(マージ後)により resolved として close します。