Status: ai-loop V2 の責務解釈ガイド。正本は
north-star.mdと companion canon であり、本書はそれらに従属する。 Purpose: Loop / Graph / Harness の境界を明確にし、二重正本や不要な Graph runtime を作らずに設計判断できるようにする。 Derived from: canon 6 本(north-star.md/taxonomy.md/harness-manifest.md/evaluation-trust-boundary.md/artifact-responsibilities.md/phase0-migration.md)@b1217b41。本書は canon ではないためphase0-migration.md§7 の canon 7 本には加えない。 下記がb1217b41以外を返したら canon が動いているので、§2 の責務表と §3 の境界規則を読み直すこと。git log -1 --format=%h origin/main -- docs/ai/ai-loop-v2/north-star.md \ docs/ai/ai-loop-v2/taxonomy.md docs/ai/ai-loop-v2/harness-manifest.md \ docs/ai/ai-loop-v2/evaluation-trust-boundary.md \ docs/ai/ai-loop-v2/artifact-responsibilities.md \ docs/ai/ai-loop-v2/phase0-migration.md
ai-loop V2 では Loop / Graph / Harness を、置換関係ではなく異なる責務として扱う。
Loop is the unit of feedback and convergence. Graph is the unit of coordination topology. Harness is the execution environment that makes both reliable.
Prompt -> Context -> Harness -> Loop -> Graph を成熟度や年代順として扱わない。Graph は Loop を置き換えない。
Loop と Graph は直交し、必要に応じて合成する。
V2 の既存責務へ当てはめると次のようになる。
本表が責務と owner の唯一の対応表である(§7 で再掲しない)。
| Concern | 責務 | Owner / 正本 |
|---|---|---|
1 Task を Evidence で MERGE_READY へ収束 |
Loop | Delivery Loop / north-star.md |
| 複数 Run から Harness N+1 Candidate を作り評価(Harness Evolution) | Loop | Evolution Loop / #869 |
| stop / progress / retry strategy | Loop | #894 / north-star.md §8 |
| durable state / Human interrupt / wait-resume / recovery | Graph + Harness | #1025 |
| Work Item Graph / intent-to-execution structure(branch / join) | Graph | #911 |
| node 遷移の妥当性評価(Trajectory evaluation) | Graph + Evaluation | #908 |
| RunEvidence / failure evidence | Harness evidence | #874 / artifact-responsibilities.md |
| Harness identity / activation | Harness | harness-manifest.md |
| evaluator / protected authority | Harness trust boundary | evaluation-trust-boundary.md |
| Canon / Trust Boundary の維持 | Harness canon | #1275 + V2 companion canon |
責務が重なる箇所では、次で分ける。
Loop は「次に何をすべきか」のうち、Evidence と Contract に基づく収束判断を持つ。
continue | repair | replan | stop / escalate
単なる retry < N は Loop ではない。Iteration 間で progress / evidence delta / failure fingerprint を比較する原則は north-star.md §8 を正とする。
Graph は「どの責務へ遷移するか」を明示する。
node -> edge -> node
branch / join / wait / resume / recovery
Graph の node 到達だけでは、その node の Contract が満たされた証拠にならない。完了判定は Verifier / Evidence / Gate の責務を維持する。
Harness は Graph state の意味そのものではなく、state を安全に保存・復元する primitive や runtime 条件を提供する。
current_node, transition, waiting / recovery path の意味Active Run 中の Harness identity は harness-manifest.md に従い固定する。
まず最小の制御構造を選ぶ。 AI を使うこと自体は Graph 導入理由にならない。
単一 Loop を優先する条件:
明示的な Graph を導入する条件:
Do not graph what a single Loop can express clearly. Do not hide real coordination complexity inside one opaque Loop.
Graph を使う場合も、V2 の既存 invariant を弱めない。
Candidate cannot modify the authority that judges the candidate.
失敗を Model に帰属する前に、周辺システムを確認する。
Harness -> Loop -> Graph -> Model -> External
これは診断順序の heuristic であり、新しい persisted failure taxonomy ではない。FailureRecord / RunEvidence の schema は companion canon と #874 を正とする。
Issue #923 は Harness / Loop / Graph の横断整理を提案したが、実装責務が既存 Issue に存在するため SUPERSEDED で close 済みである。本書は #923 を reopen せず、概念の解釈だけを残す。
owner と正本の対応は §2 の表が唯一である。ここで再掲しない(2 箇所を同期し続ける状態を作らないため)。
優先順位は次のとおり。
north-star.md と companion canon)が本書と食い違ったら canon を正とし、本書を直す設計責務に迷ったときは、次の 3 問で判断する。
How does this work converge and stop? -> Loop
What coordinates the next transition? -> Graph
What makes execution reliable and safe? -> Harness
そのうえで、要件を満たせる最小の既存 ownerへ実装責務を置く。
Informative only. Repository canon takes precedence.