<!-- informative -->

# Synthesis of the Two Replies to the Research Report

## Scope

This report compares the two replies to `docs/research/report-research.md`:

- `docs/research/report-research-reply1.txt`;
- `docs/research/report-research-reply2.txt`.

It records where the replies agree, where they disagree, and recommends a combined approach. Factual claims made by the replies were verified against the repository where possible.

## Status

Both reply authors have reviewed this synthesis. Reply 1's author concurs, including the two places this report rules against reply 1, and proposed two execution refinements that are incorporated below. Reply 2's author returns GO with four amendments — reject ambiguous *enabled* transitions rather than duplicate (state, event) pairs; sequence sandboxing before first untrusted code execution rather than before the model adapter; distinguish first-slice exclusions from MVP exclusions; and define outcome precedence beyond quiescence — plus two small corrections. All four amendments and both corrections were verified against the repository and are incorporated below. The recommendation now carries both experts' GO.

## Verified factual points

- `scripts/tables.py:519` (`check_reachability`) checks transition incidence only: every declared state must have an incoming transition and every non-terminal state an outgoing transition. It does not check reachability from the initial state; a chain of states unreachable from creation passes. Reply 2's critique of `docs/research/report-research.md:116` is factually correct, and reply 1's endorsement of that line is incorrect.
- `docs/control-plane.md:93` states "mutation admission is serialised" and `docs/roadmap.md:13` requires "a single-process controller". Both replies correctly cite these.
- No `LICENSE` file exists, despite SPDX headers in the scripts. Reply 1's observation is correct.
- The `RESULT_REVALIDATED` gap flagged by reply 2 and confirmed by reply 1's author is real: the event catalogue payload is `result_id, reason` only (`docs/event-catalogue.md:93`) while the transition guard says "Revalidation succeeded and created a new acceptance record" (`docs/tables/result-freshness.yaml:60`), and no field links the superseded record to its replacement. `ACCEPTANCE_AUTHORISED` carries only `node_id, bindings` (`docs/event-catalogue.md:22`), so a replay cannot reconstruct the supersession chain.
- Duplicate (state, event) rows exist intentionally: `docs/tables/node-lifecycle.yaml:78-85` has two `VALIDATING + VALIDATION_FAILED` rows leading to `READY` (retry permitted) and `REPLAN_REQUIRED` (retry prohibited). A checker that rejects duplicate (state, event) pairs would reject legitimate guarded branches; it must reject transitions that can be *enabled together*, not row duplication.
- The broken reference claimed at `docs/research/user-workflow.md:52` does not exist. That line is a policy-configuration table row, and the file contains no `pre-implementation` reference at all. `docs/research/report-research.md:82` is itself the error; the housekeeping instruction to "fix" line 52 is withdrawn.

## Where the replies agree

The replies agree on substance far more than they disagree. Both:

1. **Reject the report's blanket "do not start implementation yet."** Both conclude the vertical slice should be the next work item, not a postcondition of eleven gates.
2. **Accept the report's core semantic gaps as real.** The reducer/admission/reduction/persistence/dispatch boundary must be explicit, unknown event types and enum values must be rejected rather than silently skipped, and the version-compatibility baseline must be strict for the MVP.
3. **Name the harness as the first user.** The experiment harness is the operator interface for the MVP; the full user-workflow document, product CLI, and intervention workflows are premature. Harness-facing schemas (run configuration, progress/audit, result, evidence) belong in the schema work.
4. **Defer the third-party stack decision rather than commit to it now.** Temporal is a prerequisite only if chosen; OPA and Kubernetes are unnecessary to establish initial governance semantics; the alternatives memo is an unverified hypothesis. SQLite is supported for the first slice; PostgreSQL remains a reasonable candidate to reconsider when demonstrated requirements justify it, not something forbidden until after the experiment. The dispatch substrate must never hold normative state. Multiple execution workers are distinct from multiple authoritative controllers: a single controller can serialize admission while running independent attempts concurrently, so concurrency stays in scope for the later experiment arms.
5. **Treat the single-process boundary as already specified.** Serialized admission and the single-process controller are normative (see verified points above). Leases, fencing, and leader election are out of MVP scope; stale results and duplicate delivery still need explicit handling.
6. **Sequence capability-specific tests before the capability, not before all work.** Sandbox and credential tests precede the first execution of untrusted repository or candidate code — determinism is not trust, since a deterministic command such as `pytest`, a build, or a package installer can execute untrusted repository code — regardless of whether a model adapter has been introduced. The first slice uses an in-process scripted test double with trusted fixtures; the conformance harness belongs to the slice.
7. **Demote snapshots to a non-goal.** The MVP replays from genesis by deliberate choice; unspecified snapshot machinery is not a blocker.
8. **Reject exhaustive roadmap process.** No 32-step traceability matrix or requirement-ID namespace; measurable acceptance criteria are written for the next milestone only.
9. **Demand a workflow-driven vertical slice with the same demonstrations:** valid/malformed input handling, evidence-bound acceptance, duplicate-event idempotency, replay equivalence without dispatching work, and crash injection at persistence and dispatch boundaries.

