Skip to content

feat: add orchestrator-owned protocol v3 - #80

Merged
fazpu merged 1 commit into
mainfrom
proposal/state-driven-eval-cadence
Jul 17, 2026
Merged

feat: add orchestrator-owned protocol v3#80
fazpu merged 1 commit into
mainfrom
proposal/state-driven-eval-cadence

Conversation

@fazpu

@fazpu fazpu commented Jul 17, 2026

Copy link
Copy Markdown
Member

Why

The existing recursive loop could persist mechanical iteration state, but it did not make each loop layer’s semantic plan, decisions, current work, handoff, available harnesses, or completion authority consistently inspectable. The PM layer also scheduled its own eval roles and dispatched overly specific leaf actions, while parent/child communication could depend on prose or mutable artifacts.

Protocol v3 gives every durable loop layer the same explicit contract without taking judgment away from the models: the layer orchestrator owns its goal, plan, handoff, child acceptance, and completion; evals are optional evidence; delegates remain dynamic; and the engine validates identity/provenance rather than semantic sufficiency.

What changes

Durable layer state and absolute assignment context

  • Materialize a semantic state spine for each v3 session: plan, task records, current state, decisions, eval state, rolling handoff, workflow roster, scheduler views, capability roster, and terminal outcome.
  • Put absolute paths to the applicable layer state in every attempt assignment while keeping durable cross-record references relocatable.
  • Freeze the workflow contract/roster and the tree-wide four-tier harness capability roster in engine-owned session state.
  • Show coordinators the scheduled workflow roster and conditional next-workflow forecast so they can account for upcoming reviewers/eval runners without the scheduler deciding semantics.

Orchestrator-owned completion and optional evaluation

  • Declare one persistent completion/plan/handoff owner per layer (outer for inner_outer_eval, planner for pm_planner_dispatcher).
  • Allow that orchestrator to finish with no eval receipt, a non-passing receipt, or accepted receipts from earlier attempts.
  • Keep eval authors/runners as optional advisory evidence producers. Malformed or absent eval output becomes a diagnostic and never rewrites harness success.
  • Validate only identity, containment, hashes, and claimed provenance when control cites eval or handoff artifacts.

Parent/child contract

  • Keep child goals outcome-level and let the child inner_outer_eval orchestrator decompose them dynamically.
  • Give every v3 terminal lifecycle one topology-neutral session_outcome.json, including engine stops such as failure caps or max turns that have no terminal control.
  • Link that exact outcome upward; the parent separately records acceptance, rework, or reroute.
  • Freeze accepted control and handoff bytes in state so restart or trace-finalization refreshes cannot silently rewrite the terminal basis.

Cross-harness collaboration

  • Carry the released Team Harness 0.5.4 capability-roster context into root coordinators, nested harness coordinators, and direct spawn assignment records.
  • Prompt orchestrators to prefer independent cross-family analysis/review when useful, especially for eval-check creation, while leaving team shape and delegate choice dynamic.
  • Standardize four semantic tiers: frontier, strong, standard, and economy. Missing mappings stay unavailable rather than being guessed.

Stock workflows and documentation

  • Simplify pm_planner_dispatcher to planner + dispatcher; remove its scheduled eval author/runner roles.
  • Keep inner_outer_eval independently runnable as the one-layer system and as a recursively dispatched child.
  • Rewrite the packaged prompts, skill, README, HTTP/session docs, binding design, and decision log so a future reader can understand the contract cold.
  • Record the separate workflow-efficiency idea under design/proposals/; it is not implemented by this PR.
  • Bump Loopy to 0.8.0 and require published Team Harness 0.5.4.

Deliberate boundaries

  • No semantic completion checks in the coordinator.
  • No mandatory eval cadence or passing-eval prerequisite.
  • No parallel Loopy workers.
  • No path-level write prevention, approval flow, or human gate.
  • No fixed spawned-agent team topology or delegation quota.
  • No credential scanning or unrelated security machinery.
  • Historical v1/v2 sessions retain their frozen behavior; fresh stock sessions use v3.

Validation

  • Full test suite: 412 passed
  • Focused protocol/template/config suite: 72 passed
  • Pyright: clean
  • Ruff lint and format: clean
  • Wheel and sdist build: passed
  • Twine package check: passed
  • Dependency lock resolves the public team-harness==0.5.4

External review

Claude Code (claude-opus-4-8, xhigh) and Antigravity performed independent adversarial reviews. Their findings and dispositions are checked into design/analysis/.

Material fixes from review:

  • all engine-terminal child states now produce and propagate an outcome instead of crashing unwind;
  • protocol-v3 workers are accepted in the durable stale-retry handshake path;
  • accepted terminal control/handoff bytes are immutable engine snapshots;
  • adversarial provenance and retry paths have focused regression coverage.

@fazpu
fazpu merged commit 5255fc5 into main Jul 17, 2026
2 checks passed
@fazpu
fazpu deleted the proposal/state-driven-eval-cadence branch July 17, 2026 18:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant