Own exact worker process continuity
This commit is contained in:
parent
0fa4f89374
commit
75b841808b
11 changed files with 1493 additions and 92 deletions
|
|
@ -3164,11 +3164,12 @@ three. Exact live replay remains the package acceptance boundary.
|
|||
# Orphan worker Continuity authority map — 2026-08-10
|
||||
|
||||
Current mechanism: the coordinator persists an immutable runtime worker launch,
|
||||
spawns `epiphany-openai-runtime run-worker` detached, and records the returned
|
||||
PID only in its artifact JSON. The runtime store has no durable binding between
|
||||
that launch/job and the worker process incarnation. Coordinator death after
|
||||
spawn therefore leaves resident Self unable to prove whether the worker may
|
||||
still publish terminal output.
|
||||
spawns `epiphany-openai-runtime run-worker` with an activation-capability digest,
|
||||
then waits for the child-authored exact process claim before presenting the
|
||||
preimage. The worker cannot enter watchdog, provider, model, or tool paths before
|
||||
activation. Runtime result admission atomically replaces the active claim with
|
||||
`terminal-result`; resident Continuity may replace it with `terminal-death` only
|
||||
after exact native process observation.
|
||||
|
||||
- Owner: the worker runtime owns claiming its exact native process incarnation
|
||||
before model or tool work. Runtime Continuity owns activation, terminalization,
|
||||
|
|
@ -3178,9 +3179,9 @@ still publish terminal output.
|
|||
explicit activation bound to that claim, native exact-process observation,
|
||||
and authenticated terminal worker result.
|
||||
- Outputs: `claimed` before consequence-capable work, `active` only after one
|
||||
explicit activation, then exactly one `terminal-result` or `terminal-death`.
|
||||
A terminal-death attempt may be superseded by a new ordinal without deleting
|
||||
the prior launch family.
|
||||
explicit activation, then exactly one `terminal-result`, `terminal-death`, or
|
||||
`terminal-unactivated`. A terminal-death/unactivated attempt may be superseded
|
||||
by a distinct job/binding incarnation without deleting the prior launch family.
|
||||
- Derived state: coordinator artifact PID and detached `Child` handle are
|
||||
diagnostic only. Request identity remains retry-stable; launch, worker claim,
|
||||
process, session, and artifact directory are attempt-incarnation state.
|
||||
|
|
@ -3192,13 +3193,17 @@ still publish terminal output.
|
|||
direction must use the same worker start gate and terminal claim primitive.
|
||||
The worker itself claims before all provider/tool routes; no coordinator-only
|
||||
happy path may bypass it.
|
||||
- Cut line: persist a typed worker process claim from inside `run-worker`, gate
|
||||
work on exact activation, make terminal result close that claim atomically,
|
||||
and let Continuity write terminal death only after exact native observation.
|
||||
Then extend each typed launch family with ordinal/supersession bound to that
|
||||
terminal-death authority. Do not reuse the current unbound artifact PID.
|
||||
- Cut line: implemented in `runtime_spine.rs`, `epiphany-openai-runtime`, the
|
||||
coordinator launcher, and resident Self. `roleFailureReview` no longer owns
|
||||
proposal retry. All three typed lanes consult exact process terminality, and
|
||||
dead runtime-link projections are demoted before planning a replacement.
|
||||
The remaining cut is packaged Linux falsification, not another retry policy.
|
||||
- Verification layer: kill before claim, after claim/before activation, after
|
||||
activation/before result, and after valid result/before coordinator receipt;
|
||||
prove no model/tool work before activation, no dual live attempts, same typed
|
||||
request with distinct attempt/process/artifact identities, exact replay, and
|
||||
retention non-resurrection across all three typed lanes.
|
||||
retention non-resurrection across all three typed lanes. Source evidence now
|
||||
includes exact process/result race tests, activation CLI ordering, typed retry
|
||||
for proposal/Imagination/model direction, stale-link demotion, canonical Self
|
||||
settlement, core 660 passed/1 ignored, swarm 9, coordinator 17, and OpenAI
|
||||
runtime 10. Packaged Linux kill boundaries remain open.
|
||||
|
|
|
|||
|
|
@ -1,25 +1,39 @@
|
|||
# Fresh workspace handoff
|
||||
|
||||
## Orphan-worker ownership mapped — 2026-08-10
|
||||
## Orphan-worker Continuity source complete — 2026-08-10
|
||||
|
||||
The receipt-free pre-open coordinator boundary already has a focused source
|
||||
test and fails closed on exact runtime-incarnation absence. The remaining
|
||||
post-open fault is deeper than resident retry policy. Detached worker launch
|
||||
persists the immutable runtime job/document, but the spawned worker PID exists
|
||||
only in coordinator artifact JSON. No typed runtime state binds job, launch,
|
||||
PID, creation token, executable, activation, and terminal state. After
|
||||
coordinator death, neither resident Self nor Runtime Continuity can prove that
|
||||
the worker is dead; supersession would permit two workers to publish for one
|
||||
typed request.
|
||||
The runtime now persists one `EpiphanyRuntimeWorkerProcessClaim` per immutable
|
||||
worker job. `run-worker` claims its own PID, creation token, executable, and
|
||||
activation-capability digest before watchdog, provider, model, or tool work. It
|
||||
waits for the coordinator to observe that exact claim and present the matching
|
||||
capability. Failure to activate terminalizes the claim without cognitive work.
|
||||
An authenticated worker result and `terminal-result` claim replacement share
|
||||
one snapshot-fenced transaction.
|
||||
|
||||
The authority map is now explicit in the algorithmic map. `run-worker` must
|
||||
claim its own exact process before provider/tool work and wait for an exact
|
||||
runtime activation. Authenticated result or exact observed process death then
|
||||
terminalizes that same claim. Only terminal death can ground a new attempt
|
||||
ordinal. Proposal Modeling, Imagination consideration, and admitted model
|
||||
direction must share this primitive. Coordinator artifact PID is sight only;
|
||||
do not promote it or infer death from time/receipt absence. Actual c006 remains
|
||||
braked. Yggdrasil never builds.
|
||||
Resident Continuity resolves the request's exact worker launch and claim. Only
|
||||
native `Missing`, `Replaced`, or exact exit observation may replace a claimed or
|
||||
active process with `terminal-death`; alive waits, inaccessible/indeterminate
|
||||
fails closed, and a result race refuses. Self then uses its existing
|
||||
`process-failed` terminal vocabulary to clear the exact lease, terminalize the
|
||||
grant, and requeue pressure once. `roleFailureReview`, coordinator receipt
|
||||
absence, elapsed time, and legacy claimless launches grant no retry authority.
|
||||
|
||||
Proposal Modeling, Imagination consideration, and admitted model direction now
|
||||
share this terminality predicate. Imagination retries receive distinct binding
|
||||
IDs; every lane receives a distinct backend job. A dead process also demotes
|
||||
the stale active runtime-link projection so it cannot veto the new launch.
|
||||
Attempt history and terminal claims remain immutable. Focused user-story tests
|
||||
prove refusal before terminality and successful retry afterward for all three
|
||||
lanes, including canonical resident settlement. Full gates pass: core 660
|
||||
passed/1 ignored, swarm 9/9, coordinator 17/17, OpenAI runtime 10/10.
|
||||
|
||||
This cut is not yet committed, packaged, or accepted on Linux. Next commit and
|
||||
push it, package exactly once with the persistent Starfire cache, authenticate
|
||||
the 24-binary release and witness, and run the copied-state kill matrix at
|
||||
pre-claim, claimed/unactivated, activated/pre-result, and valid-result before
|
||||
coordinator receipt. Prove same typed request with distinct incarnation,
|
||||
no dual live worker, no pre-activation model/tool work, exact settlement, and
|
||||
retention non-resurrection. Actual c006 remains braked. Yggdrasil never builds.
|
||||
|
||||
## Heartbeat graceful SIGTERM accepted on Linux — 2026-08-10
|
||||
|
||||
|
|
|
|||
Reference in a new issue