## Where the replies disagree

1. **Packaging of specification closure.** Reply 1 wants a small, targeted specification-closure commit before the slice (reducer signature and effect list, wildcard precedence with `tables.py` rejecting ambiguous rows, quiescence order restated as outcome precedence, strict evolution policy, single-admission-thread sentence, extended non-goals, `LICENSE`). Reply 2 proposes no dedicated closure step; its five decisions are settled "alongside the schema code" within the slice. This is the main structural disagreement.
2. **Schemas as a separate milestone.** Reply 1 keeps schemas as step 2, extended to the harness contract, before the slice at step 3. Reply 2 merges them: the schema milestone becomes the workflow-driven slice, and the entire schema catalogue must not be frozen first.
3. **Classification demand.** Reply 2's central objection is that the report promoted verification questions into universal blockers and requires each item to be classified (already specified / contradictory / required next / deferred). Reply 1 performs that classification gate by gate but does not demand a classification exercise.
4. **The reachability claim.** Reply 2 corrects the report's line 116; reply 1 affirms it. Verification supports reply 2 (see above).
5. **Concrete schema defect.** Only reply 2 flags the incomplete `RESULT_REVALIDATED` replacement-record contract as a defect needing closure, and the entity-versus-immutable-result distinction in record semantics. Verified (see above); reply 1's author concedes the omission.
6. **Storage lean.** Reply 1 leans toward SQLite for the MVP and defers the PostgreSQL decision until after the four-arm experiment; reply 2 leaves storage open between SQLite and PostgreSQL.
7. **Housekeeping.** Only reply 1 adds the `LICENSE` file, doc-map entries for the report and `docs/research/`, and the `docs/research/user-workflow.md:52` correction. Reply 2 disputes the last item; verification confirms reply 2 is right (see above) — the alleged broken reference does not exist, so that instruction is withdrawn. Reply 2 also notes the `LICENSE` scope should be confirmed by the owner rather than inferred solely from script headers. The owner has since decided the review documents stay out of the document map entirely.

## Recommendation

Adopt the synthesis; the disagreement is mostly packaging, and each reply supplies what the other lacks.

1. **Do one small specification-closure commit first** (reply 1's step 1, amended by reply 2's classification discipline):
   - Classify every report gate as already specified, contradictory, required for the next milestone, or deferred. Record the classification as a table in `docs/roadmap.md`, one row per report gate with the disposition and a link to the section or non-goal that settles it. This gives reply 2's traceability without introducing a requirement-ID namespace, and turns deferrals into checked links rather than prose.
   - Close what is genuinely missing and cheap: reducer signature and effect list, unknown event/enum handling, and explicit transition-resolution rules. For resolution, define explicit-versus-wildcard precedence and guard evaluation, and have `tables.py` reject transitions that can be *enabled together* while allowing declared mutually exclusive branches (the two `VALIDATING + VALIDATION_FAILED` rows at `docs/tables/node-lifecycle.yaml:78-85` are legitimate and must keep passing). Because guards are prose, the checker cannot prove arbitrary guard exclusivity; use explicit structured distinctions where needed and behavioral tests for the rest. Never resolve ambiguity silently by YAML row order.
   - Define run-outcome precedence as more than the quiescence order. Quiescence covers only a subset of termination situations; acceptance, cancellation, and deadline events can compete while work is active. State how global event order determines the winning terminal transition, how multiple consequences of one admitted event are resolved, and which late events remain eligible for accounting or audit without changing the outcome. Test those cases separately from quiescence.
   - Strict MVP evolution policy (replay requires identical schema and policy versions), one explicit single-admission-thread sentence, and first-slice non-goals recorded as such (snapshots, parallel execution, external dispatch substrate) — phrased as exclusions from the first slice, not prohibitions on the MVP.
   - Housekeeping: add `LICENSE` (scope confirmed by the owner rather than inferred from script headers), and correct `docs/research/report-research.md:82`, which claims a broken reference at `docs/research/user-workflow.md:52` that does not exist. By owner decision, the report, its replies, and this synthesis stay out of the README document map: they are transient review artifacts, and their durable content lives in `docs/roadmap.md` and `docs/control-plane.md` after the closure commit.
2. **Fix the verifier claim and the checker.** Restate `docs/research/report-research.md:116` as incidence checking rather than reachability, and strengthen `check_reachability` into a structural reachability check: a breadth-first walk from every `from: null` creation row, expanding wildcards, reporting any declared state not visited. Describe it accurately as structural reachability, not proof that guards permit every path, and add a disconnected-cycle regression fixture so the check cannot regress silently.
3. **Then run the workflow-driven schema-and-replay vertical slice**, merging reply 1's steps 2–3 with reply 2's structure: the schema milestone serves one concrete workflow, with the harness as first user, and the five decision areas (harness workflow, record semantics, event boundary, version baseline, milestone acceptance traces) settled and tested with the schema code.
   - Complete the revalidation record semantics: the `RESULT_REVALIDATED` payload gains `replacement_result_id`, and the replacement's `ACCEPTANCE_AUTHORISED` carries `supersedes_result_id`. The shared versioned result/acceptance-record definition makes the distinction explicit — a node is a mutable entity with versions; a result or acceptance record is immutable and is never edited, only superseded.
   - State the storage position precisely rather than as bare "open": the MVP requires a single-writer transactional append with atomic event-plus-state persistence; SQLite in WAL mode satisfies this for the slice and the experiment; nothing in the normative documents may depend on SQLite-specific behaviour; the production store is reconsidered when demonstrated requirements justify it, not locked until after the experiment. This prevents "open" being read as "pick anything" and keeps the single-admission-thread rule defensible against a store that brings its own connection and process model. The slice itself uses an in-process scripted test double with trusted fixtures, so no untrusted code executes before sandbox tests exist.
4. **Sequence capability gates with capabilities.** Sandbox and credential tests precede the first execution of untrusted repository or candidate code — a deterministic command such as `pytest`, a build, or a package installer can execute untrusted repository code, so determinism is not trust — whether or not a model adapter has been introduced. Conformance suites precede measured trials. Keep model adapters, recursive planning, parallel execution, runtime approvals, snapshot optimization, and distributed infrastructure out of the first slice, but record these as first-slice exclusions rather than MVP exclusions: concurrency stays in scope for the later experiment arms, and storage and dispatch choices remain revisitable.

This resolves the replies' only substantive conflict — whether specification closure precedes the slice — by keeping the closure commit deliberately small (one commit, mostly `control-plane.md`, `roadmap.md`, and `tables.py`) while refusing the report's original eleven-gate prohibition. Both replies' shared conclusion stands: GO for a workflow-driven schema-and-replay slice; NO-GO for freezing the full schema catalogue, committing to the infrastructure stack, or blocking all implementation on items that require implementation to resolve.

With both experts' amendments incorporated, the agreed sequence is: closure commit (classification table in `docs/roadmap.md`, the two verifier fixes, `LICENSE`, and the first-slice non-goals), then the workflow-driven schema-and-replay slice with the harness contract and the completed revalidation record semantics, then capability-gated expansion — decomposition and concurrency, sandbox and credential tests before the first execution of untrusted code, model adapter, and the experiment arms.

Both reply authors now return GO: reply 1 with the execution refinements recorded above, reply 2 with the four amendments and two corrections incorporated here. Neither requires another general research or readiness round before implementation. The closure change stays finite, and the schema-and-replay slice follows it directly.
