RFC: Graph State Backend (Row-Level State, Resource Leases, Concurrent Applies)
The current AWS extension qualifies provider 6.74.0 for the existing SSM, log-group
and secret identity domains and the restricted SSM planning/refresh profiles. The
6.66.0 source reviews and measurements below remain historical; they have not been
relabelled as 6.74.0 evidence. The current review and rerun results are recorded in
specs/graph-state/qualification/aws-6.74.0.md (and those for 6.73.0 in aws-6.73.0.md).
Status: Core protocol implemented; stronger-claim initiatives in progress. The fifth-revision design below records the original protocol and its review findings. Its implementation and verification are recorded in delivery progress and Graph State Backend Model. The five initiatives under Stronger-Claim Initiatives are new work, not shipped guarantees.
Current focus (2026-11-14): measure and reduce orchestration overhead before
selecting another backend. Expansion of the qualification matrix is stopped;
existing work and captures are preserved. The immediate target is approximately
2.2 seconds for the original 10,000-resource, four-node-chain initial apply at
concurrency ten, with external provider work removed. This is a target, not a
shipped guarantee. The instantaneous-provider report at
specs/graph-state/performance/2026-11-14-orchestration/README.md records PostgreSQL
measurements, profiling, implementation changes and remaining costs. The next
Python algorithm pass is recorded in
specs/graph-state/performance/2026-11-14-python-algorithms/README.md: validate
stored lease ancestry directly and prepare ownership proofs once per bounded
batch, keeping the existing database fences and durable receipts. Measure these
changes before considering Rust or another native implementation.
Bounded durable return receipts are recorded in
specs/graph-state/performance/2026-11-14-return-batches/README.md. The
subsequent bounded creation pipeline, failed intermediate experiments and
per-step measurements are recorded in
specs/graph-state/performance/2026-11-14-pipeline/README.md. Its adjacent
1,000-resource comparison improved from 20.883 to 14.863 seconds; the original
10,000-resource run reduced database work by approximately 81% but did not
establish an elapsed improvement (170.520 versus the earlier 166.729 seconds).
The shared host was heavily loaded. Per-resource durable acknowledgements
became slower; throughput and acknowledgement latency must both be reported.
The proof-reconstruction follow-up is recorded in
specs/graph-state/performance/2026-11-14-operation-facts/README.md. Deriving each
object identity once and reusing small immutable lease calculations improved
an adjacent 1,000-resource pair by 4.5%. The fresh-process large pair measured
171.960/165.115 seconds (4.0%), while an earlier large pair regressed
140.408/164.986 seconds. Host and order effects prevent a stable large-run
speedup claim. All final states and receipts verified. Allocation/GC and repeated
proof construction are the next measured targets; no backend has been selected.
The
path to the orchestration target below
separates this incremental optimization from the architectural work a 100×
target may require.
A RocksDB-backed log coordinator remains a candidate; any comparison must
use the same provider, workload, authorization and durability requirements.
Date: 2026-11-04
Updated: 2026-11-14 (orchestration-overhead investigation; qualification expansion stopped).
Owners: nf.core (state engine, hybrid execution), netherframe.backends.postgresql
Summary
Before graph state, document-backed hybrid execution kept an app's state as one document: the state engine loaded all of it, held one global lock for apply, and wrote it back conditional on one serial and lineage. Two applies changing unrelated resources ran one after the other, history was a handful of checkpoint copies, and inspecting individual entries required parsing the state.
This RFC specifies a graph state backend in PostgreSQL, after Stategraph:
- State is rows, one per resource and output, each with a revision, an incarnation, the fingerprint of the configuration as written (its intent) and the inputs it was evaluated from.
- An apply is a patch of intent: the configuration changes its code makes relative to a trusted baseline, merged three ways per entry, and only then evaluated against what is committed. Concurrent patches that change different entries both apply; patches that disagree conflict explicitly.
- A run leases what it mutates (exclusive), what it consumes and what it relies on staying as its patch left it (shared), and the cloud objects it mutates, in one atomic, fairly queued request held until the run ends.
- Every mutation is a durable operation with a fenced state machine: it is validated against the row it changes immediately before the provider call, and an operation whose outcome is unknown is never overtaken by another run until its termination is established.
- Each resource is committed as it completes, in commit order, so history, audit and point-in-time state are queries.
It is hybrid-only and excludes Terraform: the state is not a Terraform state document, Terraform cannot read it, and synthesis rejects an app stored in it.
What changed from the fourth revision
| Finding (Codex review of revision 4) | Change |
|---|---|
| Fingerprints of evaluated configuration confuse code edits with upstream changes; unknowns treated as "different" | Reconciliation is on intent (configuration as written, references kept symbolic); evaluation happens after the merge, against committed upstream values; unknown is unresolved, never "different" |
| Snapshot baselines cannot protect against stale code; history retention erases the evidence | Pinned baselines are required for stale-code guarantees and for concurrent applies; without one a run is a classic two-way apply and says so; tombstones keep intent; active baselines are pinned against retention |
| Satisfied patch targets were skipped and never revalidated | Every entry the patch targets is leased (X if it writes, S if already satisfied) and validated through the end of the run |
| Validation by configuration fingerprint misses replacements, taint and identity changes; checked only at commit | Pre-call validation: revision, incarnation, status, provider and private-data digest of the target are checked in the transaction that dispatches the operation; action precedence is defined independently of fingerprints |
| Deletes ignore dependents created concurrently | Deletes and replacements lease the target's reverse-edge key; every edge writer takes it |
| Leases on addresses don't make cloud objects exclusive | Object identity leases and a uniqueness constraint on identity; adopted entries stay unconverged until a plan proves convergence |
| Reservations: refresh cannot prove an operation ended; expiry released its dependencies; returning owners stuck; replacement gap | Operation state machine (reserved → dispatched → returned → committed/aborted), dispatch fenced on the epoch, recovery requiring evidence of termination, the operation's lease footprint quarantined until recovery, loss of ownership terminal for apply and rollback, replacement as one operation with stages |
| Deferred rounds leased constructs, not actions; runtime functions can return new references | Deferred actions (deletes included) are leased; runtime-produced references need declared scopes or take app S; coverage is checked before any round mutates |
| Commit sequence had no stable frontier | The sequence is taken from a per-app counter row inside the commit transaction: sequence order is commit order, and the frontier is the last committed sequence |
| Drift policy changed meaning with concurrency | Drift correction is independent of locking mode; a fixed precedence orders missing objects, uncertainty, taint, drift and intent; unresolved upstream drift defers dependents |
| Recovery essentials scheduled late | Operations, fencing and crash recovery ship in phase 1, before anything else uses the new backend |
Background corrections from the review are applied: standalone planning releases its lock before a
later apply (execution/hybrid_planning.py), saved plans validate serial and lineage
(execution/hybrid_plan.py), and Python runtime functions are supported in configurations (only
Terraform functions are refused).
Motivation
These were the gaps motivating the original protocol; delivery status is recorded under Phases.
- Concurrency. Pull requests, teams and agents applying independent changes to one app queue behind the global lock. The PostgreSQL backend's resource-lock API exists but hybrid never uses it.
- Stale code. Today a run from an old branch silently reverts or deletes newer changes; nothing records what configuration produced an entry.
- Crash safety. A run that dies between a provider call and the state write leaves an object
nothing records; a failed state write falls back to
<outdir>/errored.tfstatefor the whole state. - History and queries. CHECKPOINT keeps the last five copies of the whole state, with no record of who changed what; "which RDS instances are not encrypted" is file parsing.
Goals
- Patch serializability: concurrent applies whose patches do not conflict, in any stacks, end in the state of applying the patches one after the other in commit order; no lost update.
- Mutation exclusion: no mutating provider call (
ApplyResourceChange, import, move) on a cloud object while another mutation of that object, by any run, may still take effect. - Stale-code safety with a pinned baseline: a run never reverts or deletes, unannounced, a change its code did not make.
- Crash safety: every operation's outcome is either committed, or recoverable from its record.
- Durable per-resource commits, attributed history, SQL access, and recovery strategies on history.
Non-Goals
- Terraform readability or interoperability (a one-off export to
.tfstateremains). - Serializing undeclared observations of the cloud: a data source that finds an object by name without declaring it, or changes made outside Netherframe. Declared observations are covered.
- Plans smaller than the app in the delivered protocol; initiative I2 proposes this extension. Current plans take no leases, so whole-app plans cost time, not concurrency.
- Transactions across independent graph states in the delivered protocol; initiative I4 records the coordination-domain decision and the gates for a future extension.
- Storage engines other than PostgreSQL in the first version.
Background: Before Graph State
This section describes the starting point of the original proposal, not the implemented graph path.
StateBackend/StateEngine(backends/): whole-document load,record_*changes, whole-document writes on an interval withinbatched_saves, compare-and-swap on serial and lineage,errored.tfstateon failure.- Planning (
execution/hybrid_planning.py) loads providers (reading the data sources their settings use first), refreshes every stored object into a newState(execution/hybrid_refresh.py), evaluates every construct, diffs per stack (diff_statesenumerates entries and deletes undeclared ones), reads data sources, and plans changes with providers. Providers whose settings wait for unknown values defer their resources to later rounds of the apply, behind their own approval (config/hybrid_settings.py). Objects a provider reports gone followdeleted_objects. - Reads are not tracked. References resolve through
HybridEnvironmentlookups, some by predicate (orchestration/state_shaping.py); data source and remote-state results are cached and reused at apply; runtime checks receive values for every stack; a hybrid runtime function may return a runtime value that is then evaluated (runtime/hybrid_runtime.py). - Apply writes more than changed resources: outputs are re-evaluated and stored on every apply, and data source results are recorded.
- The PostgreSQL backend stores the document as one JSONB row, with a global lock row.
What Hybrid Execution Already Rules Out
| Hybrid restriction | Where | What the design no longer needs |
|---|---|---|
No count/for_each: one instance per construct |
hybrid_repetition_error |
Instance keys; an address lease covers an absent entry |
No moved/import blocks; moves are explicit operations, adoption is a planned action |
_check_hybrid_constructs, execution/hybrid_state_ops.py |
Address rewrites inside a plan |
| No Terraform function calls (Python runtime functions are allowed) | _check_hybrid_constructs |
Dynamic reference targets, except references a runtime function returns (declared scopes) |
No create_before_destroy |
lifecycle_blockers |
Deposed objects: an address names at most one object |
No provisioners, connection, precondition/postcondition |
hybrid_meta_blockers |
State for them |
| No modules, no workspaces; one state per app | constructs are Python; execution/hybrid.py |
Module paths, workspace keys, cross-state transactions |
Proposal
Entries
Each entry (resource or output) row keeps, besides its state:
revision: monotonic per address, never reset, kept across delete and re-create by a tombstone.incarnation: changes whenever the object behind the address is replaced, created or adopted.intent_fp: fingerprint of the configuration as written: arguments with references kept as symbolic targets (ref(stack.aws_vpc.main.id)), constants, runtime function calls as name and symbolic arguments, lifecycle and meta-arguments, provider configuration name. No evaluated value is in it, so it never contains an unknown.inputs: the(key, revision)of every value its configuration was evaluated from when applied.applied_fp: fingerprint of the evaluated configuration it was applied with.object_identity: provider source, account and region scope, and the resource identity or import ID: the cloud object it manages.status:ready,tainted,unconverged(adopted, not yet planned against its configuration),uncertain(an operation on it has an unknown outcome),stale_inputs(kept as another run's intent while an input it was evaluated from changed; see Reconciliation).- Tombstones keep
intent_fpandrevisionat deletion.
Every committed version is kept in history with its commit sequence.
Baselines
A baseline is a commit sequence the run's code was written against. The default workflow is a
versioned nf.baseline file, created with nf state baseline pin from code matching the deployed
state before branching (or maintained by the deploy pipeline). --baseline <file|sequence|run>
overrides it; CI can pass a selector directly. The reference names backend type, state ID, lineage,
sequence and a retained pin ID. Active baselines are protected from history pruning.
A baseline older than retention is rejected, never treated as absence.
Without a pinned baseline, a run is a two-way apply (today's semantics: its code is the desired
state). It is announced as such, its reverts of newer intents are still detected from intent history
and reported as conflicts, and concurrent_applies refuses it: concurrent applies require pinned
baselines.
Reconciliation: Merge Intent, Then Evaluate
For each entry, with origin = its intent_fp at the baseline (a tombstone counts as present and
deleted), mine = this code's intent (absent if not declared), current = the committed intent:
| Case | Merge decision |
|---|---|
mine = current |
Satisfied target if mine ≠ origin, otherwise unchanged |
mine ≠ origin, current = origin |
Mine: this run's intent change |
mine = origin, current ≠ origin |
Theirs: another run's change since the baseline; kept |
mine ≠ origin, current ≠ origin, mine ≠ current |
Conflict: refused, naming the entry, the run behind current and both intents; --prefer-mine <address> resolves it explicitly |
mine absent, origin present (not a tombstone), current = origin |
Delete (the code removed it) |
mine absent, origin present, current ≠ origin |
Conflict (removed here, changed there) |
mine absent, origin absent or a tombstone, current present |
Created after the baseline, or re-created after a deletion this code made: theirs, kept |
mine present, origin absent, current present, mine ≠ current |
Conflict (both created it) |
Then evaluation: every entry whose merged intent is mine, or unchanged, is evaluated against
committed values (under the run's leases); if its evaluated configuration differs from applied_fp,
or one of its inputs changed revision, the provider plans it as an update, replace or no-op as
today. So upstream changes flow to dependents through evaluation, never through the merge: in the
review's example, a stale branch keeping a dependent's old tag sees "theirs" for the tag, and a branch
editing the tag while another replaces the VPC gets its tag change evaluated against the new VPC,
with no conflict.
Stale inputs. An entry this run keeps as "theirs" whose inputs include an entry this run
changes is re-evaluated by nobody in the run: its intent is another run's, and its evaluation is this
run's to change. Rather than mutate it under someone else's intent, the run marks it
stale_inputs (a status beside ready), reports it in the plan, and the next plan of any run that
holds its intent, or a plain re-plan, evaluates it. (Found by the TLA+ model: in a serial execution of
patches, such a dependent's inputs go stale with no run responsible for them.) The mark is itself a
write: it is made in the transaction that commits the changed input, or with a revision
compare-and-swap on the marked row while S on the input's reverse-edge key is held.
Action precedence, independent of fingerprints, per entry: an uncertain operation blocks it
(the node waits for recovery, and its dependents are deferred); an object reported gone follows
deleted_objects; tainted and replace_triggered_by replace; a merge decision of mine or delete;
drift correction; evaluation differences; otherwise no-op.
Drift is corrected as today (drift_correction defaults on in every mode) and is independent of
locking: a drifted entry becomes a write target of the run that corrects it, which contends, nothing
more. An upstream whose drift is unresolved (gone under deleted_objects=review, uncertain) defers its
dependents with reason upstream_unresolved instead of mutating them against it.
Read Provenance
Values carry the (key, revision) they came from (lookups, absences, enumerations at stack or app
generation); derived values carry the union; caches store provenance per value; data source results
carry their configuration's provenance; provider settings carry provenance inherited by every
mutation through the provider; lifecycle decisions record theirs. Reads outside any plan node are
classified in code with their disposition. Instrumentation lives in the evaluation layer. A runtime
function that returns a runtime value produces a reference not among its operands: such functions
declare their scope (hybrid_runtime(..., reads=[...])) or the node takes app S.
Declared scopes: runtime checks (reads=; undeclared reads the whole app), data sources and
ephemeral resources observing managed objects (observes=). Ephemeral values carry the declared
observation and configuration/provider input proofs to their managed consumers, while temporary
values stay in the session. An observes= declaration is a dependency like a reference: it adds the
observing entry to edges(p) of each observed entry p (the model found that without it, a run
updating p cannot see a concurrently declared observer, which then keeps p's old value). Observed
values are read again after leasing; the observation cache is never used as provenance. Phase 2
implements provenance as non-authoritative instrumentation that reports gaps on real apps.
Lease Sets
One atomic request per run, granted through a queue with aging (a younger request never overtakes an older conflicting one; a waiting run holds nothing):
- Write targets (
X): entries the run creates, updates, replaces, deletes, adopts or corrects; outputs it writes; for moves, the dependents whose dependencies it rewrites. - Satisfied targets (
S): entries its patch targets that are already as it wants, held so they stay that way until it ends. - Consumed values (
S): the provenance of what write targets consume, minus the write set; enumerations at their scope. - Reverse-edge keys: any write target
Twhose value others may consume (an update, including a follow-up update induced by evaluation, a replacement, adoption or delete) takesSonedges(T)and validates its generation, and a delete or replacement also checks that every dependent recorded there is in the run's write set or already gone. Any run adding or removing a dependency onTtakesXonedges(T)and bumps its generation; moving a reference fromTtoUdoes so on both. (The TLA+ model found that covering only deletes and replacements lets a concurrent run make an entry the updater keeps as "theirs" consume the updated entry's old value.) - Object identities (
X): theobject_identityof every write target, and for adoptions the identity being adopted, with a uniqueness constraint across entries (two addresses can never manage one object). - Adoption scope: an object being created has no identity until its create returns, so an
identity lease cannot cover it. Every adoption takes
X, and every createS, on a key for the provider scope (provider source, account, region and resource type) the object would live in, so an adoption cannot import an object another run is still creating. A create whose identity the client chooses and knows when planning (a name the configuration sets) must also takeXon that identity: the scope'sSalone lets two creates of the same name overlap. (Found by the TLA+ model, without any failure injected.) - Deferred actions: every action a deferred round may take (creates, updates and deletes whose provider is deferred, deletes leased up front even when their construct is gone), with their consumed values from static references, provider settings, declared scopes, references returned by runtime functions (declared), data sources' inputs, and the provider-scope keys of creates whose scope is known only after an earlier round (leased at the coarser scope that covers them). Coverage is checked before the first round mutates; a later read outside it fails that node before any mutation. Leases never grow during a run: the model's variant that grows them deadlocks.
Keys are structured (state_id, level, stack, kind, type, name) at app, stack and entry level, with
multi-granularity modes (IS, IX, S, SIX, X).
Canonical Object Identity Contracts
Provider configuration names and credential hashes do not identify cloud namespaces. An explicit provider contract must establish the provider source, concrete namespace, resource type and a canonical object key. Import identity schemas can help locate an object, but do not establish whether creates choose a key or allocate a fresh identity. Contracts must attest that distinction; it cannot be inferred from a computed schema attribute.
The implementation uses optional nf.graph_identities contracts returning portable ObjectLocator
recipes. These retain namespace facts, key fields and optional assertions on returned scope facts
in state and operation requests. Account/region evidence comes from the configured provider and
is refreshed for each ownership period. Returned-result recovery derives the same identity without
loading the original app or plugin. Contradictory scope facts remain quarantined.
A chosen key is required before dispatching its create. An unknown allocated key needs conservative identity-scope X coverage and the create's adoption-scope S. Independent allocations attested fresh may coexist within one run; this does not weaken cross-run coverage or allow imports to overlap unresolved creates. Returned allocations from one expired run retain their original allocation context when recovery ingests them. A state write can use an operation only when that fenced, owned operation covers its resource address.
Initial contracts cover built-in generated values and AWS SSM parameters. Unknown legacy ownership blocks canonical mutations of other objects of the same provider/type until established by a reviewed no-op of current configuration. Unsupported types retain serial compatibility; concurrent mutation requires explicit contracts and complete footprint coverage. Broader provider/type contract coverage remains open.
Planning, Validation, Approval
- Plan without leases, from one short consistent read of the rows at the current frontier (no snapshot held open while providers are called): the merge, evaluation, lease sets with revisions and generations.
- Lease atomically through the queue.
- Validate under the leases: every leased key at its recorded revision or generation; the merge
recomputed with
currentnow (a new conflict is refused; a target that became satisfied moves toS); reverse-edge sets as expected; nouncertaintarget. Stale means release and replan (automatic and bounded without a saved plan; a saved plan is rejected naming the keys). - Approve with leases held; the wait is bounded (
approval_timeout), after which leases are released and nothing is applied from that approval. A timeout between deferred rounds ends the run incomplete and keeps completed changes; the mutated run never releases and reacquires. Late callback answers cannot resume it. The initial implementation defaults to 300 seconds, configurable to any finite positive duration.
Operations
Each mutation is an operation row: op_id, run, epoch, address, object identity, action,
stage, the target's expected revision, incarnation, status and private-data digest, a digest of the
request, the returned result, and for replacements a sub-stage (delete_dispatched,
delete_committed, create_dispatched).
- Reserve (
stage = reserved), in a fenced transaction (below) that also performs pre-call validation: the target row is locked and must still have the expected revision, incarnation, status, provider and private-data digest. A mismatch aborts the node before anything is sent. - Dispatch: a fenced transaction moves
reserved→dispatchedimmediately before the provider call. Recovery can abort areservedoperation only by advancing the epoch in the same transaction, so an owner that paused after reserving cannot dispatch afterwards. - Return: the result is written as soon as the call returns (
returned, with any identity the provider returned). - Commit: the row, its version, the frontier and
committedin one fenced transaction. A node completes only after this, so dependents never consume uncommitted values.
A replacement is one operation through its sub-stages, so the intent to create survives a crash after the delete commits. Its footprint (address, identity, and the adoption scope for the create) stays held across the gap between the halves while recovery may still continue it.
Ownership, Fencing And Recovery
- Each run has an ownership row (
epoch,expires_at) renewed by a heartbeat independent of the walk. Every reserve, dispatch, return and commit locks the ownership row and the relevant lease rowsFOR SHAREand checks the epoch andexpires_at > clock_timestamp(); renewal and takeover lock themFOR UPDATE. An expired owner cannot renew. - Loss of ownership is terminal for apply and rollback: the run issues no new operations, waits for those in flight, writes what returned into their operation rows if it still can, otherwise to the errored file, and stops. It never rolls back afterwards.
- Quarantine: when a run's ownership expires, leases are released except the footprint of
each operation not
committedoraborted: every key its preconditions relied on, namely its address, object identity, consumed values, reverse-edge keys and adoption scope, which pass to the operation record. The address isuncertain. (The model's Python mirror found that releasing the adoption scope on expiry admits a create while an expired run's import is still to be sent.) - Recovery takes fenced recovery ownership of an operation (new epoch) and resolves it:
reserved: aborted (never dispatched).returned: the result is ingested idempotently (byop_id) and committed.dispatched: requires evidence of termination before the object can be refreshed and the result recorded: the owner process and its provider plugin processes are confirmed gone (same host, or the owner's heartbeat row reporting them killed), and the provider's longest operation duration has elapsed (operation_quiescence, defaulting toprovider_apply_timeoutwhen set, otherwise operator confirmation withnf state recover <op> --confirm-terminated). A create whose returned identity was lost is recovered by identity derived from configuration (as adoption does), a client token or tag the create carried, or operator import. Both evidence of termination and the identity of a lost create need a real source in the implementation; without one the operation stays quarantined, which is safe but manual.- Evidence of termination is required for every dispatched sub-stage, including a create a recoverer dispatched (the evidence is then about that recoverer's process).
- Recovery's writes are fenced by the recovery epoch and idempotent by attempt, so two recoverers never ingest one result twice.
- A footprint key is released only when no unresolved operation still needs it.
force-unlockcannot clear an operation; it only ends a run that holds no dispatched operations.
Commits, Frontier, History
Each commit takes the next sequence from the app's counter row (UPDATE ... RETURNING) inside the
commit transaction, so sequence order is commit order and the frontier is the last committed
sequence; plans and baselines read at a frontier. The counter row is held only for the commit's tail
(milliseconds). Groups recorded today with batched_saves(interval=math.inf) (moves, adoptions,
output storage, forget_stacks) commit as one transaction. A sequence allocated outside the commit
transaction and then aborted would freeze a contiguous frontier forever, so the counter row inside
the commit transaction is required, not an optimization. Outputs are reconciled like entries (their
intent is their configuration), and are never rewritten by a run that does not lease them, unlike
today's _store_outputs, which re-evaluates every output after each apply. Data source results are a
cache (nf_observations), not versioned for conflicts, never leased.
Moves And Adoption
A move takes X on both addresses, the moved object's identity, and every dependent recorded in
edges(source) (taking X on that key), and moves the row and rewrites the dependents in one
transaction. Adoption (a planned import) takes X on the address and the identity, enforces identity
uniqueness, and records the entry unconverged: its first evaluation always plans it with the
provider against its configuration, so an adopted object is never assumed converged.
Saved Plans
A saved plan records its baseline, merge decisions, lease sets with revisions and generations,
intents, evaluated fingerprints and deferred action scope. Applying it leases, validates and
re-merges as above; any difference rejects it naming the entries. format_version is bumped.
Recovery Strategies
- ROLLBACK runs only while the run holds ownership, before releasing leases; nothing outside the
run can have consumed what it deletes (that needs
S, which conflicts with itsX). It restores each row as it was before the run: a tombstone only for entries the run created from absent; an entry the run re-created (its object gone,deleted_objects=recreate) gets its previous intent back with no object, so dependents that consumed it keep a valid entry. It also removes outputs the run created. (Found by the TLA+ model: tombstoning a re-created entry left a dependent dangling and lost the entry's intent.) - CHECKPOINT is the set of
(key, revision)of the run's write targets before it. Restore is a state-only edit as today: it leases those keys, writes their checkpointed values as fresh revisions, and refuses (unless forced) when a later run changed a key or consumed a revision being replaced, naming those runs; consumers are checked under its leases, includingSon each restored entry's reverse-edge key. It takesXon every identity it restores and never waives identity uniqueness, even when forced. It ships with resource leases (phase 4). - Retention: 90 days by default, never pruning a pinned baseline in use. History keeps sensitive attributes and private data; the read-only role sees masked views.
History, Queries, Operations Outside Apply
nf state history [address], nf state show --at <sequence|run|time>, read-only SQL views
(resources_current, dependencies, outputs_current, history, runs, operations, leases)
under a read-only role: nf state query "<sql>". Taint, untaint, moves, rm, destroy_stack, whole-app
destroy, migration, restore and recovery are runs with leases and operations.
Settings
Following AGENTS.md "Orchestration Settings", secure by default: concurrent_applies (off; requires
pinned baselines when on), baseline, drift_correction (on), lease_timeout, approval_timeout,
operation_quiescence, kill_providers_on_lease_loss (on). --prefer-mine is per address only.
Data Model (Sketch)
| Table | Key | Contents |
|---|---|---|
nf_apps |
state_id |
lineage, schema version, app generation, commit counter (frontier) |
nf_stacks |
(state_id, stack_id) |
generation |
nf_entries |
(state_id, address) |
state, revision, incarnation, intent_fp, inputs, applied_fp, object_identity (unique), status, tombstone, run, sensitive paths |
nf_edges |
(state_id, target, dependent) |
reverse edges; generation per target |
nf_outputs |
(state_id, stack_id, name) |
value, sensitive, intent_fp, revision |
nf_observations |
(state_id, address) |
data source results (cache) |
nf_versions |
(state_id, key, revision) |
row as committed, commit sequence, time |
nf_baselines |
(state_id, name) |
pinned commit sequence, pinned by, expiry |
nf_runs |
run_id |
actor, operation, baseline, plan, sets, status, outcome, epoch, expires_at |
nf_leases |
(state_id, key, holder) |
mode, ticket; holder is a run or an operation (quarantine) |
nf_lease_queue |
ticket |
requested keys and modes, requested at |
nf_operations |
op_id |
run, epoch, address, identity, action, stage, sub-stage, expectations, request digest, result, footprint |
Formal Model
specs/graph-state/ holds a TLA+ model of this protocol (database, runs, cloud objects, crashes,
lease expiry, slow provider calls, recovery), summarized in
Graph State Backend Model. Invariants: no overlapping mutations, no
lost update, no unleased consumption, fenced commits, recovery never admitting overlap, patch
serializability, no dangling dependents, unique ownership of objects, no silent revert; liveness of
queued requests, quarantine resolution and a waiting writer; stable snapshots at the frontier.
TLC (2.19, OpenJDK 21) passes on all 104 configurations, about 12 minutes in total: the intended
design on 47 safety and 7 liveness configurations (up to 377,396 distinct states), reachability probes
violated as expected, and 37 regression variants each failing its named invariant. They reproduce
every review counterexample and 18 of 20 adversarial scenarios Codex (gpt-6-astra) proposed for the
extended model. The model covers replacement sub-stages, deferred rounds, three-entry dependency
chains, outputs, observations, checkpoint restore and concurrent recoverers. A standard-library Python
mirror explores the same state spaces state for state.
The model found five bugs in this revision's drafts, all fixed above: the reverse-edge predicate covering only deletes; identity leases unable to cover objects being created (the adoption scope); a quarantine footprint missing the adoption scope; rollback tombstoning a re-created entry; and observations not registering reverse edges. It also found the stale-inputs case of Reconciliation and made explicit the requirements stated above for replacements, client-chosen identities, deferred coverage, follow-up updates, stale marks, outputs, observations, restore and the commit counter.
Those are the original GraphState results and bounds. Later focused models cover retention,
approval, scheduling and locked SQL transactions. CombinedExecution, CombinedReplacement
and CombinedApply now compose operation DAGs, actual provider/check/value inputs, separate
clocks, replacement halves, canonical aliases, approved deferred rounds and SQL publication
waits. Twenty-six complete TLC witnesses replay against memory and PostgreSQL; the SQL/approval
cases use real row locks, buffered writes and the bounded approval function. The combined bounds
are four update nodes or three approval/SQL nodes with one replacement. See
implementation progress and specs/graph-state/README.md for
per-module results and limits. Fixed-grant admission and recovery claims are atomic assumptions
in the combined models and remain checked in their detailed models. Termination evidence,
locating a create whose response was lost and complete real-program read provenance still need
external evidence; finite model checks do not prove those facts for arbitrary programs.
Phases
- Rows, operations and recovery under an app lease (implemented:
PostgreSQLGraphBackend, see Graph State Backend). Schema, per-resource commits with the commit counter, the operation state machine with pre-call validation, fenced ownership, quarantine and recovery, runs, history, views, migration (rejecting keyed addresses such asweb[0]). Every run takesXon the app. This alone makes crashes recoverable. - Provenance instrumentation (implemented; authoritative for graph state, with optional
provenance_reportdiagnostics): recorded read sets and a gap report on real apps, including runtime functions, data sources and deferred rounds. The implemented provider/read surface has an RPC and cache inventory, service-descriptor coverage and direct-wire observation. Real AWS create, update, replacement, shared-cache and deferred-provider reference workloads report zero unexplained reads. Public concurrency controls and scale validation are complete; the progress document records their evidence and limits. - Intent, baselines and three-way merge under the app lease (implemented): intent fingerprints, inputs,
tombstones, pinned baselines and retention, identity uniqueness and
unconvergedadoption, the action precedence and drift rules. Valuable alone: stale branches stop reverting newer changes. - Resource leases (implemented): the queue, all lease sets, validation, quarantine of footprints, deferred
actions, consumer-safe restore;
concurrent_appliesbecomes available. Gated on the TLA+ model checking (it does, including replacement sub-stages and deferred rounds) and on phase 2 reporting no unexplained gaps on the reference apps.App(concurrent_applies=True)and the CLI flag select the resource policy with a pinned baseline; default applies and unsupported identities retain app X. Current-source 100/1,000/10,000-consumer and 1/2/4/8-writer captures pass; the progress document records exact checks, renewal statistics and the substantial cost of large fixed grants. - History administration (implemented): protected retention preview/prune, retained baselines and checkpoints, stable filtered history pages, masked CLI/JSON output and SQL views.
Testing
Against real PostgreSQL (podman) with a fake cloud that records every RPC with its interval: an execution-history oracle (no overlapping mutations of an object, every consumed value committed and not rolled back, committed patches equal to a serial order); fault injection at every operation stage (crash after reserve, after dispatch, after return, between the halves of a replacement, inside a move; paused heartbeat; dropped database; takeover racing a commit; a call outliving TTL); starvation tests; and the TLA+ traces replayed as integration tests.
Failure Matrix
| Failure | Outcome |
|---|---|
| Conflicting leases | Queued; fails after lease_timeout naming keys and holders; holds nothing while waiting |
| Plan stale at validation | Replan (automatic without a saved plan); saved plan rejected naming keys |
| Merge conflict | Refused naming the entry, the other run and both intents |
| Target changed between validation and dispatch | Pre-call validation aborts the node; nothing sent |
| Crash after reserve | Recovery aborts the operation; nothing was sent |
| Crash after dispatch | Address uncertain; footprint quarantined; recovery needs evidence of termination |
| Crash after return | Recovery ingests and commits the result |
| Crash between halves of a replacement | The operation's sub-stage records it; recovery continues or reports |
| Database unreachable | No new operations; in-flight calls finish; results to operation rows or the errored file |
| Ownership lost | Terminal for the run: no new operations, no rollback |
Stronger-Claim Initiatives
These initiatives turn the Stategraph comparison into implementable work and evidence requirements. They do not authorize weaker admission, incomplete provenance, unconditional recovery, or an "exactly once" cloud-execution claim. PostgreSQL cannot atomically commit an external provider's side effects. A checkpoint restores recorded state; it is not a cloud rollback.
The comparison inspected Netherframe bae6bf26 and the public Stategraph repository at
24e99ac1.
Stategraph documents scoped planning,
pre-apply conflict checks
and multi-state execution.
Its public source does not expose the complete commercial conflict/recovery implementation.
An unobserved or undocumented guarantee is unknown, not a demonstrated failure. Comparison
results must identify the tested build and distinguish documented, inspected and observed behavior.
A subsequent inspection on 2026-11-08 examined the Linux amd64 commercial image
ghcr.io/stategraph/stategraph-server@sha256:330ee52ec9132b5ffa51ff44a27722aeb60a7d71989b0e5ecfb4e4b76ed0910a.
Both executables reported 3.2.27; the server executable's SHA-256 was
f02d5414840eb4be93ab9c2b4c56eb60e7f3a3471c931ead078d46de6bf40451.
Embedded SQL, debug symbols and selected disassembly exposed revision comparison, subgraph
selection, per-state admission locks and transaction-cache cleanup. Twelve isolated PostgreSQL
replays checked the extracted conflict predicate; they did not exercise an activated server or
establish end-to-end recovery behavior. The refinements below are Netherframe proposals informed
by those mechanisms, not copied implementation or new comparative guarantees. Retain branch-origin
merge, authoritative provenance, canonical object exclusion and per-operation fencing throughout.
A deeper pass recovered 183 intact SQL strings/fragments, including their embedded comments, and traced selected OCaml closures through module initialization and disassembly. Twenty additional isolated SQL cases checked data-source pinning/comparison guards and per-state narrowing cleanup. These are statement-level results, not tests of the complete Stategraph planner. Comments describing internal benchmarks are leads for experiments, not independently reproduced performance evidence. The inspected structural-round cap logs non-convergence and returns its current result; other stages may impose additional checks. Timeout/failure handlers select abort/fail transitions whose comments retain conflict footprints, while the inspected admission predicate excludes those two terminal statuses. Neither observation establishes an end-to-end defect without the I1 schedules. They motivate explicit convergence outcomes and operation-level enforcement below; symbol names, retained rows and comments alone do not establish those guarantees.
A local Ghidra pass added C-like pseudocode with OCaml register/closure annotations, exact ELF address checks and explicit bounds for inferred jump tables. This is static analysis, not recovery of the original OCaml source or a new conformance result. The reviewed value guard treats an undecodable file reference as affected and requires positive certainty before returning unchanged. Indirect calls and inferred types still require assembly review; a successful decompiler export alone proves no guarantee.
| ID | Initiative and owner | Delivered starting point | Claim permitted only after its gate |
|---|---|---|---|
| I1 | Adversarial conformance suite — core testing, PostgreSQL | Operation histories, native fault injection, bounded models and wire audit | The named invariants hold in the published scenarios and schedules on the tested builds |
| I2 | Scoped planning — execution, values, graph backend | Whole-app planning; selective concrete proof validation | Evaluation, refresh and payload reads are confined to a proven dependency closure, with explicit drift coverage |
| I3 | Identity contract coverage — provider extensions, core providers | Version-bound profiles for generated values, AWS SSM Parameter, log groups and secrets; conditional app X fallback | Canonical exclusion and safe recovery for the specifically qualified resource types and provider versions |
| I4 | Coordination-domain decision — core execution, backends | One app state in production; bounded two-state model and experimental PostgreSQL coordinator | No production cross-state claim today; an extension must pass the gates below |
| I5 | Matched performance evidence — performance harnesses | Microbenchmarks and native/Terraform end-to-end fixtures with raw correctness observations | A measured improvement for the published workload, correctness contract and environment |
I1 — Adversarial Conformance and Comparison
Contract. Test effects, consumed values and recovery outcomes through each system's supported interface. An oracle must not derive expected safety from the lease or footprint algorithm it is testing. A refused or indefinitely quarantined operation may be safe without being live; report those outcomes separately. Abort alone is not proof that a remote mutation stopped.
Implementation seams and artifacts. Extend tests/helpers/graph_execution_history.py,
graph_apply_history.py, graph_rpc_inventory.py and graph_rpc_audit.py; reuse the memory and
PostgreSQL adapters and the actual hybrid provider gateway. Keep portable scenario definitions
under tests/helpers/, recorded histories under specs/graph-state/histories/, and runnable
comparative cases under libs/netherframe.core/tests/integration/graph_comparison/ (new, collected
by the workspace test paths). Keep backend-specific SQL schedules in the PostgreSQL package's
tests. Do not add another production backend interface just to make the comparison fit. The
external adapter may drive a supported Stategraph CLI/server when available; absence of that
server is an explicit not-run result.
Live demo qualification (2026-11-09). The user has now authorized direct tests against a
30-day Stategraph cloud demo, superseding the earlier exclusion. The installed CLI reports
3.2.28; authenticated stategraph info also reports server 3.2.28 and state schema 19.
The supplied key sees one tenant, whose initial state listing is empty. Subsequent fixture
observations below go beyond connectivity but do not complete the portable comparison suite.
Historical not-run records remain unchanged, and no comparative guarantee follows from having
the CLI or a demo subscription. Keep the API key in local private configuration, outside the
repository and evidence artifacts.
Qualify this adapter in stages:
- Record the authenticated service/CLI versions, edition, tenant/workspace binding and supported observations. Use new, uniquely named synthetic fixture states; do not overwrite an existing workspace's state or configuration. Record the demo expiry when the service exposes it rather than assuming the 30-day period starts on the inspection date.
- Exercise import, plan, saved apply, export and direct service checks with the same pinned Terraform/provider binaries and isolated FakeCloud accounts as the native fixture. Retain refresh and revision checks. Verify that the provider runs locally and can reach the fixture endpoint; do not substitute real AWS credentials if that setup is unsupported.
- Prioritize stale saved plans, both stale-branch commit orders, disjoint/shared-input/conflicting writers and two addresses for one physical object. Then inject caller loss after dispatch, delayed results, replacement gaps, transaction abort/expiry and recovery retry. Observe actual provider/service effects and durable state independently of CLI exit status. An unavailable barrier or observation is an explicit unsupported/unverified case, never a passing substitute.
- Exercise two linked synthetic states separately: changed producer input, conflicting cross-state
writers and partial provider failure. Record the scope of committed state and surviving cloud
effects; the word "transaction" does not establish whole-apply cloud atomicity. Compare against
the bounded Netherframe prototype separately from the single-state production backend.
The implementation protocol is
specs/graph-state/qualification/stategraph-linked-state-interface/README.md: qualify exact transaction membership, automatic dependency expansion and explicittf mtxindependently, then bind each fault to actual service effects and per-state exports. Installed CLI help, current documentation and single-state API probes establish entry points. The exploratory two-state probe20261110T041728observes automatic and explicit planning of both objects, but refuses both linked applies at the expected-writer check. Post-abort API receipts report only the producer UUID while/state-maplists both names; the exact earlier rejection payload was not retained. Reported IDs cannot yet certify complete writers or readers, and display indexes alone do not qualify the plan's UUID binding. The second probe20261110T043630preserves original plan files and both show outputs: the text legend explicitly maps indexes to names, resolved through a separately checked inventory. Both planned writer UUIDs are now independently projected, while a captured previewed API response reports the producer alone. The 247-test projection/boundary suite now includes composite dispatch and export checks. Prepare and apply require exact expected planned writers, unchanged original show/artifact bytes, fresh inventory and stable reported API membership; reported IDs are never promoted to a complete write receipt. The dedicated discovery runner preserves controls through independent full exports/service reads, since selected plans omit unchanged objects. E27 (stategraph-linked-state-interface/discovery/README.md) independently verifies both discovery paths through actual applies: two state-qualified updates, preserved controls, producer acceptance before consumer mutation, matching exports/service versions and committed transactions. The original inline tuple/list verifier diagnostic remains archived with an explicit corrected replay. Shared regressions pass 1,170 tests. E28 (stategraph-linked-state-interface/contention/README.md) then verifies the two-state overlapping-writers case: both explicit saved plans share the origin, the left producer request is held before service forwarding, and the actual right apply is refused without provider mutations. After release the left updates both states, controls remain unchanged, state/service versions agree, and terminal statuses are committed/aborted. The 418-test suite includes coherent adverse-history controls; matching final exports alone cannot pass. This is one hosted fixture, without a matched production Netherframe multi-state counterpart. E29 (stategraph-linked-state-interface/stale-consumer/README.md) verifies the sequential stale-consumer case: the original consumer-only plan proposesc1|p0, a separate producer publication establishesp1/c0|p1, and actual apply of the unchanged saved consumer plan is refused without provider mutations. Producer no-ops retain the observed read value in the original plan; no state-binding rule was relaxed. All 473 targeted tests pass, including coherent stale-input and unreviewed-value-change controls even when final state/service agree. E30 (stategraph-linked-state-interface/partial-failure/README.md) executes the final named linked partial-failure/fresh-recovery schedule and retains an adverse intermediate result: producerp1/version 2 is accurately recorded, but the denied consumer export contains plannedc0|p1/version 1 while the service retainsc0|p0/version 1. Actual provider diagnostics confirm the injected permanent error; caller/provider termination is witnessed before fresh recovery. A new plan repairs only the consumer, without repeating the producer mutation. Final state/service agree, but partial-state accuracy fails. All 571 targeted tests preserve this adverse verdict; no layer-specific cause or universal parity claim follows. The four named linked schedules now have bounded observations; the broader I1 matrix remains open. In particular, documentedfailed-committedprogress must not be confused with cloud rollback, and sequential exports cannot prove atomic multi-state publication. - Only after correctness qualification, collect matched I5 repetitions. Record hosted service placement, network latency and unavailable server counters. A hosted Stategraph versus local PostgreSQL result is an end-to-end deployment comparison, not an isolated planner speed claim. Preserve raw failures and uncertain outcomes; clean up only fixture-owned objects after their outcomes are checked, retaining the evidence before removing synthetic states.
The demo time limit prioritizes external observations without relaxing these evidence gates.
First live observations (E16). Empty-state creation followed by ordinary plan/saved apply
successfully creates and updates two isolated SSM parameters through Terraform 1.15.9/AWS 6.66.0
against local FakeCloud. Direct service reads agree with exported state. HCL-only onboarding
before the initial plan instead produces a no-op and failed export in both JSON and native HCL
controls; those failed attempts are retained. StategraphCLI.bootstrap_empty() supplies the
successful path, with thirteen boundary tests passing.
An initially refused saved apply only exercised local file revision checks. In the corrected
schedule the exact planned HCL is restored after a competing same-resource commit: Stategraph
reports a transaction conflict, and the winning value remains in cloud/state. Separately, two
copied-checkout observations plan updates to both resources and revert a newer independent edit
still declared at its old value by the checkout. Native E1/E14 preserve that newer untouched edit
with a retained origin. These are distinct stale-plan and branch-intent behaviors, not a universal
comparison of either product. E16 retains rendered configurations, plan actions, command outcomes
and ordered service/state reads; normalized I1 wire/effect histories, other interleavings, aliases,
loss/recovery, two-state cases and matched timings remain open. The demo key lacks tenant admin,
so deletion of the five synthetic state records was refused; cleanup attempts are retained.
The user subsequently removed those states in the UI; a fresh CLI listing confirmed zero states.
See specs/graph-state/qualification/2026-11-09-stategraph-demo/ for exact evidence and limits.
Matched configuration histories (E17). The repository harness graph_comparison/run_configuration.py
now drives the same two-SSM fixture through native full, native affected and Stategraph 3.2.28.
Four schedules vary overlapping/disjoint edits and whether the old plan was saved before the
newer commit or created afterward from an old checkout. Twelve captures pass independent checks
over 988 events, 400 actual HTTP requests and 45 mutations. Separate hosted directories retain
the exact planned HCL, so local revision refusal cannot substitute for a remote conflict check.
The checker imports no planner and verifies mutation payloads, saved bytes, native origins,
actual planning scope and ordered independent service/state reads. All 59 targeted tests pass,
including 29 damaged-history controls; initial diagnostic-matcher failures remain archived.
| Matched workflow | Native full / affected | Stategraph 3.2.28 |
|---|---|---|
| Saved plan, overlapping newer commit | Refuses without an old mutation | Refuses without an old mutation |
| Saved plan, disjoint newer commit | Preserves both edits | Preserves both edits |
| Fresh plan from older checkout, overlapping edit | Refuses the intent conflict without mutation | Plans and applies the older checkout's desired updates |
| Fresh plan from older checkout, disjoint edit | Preserves both edits | Plans and applies a reversion of the newer untouched edit |
The hosted checkout updates are visible in the new plan. These results distinguish optimistic
saved-plan checks from retained branch intent; they do not establish behavior for every possible
workflow. Source c1b33cec…, exact producer/verifier hashes, raw captures and the offline report
are in specs/graph-state/histories/conformance/2026-11-09-cli-configuration/. HTTP exchanges are
not provider RPC intervals or database receipts. E18 adds sequential dependency histories and
E19 adds independent/shared-reader HTTP overlap, E20 contended applies and E21 explicit-name
physical aliases; failure/recovery, cross-state, wider identity and I5 timing gates remain open. Four fresh hosted fixture
states remain for UI/admin cleanup; the local accounts were reset.
Matched dependency histories (E18). graph_comparison/run_dependencies.py adds one producer
and two consumers, with four schedules crossing shared/changed producer and saved/fresh planning.
Both seed consumers look up the producer's description in a dictionary whose origin and
new-edit keys map to the same stable value. The old actor changes r1 to read the producer
directly. The competing actor either edits r2 or changes only the producer. In the latter case
neither consumer receives a competing HTTP mutation, so a saved-plan refusal cannot be explained
by a competing cloud write to the old reader. This does not expose the hosted server's internal
read-set or revision-validation mechanism.
All twelve native full/affected and hosted 3.2.28 captures pass independent checks over 1,320 events, 564 HTTP requests and 59 mutations. All 120 targeted tests pass: 61 dependency checks, including 44 damaged histories, plus the existing 59 configuration/observer/CLI checks.
| Matched dependency workflow | Native full / affected | Stategraph 3.2.28 |
|---|---|---|
| Saved consumer plans share an unchanged producer; sibling commits first | Preserves both consumer edits | Preserves both consumer edits |
| Saved consumer plan; producer-only edit commits first | Refuses without an old mutation | Refuses for remote transaction conflict without an old mutation |
| Fresh consumer plan from older checkout; sibling committed | Preserves both consumer edits | New plan visibly reverts the sibling's newer edit |
| Fresh consumer plan from older checkout; producer changed | Preserves the producer edit and consumes its current value | New plan visibly restores the old producer and uses that restored value |
Source a3b4ca66…, exact producer hashes, raw captures, six preliminary attempts and the offline
report are in specs/graph-state/histories/conformance/2026-11-09-cli-dependencies/. Two preliminary
attempts failed before mutation because ConditionalExpression cannot currently be fingerprinted
as graph intent; the final fixture uses the supported dictionary-index expression. Four corrected
native preliminary captures are retained too. No production behavior was changed for these runs.
The fixture uses ordinary planning with refresh/revision checks enabled. These are sequential
HTTP-effect histories, not proof of simultaneous read/read grants, provider RPC intervals, server
database receipts, recovery or performance. Four additional hosted records remain for UI/admin
cleanup, with their local accounts reset; eight E17/E18 records remain in total.
Matched overlapping applies (E19). graph_comparison/run_overlap.py saves both plans before
starting either apply. Each actor changes a different SSM parameter. In the shared-producer
variant both consumers also read one unchanged producer. All six native full/affected and
hosted 3.2.28 captures demonstrate two actor-owned mutation HTTP requests in flight before either
is forwarded, followed by preservation of both edits in service/state. There are 982 events,
264 HTTP requests, 30 mutations and six overlap witnesses. All 191 targeted tests pass, including
52 damaged-history controls and eight observer checks over real sockets/processes.
The observer uses one common proxy and identical provider settings/environment. Linux socket
ownership and process ancestry identify each request; resource names do not supply attribution.
Native actors use separate processes/backend sessions, and hosted actors use separate CLI
commands. A barrier holds both actual PutParameter requests before forwarding. Unknown actor
ownership, a timeout, early forwarding, changed saved bytes or two serialized successes fail
the independent checker. This is observed HTTP overlap, not measured complete provider RPC
intervals, simultaneous service-side mutations, internal hosted grant receipts or throughput.
An initial distinct-proxy experiment correctly broadened native planning evidence because the
provider-runtime fingerprint includes the launch environment; it is retained as a failed overlap
attempt. The common-proxy fixture preserves that evidence without weakening validation. Eleven
preliminary captures remain: seven pass the final checker, four retain the proxy/ownership/snapshot
observer failures. No production behavior was changed. Source 4cb66114…, exact producer hashes,
the runtime-input control, raw histories and offline reports are in
specs/graph-state/histories/conformance/2026-11-09-cli-overlap/. Four additional hosted records
(two preliminary and two final) remain for UI/admin cleanup; all local fixture accounts were reset.
The E19 post-run inventory contains twelve records. E20/E21 below add contended-writer and
explicit-name alias evidence; loss/expiry/recovery, opaque/cached inputs, linked states and I5 timings remain open.
Matched contended applies (E20). graph_comparison/run_contention.py saves both plans
before dispatch, then holds the first actor's actual PutParameter request while the contender
attempts its apply. Three schedules cover two writers of one parameter, a consumer held before
a producer update, and a producer held before a consumer update. All nine native full/affected
and hosted 3.2.28 histories pass: each contender is refused before any mutation, each holder
completes, and direct service/state values and SSM versions agree. There are 1,419 events,
372 HTTP requests and 36 mutations. All 273 targeted tests pass, including 72 contention-oracle
and 12 real socket/process observer checks.
The dependency fixture uses a lookup with equal results for both producer values, so a producer edit does not itself mutate the existing consumers' cloud values. The reader's changed expression consumes the producer directly. Metadata footprints can still intersect; this does not isolate an internal read-set algorithm. Native uses explicit zero-wait lease acquisition. Hosted refusals must report remote transaction conflict, with local revision-hash failures excluded. No refresh, revision or admission guard is disabled, and saved plan bytes remain unchanged.
The observer records an actual contender apply-process launch. It watches up to 20 seconds and requires a live PID/start-identity witness for a pending outcome; all nine contenders finish during the hold. Any competing mutation is forwarded and recorded, so the observer cannot manufacture exclusion. Successful SSM response versions reconstruct per-object mutation order independently of response arrival. The checker separates a valid observation from a successful safety check: concurrent effects, serialized stale writers, state disagreement and post-effect failures cannot be promoted to safety. A hold timeout invalidates observation and prevents later retries from forwarding, including after late controller release. Synthetic controls cover both unsafe histories and the bounded pending-process path; they are not additional live coverage.
Source ebdcd060…, exact producer hashes, three preliminary native histories, raw final captures
and offline reports are in specs/graph-state/histories/conformance/2026-11-09-cli-contention/.
No production behavior changed. This establishes the stated three conflict outcomes, not complete
provider RPC intervals, hosted grant/readiness receipts, unbounded waiting, recovery or throughput.
The E20 post-run CLI inventory contains fifteen completed fixture records, with local accounts
reset. E21 below adds explicit-name alias comparisons; loss/expiry, replacement/recovery,
cached/opaque inputs, linked-state schedules and the full I5 timing matrix remain open.
Matched physical aliases (E21). graph_comparison/run_aliases.py gives distinct logical
addresses aws_ssm_parameter.r1 and r2 the same explicit SSM parameter name under the same
account/region/provider configuration. Both native and HCL configurations explicitly use
overwrite=true; actual HTTP bodies must confirm it. The provider therefore permits an upsert,
so a provider-side create-only refusal cannot masquerade as graph ownership protection.
All nine captures are valid observations: six native safety passes and three hosted adverse outcomes. There are 753 events, 169 HTTP requests and 21 mutations. All 80 alias-checker tests and 273 existing comparison/observer/CLI checks pass. The results establish a bounded additional native protection for these configurations, not universal superiority or a conclusion about Stategraph's advertised promises outside this tested profile. Full/affected identifies the requested native policy: the existing-owner case refuses before producing a plan artifact, while successful plans in the other cases verify their actual scope.
| Physical-alias workflow | Native full / affected | Stategraph 3.2.28 |
|---|---|---|
| Add a second address for an already-owned parameter | Planning refuses duplicate physical ownership; no alias mutation | Applies the alias upsert; exports both owners; original owner disagrees with current cloud values/version |
| Save two creates from one original baseline; apply them sequentially | Second saved apply fails physical ownership validation before mutation | Both succeed; two owners remain and the first owner's row becomes stale |
| Hold the first create's actual HTTP request; attempt the other saved create | Zero-wait admission refuses the contender before mutation | Contender mutates while holder request is held; both applies succeed; two owners remain and the contender's row becomes stale after holder completion |
Snapshots retain every logical row rather than collapsing by physical name. The independent checker verifies exact targets, saved bytes, origins/scope, process/socket attribution, actual request/forward/response order, sequential publication or held-request ordering, and direct cloud reads against per-response SSM versions. It reports duplicate owners and each stale logical row separately. Removing a stale row from exported evidence cannot hide the independently observed alias effects; controls exercise that omission as well as version gaps, changed names and forged pending-process witnesses. A valid adverse observation is never promoted to a safety pass.
The hosted race has one conflicting HTTP interval pair, not evidence of simultaneous service-side
mutations or complete provider RPC timing. These observations do not expose internal hosted grants
or qualify generated names, separate states, other providers/versions, overwrite=false, recovery
or throughput. The race capture does not independently decode the native grant footprint; the
planning and sequential cases separately observe explicit physical-ownership refusal diagnostics.
Source 2e7a0701…, exact hashes, raw histories and offline reports are in
specs/graph-state/histories/conformance/2026-11-09-cli-aliases/.
Three preliminary native histories remain intact. Two initially failed only because the checker did not recognize the specific ownership diagnostics; all three replay safely with the corrected classifier. No production behavior changed. Three new hosted records bring the latest CLI inventory to eighteen completed fixtures, with zero unrelated visible states and all local accounts reset. Fault/expiry, replacement/recovery, cached/opaque inputs, linked-state comparisons, wider identity profiles and the complete I5 timing matrix remain open.
Equal names in distinct namespaces (E22). graph_comparison/run_namespaces.py supplies
the complementary physical-identity control: r1 and r2 share one explicit SSM name but use either
different resource regions (us-east-1/us-west-2) or different fixture accounts at us-east-1.
The account case uses a second provider configuration. Both actors save plans from one origin,
then both actual mutation requests must reach a common barrier before either is forwarded.
All six native full/affected and hosted 3.2.28 cases preserve both edits with matching cloud/state
ARNs and SSM versions. There are 994 events, 266 HTTP requests, 30 mutations and six HTTP overlaps.
All 69 namespace-checker and 364 observer/regression checks pass (433 total).
The observer maps each signed request's access key to its temporary fixture-account binding and records only the public account ID, signing region and service. Keys, signatures and authorization headers are excluded; unknown accounts/scopes fail before forwarding. It does not independently verify signatures. Direct enumeration of both FakeCloud account/region namespaces supplies ARNs and versions; every logical state row remains visible. The independent checker compares exact inputs/HCL, signed namespace observations, expected physical ARNs, returned service/state ARNs, versions, saved bytes, retained native origins/scope and actual pre-forward overlap. Collapsing objects by equal name, inventing a namespace or merely matching final state cannot pass.
Source 0723cd90…, exact hashes, raw captures and offline reports are in
specs/graph-state/histories/conformance/2026-11-09-cli-namespaces/. Three preliminary attempts
remain: two positive controls and one account seed failure from an unsupported fixture constructor
argument, corrected to ProviderSettings(alias="other"). No production behavior was changed.
The shared observer gains a secret-free request-field hook, and final capture redaction includes
all registered fixture credentials, including the second account. Existing comparison checks pass.
Together E21/E22 distinguish the tested duplicate physical owners from independent account/region namespaces. The hosted alias adverse outcomes remain unchanged. These controls do not qualify other providers/versions/partitions, generated names, cross-state ownership, recovery or throughput, and HTTP overlap is not a complete provider RPC or hosted grant receipt. The latest CLI inventory contains twenty completed fixture records and no unrelated visible states; all local accounts were reset. Remaining external fault/expiry, replacement/recovery, cached/opaque and linked-state gates and the full I5 matrix remain open.
Accepted response loss and explicit recovery (E23). Two matched schedules now cover an accepted SSM update and an accepted explicit-name create whose successful HTTP response never reaches the provider. All six native full/affected and hosted Stategraph 3.2.28 captures pass: 851 events, 181 HTTP requests and 15 mutations. Both plans are saved first. The observer holds the actual successful service response, verifies live owned caller/provider PID birth identities and an isolated process group, kills that group, and witnesses termination. Direct service reads prove acceptance while state remains unchanged.
Native waits for real lease expiry (TTL 2 s, renewal 0.25 s), retains the exact dispatched operation and identity/value exclusion footprint, and refuses the contender without a mutating request. Explicit recovery probes that operation, records the object as unconverged, and a fresh plan/apply makes it ready. Hosted keeps the abandoned transaction committing and also refuses the contender. After witnessed termination, abort of that exact saved-plan transaction permits supported repair: a fresh plan/apply refreshes the update; an explicit import block adopts the orphaned create. Abort itself does not repair state. All final target versions remain 2 (update) or 1 (create), with no repeated provider mutation. Native identity-based discovery and hosted explicit import are distinct recovery workflows with the same observed exclusion/no-replay result in these cases.
Independent replay checks effects, process death, saved inputs, scope/baselines, exact operation
or transaction association and service/state convergence. All 132 checker controls and 438
observer/regression/CLI checks pass, including synthetic repeated effects that cannot pass merely
because final state matches service. Six preliminary histories retain one optional-field reader
failure and five valid observations. Source 204f296e…, raw captures and hashes:
specs/graph-state/histories/conformance/2026-11-09-cli-loss/.
This is one-state, explicit-name AWS 6.66.0 SSM/FakeCloud evidence with confirmed local termination, not exactly-once cloud execution. Live old-provider/late-response, abort/expiry while in flight, replacement-gap, interrupted recovery, database-outage, cached/opaque and linked-state comparisons remain open, as does the full I5 matrix. E21's hosted alias adverse outcomes are unchanged. The new read-only inventory contains 25 completed owned fixtures, no unrelated states; all jobs are terminal and local accounts reset. Old cleanup records were not reused.
Paused caller with a live provider (E24). Two explicit-name SSM schedules now exercise an old provider call still capable of taking effect after its caller stops progressing. Six valid native full/affected and hosted 3.2.28 histories contain 962 events, 198 HTTP requests and 17 mutations: four native safety passes and two hosted adverse outcomes. Both plans are saved first; the observer holds the left provider's actual mutation before forwarding. Only its caller receives SIGSTOP. PID birth, ancestry, process-group and kernel-state observations prove that caller stays stopped and its distinct provider stays alive through the intervention, the contender attempt and the old request's eventual successful service response.
Native waits for real lease expiry (TTL 2 s, renewal 0.25 s). Early recovery, without a termination override, quarantines the exact dispatched operation. Its recorded identity/value footprint remains; the contender refuses without a mutation. After the late service effect and caller resumption, the old apply fails, its publication frontier and rows stay unchanged, and explicit recovery then records the object. Fresh plan/apply converges without repeating the mutation. Default provider termination on detected lease loss remains enabled; pausing the caller prevents its watchdog from running until it resumes.
Hosted deliberately aborts the exact saved-plan transaction while its local caller is stopped and provider alive. The server records aborted; the competing saved apply succeeds. Releasing the old request then overwrites the contender's value. The old CLI ultimately reports failure, but its late value also becomes visible in exported state while its transaction remains aborted. Final state and service agree, with version 3 for update or 2 for create; that agreement does not preserve the successful contender's edit. The checker retains these as valid adverse observations, not passes.
These are different control operations: native lease expiry plus early recovery versus explicit
hosted transaction abort, not a claim that Stategraph spontaneously drops an active lock or
promises abort will terminate a provider. E23's safe recovery after confirmed termination remains
valid. E24 demonstrates a stronger observed native unresolved-call exclusion property in the named
profile; it does not establish universal product superiority. SSM overwrite=true, AWS 6.66.0,
FakeCloud, one state and a local SIGSTOP fault bound the result. Further accepted-response delay/abort interleavings, replacement gaps, interrupted recovery,
database outages, cached/opaque and linked-state comparisons and the full I5 matrix remain.
All 146 checker tests and 577 observer/regression/CLI tests pass. Fourteen preliminary histories
retain six observation failures and eight valid observations. The native observer waits for one second
of HTTP quiet with the caller still stopped before resuming it; this prevents a native shutdown
race in socket attribution, and is explicitly not proof of complete provider RPC return.
Source 04c359fe…, exact hashes, raw histories and independent replay:
specs/graph-state/histories/conformance/2026-11-09-cli-live/. All commands are terminal, stopped
callers resumed and local accounts reset; the latest read-only inventory has 32
owned fixture states and no unrelated visible states, ready for UI/admin cleanup.
Replacement deletion/create interruption (E25). Two further matched schedules now interrupt an explicit-name SSM replacement after its old object has been deleted: either hold the successful DeleteParameter response before delivery, or deliver that response and hold the successor PutParameter before forwarding. Direct service reads prove that both old and new objects are absent at the gap. The observer kills only the actual apply's isolated process group, with PID birth, socket ancestry and caller/provider death witnesses. Both competing plans were saved before the fault; the contender attempts the same logical replacement after termination.
All six final full/affected/hosted histories pass: 941 events, 211 HTTP requests, 24 accepted mutations, and 3 additional successor requests that never reach the service. Each history contains two seed creates, one old-object delete and one final successor create. Every contender refuses without a mutation; final state and service agree, the old name is absent, and both the control and successor have version 1. This is observed parity for these specific interruption/recovery workflows, not an additional superiority result.
Native uses real lease expiry and retains the exact replacement operation and the old/new physical
identity, logical value and membership footprints. At response loss it remains delete_dispatched
with the old row; at the held successor request it is create_dispatched with a published deletion
tombstone. The latter is an HTTP boundary inside an already-dispatched provider RPC, not an
exact observation of delete_committed before create dispatch. Confirmed-termination recovery
commits the completed deletion or the create-with-no-object outcome. A fresh retained baseline and
ordinary plan/apply create the successor once, with no repeated delete.
Hosted 3.2.28 keeps the exact saved transaction committing and rejects the contender. Exported
state still shows the old row at both interruption points. Only after witnessed termination does
recovery abort that owned transaction. Fresh plan refreshes the missing old object and contains
only a successor create; apply converges without import or repeating the delete. No transaction
abort is treated as evidence that a provider stopped.
The independent checker validates complete accepted service history, the one deliberately unforwarded request, actual configuration and immutable plans, death-before-recovery order, physical key/namespace binding, tombstone/frontier transitions and final values/versions. Its 188 replay/damage controls pass, including an adverse synthetic repeated-successor write that still leaves state and service equal. Another 727 observer/regression/CLI tests pass, including six real process/socket controls. Ten preliminary captures are retained: nine replay under the final checker; one seed capture failed closed on missing unique socket attribution. Three of the nine originally failed the new checker's incorrect plain-JSON identity hash; the corrected checker uses the typed identity encoding. Original raw failures and the earlier checker/report remain archived. No production behavior changed.
Source fca0206d…, exact build and artifact hashes, replay report and cleanup records:
specs/graph-state/histories/conformance/2026-11-09-cli-replacement/. All commands are terminal,
old caller/provider processes are gone and local accounts reset. The read-only inventory contains
38 completed owned fixtures and no unrelated visible states.
This qualifies AWS 6.66.0 SSM, FakeCloud, one state and a same-logical-resource contender. It does
not independently qualify a different logical alias competing for either name during the gap,
create-before-destroy, generated names, arbitrary retries, interrupted recovery, database outages,
linked-state behavior or exactly-once effects. E21/E24 adverse outcomes remain unchanged; broader
I1 comparisons and the full I5 benchmark matrix remain open.
Native connection loss around COMMIT (E57). Four actual-provider captures now cross successful three-resource create publication with a socket cut before COMMIT forwarding or after PostgreSQL's COMMIT completion, under app X and admitted resource grants. A protocol-aware loopback proxy binds the cut to the actual transaction's server PID; the original caller receives a real asyncpg connection error. A separate connection observes either no publication and three returned operations, or the complete three-row publication with its history, operation receipts and one frontier advance. All writes and operation identities remain in the emergency journal in either uncertain outcome. Recovery ingests the returned outcomes once or recognizes existing committed receipts; no additional provider mutation occurs and all service versions remain 1.
Four additional engine cases check opaque provider data, conflicting admission after
release and repeated recovery. The 49-test PostgreSQL regression and 129-test unit/replay
selection pass, including 44 damaged-witness controls. The actual-provider fixture uses
an explicit collection barrier and full planning; no latency or natural grouping claim
follows. Source, raw histories, transport traces and independent replay are retained in
specs/graph-state/histories/conformance/2026-11-10-commit-disconnect/.
This qualifies one native connection-loss boundary, not server restart/failover,
sustained unavailability, interrupted recovery or hosted Stategraph database behavior.
Interrupted recovery publication and natural expiry (E58). Four further native SSM/FakeCloud schedules first retain an acknowledged create after its original publication loses the connection, then interrupt a recoverer's own COMMIT before forwarding or after server completion. Separate proxy connections bind both faults. Independent database-clock reads witness the first recoverer's natural lease expiry with renewal paused; no SQL rewrite expires the registration.
When the recovery publication rolled back, an exact physical-object grant remains
blocked and a successor advances both claim fences before publishing once. When it
committed without acknowledgment, that target grant is available and the successor
recognizes the existing receipt without replacing the claim. An unrelated target
grant succeeds in both cases. The expired first claim's actual write is refused,
and every history ends with one cloud mutation, one publication and service version 1.
The 28-test PostgreSQL and 219-test unit/replay selections pass, including 56 damaged
histories. Evidence is in
specs/graph-state/histories/conformance/2026-11-10-recovery-disconnect/.
These are full-planning, known-returned-create recovery schedules under app X/resource
grants. Unknown outcomes, process loss during probing, repeated outages, other
mutation types and hosted recovery still need separate qualification.
Sustained application database connectivity loss (E66). Two further native profiles cut the application's database route after an actual AWS SSM create returns and before its response can be stored. During at least 5.25 seconds of unavailability, the complete emergency journal retains the response, the five-second lease expires naturally, and direct database observations confirm an unpublished operation with retained target exclusion. An unrelated object can acquire ownership. After the original application's connection succeeds again, its expired owner's late write is refused; a separate explicit recoverer publishes the retained response once and repeated recovery skips it. Service/state versions and provider mutation count stay one. The direct observer/recoverer is a test client, not automatic failover.
The initial two-case checkpoint and subsequent 16-attempt repetition series both
pass independent replay. Sixty outage replay/corruption tests, thirty transport tests
and thirty-two cost-report tests pass. This extends the known-result connection-loss
profile, not server crash/failover, unknown outcomes, other mutations or Stategraph
behavior. Histories and costs are retained in
specs/graph-state/histories/conformance/2026-11-13-database-outage/ and
specs/graph-state/qualification/2026-11-13-i5-database-outage/.
The current actual-provider corpus covers all twelve primary schedules. The publication-wait
case uses a real SSM update and a PostgreSQL history-table lock: database-clock observations prove
publication was waiting before and after lease expiry, the final fence leaves row/history/frontier
unchanged, and explicit recovery commits the durable response without another mutation. Its raw
capture and offline report are in specs/graph-state/histories/conformance/2026-11-08-i1-publication-wait/.
The late-response and recovery-retry captures demonstrate stale-owner refusal and explicit recovery
without a second mutating call. Killable subprocess captures cover unknown-create and the
delete-committed replacement gap, including actual conflicting admission/adoption refusals after
the caller dies. These twelve captures do not by themselves close the initiative: supplementary
interleavings, broader per-type hold/ownership observations
and the complete per-case/type ledger still require the gates below. The explicit-name SSM adapter
now observes complete operation records and physical row ownership independently of lease/locator
code; negative controls reject conflicting admission after expiry, duplicate ownership and early
resolution of a still-running call. See the progress ledger for
exact builds, negative controls and evidence paths.
Affected-planning checkpoint (2026-11-09). The same twelve primary and two supplementary
SSM scenarios now run with both full and affected requested. Scope observations bind each
successful plan's ID and format to its actual execution cache and immutable admission at provider
send; refused planning and explicit fallback reasons remain separate. All affected-request plans in
the eleven executable scenarios must actually be affected, including a saved deletion plan refused
after a new dependent commits. Full bootstrap plans cannot satisfy that gate. Nine primary and two
supplementary scenarios exercise affected execution; duplicate identity is refused before execution,
and opaque/cached runtime plus deferred-provider work explicitly use full fallback. The latter two
are safe fallback evidence, not qualified affected runtime/deferred execution.
Killable workers publish an acknowledged plan observation before their send barrier, then expose the actual selected-cache/admission state. Both unknown-create and replacement-gap cases therefore retain a scope witness across process death and recovery. The independent effect oracle still uses wire payloads, authenticated service reads, publications and admission intervals; scope metadata does not compute expected effects or grant safety.
Immutable captures and their offline report are in
specs/graph-state/histories/conformance/2026-11-09-i1-planning-scope/. An earlier unchanged capture
under the sibling -initial/ directory is deliberately rejected by the strengthened scope gate:
its empty delete configuration lacked retained provider qualification and fell back to full while
the competing writer used affected planning. The corrected fixture retains an unchanged resource
on that provider. This closes a test-coverage gap without widening runtime eligibility. These
captures qualify the stated single-state AWS 6.66.0 SSM/FakeCloud profile and resource-grant policy;
the remaining I1 schedules and type coverage, and I5 cost gates remain open. Live
Stategraph evidence is qualified separately in E17–E22 above; these native captures do not
establish external behavior.
A versioned scenario specifies initial cloud objects and state, branch origins, desired edits, actors, barriers, faults and allowed outcomes. Evidence records logical event order, provider-call intervals, canonical object keys, value/revision witnesses, durable operation/transaction IDs, grant mode, final cloud/state assertions and recovery decisions. Redact values and credentials; retain hashes or fixture literals sufficient for reproducibility. Use provider-side barriers to force races; sleeps and matching final state alone do not establish that an overlap was tested.
| Case | Forced interleaving | Required assertion |
|---|---|---|
| Independent writers | Both actors hold permission before either mutates | Both changes survive; demonstrate real overlap, not two serialized successes |
| Read/write conflict | A consumes producer revision r; B changes that producer before A dispatches | A validates/replans or B is excluded; A cannot publish ready state falsely claiming the new revision |
| New dependent during delete | A observes no consumers; B introduces one before A's destructive call | Predicate validation or exclusion prevents a dangling dependent |
| Stale checkout | B deploys before A starts a new plan from an older branch | With A's original pin, preserve B's untouched intent; deliberate conflicting edits require resolution |
| Unknown create | Provider accepts the request; kill the caller before returning an identity | Conflicting creates/adoption stay blocked until termination and identity evidence suffice |
| Late response | Expire ownership, start recovery, then release the old response | Old ownership cannot publish; recovery cannot authorize overlapping effects |
| Replacement gap | Crash after delete commits and before successor dispatch | One durable operation retains address, identity and allocation/adoption coverage |
| Aliased object | Different addresses/aliases resolve to one physical object | No simultaneous incompatible mutation; equal names in distinct proven namespaces remain distinct |
| Opaque and cached reads | Warm a runtime/data/provider-settings cache, then change its source | The consumer retains its original proof or reevaluates; no unexplained managed read |
| Publication waits | Block SQL after the initial fence, then expire/remove part of the grant | All buffered state and receipts roll back at the final fence |
| Approval and deferred work | Expire approval after an earlier round committed | No late answer or larger deferred footprint restarts mutation; partial progress is reported |
| Recovery retry | Lose a recoverer after claiming an operation | A fresh valid claim can resolve it once; unrelated or older claims cannot write it |
Additional schedules within these cases. Exercise read/read, read/write and write/write pairs separately, including a shared unchanged producer: graph membership alone must not make both consumers writers. Race two admissions before either permission is visible and require at most one conflicting grant. For unknown-create and late-response cases, request abort or mark the run failed while its accepted provider call is paused, then attempt an incompatible grant. Run status, an elapsed reservation timeout or deletion of a derived cache must never erase the unresolved operation's hold. For stale checkout, retain both orders: the competing commit happens before the old checkout opens its plan, and after it opens. A transaction-start timestamp check alone does not establish branch-origin safety.
Branch-order checkpoint (2026-11-09). The SSM fixture now crosses both commit orders with
untouched and deliberately conflicting old-branch edits, under full and affected planning. For
the later competing commit, the old saved artifact is captured first and applied unchanged.
Untouched branches publish their independent edit while preserving the newer shared row's exact
revision and service value. Conflicting saved plans fail validation before another provider call;
fresh planning from the original pin requires explicit intent reconciliation. The earlier-commit
order produces the same preserve/conflict distinction directly during planning.
The independent branch_origin observation contract binds the original pin/sequence and fixture
value hashes to witnessed plan-open/commit/completion order. It checks durable row revisions,
direct service values, forbidden calls and explicit conflict refusal without importing the merge
implementation. It rejects partially executed conflicting plans and does not count an incomplete
prefix as a completed schedule. Eight native captures and their offline report are retained under
specs/graph-state/histories/conformance/2026-11-09-i1-branch-order/; witness mutations and scope/effect
replays are recorded in the progress ledger. This closes the stated scalar SSM branch-order gate,
not broader type/runtime behavior or external comparisons.
Assert the hold through the actual admission predicate after the run becomes terminal: merely checking that footprint rows still exist is insufficient. Distinguish failed work with a known, durably recorded partial result from failed work whose provider outcome remains unresolved. Both the normal admission path and recovery must preserve the latter's incompatible-operation exclusion. Inject a state-publication failure after a provider returns a partial result with diagnostics: retain the returned state and recovery evidence, and do not report its operation as durably committed until publication succeeds. A failed workflow is not evidence that its provider made no changes; terminal run status cannot substitute for the operation's durable outcome.
Failed-run implementation checkpoint (2026-11-09). The actual-provider cancellation
schedule exposed a backend defect: abort() accepted a dispatched operation while delivery of
its successful provider response was paused. The independent oracle rejected that real history;
the unchanged failing capture is retained under
specs/graph-state/histories/conformance/2026-11-09-i1-cancellation-initial/.
Memory and PostgreSQL now validate operation resolution before changing rows or the commit
counter. Neither abort nor commit(..., ops=...) can resolve an in-flight operation; dispatch
cannot reset it to a reservation or fabricate a response. A replacement whose delete committed
must retain that committed fact. Never-sent reservations can abort; read-only imports and local
moves can still publish their state without a mutating provider dispatch. PostgreSQL schema 32
adds a transition trigger independent of the writer-version check. Schema-31 clients using the
same protocol 19 cannot bypass it with their older direct-resolution path. The migration leaves
existing operation requests, outcomes, footprints and history intact; original late responses
remain recordable through the existing fenced return path.
Recovery of every dispatched call now persists record_recovery_probe before resolving it.
That fenced write rechecks termination after the provider read, validates the observation, and
stores a returned receipt with the original call stage. The receipt is distinct from an
original response. If publication then fails, a later claimant can ingest it without repeating
the probe; if the claim changes, the old recovery attempt cannot publish. Recovery still refuses
a live original caller, unknown observations and insufficient termination evidence.
Full/affected provider cases cover failed create/update runs with paused responses: refused abort, terminal run status, actual incompatible app-X/resource-X grant refusal, quarantined recovery, retained late response and eventual publication without another mutating call. Additional create/update/replacement cases attach an injected error diagnostic to the real provider response and fail the SQL transaction after its row write. They require retained returned state, no premature frontier advance, continued incompatible-grant exclusion and idempotent recovery. Recovered creates are tainted and updates unconverged. The diagnostic and database failure are injected; provider requests, returned object state and independent service reads are real. These gates qualify the recorded AWS 6.66.0 SSM/FakeCloud schedules, not arbitrary provider outcomes or live AWS. Wider per-type and supplementary schedules remain open.
If grant waiting later gains durable notifications, record a message sequence or generation at claim and recheck it when transitioning to sleep. Force enqueue-before-claim, enqueue-during-run, enqueue-during-sleep-transition and duplicate-delivery schedules; no accepted wakeup may be lost. Audit foreign-key locks as well as explicit locks when tuning queue contention. A weaker row-lock mode is permitted only after proving it preserves the queue's own admission and fencing invariants.
Lifetime checkpoint (2026-11-09). Eight additional actual-provider captures cross
create/update, full/affected requests and presence/absence of persisted-cache eviction. An accepted SSM response remains paused while the
test expires the original owner and ages the unresolved operation beyond a one-day retention
cutoff. Public pruning retains it. A separate PostgreSQL client, with no actor plan, execution
cache or local journal, refuses both app-X and entry-X grants. A fresh engine's positive
admission timeout cancels its waiting ticket without resolving the original operation. Recovery
still quarantines the live caller; later response delivery cannot publish through expired
ownership, and journal recovery publishes without another mutation. Cache cases first populate
the observations table through real provider data-source reads, then fault-inject deletion of
that derived row while the mutation is paused. They retain exclusion and recovery. All eight
native and offline checks pass; sixteen altered histories with removed holds or conflicting
grants are rejected. Raw evidence and limits are in
specs/graph-state/histories/conformance/2026-11-09-i1-lifetime-cache/. The affected no-cache
cases execute affected plans; the cache cases explicitly fall back to full.
The current protocol has no separate reservation-expiry timer: lease expiry, admission wait
timeouts, provider deadlines and retention are different events. None proves a dispatched
provider call terminated. The observations table is a derived data-source cache; it is not an
operation journal. The eviction schedule covers this concrete cache with an external observation;
it does not introduce an automatic cache garbage collector or establish broader affected
data-source eligibility. Fresh-client admission and killed-caller tests establish independence
from process-local caches. Requests, outcomes, admitted-plan proofs and recovery
journals must not be reclassified as disposable caches to satisfy this gate.
Conflict explanations. Add a structured diagnostic projection of admission refusals and waits: the requested key namespace and mode, blocking holder/run or operation, incompatible mode, expected versus observed revision or predicate generation, and the plan reason that introduced the demand. Distinguish contention, stale evidence, changed intent and unresolved operations; these require waiting, replanning, explicit reconciliation and recovery respectively. Mask object keys and values using the existing sensitive-data rules. An optional preflight explanation is advisory and takes no grant; only the atomic admission check authorizes execution. Tests require the report to explain an actual blocker without changing fairness or permitting a bypass.
Diagnostic implementation checkpoint (2026-11-09). backends/graph_diagnostics.py
defines masked conflict/report projections. Memory and PostgreSQL implement
explain_lease_request over an existing queued request; PostgreSQL uses one read-only
repeatable-read transaction and the same effective legacy-operation footprint as admission.
It never expires a run, moves a ticket or takes a grant. Reports identify granted holders,
older waiters and unresolved operations (including their current recoverer), incompatible
namespace/modes and the reviewed demand's reason. At most 100 conflicting keys are returned,
with an explicit omitted count. Identity/allocation and arbitrary auxiliary/extension key
contents use the existing sensitive-value marker; payloads and private state are not exposed.
The engine reads this advisory report on first wait and timeout. Failure to read diagnostics
cannot change the refused grant. GraphPlanBasis.problems remains the authoritative validation
predicate; failed admission projects row/input/reverse-predicate observations from the same
snapshot into structured expected/observed evidence. Full-state preparation reports its captured
and current frontier. Three-way intent conflicts carry branch/baseline/deployed fingerprints.
These use distinct stale_evidence/replan, changed_intent/reconcile,
contention/wait and unresolved_operation/recover categories/actions.
Direct exceptions carry context["graph_conflicts"]; public app/stack apply preserves it as
ExecutionResult.graph_conflicts and in result serialization. Existing retry and saved-plan
rules are unchanged. Backend and provider tests require actual blocker/proof agreement,
read-only behavior, preserved fairness, masking and refusal despite diagnostic failure.
The detailed evidence and remaining per-type/schedule gates are recorded in the progress ledger.
Delivery slices. First extract the existing native cases into the common result format without changing their assertions. Then add missing schedules and adapter-independent cloud witnesses. Finally run the same applicable scenarios through an external adapter. Do not replace real SQL lock waits or native gateway tests with a mock solely to obtain a common interface.
Release gate. Every case has both a successful/refused outcome assertion and a witness that its
critical interleaving occurred. A deliberately broken fence, missing input proof or released
quarantine must make the corresponding oracle fail. Publish per-case pass/fail/not-run/unsupported,
reproduction commands, versions and evidence paths. Unsupported semantics are capability gaps,
not successful safety tests. Liveness tests name their assumptions: bounded pauses, eventual
database availability and supplied termination evidence. No automatic quarantine timeout is added.
The case/type index in specs/graph-state/histories/conformance/README.md separates the 56 recorded
SSM scope/scenario slots, superseded captures, native diagnostic assertions and sixteen
verified log-group/secret cases. The lifetime corpus adds explicit expiry, admission timeout,
retention and persisted-cache eviction schedules; ended-run cancellation alone was insufficient.
Scope/type qualifications and conditional future notification-queue gates remain explicit.
After built-in expression qualification, 2026-11-09-i1-derived/ recaptures all existing SSM
schedules and adds shared-read and stale-input cases using indexed ASCII prefix/uppercase values.
The complete native suite passes 60 tests: 56 positive scope/scenario slots and four deliberately
corrupted direct/derived wire requests. All positive observations replay independently, and 221
checker tests pass, including sixteen new value/proof corruptions. Both derived affected requests
execute affected plans. The observer computes its bounded value algebra independently of the
production evaluator and binds it to the original producer revision; arbitrary callbacks and
Unicode equivalence remain outside that observation contract. This satisfies the I1 regression
checkpoint for that eligibility change, without establishing a comparative Stategraph guarantee.
After the I2 index-integrity/startup changes, 2026-11-09-i1-index-integrity/ independently
rechecks all 56 slots on source 58db3bf0…, with 136 provider calls, 206 publications, ten overlap
witnesses and zero unresolved calls. Its 60 native cases are included in the passing 517-test
PostgreSQL regression. This supersedes overlapping earlier captures for that source; Stategraph's
28 scenario labels remain intentionally not-run.
Current-source regression checkpoint (E107, 2026-11-13). After the planning,
batching and retention changes through E106, all 60 native SSM cases pass again:
56 positive scope/scenario slots and four deliberate direct/derived wire
corruptions. The frozen offline checker verifies every positive capture and
rejects 152 altered current histories covering incomplete schedules, missing
interleaving witnesses, false input values/proofs, expired publications and
admissions that bypass unresolved holds. The two portable checker suites pass
151 tests. Requested affected classification remains twenty-three executions,
four explicit full fallbacks and one pre-execution refusal. Observations contain
136 provider calls, 140 publications, twelve overlap witnesses and zero unresolved
calls; these include bootstrap work and are not timing samples or a matched
performance comparison. Source, context, commands, raw captures, JUnit and an
implementation-independent replay are retained under
specs/graph-state/histories/conformance/2026-11-13-i1-current-source/.
No production behavior or eligibility changes in this checkpoint. Other native
type/fault corpora and hosted comparisons retain their separate source-qualified
evidence; wider I1–I5 gates remain open.
I2 — Scoped Planning Without Losing Evidence
Implementation checkpoint (2026-11-08). The first read-interface slice exists in
backends/graph_planning.py: complete resource/output summaries, symbolic manifest types and an
explicit partial payload view. Memory holds its lock across the read; PostgreSQL reads summaries,
the retained origin, topology and selected payloads in one repeatable-read transaction. Expansion
must match a capture bound to backend/state/lineage, frontier, summaries, origin, unresolved
operations and edge generations. This view cannot be passed as a State or GraphSnapshot.
The payload query is selective; summary and topology materialization remain O(N + E).
execution/graph_intent_manifest.py collects the complete app, including empty stacks, outputs,
provider source/version/settings, observations, variables, imports, moves and semantic settings.
It uses the full planner's resource intent fingerprints and records provider configuration
separately; it never loads state, configures providers or evaluates runtime/check bodies. Known
empty reads remain distinct from purity. Runtime qualification is a separate, versioned provider
contract; symbolic provider settings alone cannot establish it.
backends/graph_planning_selection.py adds a pure shadow selector. It merges intent before
selection, traverses old and proposed adjacency once per entry/role, preserves newer consumers,
promotes changed boundary reads, and reports budget/evidence fallbacks. Its concrete fixtures do
not qualify production provider settings: a declared provider fingerprint still explicitly causes
full fallback without fresh runtime qualification matching the retained context.
Selection now requires matching per-entry static context and the exact reviewed row revision;
missing, changed or stale context seeds reevaluation. Fresh provider runtime qualifications can
be supplied separately, but must match the complete current symbolic manifest.
Schema 31 and backends/graph_planning_context.py add optional context to resource/output rows,
their history and complete planning summaries. Publication binds it to the exact row revision and
intent; an older writer that leaves the column untouched advances the revision and invalidates its
eligibility. Writes without context clear it. No-op persistence compares the reviewed context
without manufacturing a revision on every identical review. Nodes, saved full plans, operation
requests, returned-response recovery and the result-write path carry explicit context; context
changes join write coverage and propagate to consumers. Memory and PostgreSQL tests cover these
paths, including schema-30 upgrade and older-writer behavior. The normal full planner now produces
static context before evaluation and carries it through reviewed full plans. Pure output shape can
qualify; resource providers need the runtime policy described below.
Unknown app evaluation effects invalidate neighboring rows' qualification too, so removing opaque
work later cannot silently bless its earlier results. Preserved/untouched nodes retain their stored
context and carry no new context in the saved execution plan. Saved intent/context mismatches fail
before execution.
providers/graph_planning.py now defines optional nf.graph_planning profiles, separate from
identity contracts. Qualification binds the exact running release, immutable launched environment,
normalized successful Configure payload, installed policy and authenticated namespace. Failed or
changed Configure observations clear eligibility. Whole-round validation precedes resource
execution, with further checks before no-op publication and operation reservation. The initial
AWS profile covers only SSM on 6.66.0, explicit static credentials/region, disabled tag policy
and explicit /dev/null shared-file inputs; write-only/ephemeral settings and unreviewed runtime
sources remain unqualified. specs/graph-state/qualification/aws-ssm-planning.md records the source
audit, test boundary and eligibility conditions. Complete environment hashing is deliberately conservative and may invalidate
evidence for unrelated environment changes.
Actual AWS/PostgreSQL/FakeCloud tests feed fresh qualified contexts into shadow selection for unchanged graphs, consumer/producer changes, removal and environment changes. They compare selected addresses with managed provider actions, complete admission writes, original read revisions, reverse-edge generations and actual published row/input/context changes, then verify service values. Fresh qualification remains available after an untouched no-op is stripped from execution; the selector never substitutes stored qualification for the current provider observation. Negative controls omit a boundary read or a required consumer publication and must fail these checks. These are concrete shadow coverage checks, not affected-executor equivalence. The removal fixture exposed and fixed a full-planner race: deleted consumers now precede retained producers' publication, including refreshed metadata writes, using the final coverage closure and stored dependency/input edges. Exact reservation checks remain unchanged.
The first SSM refresh can normalize tags from null to an empty map without a provider mutation.
Stable-cloud comparisons therefore identify whether the baseline was already refreshed. Separate
fixtures replay normalization and drift from a boundary read: both promote that producer and its
other consumers, including consumers whose only work is recording a new input revision. An
unrelated normalization/drift observation belongs to full refresh's wider inspection scope and is
reported explicitly; it cannot be passed off as affected-mode equivalence. These tests use recorded
results from one full evaluation; they do not yet implement selective refresh or its restart loop.
Eighteen immutable shadow captures now live under
specs/graph-state/qualification/2026-11-08-i2-shadow/. A plain-data checker verifies actions,
metadata publications, original/published input revisions, context binding and hashed service
observations independently of production coverage helpers. A separate replay reconstructs the
original summary/origin/topology and fresh runtime qualifications, requires the same capture and
reruns selection without provider work. The corpus and negative controls cover closed concrete
SSM graphs; outputs, preserved rows, opaque observations and deferred rounds remain open gates.
Full graph artifacts now retain the complete branch manifest inline as nf-graph-intent-manifest
version 1, under summary.graph_state.intent_manifest. Its canonical digest covers managed
addresses/intents, symbolic references, empty stacks, provider and other non-row context, semantic
settings and stability classifications, without retaining configuration values. Decoding rejects
unknown formats, missing fields and inconsistent digests. Plan creation and saved execution also
check the manifest against executable nodes: desired membership cannot disappear from an executed
stack, undeclared managed work cannot appear, and node intent/static context must agree. A full app
artifact retains the complete stack set; a stack plan still retains the whole manifest while
executing only its stack. Preserved newer rows and their unresolved drift placeholders remain
distinct from this branch's executable intent.
The inline copy has the artifact's lifetime and is never reconstructed from newer state. Existing baseline pins remain independently required: a missing baseline rejects apply even when the inline manifest is intact. This implements the RFC's inline-evidence option, so there is no new external manifest reference for cleanup to expire. Existing full artifact format 17 stays compatible when the optional manifest is absent; the manifest has its own versioned schema. Future affected/partial artifacts must use a new required format and may not silently drop this evidence. The complete inline manifest costs O(N) space and does not yet reduce the full artifact's resource payloads.
backends/graph_planning_rounds.py now implements a bounded pre-approval closure controller.
It reads the selected payload union at the original capture, refreshes each live managed key once
per capture, promotes changed/absent boundary observations before evaluation, and incorporates
new exact observed reads into the old/new adjacency. Evaluators report complete input sets or
explicit missing reads; known empty, unknown and not loaded remain distinct. Newly needed rows
cause another consistent read/evaluation wave. The guarded read interface requires a selected
current configuration owner and records its reads independently of the evaluator's report. A
complete report that omits a consumed row falls back to full planning. Catching an unloaded-read
exception cannot suppress expansion; catching an unclassified-read exception cannot suppress full
fallback. Malformed/noncanonical addresses and kind/address mismatches cannot certify absence,
whether supplied through a lookup, a reported input or a requested expansion. These guards apply
to the callback interface; the callbacks remain trusted internal planners, not a security sandbox.
A final capture check and fresh runtime-qualification sweep also protect a round with
no expansion. Changed runtime qualification discards the candidate even if the database capture
is unchanged. A changed view discards refreshed values, observed edges, inputs and the candidate
payload, then obtains fresh runtime qualification before restarting. Budgets and unknown evidence
return explicit full fallback with no executable payload; database failures are not cached absence.
Complete summaries/topology remain O(N + E). The initial controller reread the payload union on
expansion and final validation; the cache checkpoint below removes those repeated payload loads.
Memory cases cover late reads across multiple waves, changed boundaries, concurrent publication, negative-lookup invalidation, output/collection shape, instance identity, removed constructs, preserved newer consumers, omitted read evidence, swallowed exceptions and full fallback. In the initial controller, at N=100/1,000/10,000, a fixed one-consumer change refreshed two resources and materialized four payload rows across the load/final-check reads; the complete metadata view still contained N entries. Twelve PostgreSQL/AWS/FakeCloud cases use actual selective ReadResource calls, including first-refresh normalization, unrelated drift, deletion and a publication during an in-flight read. Six retain a concrete projection callback; six use the actual configuration evaluator and PlanResourceChange, with full-state loading and provider apply calls refused during the closure loop. Those controller captures use full hybrid bootstrap; the public routing slice below supplies separate frontend evidence.
Payload-cache checkpoint (2026-11-09). close_graph_plan now fetches only missing
original payloads as its selected closure grows. GraphPlanningView.with_cached_payloads
combines disjoint batches only under the identical complete capture: backend/state/lineage,
frontier, summaries, retained baseline/origin, topology/generations, unresolved operations and
cleanup inventory must agree. A matching row revision alone is insufficient. Rows remain keyed
by their complete instance address. Detached private originals are shared between these views;
public reads return detached copies. Provider observations and proposed values stay in their
separate round contexts, and each consumer retains its own input evidence.
Every expansion still validates the complete capture. Final validation performs a metadata-only read and fresh runtime qualification even when no new payload is needed. A changed capture discards payloads, refreshes and evaluation before restarting; a released baseline or failed read cannot become a cache hit or confirmed absence. The cache lives only inside one closure attempt, creates no persisted evidence and grants no mutation permission.
The PostgreSQL archive specs/graph-state/qualification/2026-11-09-i2-payload-cache/ records
two consumers sharing a 1 MiB source across three expansion waves. A stable attempt decodes each
of five selected rows once, never the unrelated 2 MiB row; its fifth/final view reads no payload.
A source commit before final validation forces one restart and ten decodes across two captures,
with the updated source value and separate consumer proofs. These are actual selected SQL/decode
observations with simulated refresh/evaluation callbacks, not provider-wire or latency results.
Shared memory/PostgreSQL contracts also reject foreign states, changed evidence and overlapping
batches; controller tests cover distinct instances, original versus refreshed values, repeated
misses, insertion after a miss, failed expansion and baseline release. The fixed-change tests at
N=100/1,000/10,000 now materialize two rows, with three complete metadata reads. O(N + E)
metadata work, per-consumer copies and wider I5 cost measurements remain separate. Previously
archived benchmarks retain their original source hashes and counters; this change does not
retroactively improve those measurements.
Built-in expression checkpoint (2026-11-09). The manifest classifier now recognizes
explicit built-in operator, index, method and transform nodes with recursively qualified operands
and a supported Terraform operation. This covers concatenation/arithmetic/comparison, supported
collection indexes/slices and the operation registry's deterministic methods/transforms. It checks
operator callable identity as well as the symbol, and accepts exact built-in node classes.
Arbitrary callbacks, subclasses, unsupported or ambiguous operations, and runtime/check bodies
remain unqualified. No evaluation, rendering or provider read occurs during classification.
Declared operand types can change operation semantics without changing ordinary reference intent.
The collector therefore retains per-entry expression context with a versioned
nf-builtin-expression-v1 fingerprint of the hole positions, reference kinds, collection element
kinds and selected operation shapes. GraphIntentManifest.planning_contexts folds this evidence
into that entry's symbolic fingerprint; global settings remain separate. Provider expressions
bind their evidence into the provider fingerprint. A type change invalidates the affected row's
qualification even when its ordinary intent matches. Saved plans retain this context inline;
removing or changing it fails node-context validation even with recomputed outer digests.
specs/graph-state/qualification/2026-11-09-i2-derived/ records six full/affected pairs for chain,
fork and diamond under both grant policies. Actual AWS 6.66.0 planning observations are recorded
once and replayed, with complete-state access refused during affected planning. Saved affected
apply and independent service/state/output checks pass. Concatenation, a one-element indexed
collection, upper and len retain direct and carried ancestor inputs, original planned-read
revisions and final producer revisions. The independent checker reconstructs values and ancestor
sets; fifteen negative controls reject mutually consistent corruption of both plans or claimed
expected values. The complete native suite passes 38 cases, and 515 core/artifact checks pass.
The earlier diamond benchmark fallback remains an accurate historical result for its older build;
this qualification does not establish new latency results or qualify arbitrary Python effects.
execution/graph_planning_values.py now supplies the distinct partial evaluation context.
PlanningValues uses an explicit resource-read interface; its full-state accessor delegates to
the reader and a partial reader refuses it. Existing expression resolution, including explicit
cross-stack references, goes through the guarded reader. Every round owns a fresh authoritative
recorder and planned-value/output caches. Node scopes retain consumer-specific provenance across
context-propagating workers; a thread that loses its context, an unfinished/duplicate node or an
unattributed cache read cannot certify completion. Only the current selected body can record its
own planned value through the cache interface. Carried reads are checked too: they cannot bypass
the immediate reader's rejection of unclassified identities or unqualified observations.
Original revisions are decoded by the same
recorded_node_inputs function as full graph planning. Carried cache reads retain their captured
revision rather than being relabelled with the new view's revision. Broad membership, opaque
runtime scopes and non-managed observations currently request full fallback at this seam.
Full and partial evaluation share _build_resource_configuration, including normal metadata and
identity binding. _plan_resource_change now accepts a single change and no whole-state arguments;
its old state arguments were unused. The real-provider fixture uses these methods in its known
topological order. This proves the evaluation/provider seam, not general scheduling, lifecycle or
deferred-round integration. Normal hybrid planning still uses its existing complete-state path.
Regression testing also found that a frozen data-source proof must retain a planned input when a reviewed metadata-only source publication advances its row revision. After the final coverage closure, those exact reads are marked planned in the frozen observation as well as the consumer node. The read must still name this view's original revision; stale cache proofs are rejected. Sources with planned provider mutations are excluded from this metadata transition. This prevents live saved-plan evaluation from overwriting its planned seed with an older cached revision. Four PostgreSQL/AWS/FakeCloud cases verify this with live constructs and saved-plan-only execution, under both app and resource grants: the source's cloud version stays unchanged, its state revision advances, the cached data source is not reread, and the consumer publishes the new source revision.
Registration is now lazy: GraphStateEngine.register() opens renewable ownership without a
mutation grant, resource payloads or a rollback copy. Reusing an engine clears prior cached rows,
proofs, operation lists and rollback originals. Full-state reads and quarantine inspection still
load an ordinary snapshot explicitly. App/plan admission captures a fresh complete pre-apply basis
after granting and validating its capability; unrelated commits made during planning remain in
that basis. Recovery registration retains its existing full read and explicit operation claims.
_load_providers(planning_view=...) now discovers state-only providers from requested live
resource rows, including removals. It validates the complete metadata capture against the backend
before startup, so foreign lineage, stale evidence or migration cannot start clients from that view.
This validation loads summaries, not all payloads. Declared static provider settings are configured
in full. Runtime holes or declared provider reads request full fallback before any client starts;
this path does not qualify their dependencies. Undeclared aliases retain the existing error rules
for selected rows. The eventual coverage builder must carry these provider-discovery row proofs;
selecting or reading them does not itself grant mutation rights.
_refresh_graph_rows uses the same provider upgrade/read/diagnostic logic as full refresh, but
accepts exact selected rows and operation summaries from the captured view. It returns distinct
present, absent and unknown observations, preserving original proofs in the view. A held operation
or deferred provider prevents a read; timeout/failure never becomes absence. Its internal refresh
batch cannot enter diff/deletion or the engine cache. Capture validation and restart remain the
closure controller's responsibility. A PostgreSQL/AWS/FakeCloud test now starts the real provider
and refreshes only a selected removed resource under unleased registration with both full-state
entry points forbidden. The existing twelve closure cases use this same refresh method.
The ordinary coverage builder now accepts GraphPlanningView plus explicit desired resource rows.
Its internal reader obtains original payloads and exact RowVersion objects from that view once
per key; it never assembles a partial GraphSnapshot or derives write proofs from summaries.
Requested rows inspected for provider discovery retain ordinary shared row expectations unless
they are writes. Existing mutation, identity/allocation, rollback, input and reverse-edge coverage
uses the same builder as full planning. Refreshed metadata can add a write and propagate it to
consumers. Desired-row omission never creates a deletion; the caller must provide explicit removals
from the complete intent merge. Carried exact input revisions, including planned reads, must match
the captured originals rather than being relabelled. Unloaded originals request expansion/fallback.
Partial views also carry a complete cleanup-key inventory: observation addresses and the presence of legacy output metadata, without their payloads. Memory and PostgreSQL capture it with the same view as the managed rows. Unknown older inventory, relevant cached-observation cleanup, legacy output cleanup and broad scope/enumeration proofs currently require full planning. Those cases cannot silently become empty auxiliary coverage. Older immutable shadow captures remain replayable without this optional field, but cannot supply partial coverage's cleanup evidence. PostgreSQL tests admit the partial basis through the ordinary grant path, allow an unrelated commit, and reject a changed input or a new dependent before destructive work. Those initial admission tests reload a full pre-apply snapshot; the selected execution and public routing slices below close that boundary.
Fresh runtime qualification now has a separate symbolic entry point,
qualify_graph_intent_manifest. It uses the configured clients and the same resource metadata,
schema and authenticated ownership-scope rules as ordinary planning. Each expression hole is
replaced with UNKNOWN; the sweep neither evaluates resource bodies nor substitutes stored values.
It does not call managed-resource Read/Plan/Apply RPCs or load state payloads. Namespace discovery
may call the provider's identity data source. Namespace facts are observed again on every sweep
and shared only within that provider configuration during the sweep.
An unknown namespace, excluded argument or write-only argument cannot qualify omission. Missing runtime observations, unsupported releases and changed contracts also remain unqualified. The complete manifest is checked before and after the sweep; a changed configuration or configured runtime aborts mixed evidence. The controller compares a final fresh sweep with its initial qualification, discarding and restarting the candidate if they differ. Repeated changes exhaust the bounded restart budget and return full fallback without a candidate payload.
All twelve PostgreSQL/AWS/FakeCloud closure cases now obtain qualification this way, with full-plan construction and both full-state read entry points forbidden throughout partial planning. Their already-deployed baseline still comes from ordinary apply, and the changed-view fixture's separate writer uses ordinary admission. The six configuration cases now use the production scheduler and candidate assembly described below; the later public-routing tests separately exercise the frontend. The complete symbolic qualification pass remains O(N), in addition to complete summary/topology reads. The older immutable shadow captures retain their original full-planning provenance and are not evidence for this newer path.
evaluate_graph_plan_round now assembles a GraphPlanningCandidate through the existing
_plan_in_dependency_order walk and ParallelStrategy. Selected resources are configured once at
their dependency position, so consumers see planned upstream values and independent provider plans
can overlap. The walk and change-recording code accept explicit resource mappings as well as full
State inputs. Partial evaluation uses its original view for convergence and completed replacement
trigger checks; it never installs selected rows in the engine's complete-state cache or reads that
cache to discover metadata revisions. Ordinary full planning retains its existing path.
The candidate retains normal execution nodes, provider private data, selected desired entries,
output changes, original consumed revisions and ordinary GraphPlanCoverage. No-op producers
supply refreshed values. Static lifecycle replacement, taint, ignore-change provider planning and
prevent-destroy rules use the shared implementation; unqualified dynamic lifecycle metadata falls
back before provider planning. Cycles and failed prerequisites cannot produce a completed candidate.
Output shape, unknown values and sensitivity survive assembly. Complete selection alone authorizes
explicit removal candidates; an unloaded or omitted payload cannot become a deletion. Already-gone
removals retain explicit forgetting evidence. The deleted-object policy and affected inspection list
remain available for frontend approval/reporting.
Old topology orders resource and output deletions before their producers' publications, including metadata-only writes. Coverage closes metadata writes and marks their consumers' planned input transitions. Preserved newer bodies never run old branch code; unresolved drift/status in such a selected resource requests full fallback. Duplicate physical owners among selected desired rows are rejected. The six actual configuration/provider cases now admit their assembled coverage through the ordinary PostgreSQL resource-grant path, with no provider mutation. Post-admission rollback capture still reads full state. The compact carrier and retained-evidence review described below now provide kept/stale reporting and approval summaries. Frontend routing and saved partial apply must still connect those pieces before exposing affected mode.
Partial candidates now also check physical ownership outside their selected payloads. Each resource
write retains an ObjectCheck derived by the existing operation identity/lease rules from the original
row and planned template. This includes explicit forgetting and metadata writes. Replacement checks
use replacement semantics, retaining namespace exclusion when the provider allocates an unknown new
identity. Output-only candidates need no resource ownership checks.
check_planning_ownership(view, checks) requires the exact complete capture and performs the owner
lookup in the same consistent snapshot. PostgreSQL batches address, canonical-identity, legacy-type
and bound-type index lookups into one query and projects only owner/source metadata, without decoding
unselected entry/private payloads. The memory backend uses its row metadata under the same lock as
capture validation. Same-object aliases are refused regardless of logical address. Unknown legacy
ownership of the same provider/type blocks a bound request; an unbound request cannot bypass existing
bound ownership. Own-address legacy normalization remains possible. Different canonical namespaces,
provider sources, types and tombstones are distinguished. A bound owner without a known canonical
identity is treated as uncertain ownership, not evidence of absence.
The checks remain in GraphPlanBasis, join its required leases, and are re-evaluated at ordinary
admission. PostgreSQL queries owner metadata separately from the exact selected-row proof, so an
owner inserted between planning and admission cannot disappear outside that proof. Resource admission
releases its grant on failure before approval/mutation. App-X validation also checks the predicate.
After resource admission, retained canonical/namespace leases exclude conflicting alias grants.
These predicates supplement the existing reserve/dispatch/commit guards; they do not authorize calls.
The controller's final capture check still detects a commit that followed the preflight snapshot.
Partial candidate coverage uses identity-evidence envelope version 3, requiring exactly one retained ownership check for every resource write. Missing, duplicate, malformed or downgraded retained checks are rejected. Ordinary full-planner coverage remains version 2. Readers unaware of version 3 reject that envelope; this is not a new compact saved-artifact format or evidence that older backend plugins can perform the new preflight. Unsupported backends still require full planning. Complete summaries, topology and symbolic qualification remain O(N+E); indexed owner lookup is not a claim of wholly O(k) planning. SQL execution-plan tests establish index eligibility, not end-to-end speed.
Frontend integration contract. The public routing slice below connects lazy registration,
selected provider startup/refresh, the closure controller and the production scheduler. It retains
complete summaries and original selected row proofs without putting a partial State into the
engine's complete-state cache. Whole-state diff/deletion and HybridPlanArtifact continue to require
complete payloads; qualified partial work uses GraphPlanArtifact and GraphExecutionRows instead.
Provider setup retains complete declared scopes and fresh runtime qualification, including the controller's final sweep. Captured-view revisions supply setup/refresh provenance; the final candidate retains its authoritative evaluation recorder. Ordinary basis/coverage construction retains row, input, identity, reverse and indexed omitted-owner predicates. Selection adds no mutation authority. Complete three-way manifest evidence controls removal and preserved newer intent; omitted payloads never mean deletion.
Explicit unsupported work falls back before approval, discarding selected values and proofs and restarting provider configuration. Invalid proofs, conflicts and unexpected provider errors remain errors. After approval, discovery outside the fixed admission stops execution. Deferred/opaque or otherwise unqualified work uses full planning. Broader provider/check/runtime qualification, the full shadow matrix, measured costs and I1/I5 affected-mode gates remain required below.
Target. Reduce resource payload loading, provider refresh and configuration evaluation for a small change in a large app. Full Python app construction and an initial complete intent/address manifest remain required in the first version. That manifest and baseline verification can remain O(N); do not advertise total O(change-size) planning while they do. The existing concrete proof reader is a validation optimization, not an incremental planner.
Implemented interface, subject to the qualification gates below. App graph_plan_scope="full" | "affected", project
[tool.nf.config].graph_plan_scope and --graph-plan-scope on nf plan, nf apply and
nf deploy. Default to full, with the usual flag > project > app > default precedence. Initial affected mode requires graph state and a valid retained
baseline; an explicit request without either is rejected. It can still take app X if resource
grants are unavailable: planning scope does not select locking policy. An affected plan reports
selected addresses, refreshed addresses, dependencies read from state, exclusions, reasons for
expansion/fallback and its consistency/coverage evidence. This is a planning policy, not permission
to apply an arbitrary --target subset or silently omit deletions.
Drift contract. Full mode retains app-wide refresh behavior. Affected mode refreshes the
managed resources in its dependency closure, including resource values used as boundary inputs;
it does not claim to discover unrelated external drift or refresh-normalize unrelated stored
observations. Provider normalization can change stored metadata even in a stable cloud; compare
the inspected closure and report those outside observations separately. drift_correction still
governs what to do with discovered drift. The plan and result explicitly state the narrower inspection scope.
An explicitly requested full drift inspection forces full mode. Rollout must never change the
default by treating an unrefreshed resource as verified unchanged.
Type contract (selected reads, execution and qualified public routing implemented):
GraphIntentManifest: complete desired resource/output addresses, symbolic intent fingerprints, declared references, provider/check/runtime scopes and a configuration digest. Construct removal is detected against this complete manifest and the baseline/current intent summaries, never against a partially loaded state. Persist any new manifest/index under a versioned schema.GraphPlanningSelection: change roots, evaluation closure, boundary reads, guarded predicates, reasons, observed reverse-predicate generations, and policy/capture version. Record each role independently: a boundary read may later need evaluation, and a selected entry may plan no write. Include this evidence in saved plans.GraphPlanningView: a consistent, explicitly partial view with lineage/frontier and a complete address/tombstone summary. It distinguishes not loaded, known absent, tombstone and loaded. Access outside its coverage requests expansion; it never returns absence by default.GraphExecutionRows: a fixed set of admitted resource/output payloads, including explicit absence and tombstones, with a separate copy for rollback. It cannot be used as a completeState. Point reads outside this set refuse execution; expansion requires replanning and a fresh admission before mutation. Complete status metadata can report omitted stale entries without loading their payloads or adding write permission.
Keep full GraphSnapshot semantics unchanged. Add a planning-view read at the GraphStateBackend
seam, implemented in memory and PostgreSQL, and route graph planning through it in
hybrid_graph_state.py and the planning/evaluation path. Do not pass a filtered State into
whole-state diff/deletion code. Reuse GraphPlanBasis, GraphPlanCoverage and the ordinary
admission path; a selection is not a second source of mutation authority.
Selection roles. Change roots explain why work starts; the evaluation closure identifies what must be refreshed/evaluated; boundary reads supply original values and revision proofs; guarded predicates cover membership, absence and reverse consumers. Derive mutation demands from actual planned writes and possible deferred actions, including refresh publication and stale marks, not from selection membership. Two consumers of an unchanged producer should retain compatible shared reads when no other demand conflicts. A changed boundary observation expands evaluation and any affected consumers before approval; it cannot remain a supposedly stable cached input.
Selection granularity is part of each node kind's contract. Resource-instance selection cannot implicitly trim provider configuration, shared runtime checks or other control inputs to the fields mentioned by one consumer. Evaluate their complete declared scope unless a narrower contract is proven; preserve their own provenance and deferred-configuration behavior.
Positive evidence for pruning. An exclusion decision records proven_unchanged, changed or
unknown, its input proofs, observed view/evaluation epoch and reason. Only proven_unchanged
permits pruning; missing certainty, missing prior/fresh observations or unsupported value shapes
produce unknown and retain the affected consumers. An explicitly known empty read set remains
different from missing evidence. Apply these rules to both direct reads and values reached through
derived expressions. Never substitute the committed observation for a missing fresh result and then
treat their equality as evidence that the current observation is unchanged.
Sensitive display values and redaction placeholders cannot prove equality of underlying values. Use existing authorized internal value/proof handling where it establishes equality without exposing secrets; otherwise widen with a recorded reason. Masking happens at the reporting boundary, not by replacing a value used to certify pruning. A node excluded from evaluation still contributes the input and predicate proofs required by the plan's admission contract.
Apply the same rule to read identities: an identity that cannot be decoded or classified must widen selection with a recorded reason. Do not turn an unsupported file/reference encoding into a negative set-membership result and use it to prune a consumer. Value-path projection needs the same distinction: a proven absent member is different from an invalid selector, incompatible container type or unavailable parent value. Two failed projections cannot certify equality. Any supported path-level comparison retains the container/access and membership proofs needed by that consumer; otherwise compare the complete supported value or widen.
Cached values and required execution. Replacing evaluation with a cached value requires separate proofs of value equivalence, preserved type/instance shape and absence of required effects. A one-element collection is still a collection: retain its keys/indexes, instance context, unknownness and sensitivity rather than substituting one member's attributes for the entire collection. Equal output values do not prove that execution's files, credentials, ephemeral handles or other artifacts exist in the current environment. For example, a cached archive path/checksum cannot replace the step that creates that archive. Keep effectful or unclassified work in evaluation and apply; any supported reuse of an artifact needs its own availability/lifetime proof and invalidation rules. Preserve full-mode provider/data-source semantics while introducing affected-mode selection.
Selection and evaluation algorithm:
- Construct the app and produce the complete symbolic manifest without executing runtime bodies or provider mutations. Read current and retained-origin intent/status summaries consistently. Perform the existing three-way merge first. Keep preserved newer intent distinct from this branch's code; an old checkout cannot evaluate a preserved node as though it owned that code.
- Seed changed intent, explicit removals/replacements/adoptions, tainted/stale/unconverged or uncertain entries, relevant unresolved operations, and nodes whose behavior cannot be proven stable from recorded evidence. Time-dependent runtime work or unknown purity is such a seed. A no-op seed may still need intent or refresh publication.
- Close over both desired symbolic references and persisted consumed inputs/order edges. Include providers, outputs, runtime checks, data/ephemeral observations and the reverse consumers whose evaluation or stale marking can change. Persisted inputs alone are insufficient: new code may introduce an edge that has never been stored. Deletes/replacements must close their destructive reverse predicates, including newly introduced and broad observers.
- Expand declared opaque scopes to their necessary stack/app members. Unknown inputs, unsupported effect/purity classification or missing index evidence widen to the conservative full view; an explicitly known empty read set remains different from unknown. Preserve the existing deferred-provider and identity fallback rules.
- Load selected payloads and boundary proofs in one repeatable-read snapshot. Validate the seed/closure summaries in that snapshot too; changed revisions restart the merge and selection. Release the database read transaction before provider calls or runtime evaluation. If subsequent discovery needs more rows, reread the expanded selection consistently and discard dependent evaluations from the previous view; never splice rows from two frontiers and call them one snapshot. A bounded expansion/restart budget falls back to full planning before approval.
- Refresh and evaluate the closure with authoritative provenance. Changed refresh values, dynamic references and runtime-returned references can expand it; repeat to a fixed point. Preserved consumers whose current code is unavailable are marked stale/deferred, not evaluated from the old branch. Check caches against state/run/evaluation epoch exactly as in full mode.
- Build the same complete action/read/identity/reverse-edge coverage used today. Acquire and validate the fixed grant before approval. Changes outside the observed evidence can proceed; changes to membership, inputs or predicates require replanning. After approval, any discovery outside admitted coverage stops the attempt; it never grows the grant or silently switches mode.
Indexed worklist (proposed). Implement the closure as batched frontier expansion, with separate indexes for desired symbolic references, committed consumed reads, reverse consumers and membership predicates. Consult both old and proposed edges: deletion removes the proposed edge precisely when the old reader is still needed. Fetch unseen neighbors in batches; do not rescan the full relation at every hop. Deduplicate by entry, required role and evidence version, so promotion from a boundary read to evaluation is not suppressed by an earlier visit. Within one consistent view, demands only grow. Changed evidence starts a new view and invalidates dependent evaluations as in step 5.
If selection later narrows collection members or output paths, give demand an explicit join:
finite requests combine by union, and a request for the complete scope dominates every finite
request. Keep no recorded demand, an unresolved selection, a proven empty selection and complete
scope distinct through caching and serialization. A larger demand re-enqueues an already visited
node even when its role and source revision are unchanged. This generalizes selection evidence;
it does not add Terraform count/for_each execution to NF or grant mutation authority.
Track removed members separately from selected surviving members. A collection whose final member was removed can have an empty surviving selection and still require deletion work with the original state and identity proofs. Equal collection keys do not prove equal bodies: a changed shared input re-evaluates every consumer it can affect unless narrower per-member reads are proven.
Keep monotone demands separate from derived narrowing decisions. A later wave's newly discovered anchors, collection keys or module members can invalidate an earlier exclusion within the same view. Version or clear those decisions by state and selection round, re-enqueue their affected consumers, and require the final sweep to use the last validated answers. An insert-once cache must not silently retain the first exclusion after its evidence grows. Per-state invalidation cannot erase another state's work in a future coordinated build.
Deduplicate immutable input payloads across consumers and waves independently of node visitation. A cache key must bind state/lineage, view or value revision, input kind/address, instance context and comparison side; the proposed and committed values are distinct inputs. Preserve each consumer's own provenance even when its payload is shared. Cache only what those keys certify; new observations and changed evidence invalidate the affected entries. Distinguish an unqueried key from a completed lookup with no value and from a present value. Cache a negative result only after a successful, complete lookup in the bound view; query failure or incomplete coverage is not absence. A negative cache entry avoids a repeated fetch but does not prove a consumer unchanged. Invalidate or revalidate it when its view or relevant membership evidence changes. Measure payload bytes and database rows scanned as well as queries: a small result can still require repeated full scans. Tune joins/materialized subsets against measured query plans, including freshly populated tables with weak statistics, rather than assuming that a SQL CTE or cache guarantees bounded work.
Versioned scope digests may skip loading unchanged index partitions. Their canonical encoding must cover the partition's membership and relevant intent/edge versions; changes and deletion publish with the corresponding rows. They accelerate topology lookup, not cloud refresh or arbitrary Python execution. Keep observed-input proofs, entry status, provider qualification and runtime purity checks separate. A structurally unchanged scope can still contain drift, taint or time-dependent work. Missing or incompatible optional selection indexes can fall back to full planning only when its dependency evidence is independently complete. A corrupt authoritative reverse-edge index is an integrity error for both planners, not a reason to trust the same index through full fallback.
Bound worklist rounds, selected size and consistent-view restarts, with reported reasons. Budget exhaustion widens to full planning before approval; it never returns a truncated closure as complete. Return an explicit convergence/fallback/error outcome. A warning followed by an ordinary successful selection result is insufficient, including when omitted structural support could turn retained state into an apparent deletion. If full planning cannot establish coverage either, fail the attempt. Record newly selected nodes/edges per wave, queries, payload bytes and fallback reason. The complete manifest still costs O(N); only measured payload/refresh/evaluation savings may be attributed to incrementality.
Persistence and compatibility. Bind the selection, policy, manifest digest, capture version, baseline and original boundary proofs into the saved-plan artifact. Do not rebuild boundary values from newer state at saved-plan apply. Older full plans keep their existing semantics; unknown affected-plan versions fail with a replan instruction. Missing optional acceleration indexes permit full planning with independently complete evidence; damaged authoritative indexes refuse until repaired. Index updates, edge generations and the corresponding state/intent writes publish in the same SQL transaction.
Retained planning qualification. The manifest collector exposes a gap that the current row intent cannot fill: a resource fingerprint names its provider configuration but does not fingerprint that provider's settings. Before omitting an unchanged resource, retain versioned planning context with that row's reviewed intent: symbolic provider settings and source/version, the actual provider selection and authenticated namespace where applicable, relevant semantic settings, and the effect/purity classification used by selection. Runtime environment or provider defaults that can change behavior need explicit qualification or full fallback; hashing configuration text alone is insufficient. Do not confuse a known empty read set with stable behavior.
Publish this evidence through the normal node/row-write path, including reviewed no-ops, history, refresh preservation, replacement and saved-plan replay. A legacy or incompatible context is unknown until a reviewed full apply establishes it. Retain context per entry: a single latest app digest cannot describe a state assembled from independently reviewed branch intents. Preserved newer rows keep their own context; an older branch cannot overwrite it with the manifest it just constructed. The complete branch manifest still proves membership/removal separately.
The retained record binds intent_fp, the entry's symbolic evidence, semantic settings, symbolic
provider settings and qualified runtime provider context, stability/reasons, policy version and
reviewed_revision. Omission requires both a matching current context and an exact match between
that reviewed revision and the current row revision. Storage format compatibility is not provider
qualification. An unreviewed administrative write, deletion or legacy write cannot inherit the old
record as proof; state-only restore may conservatively invalidate it. Known returned provider
results recover the context of their immutable original request. Observed/imported outcomes that
remain unconverged do not establish new qualification.
Compact saved plans (proposed). Affected mode must reduce the execution artifact as well as the planner's database reads. Store selected original row images and required private provider data, evaluated inputs, original boundary values/proofs, possible deferred actions, predicate generations and the complete admission basis. Carry complete address/intent evidence needed to prove removals, or a verifiable reference to a retained immutable manifest; never infer deletion from omitted payloads. Do not serialize the full app's resource payloads merely to reuse the old artifact shape. Retained manifest references need explicit lifetime protection; a missing reference rejects apply rather than reconstructing evidence from newer state. Preserve full-plan compatibility and use a new version for partial artifacts. Measure manifest bytes, selected payload bytes and proof bytes separately: complete summary evidence can remain O(N).
GraphPlanArtifact implements the compact carrier in a separate format 18 envelope
(nf-graph-affected-plan). The public loader dispatches both full and affected formats. The
class-specific HybridPlanArtifact reader still supports format 17 and rejects this envelope,
preserving its complete-State contract. The carrier can only be built from a converged
GraphPlanningClosure with its GraphPlanningCandidate; a full fallback has no partial artifact.
Currently qualified artifacts require resolved, unmigrated state without auxiliary cleanup and no
deferred provider actions. Unsupported cases continue to require full planning.
The inline evidence contains the complete manifest, original intent/status summaries and origin,
reverse edges/generations, selection roles/reasons/observed reads, exact selected original row images,
refreshed boundary observations, evaluated desired payloads, ordinary serialized execution nodes,
provider fingerprints and coverage version 3. It never constructs or serializes a partial State.
Original payloads must match their row value/private proofs. Loaded row coverage, consumed revisions,
reverse predicates, manifest contexts, executable membership and ownership checks must agree. An
explicit forgotten object requires both a complete-manifest removal and a retained absent refresh.
Unknown output values retain collection shape and sensitivity through the shared node codec.
Loading reconstructs evidence entirely from the file, preserving originals even if live state has advanced. Admission still checks current rows, predicates and ownership; a changed boundary is rejected, while an unrelated commit can remain compatible. Missing or mixed evidence, future versions and content corruption require replanning. The content digest detects corruption, not file authenticity: the artifact remains trusted executable input containing private/sensitive data. Its accessors return detached values, and saves use atomic replacement. Inline evidence lives with the file; the baseline still needs its existing retained pin when admission checks it. No cache expiry or current-state reconstruction substitutes for that pin.
section_bytes() reports encoded manifest, selected payload/node and proof categories separately
from total file content. These are serialization sizes, not database/network traffic. Complete
summaries, manifests and topology still cost O(N+E). A unit case confirms that increasing an omitted
resource payload does not add that payload to the artifact. The six actual-provider configuration
cases now save/reload this carrier before ordinary PostgreSQL resource admission, with provider
mutation forbidden. These tests establish transport and admission, not an enabled saved partial
apply on their own. The execution, selected-cache and public routing slices below provide separate
evidence; broader artifact-size/performance gates remain required.
Review from retained evidence. GraphPlanArtifact.summary/to_summary() derive counts and
action details from the saved nodes, exact selected originals and refresh observations; the format
does not accept a caller-supplied display summary. Complete original/current/desired intent summaries
identify all preserved newer entries, including entries whose payloads were omitted. Their retained
input lists identify existing or predicted stale inputs. This report needs no backend read and cannot
substitute newer values after a file is saved. Selected action classification uses the same material
resource comparison as full planning. Sensitive output values use the existing masked output codec;
resource attributes and provider private data are not copied into the review projection.
Each refresh observation retains the provider refresh's drift and schema-upgrade diagnostics. Comparing pre-upgrade stored values with refreshed values is insufficient to distinguish those outcomes. Diagnostics absent from a custom observation remain explicitly unknown; reported counts include confirmed observations only. Planning-time runtime-check outcomes are retained separately because the shared executable codec drops them and apply must run the checks again. Missing or malformed retained diagnostic fields require replanning; explicit unknown values remain reportable.
The artifact retains its deleted-object policy and explicit forgetting evidence. Review separates a missing object that remains desired (create again) from one the complete manifest removed (forget its already-absent state entry). The error policy refuses a candidate with absent objects. The review policy retains its approval requirement; the recreate policy does not add that requirement. A forget-only plan is a state change, even when its provider action counts are zero.
Shared API approval and CLI renderers display the affected inspection scope even for an empty plan,
and state that unrelated infrastructure was not inspected for external drift. Structured inspection
details retain evaluated/refreshed/boundary/excluded entries, roots, reasons and closure metrics.
Public review/loading preserves these capabilities; the class-specific full-State reader still
rejects format 18. Neither a review projection nor successful transport authorizes execution.
Internal partial apply. An explicit GraphPlanArtifact now enters the ordinary hybrid apply
path with immutable admission before approval or mutation. GraphStateEngine.acquire_plan can
request app X while retaining exactly the same write/action admission as resource grants. The
broader grant changes exclusion, not the admitted write set. The public concurrency opt-in chooses
the grant policy; both policies require a retained baseline, current identity qualification and
the saved coverage. Unsupported contracts and missing rollback capabilities reject a partial
artifact and require replanning; they cannot fall back to unrestricted serial mutation. An existing
unadmitted grant is likewise refused, including for an empty plan. Backend admission and dispatch
checks remain authoritative, without a new SQL protocol or relaxed canonical-identity requirement.
The apply path activates the carrier's selected-node manifest rules, loads providers from its retained view when necessary, and checks provider fingerprints/runtime qualifications normally. It uses retained concrete resource configurations and output values. A selected value still unknown at planning needs its live construct to resolve it, as with full saved plans. Resolving an output's unknown fields cannot change its already-known elements; inconsistency fails before publishing that output and reports paths without values. Ordinary provider and input-proof checks still guard calls.
Only saved selected nodes execute. Their output nodes publish or remove outputs; partial success does not run whole-app output/data-source cleanup. Already-absent state entries are removed only from the artifact's validated explicit forgetting list, never inferred from omitted nodes or a display cache. Tests change unrelated live code and cloud objects after saving and retain their state versions and external drift. Known selected values likewise come from the saved artifact.
Selected state after admission. For an internal partial artifact, the engine reads exactly the
admitted resource/output row keys through planning_view after acquiring and validating the
complete grant. It verifies the retained baseline and state identity, exact row versions,
value/private proofs, consumed input revisions and reverse predicates again. A mixed view, missing
payload, changed proof or migrated/transferring state refuses before approval and releases the
unapplied grant. An unrelated commit may advance the global frontier; equality of that frontier
is not required when the selected proofs still match.
GraphExecutionRows keeps selected live values, explicit absences and tombstone revisions distinct
from omitted keys. Execution uses point reads for references, writes and materialized input proofs.
Whole-state reads, undeclared point reads and broad scope/enumeration reads fail explicitly while
this cache is active. A partial cache is never exposed through load_state() or planning_snapshot().
The selected rows cannot expand after admission. Commits update their values and revisions; complete
status summaries retain omitted stale/unconverged entries, including through post-unlock result
decoration. These diagnostics describe captured evidence plus this run's commit results, not a
fresh inspection of unrelated concurrent work. An explicit full read after the run reloads complete
state normally.
Checkpoint creation reads only its selected current revisions and pinned history images under the existing fence, in PostgreSQL and the memory model. Rollback keeps a separate selected before-image and orders its explicit deletion set without app enumeration. Original create-operation IDs are candidate lookup keys only: point reads must find this run's durable committed create of the current incarnation, and the backend rechecks that cause before compensation. Missing or inconsistent receipts require recovery; a local ID never grants deletion authority. Output restoration considers only selected rows written by this run. An unrelated output committed after admission retains its value and revision.
The saved-apply provider cases forbid complete engine and SQL snapshots and reject decoding omitted resource payloads through admission, approval, provider calls, checkpointing and compensation. Shared memory/PostgreSQL cases fault the post-admission view and verify grant cleanup, point-read boundaries, selected absence/tombstones, stale-result diagnostics and concurrent foreign output preservation. These are functional payload-boundary checks, not an asymptotic cost result. Complete summaries, topology and retained-baseline verification remain O(N+E); unresolved-operation and physical-ownership checks retain their existing protocol costs. Measured payload bytes, allocations, fallback rates and end-to-end cost as total state grows remain I5 gates.
Public affected planning and saved-plan routing. execution/graph_planning_frontend.py now
connects graph_plan_scope="affected" to this path. App-level API planning, automatic apply, plan
summaries, and nf plan/apply/deploy use the same controller. The default remains full; invalid
scope values are rejected. Missing graph state or a retained baseline is an error before provider
startup, including for empty plans. Planning scope and concurrent_applies are independent: both
app-X and resource-grant policies admit the exact artifact before approval.
The initial qualified runtime is AWS 6.66.0 SSM under the restricted configuration profile
described above. Missing optional backend planning-view/ownership capabilities, adoption,
auxiliary state cleanup, unsupported runtime/proof scopes, opaque or
deferred work and exhausted closure budgets report explicit full fallback. Stack-targeted planning
currently falls back to full planning of the requested stacks. A fallback reports its requested
and actual scope, reasons and available closure metrics; it does not certify that every full-mode
refresh succeeded. Normal refresh diagnostics retain that distinction.
Each capture owns setup/refresh/qualification diagnostics, and each evaluation round owns its planned values and authoritative input recorder. Only the final capture/candidate contributes to the successful plan's diagnostic report. Full fallback resets the provenance cache epoch, stops the selected providers and clears their graph context before full evaluation. It cannot reuse a discarded partial candidate. Capture changes during startup can fall back directly; changes within the closure use its existing bounded restart protocol. Unexpected exceptions and invalid evidence propagate instead of silently changing planners. Only an explicit unsupported-capability result from a backend view/ownership call becomes an eligibility fallback; a failed database read is an error.
execution/plan_artifacts.py dispatches formats 17 and 18 for the public hybrid loader, CLI show
and apply, and embedded plan summaries. A saved affected artifact preserves its scope, manifest,
selected originals and reviewed nodes even when the current App or flag requests full; the
setting governs future planning. Corruption or missing evidence requires replanning. Existing
saved-plan admission and provider checks still apply, and no full state is fabricated from the
partial file.
Native tests exercise public automatic apply, embedded summaries, CLI plan/show/saved apply, automatic CLI apply and deploy under both grant policies. They forbid full engine and public/private SQL snapshots, leave unrelated external drift and its stored revision untouched, and verify selected cloud values and outputs. The saved-plan failure/recovery cases also use the public create/load paths, with provenance reporting enabled. Late unsupported work and newly observed cleanup return full artifacts with reasons; unexpected planning failures stop without a full retry. These tests qualify the stated SSM/FakeCloud paths, not arbitrary providers, live AWS or Stategraph.
Paired full/affected observations. A new immutable corpus in
specs/graph-state/qualification/2026-11-09-i2-paired/ compares both public planners on twelve
concrete SSM cases under both grant policies. The full run records exact managed-resource and
identity RPC observations. Affected planning replays those responses, refusing a request absent
from the tape. Provider startup/configuration remains live under the qualified static profile;
the tape excludes Configure calls and credentials. Fixture bodies are concrete and side-effect
free, so this is not qualification for replaying arbitrary opaque Python bodies.
Cases cover consumer/producer changes, creation, deletion, outputs including an unknown ARN and a single-element collection, first-refresh normalization, boundary and unrelated drift, changed provider settings and preserved newer consumers. Affected planning refuses complete snapshots; saved affected apply then uses real provider calls, with independent final service/output checks. The offline checker compares executable values and unknown marks, contexts, writes, original rows, inputs and reverse proofs. It binds concrete fixture fields to decoded wire requests/responses and checks response hashes, publication coverage and persisted stale statuses. Negative mutations must fail even when both plans' values or coverage are changed together.
The checker permits two explicit representational differences with extra evidence: a deleted node can carry original inputs that the full plan retains only in coverage, and a retained unchanged output can have an explicit affected no-op where full planning drops the record. The latter must have no publication and identical original value, intent and inputs. Other differences fail.
The preserved-consumer case exposed a shared reporting gap: direct consumers were predicted stale,
but their downstream output was omitted even though apply marked it stale. Both full and affected
review now use predict_stale_inputs over complete revision/status/input metadata. It follows
retained consumers transitively, treats value and membership scopes separately, and reports existing
stale rows that are not being reconciled. It does not change admission or add write authority.
Memory checks compare predictions with actual metadata/value/create/delete invalidation; the native
paired case verifies both plans' warnings against PostgreSQL's final stale set. Its successful apply
remains incomplete until the preserved newer configurations reconcile.
All 24 paired captures and 43 offline replay/checker tests pass. These observations extend the historical eighteen selector-only captures without changing their provenance. They are evidence for the stated AWS 6.66.0/FakeCloud profile, not performance or comparative Stategraph guarantees.
The I1 checkpoint above adds scope-verified adversarial captures for the concrete SSM profile. Broader runtime/failure cases, wider I1 coverage and I5 affected-mode costs remain required before claiming the RFC's full scoped execution and cost guarantees.
Opaque/deferred fallback comparison checkpoint (2026-11-09). Eight additional paired
captures cross four cases with app-X/resource grants: a stack-scoped runtime expression, a
cached file-producing expression whose file is removed, deferred provider configuration, and
separate planning/apply runtime checks. Every affected request explicitly falls back to full.
Provider observations and opaque runtime results are recorded once and replayed for comparison;
a missing request fails instead of running the body or making a live read. Full and fallback
retain identical actions, evaluated values, original row/input/scope proofs, unknown marks,
deferred outcomes and admission coverage.
Actual saved apply uses live constructs and real provider calls. It recreates the missing file even when the consumer's provider action is a no-op, executes the saved pre-apply check separately from its planning check, and completes the deferred consumer/output after configuring their provider from the producer's computed ARN. The broad runtime scope instead finishes successfully but incomplete, with its consumer and output correctly reported as having stale inputs. The comparison preserves that conservative outcome rather than treating success as convergence.
All eight native cases and offline replays pass; the combined concrete/fallback checker suites
pass 84 tests, including corrupt matching plans, lost proofs, repeated effects, missing artifacts,
lost unknown/deferral marks, wrong check phases and false completion reports. The exact running
AWS provider and PostgreSQL versions are observed. Captures and limits are in
specs/graph-state/qualification/2026-11-09-i2-fallback-qualified/. These are bounded full-fallback
comparisons, not broader affected eligibility or arbitrary runtime-effect replay from a standalone
saved file. Broader failure/value/index/cache checks and I5 cost gates remain separate.
Derived caches and durable evidence. Separate reconstructable selection/rendering caches from saved-plan proofs, pinned origins and unresolved-operation requests, returned results and footprints. A terminal run may release an unused cache; it cannot release evidence still required by a saved plan, dependent reader or recoverer. Pin needed artifacts before cleanup can race their consumers, and delete idempotently only after those references end. Reconstruction must use the recorded view; if it is unavailable, refuse or replan before approval. Never silently rebuild a saved plan from current state. Reuse the existing retention protections rather than adding a timeout that releases uncertain operations.
Delivery slices and gates:
Initial broad-read progress (E96). The earlier initial-creation benchmark failure is now reproduced with one producer and two consumers. A sibling create changes a declared stack/app scope even when the runtime body returns its input unchanged. Serial execution can record every object but leave an earlier reader stale; parallel scheduling can refuse the later stale dispatch. Removing the pre-call check or relabeling the earlier scope as current would lose provenance. Full planning and an app-X grant do not make these self-induced changes disappear.
Twenty-four PostgreSQL/FakeCloud cases now inspect every partial state, covering
AWS 6.66.0 SSM, app-X/resource grants, one/two consumers, scheduling limits 1/10,
and concrete/stack/app/undeclared reads. Concrete and single-consumer controls
complete immediately. The twelve two-consumer broad cases converge through fresh
plans in two or three attempts, under the same retained branch origin. Across
42 attempts, all 64 mutations are creates, every service object stays at version
1, all effects are represented accurately in state, and final consumed proofs
are current. No production retry loop or one-shot guarantee was introduced.
Sixteen memory controls and the plain-data checker/negative controls pass; the
combined run has 388 passes and twelve inapplicable partial-only skips. Frozen
evidence: specs/graph-state/qualification/2026-11-13-i2-broad-creation/.
The small no-op benchmark also exposes a separate checker assumption: admission coverage rows need not include untouched originals, while that checker demands equality with the complete state inventory. Its failure and original worker metrics remain retained and unqualified. E97 below fixes the harness gap; automatic safe reconciliation semantics, changing/oscillating runtime bodies and repeated mutating broad-read costs remain separate gates. The metadata-introduction workload does not substitute for those cases.
Untouched-origin benchmark proof (E97). Version-2 benchmark evidence now records admission-covered rows separately from explicitly untouched keys. Their disjoint union must equal an independently inspected complete inventory, bound to the exact state ID, lineage and frontier. Covered revisions must match that inventory. Untouched targets must be ready with unchanged consumed inputs; changed fixture resources cannot be labeled untouched. Per-node scope proofs remain checked even when the node has no admission write target. The offline report binds its declared version to each verified native sample; legacy version-1 captures retain the original complete-coverage requirement.
Two bounded PostgreSQL/FakeCloud runs pass 18 attempts each, covering stack/app/
undeclared reads with full and requested-affected planning. The latter falls back
to full. Two-resource no-ops preserve every graph row and make zero provider
mutations/publications; eight-resource metadata introduction makes no provider
mutations and three publications per sampled apply. Each cell has one warm-up
and one sample, so neither run qualifies comparative latency. The 397-test
checker suite includes malformed origins, missing/duplicate/overlapping roles,
concealed changed work and mismatched report versions. Frozen replay retains the
original offline-report failure and exact raw hashes, with capture and rechecker
source identities separate: specs/graph-state/qualification/2026-11-13-i5-untouched-origins/.
This closes the harness omission; production planning, admission and broad-read
convergence behavior are unchanged.
Mutating broad-read progress (E98). Twenty-four additional native cases change actual SSM values under settled concrete/stack/app/undeclared contracts, with one/two consumers and both app-X/resource grants. Setup creates concrete state and introduces runtime metadata separately; fresh update plans share the settled branch origin. Every setup and partial update has independent service/ state, operation, input and grant observations.
Concrete and single-reader updates complete in one plan. Two broad readers need
two plans serially or three in parallel: serial updates leave earlier scope
evidence stale; parallel execution refuses the later stale dispatch, records its
update under a fresh plan, and then reconciles metadata. Across 42 update attempts,
exactly 64 updates follow 64 setup creates. Every service object ends at version
2, and final reconciliation sends no provider mutation. The 1,002-test combined
checker suite includes missing/repeated effects, wrong consumed values, coherent
wrong revisions and false completion; 24 partial-only controls are inapplicable
to immediate-convergence cases. Frozen sources, every partial state and the
original checker diagnostic are in
specs/graph-state/qualification/2026-11-13-i2-broad-updates/.
This adds bounded mutating-workload correctness. Production behavior is unchanged; automatic retry, one-shot broad-read convergence, arbitrary bodies, external writers and provider failures remain open. E99 below measures the complete small update fixture; wider mutating cost cells remain open.
Complete broad-read update costs (E99). A bounded PostgreSQL/FakeCloud campaign passes 64 captures: concrete/stack/app/undeclared reads, resource grants, full planning and scheduling limits 1/10, with one warm-up and seven samples per cell. The source-bound trace includes the update origin pin and every fresh plan; creation, metadata introduction and independent observer SQL remain separate. Concrete updates use one plan, 282 body SQL requests, 22 returned write-mode transactions and three publications. Two broad readers use two plans serially (441 requests, 32 write-mode returns, four publications), or three in parallel (567 requests, 41 write-mode returns, four publications). Returned read transactions are 7/14/21 respectively. Each case performs exactly three provider updates; the parallel broad case also records one pre-call stale-dispatch refusal.
The origin pin costs six requests. Final broad-read metadata reconciliation alone
costs 136 requests and one publication with no provider mutation: a concrete
remaining optimization target, subject to preserving current proofs and approval
semantics. The complete campaign takes 144.38 seconds; resident-process update
medians are 0.398–0.405 seconds concrete, 0.729–0.761 broad serial and 0.998–1.061
broad parallel. Different read contracts are not a speed comparison. The raw
records bind actual runtime module paths, source bytes, transaction/transport
events and independently observed graph/service outcomes. Frozen replay and
1,356 focused tests pass (12 inapplicable skips). Initial captures without runtime
module-path witnesses remain separate. No production retry, one-shot broad
convergence, CLI-process timing, p95, large-fanout or hosted comparison follows.
See specs/graph-state/qualification/2026-11-13-i5-broad-update-costs/.
One-statement baseline validation (E100). The 136-request metadata-only phase includes four separately required baseline checks. PostgreSQL now reads lineage, pin and retained intents in one typed statement per check instead of three. It preserves every validation boundary, scope/pin check and intent digest; there is no cross-boundary cache or protocol/schema change. The phase uses 128 requests, with the same 17 transactions and single publication. Complete updates use 274 requests concrete, 425 broad serial and 543 broad parallel, saving eight per fresh plan. Provider effects, transaction counts and publications are unchanged. All 64 final captures pass, with one warm-up and seven samples per profile; shared-host timing outliers remain recorded without an overall speedup claim.
A rejected JSON-envelope version reduced requests but increased the synthetic
10,000-intent reader median from 57.08 to 90.37 ms. Typed rows avoid that penalty;
the separate typed comparison is 52.25 versus 53.57 ms at 10,000 rows, still
slightly slower, so fewer requests are not a large-history latency claim.
The final native planning/baseline/admission suite passes 395 tests, including
old-reader request-count failures and invalid-scope/pin/history controls.
The frozen sources, bounded reader comparisons, final provider captures and
original rejected variant are in
specs/graph-state/qualification/2026-11-13-i5-baseline-reads/.
Five complete snapshots still contribute 35 requests to metadata reconciliation.
Any narrower proof reader must preserve broad-scope values/membership, tombstones,
unresolved operations and reverse-index integrity at each validation boundary.
Automatic retries, broader performance cells and hosted comparisons remain open.
Smaller broad-proof reads (E101). Three full validation snapshots now read complete semantic counters, membership, unresolved operations and reverse-index metadata, plus exact payloads for explicit row and auxiliary expectations. Each validation boundary and app-row lock remains. Ownership checks still reconstruct owners from stored attributes/locators; an index-only prototype failed four corrupted-identity controls and was rejected. Legacy counters and observation overlays fall back to full snapshots. Ordinary application snapshots are unchanged.
All 64 provider captures pass: complete concrete/serial-broad/parallel-broad
updates use 274/395/498 requests, with unchanged fresh plans, transactions,
publications and provider effects. Broad proofs save 15 requests per fresh plan;
the final metadata phase uses 113 requests. The 112 dedicated reader cases,
402 native regressions and 843 final-corpus cost controls pass. A 96-attempt
storage-only comparison retains a tiny-case regression and faster larger reads;
it does not establish whole-apply latency. Complete metadata remains O(N+E), and
ownership checks can still read all resource documents. Two ordinary full
snapshots and 17 metadata-plan transactions remain. Evidence:
specs/graph-state/qualification/2026-11-13-i5-scope-proof-reads/.
Mutating broad-read fanout (E102). The cost harness now binds an explicit consumer count and paginates its independent service inventory. Raw evidence v2 accounts for every partial effect across bounded explicit fresh plans; an incomplete attempt without new provider progress stops the campaign. Historical small-fixture formats and reports retain their original contract. Production code is unchanged from E101.
Four full-planning/resource-grant cohorts at one producer plus 100 consumers,
scheduling limit one, pass all 32 captures: one warm-up and seven measured cases
each for concrete, stack, app and undeclared reads. Concrete uses one plan, 5,860
requests and 101 publications. Broad reads use two plans, 6,985–7,031 requests
and 103–105 publications, including two to four final metadata publications.
Every case updates all 101 objects exactly once. A separate 10-consumer pilot
needs eleven plans and twenty publications under parallel broad reads, versus
two plans and twelve publications serially. One sample per pilot profile is
diagnostic, not a repeated timing claim. A capped mixed 100-consumer pilot retains
six verified cases and its interrupted seventh case as an incomplete campaign.
These are named full-planning costs, not automatic/one-shot convergence, affected
planning, comparative speed or larger/hosted qualification. Evidence:
specs/graph-state/qualification/2026-11-13-i5-broad-fanout/.
A separate instrumented control observes 99 final metadata rows (876,228 bytes under the software queue budget) published as 15/44/40 rows, below the 128-row / 1-MiB limits. Its first publication starts just after the 20 ms collection window; later cohorts' oldest rows have already exceeded it. This supplies a concrete cohort-fragmentation witness. A better scheduler must preserve dependency/input validation, bounded memory, cancellation and durable acknowledgement; the probe does not establish a universal single-publication or latency guarantee.
Scheduler-driven metadata collection (E103). Runnable no-op preparation now drives normalization collection; dependency-blocked nodes, receipt waiters and provider/ephemeral work do not extend the wait. Row/byte backpressure forces a flush, and custom or mixed scheduling pools retain the timer fallback. Creation and authorization collection policies and engine/backend validation are unchanged. The 430 core/orchestration checks and 143 distinct native cases cover dependencies, durable acknowledgments, cancellation, bounds, changed inputs, conflicts, expiry and lost replies. The initial native test-constructor error remains archived.
Eighteen current-source provider captures pass, including a smoke pair and seven measured pairs plus warm-ups for the same 100-consumer stack-scope fixture. The control substitutes only the timer policy on the current code; it is not the historical implementation. All 99 final metadata rows fit the existing limits and share one publication, versus three with the timer. Final metadata SQL falls 160 to 114, write-mode transactions 12 to 10; complete update SQL falls 7,008 to 6,962 and publications 104 to 102. Each case still requires two explicit plans and 101 provider updates. One is the exact publication minimum for this nonempty, independent metadata correction, not for the complete apply.
The complete-update median is higher, 13.372 versus 13.016 seconds; its paired
ratio interval includes parity (0.9704–1.0773). The metadata interval also includes
parity. Fixture setup, including contract installation, has a preliminary paired
ratio 0.9715 (0.9663–0.9807); it is not a single initial-creation timing. No overall
update speedup or SQL optimum is established. Frozen replay rejects nine corrupted
evidence controls. The remaining metadata plan still has 114 SQL requests and
17 returned transactions; broader scopes, scales, contention and I5 gates remain
open. Evidence: specs/graph-state/qualification/2026-11-13-i5-normalization-waves/.
Reuse the admitted baseline (E104). Transaction attribution finds a five-request write-mode transaction that re-records the baseline already fixed by admission, then returns without changing a row. Preparation already validates the exact plan/baseline and its complete live grant before this call. Admitted applies now reuse that durable origin; unadmitted app-wide runs retain explicit recording. The interface makes admission's history/pin-protection obligation explicit. Dispatch, publication and approval validation boundaries remain.
The 621 core and 404 native cases pass, including eight PostgreSQL/provider cases
that independently read the committed origin before approval, refuse active
unpinning and verify history afterward. Four diagnostic before/after captures
pass for the 100-consumer stack-scope fixture. Final metadata costs fall from
114 requests/17 returned transactions to 109/16; complete update costs fall from
6,962 requests/424 write-mode transactions to 6,952/422. Publications remain
one for metadata and 102 for the full update, with 101 provider updates and two
explicit plans. Frozen replay proves that every other metadata transaction's
SQL sequence is unchanged. The instrumented after timings are higher and retained;
these single samples plus warm-ups establish counts, not a latency improvement.
Retention at release still uses twelve requests, and two full snapshots fourteen.
Broader timing and optimization gates remain open. Evidence:
specs/graph-state/qualification/2026-11-13-i5-metadata-transactions/.
Automatic retention without a discarded report (E105). Run release now uses the same locked deletion implementation as explicit pruning without computing the unused totals/eligibility report. Its fresh post-lock clock/frontier read, checkpoint protection, deletion predicates and history marker update remain. Maintenance still runs on every release in its own transaction; public preview and prune reports retain their behavior. Eight count controls reduce automatic cleanup from twelve to seven body SQL requests, with one write transaction. The 27 focused and 447 broader native checks pass, including rollback after a later deletion fails and expired mutations waiting behind either pruning path.
Two new 100-consumer provider captures pass: final metadata uses 104 requests instead of E104's 109, and complete updates use 6,942 instead of 6,952. The 16 metadata transactions, one metadata publication, 422 complete-update write-mode transactions, 102 publications, 101 provider updates and two plans remain. Frozen replay proves all other metadata SQL sequences unchanged; maintenance retains its lock and five pruning statements. Higher diagnostic elapsed times remain recorded and establish no whole-apply speedup.
Forty synthetic pinned-history cases pass, including seven measured pairs per
100/1,000-resource profile. Report/cleanup medians are 35.609/29.352 ms and
1,664.027/1,474.705 ms. The paired geometric ratios and bootstrap intervals are
0.8884 (0.7278–1.0532) and 0.3900 (0.1423–0.9767). The second interval favors
cleanup but is wide: the shared version-deletion statement alone ranges from
62.7 ms to 2.613 s in the 1,000-resource cleanup samples. That variance is not
explained by the five omitted requests, and a repeatable latency improvement
remains unproven. The fixtures have fresh state IDs in a shared database that
retains earlier cases; they do not establish cold-cache or isolated-database
behavior. Current values/private bytes, pinned origins/intents, exact retained
history and commit counters survive every case. Replay rejects 22 corruptions.
Next, inspect the shared deletion's SQL plans and history-density sensitivity;
broader I1–I5 gates remain open. Evidence:
specs/graph-state/qualification/2026-11-13-i5-retention-cleanup/.
Bound history-successor probes under stale statistics (E106). Live SQL plans
reproduce a seconds-long deletion when statistics do not yet describe a newly
populated state. The planner flattens the successor EXISTS into a semi-join
that repeatedly scans state-wide history. Explicit ANALYZE changes that plan;
JIT is absent from the recorded probes. The successor test now uses a scalar
(SELECT 1 ... LIMIT 1) IS NOT NULL expression with the same conditions. This
retains the existence semantics while keeping the resource key in the lookup.
All other retention predicates, locks, cutoff/frontier reads, deletions and
history-marker logic are unchanged. No index or production database setting is
changed, and no extra request is added.
The structural regression fails on the old query at 70,900 scan rows for 100 resources and 6,010,000 for 1,000. All 81 native checks pass with the rewrite, including four successor-work cases and retention/checkpoint/expiry/fence cases. Four post-change plan observations scan 10,000 history rows at 1,000 resources. The initial test-harness pagination mistakes remain archived.
Forty matched synthetic-history captures pass. At 1,000 resources, seven measured
pairs per statistics profile show old/new maintenance medians of 2,714.228/55.760
ms with stale statistics and 43.459/49.315 ms after explicit ANALYZE. Paired
geometric ratios are 0.02376 (bootstrap interval 0.01827–0.03046) and 1.12664
(1.08107–1.17942). The measured tradeoff is a large reduction on the bad plan and
about six milliseconds of additional work on the already-efficient analyzed
plan. These are preliminary local fixture comparisons, not an unconditional
latency improvement or a prior-five regression verdict. Both policies retain
seven body SQL requests, one transaction, zero publications and the exact pinned,
current and historical state. Fixture-only autovacuum suppression and explicit
analysis make the statistics treatment repeatable; production settings remain.
Two new provider captures pass with the existing 6,942 complete-update requests,
422 write-mode transactions, 102 publications, 101 updates and two plans. Final
metadata remains 104 requests/16 transactions/one publication; only the successor
expression changes in its SQL ledger. Frozen replay rejects 19 corruptions.
Larger histories, more pins/checkpoints, concurrency, natural statistics refresh,
whole-apply latency and broader initiative gates remain open. Evidence:
specs/graph-state/qualification/2026-11-13-i5-retention-plans/.
The requirement-level audit in specs/graph-state/qualification/scoped-planning-gates.md
maps the value/cache/index gates to current evidence, including the saved-apply cleanup and
persisted-index checks below. The 2026-11-09-i2-values/ archive adds six full/affected SecureString
pairs for changes, drift and provider-reported absence. Direct and indexed prefix/uppercase reads
preserve producer revisions even when before/after public displays are identically redacted;
saved apply retains sensitive output flags. Thirty altered-observation controls reject matching
wrong values, missing proofs, changed masking and a forged fresh response with updated replay
hashes. Ten unit cases separately cover direct/derived absent and unknown refreshes and sensitive
boundary promotion. Four native structural-cap cases fall back before mutation, retain the whole
eight-resource chain and complete saved full apply without unintended deletion. The final suites
pass 48 native and 378 core/checker tests. No production code or runtime eligibility changed;
these checks close value/cap evidence gaps without closing the remaining audit or I5 matrix.
The subsequent 2026-11-09-i2-saved-retention/ archive passes eight native saved-affected-apply
schedules: before/after fixed admission, prune/attempt pin release, and app-X/resource grants.
A second PostgreSQL client performs actual pruning while the saved apply is paused. Pinned origins
survive, release before admission refuses the saved plan before any provider mutation, and release
after admission is refused while cleanup still removes eligible history. Successful runs preserve
unrelated versions and complete one reviewed provider update; every origin can be reclaimed after
its references end. Complete-state reads and rebuilding the saved plan are forbidden. This closes
the named saved-apply cleanup audit at those controlled boundaries. The records are native assertions, separate from I1's independent
recovery oracle, and do not claim all provider-in-flight or SQL interleavings.
Persisted-index integrity and retained provider startup. Complete snapshots and planning
views now independently derive expected reverse edges from every live resource's stored
dependencies and consumed inputs, and every live output's inputs. This includes newer preserved
rows absent from the current Python manifest. Compare exact edge membership and require positive
integer generations for every indexed target. Retain positive historical counters after edge
removal; they prevent ABA and need not have a current edge. The PostgreSQL metadata projection
adds only entry -> 'dependencies', not attributes/private payloads, to its existing query. The
validation runs inside the same consistent transaction as the complete view. Selected predicate
reads cannot prove completeness and do not perform a whole-graph scan per provider call.
An order-only dependency is essential to this gate: a consumed-value input would let the existing input cross-check conceal a missing-edge defect. Before the fix, removing a newer consumer's persisted order-only edge at an unchanged app frontier let an older branch omit that consumer and send a producer update. The integrity check now refuses missing, retargeted or extra edges, and missing/non-positive reverse generations, before selection or execution can trust them. It cannot detect an administrator consistently forging the authoritative rows and all proofs, or reconstruct a positive counter's entire historical sequence from current membership alone.
Saved provider startup validates the retained values, private-state proofs, exact selected keys, baseline and input/reverse proofs against the immutable admission, then rechecks current metadata integrity, baseline lifetime and the complete grant. It never reloads newer values into the saved view. Unrelated publications or generation changes need not match the old global capture; selected proof changes still refuse. Unleased planning continues to require its exact complete capture. This distinction fixes a control case that previously rejected a valid saved plan after an unrelated counter change. No saved-plan, database or writer protocol version changes.
The 2026-11-09-i2-index-integrity/ archive passes 48 native fault/control cases across selection,
saved apply and post-admission startup, including six destructive producer-removal cases. Fourteen
valid controls each make one provider update; 34 expected refusals reserve no operation, send no
mutation and preserve the frontier. Both grant policies run every schedule. The 2,036-test core
regression includes 48 complete-read index faults and 24 shared retained-provider-view cases.
The separate 517-test PostgreSQL regression passes, including those shared startup checks and
the I1 captures described above.
Initial defect/control failures, current observations and source/fixture hashes are retained.
These are native assertions with independent service reads, separate from the I1 portable oracle.
These checks add dependency metadata and O(N+E) comparison work to complete reads. Retained startup also verifies/copies its selected payloads. They preserve selective payload loading, but are not free and do not establish end-to-end O(k) work. Earlier frozen I5 timings describe their recorded source, not this change; current-source measurement and the wider I5 matrix remain separate gates.
- Introduce the manifest and partial-view types; keep execution on full planning. Tests prove that omitted payloads cannot cause deletion and that mixed-frontier reads are refused/restarted.
- Run a shadow selector against full plans on immutable recorded fixtures. Compare actions, evaluated values, observed revisions, deferred outcomes and admission coverage. Replay impure observations; do not execute opaque bodies twice merely to compare planners. Include first-refresh normalization as well as already-refreshed baselines, and validate metadata-only publications and their consumers. An action-complete selection with a missing boundary proof must fail.
- Enable affected mode for closed concrete graphs. For stable clouds, its relevant results must match full planning. For unrelated drift, the difference is permitted only with the explicit scope report. Add creates, deletions, outputs, changed provider settings, preserved consumers, runtime scopes and deferred rounds before widening eligibility.
- Run I1 against affected mode and I5 on fixed-size changes as total app size grows. Assert bounded payload materialization and provider calls separately from the complete manifest/baseline cost. Full fallback reasons and frequencies are measured, not hidden as successful scoped cases.
- Gate indexed lookup and compact artifacts independently: prove old-edge deletion discovery, read-to-evaluation promotion, boundary drift expansion, diamond deduplication and bounded fallback on chains/fanout/opaque reads. A large unrelated partition must not be materialized by each wave. Mutate each persisted index/digest or artifact proof in negative controls and require refusal/replanning rather than false absence. Race cache cleanup with saved apply and recovery; required evidence remains available or the consumer fails before mutation.
- Gate value substitution and pruning with direct and derived reads of missing, unknown and sensitive observations; equal redaction placeholders; a one-element indexed collection; multiple instances sharing a definition; and a cached file path whose artifact is absent. Late evidence in a subsequent wave must invalidate an earlier exclusion. Exercise per-state round cleanup and structural-cap exhaustion with a retained resource whose required support lies beyond the cap; require full fallback or failure before approval, with no unintended delete. Shared-input tests preserve consumer-specific provenance while fetching a large immutable payload once per valid cache key; a changed view/side/instance must not hit that entry. Include repeated missing-key lookups, a key inserted after a cached miss, and a failed/incomplete batch; none may turn missing knowledge into pruning evidence. Change a provider setting outside the selected resource's apparent field demand and require reevaluation under its complete scope contract.
- For any future member/path narrowing, gate finite-demand union, finite-to-complete promotion, and promotion after visitation; vary discovery order and duplicate delivery. Preserve removed members when the surviving selection is empty, including last-member deletion. Hold keys fixed while changing a shared body input and require all affected members. Round-trip no-prune and empty selections distinctly. Invalid indexes, incompatible containers and missing parents must not compare unchanged merely because both projections failed.
I3 — Expand and Qualify Canonical Identity Contracts
Contract. Coverage is per provider source, resource type and tested provider-version range. Schema identity/import fields are evidence about how to find an object; they are not sufficient proof of the namespace or of exclusion between aliases. Unsupported or unproven types retain the existing app X fallback. That fallback does not establish global uniqueness across unrelated states.
Implementation seams. Extend ProviderIdentityContract registrations through
nf.graph_identities, using ProviderIdentityContext, ObjectScope and portable ObjectLocator
data. Provider-specific resolution remains in extension packages; core must work with each absent.
Do not introduce dependencies from values/constructs into runtime or from core into the AWS plugin.
Keep namespace facts bound to the configured provider client and ownership period.
Each proposed contract needs a qualification record containing:
| Field | Required decision/evidence |
|---|---|
| Namespace | Actual account/project/cluster/partition/region or service-global domain; how authenticated facts are obtained and rechecked |
| Object key | Typed components and normalization, including import IDs and provider-returned identities; aliases/credential hashes are never namespace evidence |
| Allocation | Client-chosen versus service-allocated identity; coverage before the final ID is known and when it can narrow |
| Mutation domain | Whether distinct provider resource types can mutate the same underlying object or shared aggregate; separate type-qualified keys must not incorrectly permit overlap |
| Recovery | How a lost create response is located uniquely, or why it must remain quarantined; process death alone does not prove remote quiescence |
| Portability | Locator/contract version persisted in state, saved plans, operations and checkpoints; interpretation without the original plugin |
| Evidence | Supported provider versions, native namespace/alias tests, import/update/delete/replacement cases, and any emulator limitations |
Candidate waves, not assertions of support. Start with additional named AWS objects used by the reference apps, such as Secrets Manager secrets and CloudWatch log groups. Then qualify service-global naming (for example S3 buckets), followed by allocated-ID resources such as EC2 instances/VPCs. Prioritize measured app-X fallback frequency from real plans; these examples do not bypass service-specific investigation. Global bucket names must not be partitioned by an invented account-local uniqueness rule. Allocated IDs must not be inferred before the provider returns them; unknown-create recovery may need operator evidence and remain blocked.
The initial AWS investigation identifies these obligations. Named log groups and non-replicated
secrets now have contracts for provider 6.66.0; the ledger distinguishes their exercised gates
from remaining fault coverage and broader reference-app qualification.
The per-type evidence ledger in specs/graph-state/qualification/aws-identity-evidence.md
maps the four mandatory I1 families, native namespace/import/lifecycle gates and shared
qualification rules to test IDs and captures. Sixteen independent log-group/secret captures now
cover the four mandatory families. The ledger specifies how the allocation adapter observes a generated name
before forwarding its create, while preserving the separate pre-call namespace reservation.
The 2026-11-09-i3-native-gates capture retains 36 passing native cases and 72 shared unit
tests. Six new cases cover names/prefixes that depend on an apply-generated value, including
deferred provider settings: the source must be committed before dispatch and its exact revision
must remain in the child operation and final state. These are native capability/provenance
checks; their use of production identity interpretation is distinct from the independent I1
evidence below.
Independent-observer checkpoint (2026-11-09, verified bounded profile). The allocation
observation contract now has code in tests/helpers/graph_allocation_evidence.py and a bounded
HTTP adapter in graph_named_evidence.py. It retains the pre-call namespace separately from an
exact-name service absence read and the actual create request observed before forwarding. A
concrete name never replaces the original unresolved allocation scope. Follow-up retention/tag
requests remain inside the enclosing provider-call interval. The oracle checks namespace
exclusion, binding order and freshness; independent recovery-retry observations also bind the
successor's fence counters and single publication to the original acknowledged result.
The provider-interval contract keeps gRPC start/completion and individual mutating HTTP requests as separate observations. For a generated name the required order is gRPC dispatch, exact-name absence read, then observed create HTTP request before forwarding. Every follow-up request must refer to the same physical target while its enclosing exchange is still open. Its physical call can finish only with the observed provider return, undelivered response or process termination; an AWS create response alone cannot close that interval. Unsupported observation-contract names are rejected instead of receiving an unchecked pass label. Old histories retain their original observation scope through optional-field defaults.
The verified native scenarios cover existing/new aliases, explicit/generated lost creates and replacement
gaps for both types, recovery-claim replacement, and log-group interruption before retention.
They probe both app-wide admission and physical-object admission. After an unresolved generated
create, both its observed name and an unrelated name in the original namespace must remain
excluded. A returned update keeps its known target excluded through recovery-claim replacement;
an unrelated named demand supplies a positive control. Tests use the public identity encoder to
submit demands, while the oracle derives expected conflict from authenticated fixture namespaces
and actual names rather than the stored lease footprint.
The adapter deliberately observes one provider mutation at a time; this does not establish
parallel generated-allocation coverage. All 16 native tests pass in 56.00 seconds, and the
immutable 2026-11-09-i1-named archive independently replays sixteen passes. Its source SHA-256
is b970c73d0e6d98256114189b0386adc73000796d55e7932f571404d3a47502de. The full conformance
unit suite passes 205 tests, including 84 allocation/transport/recovery cases. Nineteen earlier
archives retain 299 passing and two intentionally rejected observations under the expanded oracle.
These counts include overlapping historical builds, not distinct additional scenarios.
The first named run exposed an observer error: an update whose configuration omits a computed
name still has a concrete prior identity. That failed capture remains unchanged in
2026-11-09-i1-named-initial. The corrected observer uses prior identity for updates, requires
every actual HTTP target to match, and preserves allocation scopes for fresh creates/replacements.
Capture metrics record 36 actual admission probes, 26 provider exchanges, 36 mutating HTTP
requests and nine pre-allocation bindings. This closes the independent per-type families for
the declared name/retention or name/description profiles. It does not cover inline secret policy,
KMS changes, log deletion-protection mutations, parallel generated calls or affected planning
for those types. No production runtime code changed in this observer slice.
Concurrent generated-allocation checkpoint (E59). Four further independent histories qualify two fresh creates within one run for log groups and non-replicated secrets on AWS 6.66.0/FakeCloud. Each provider gets a dedicated HTTP route, bound to its actual ConfigureProvider message and gRPC stub. Both create requests reach a barrier before forwarding, with distinct names and separate absence observations. No route is inferred from a generated prefix or completion order.
The successful cases converge both rows. The expiry cases publish one sibling while
the other's provider response is delayed, observe natural lease expiry and verify
that app, allocation, unrelated-name and both known-name grants remain blocked by
the unresolved namespace. Its kept late response recovers without another provider
mutation; a fresh namespace grant succeeds afterward. The report observes eight
allocations, twelve mutating HTTP requests, four overlaps and 26 admission probes.
All 22 native and 207 unit/replay tests pass, including two native misroute refusals
and 52 damaged-history controls. Exact sources, raw histories and the original
sixteen named cases recaptured on this source are archived under
specs/graph-state/histories/conformance/2026-11-10-parallel-allocations/.
This extends the earlier single-call qualification only to these two-allocation
full-planning schedules. It does not qualify cross-run parallel allocations, one
provider process handling concurrent calls, larger cohorts, deliberate generated-name
collisions, lost-identity discovery, wider profiles or live AWS/Stategraph.
One provider handling concurrent allocations (E84). Four further native histories exercise both generated-name types through one live provider process, one configured gRPC session and one HTTP listener. A fixture tag is independently observed in each actual gRPC configuration and create HTTP request before forwarding. Follow-up retention requests bind to the already observed exact name. Neither prefix matching nor return order assigns calls. Stable process/session/marker observations and declared resource slots must agree in the independent checker; the tags are observation markers, not identity or permission evidence.
Both actual create requests reach a barrier before either service object exists. Success preserves both rows. The expiry schedules retain the unresolved namespace after one sibling publishes, refuse incompatible app/allocation/name grants, and recover the kept late response once under a successor. The four histories contain eight allocations/publications, twelve mutating HTTP requests, four actual overlap witnesses and 26 admission probes. All 34 native cases and 267 unit/replay cases pass, including eight native missing/wrong-marker refusals and 56 new damaged histories. E59's dedicated-provider report remains exactly reproducible.
This closes the two-call, single-provider gap for the stated full-planning,
tagged-create AWS 6.66.0/FakeCloud profiles. It does not qualify larger cohorts,
generated-name collisions, cross-run parallel allocations, irretrievable-response
identity discovery, affected planning or wider mutation profiles. Production
identity eligibility and backend code are unchanged. Exact source, earlier attempts,
refused observation histories and reproducible checks:
specs/graph-state/histories/conformance/2026-11-13-shared-provider-allocations/.
These barrier/expiry schedules do not provide a throughput measurement.
| Candidate / configuration | Evidence and required implementation |
|---|---|
| CloudWatch log group with an explicit name | Names are account/region unique. Keep the exact name, including its leading slash; the SSM normalization rule must not be reused. Bind account/partition/region and validate returned ARN scope. AWS naming rules |
CloudWatch generated name or name_prefix |
Provider 6.66.0 chooses the name inside create. Establish fresh-allocation semantics from that implementation and service collision behavior, or retain serial eligibility. A later returned name must not retroactively prove the original reservation. Test a lost response after create but before subsequent retention work. Provider implementation |
| Secrets Manager with replicas | The provider can create replicas, and the service's overwrite option can replace a same-name secret in another region. One home-region locator cannot cover these effects. Initially exclude replica/overwrite configurations from resource-grant eligibility while preserving their portable locator; unknown replica settings must also exclude eligibility. Later support needs complete multi-region footprints, including old and new replicas. Provider implementation, AWS replication API |
| Log group versus subordinate writers | Group deletion removes associated archived events. Stream/filter/policy writers require a reviewed shared mutation domain before qualifying them alongside group operations; their current app-X fallback remains necessary. AWS deletion API |
This requires a per-instance eligibility verdict in addition to the type/version profile: the binder must consider both prior and proposed attributes, preserve the locator even when the verdict requires app X, persist the reason, and recheck it before dispatch. Do not implement conditional support by returning no locator for an already managed object: that conflates eligibility with recovery interpretation. Bind the eligibility-rule revision into the profile fingerprint and test transitions into and out of excluded configurations. No new type is qualified by this investigation alone.
The current implementation expresses conditional exclusion as IdentityQualification.serial_attributes.
A populated or unknown field excludes that instance; the field list participates in the profile
fingerprint. Secrets use replica and force_overwrite_replica_secret. Both prior and proposed
instances contribute to plan and operation coverage. Imports use app X when the profile has
conditional fields, because configuration alone cannot establish the imported object's effects.
The locator remains available for ownership checks and recovery even when eligibility is false.
Log groups and secrets preserve exact names and use fresh-allocation semantics: their create
APIs refuse an existing name, including one selected by the provider from name_prefix.
Per-instance fallback must survive the run. object_request adds root app X to the retained
operation footprint and sibling exclusion, rather than only choosing a coarse run grant.
Schema 30 fences old dispatch/state writers (protocol 19) and grant writers (queue protocol 8).
New requests carry identity_qualification_version=1; older immutable requests retain effective
app X until resolved. Upgrade tests cover both dispatched and returned operations, old narrow
declarations with an excluded qualification, late responses, queue refusal and recovery without
rewriting the request or digest.
Native PostgreSQL/FakeCloud tests exercise the pinned real provider binary for create, update, replacement, delete, alias collisions, equal names in distinct accounts/regions, explicit imports, saved-plan namespace changes and overlapping independent saved patches. Child-process termination after a successful create leaves a dispatched operation without a state row. Named log groups recover by provider identity; generated log names and secret ARNs require explicit operator identity evidence. This establishes safe quarantine, not automatic lost-create discovery. A separate HTTP barrier stops the provider between log-group creation and retention configuration, then terminates the owner/provider process group. The retained operation blocks another writer; recovery records the partial object as unconverged and a later apply finishes retention. Both explicit and generated names pass this schedule. These tests use FakeCloud service observations; they are not captures against a live AWS account or an independent I1 comparison adapter.
Where different types share a mutation domain (for example aggregate policy/attachment writers),
either define a versioned shared exclusion key plus its lock order and migration, or retain
conservative exclusion. The present key includes resource type; merely adding more entries to
resource_types cannot solve cross-type aliasing. Broad scopes may safely reduce concurrency;
silently guessing a narrow key is forbidden.
Compatibility and rollout. Recompute authenticated namespace facts when applying a saved plan under a new client; a changed account/region stops dispatch. A contract upgrade cannot give an unresolved old operation a smaller footprint. Keep interpreting its persisted locator until it resolves; incompatible versions fail closed. Backfill existing rows only with sufficient evidence and verified uniqueness, otherwise require a reviewed apply. Do not silently rekey identity leases while old writers remain able to dispatch; version the writer protocol when key semantics change.
Add machine-readable qualification metadata to contract registration: contract/key version, resource type, tested provider-version constraint and required namespace facts. Eligibility must check the actual configured provider binary, not just its declared source or version constraint. Persist that qualification in plan coverage and revalidate it at apply; unknown versions retain app X rather than inheriting a type's attestation. Ship this gate with an explicit qualification for existing supported contracts, then add resolvers and evidence one type at a time. Locator interpretation for recovering old operations remains separate from eligibility for new dispatch.
The first implementation slice uses IdentityQualification on ProviderIdentityContract and
coverage evidence version 2. The provider loader/resolver carries a ProviderBinarySelection
into the launched connection; its selected cache release, rather than the requested constraint,
qualifies the sender. Explicit binary overrides remain unqualified. This assumes a trusted
installation/cache and does not establish binary attestation. Portable row metadata retains the
profile and its fingerprint beside the locator. Saved-plan activation binds those facts, and the
pre-dispatch binder rejects changed running releases/profiles. Deferred coverage binds the profile
before configuration and checks actual eligibility when the client becomes available. Such a
failure may follow completed earlier rounds; it does not acquire broader coverage mid-run. These
mechanisms do not complete the per-type evidence or broader-coverage release gates below.
Release gate per type. Run I1's alias, lost-create, replacement and recovery cases; verify equal names in genuinely distinct namespaces, deliberately misleading provider aliases, namespace changes between plan/apply, import normalization, unknown/deferred names and plugin absence. Require a small real-service contract test where FakeCloud cannot establish namespace behavior; otherwise label the contract experimental and keep it out of automatic fine-grained eligibility. Plans report eligible types, exact fallback reasons and unresolved allocation scopes. Report coverage as the qualified list and the percentage of reference-app operations eligible for resource grants, never "supports AWS concurrency" based on one type.
I4 — Define the Coordination Domain Before Multi-State Writes
Current decision. One app state is the transaction/lease domain. Multiple stacks in that app already participate in it. Independent apps sharing a PostgreSQL schema do not gain cross-state read protection or canonical ownership by proximity. Preserve this contract in the next production release; do not implement multi-state apply by acquiring app leases one at a time. State transfer is a cutover protocol, not a multi-state execution coordinator.
Bounded extension to design and prototype. The first candidate is a single coordination domain on one PostgreSQL database, managed by one protocol version. It coordinates patches across named member states. Cross-database, cross-region distributed commit and arbitrary external state backends are excluded. The target is consistent cross-state admission, dependency ordering, retained holds and recoverable per-resource progress. It does not promise all-or-nothing cloud effects or atomic publication of a whole multi-resource apply. A whole-apply atomic-publication contract would need a separate design; this proposal cannot be advertised as equivalent to another product's "atomic multi-state transaction" without resolving that distinction.
Proposed protocol obligations:
- Persist domain membership, protocol version and a domain operation/run ID. Qualify logical row keys by state ID and lineage, but canonical object keys by physical namespace, not state ID. Every writer to a participating state, including an ordinary single-app apply and administration, must enter the same coordination protocol. An upgrade fences old writers; no opt-out bypass.
- Capture member snapshots in one database-consistent read, with a baseline/frontier vector rather than pretending independently sampled app counters form one snapshot. Pin each origin against retention. All cross-state references identify state, lineage, kind, key and consumed revision. A missing or migrated member, unknown origin or untracked external read stops admission.
- Acquire the entire cross-state read/write/identity/predicate set in one fair domain queue. Waiting holds nothing. Retained operations and ordinary single-state holders participate in conflict checks. Define and test one global SQL lock order before implementing acquisition or renewal.
- Validate every member's baseline and proof under that fixed grant before a single approval. A dependency consumes a producer only after its durable commit; reference cycles that require mutually unavailable values fail before mutations rather than being serialized arbitrarily.
- Record each provider operation under the domain run, with its state destination and full cross-state footprint. State rows, local frontier and a domain commit receipt publish in one SQL transaction per operation. A domain receipt orders committed publications; it is not a claim that all operations succeeded together. Multi-state readers use a consistent snapshot or a validated receipt/frontier vector, not an arbitrary combination of latest rows.
- Domain ownership loss is terminal for all members. Quarantine retains cross-state input, identity and predicate holds. Recovery uses explicit operation claims without reacquiring a conflicting all-state grant. Partial completion is reported by member and operation; retries must distinguish already committed effects from unresolved calls and remaining desired work.
- Administrative restore, retention, move, import and migration must honor domain consumers and identities. Membership removal/cutover is refused while live grants, pins or unresolved cross-state operations depend on the member. There is no force option that waives object safety.
Cross-state selection for a future production extension. Seed the explicitly requested members and expand both upstream dependencies and affected downstream consumers to a fixed point over desired and committed edges. One-hop discovery is insufficient for A → B → C or a consumer of two producers when only one producer was initially selected. A read of one output and an enumeration of all outputs carry different demands; whole-output reads need membership proofs, including the absence of outputs. Discovery is bounded by the authorized coordination domain. Report automatically included members and unavailable current intent before approval; never execute preserved intent using a stale checkout. An unauthorized/migrated member, incomplete dependency evidence or exhausted expansion budget refuses the cross-state plan. Only after the consistent member set and its baseline vector are complete may the coordinator acquire its single fixed grant. These are extra selection gates for the production decision, not features certified by the current two-state model.
Implementation seam and decision gate. Keep the domain coordinator as a module above per-state row persistence; prototype it with two state IDs and one database before extending public App/CLI interfaces. First write a bounded model for two states, two competing domain runs, an ordinary single-state writer, shared object aliases, crash/recovery and membership change. Replay its counterexamples against real PostgreSQL. Measure whether admission/renewal introduces an unacceptable domain-wide bottleneck, and publish that cost rather than assuming parallelism.
Production implementation requires an explicit follow-up decision recording the chosen publication semantics, new schema/writer versions, backward-compatibility strategy, authentication/authorization for every member, lock order, recovery procedure and CLI result shape. Acceptance includes races with single-state writers, stale member pins, partial grants, a lost response in one member, cross-state consumer-safe restore and duplicate ownership across member states. Until those pass, the supported alternative is to place cooperating stacks in one app graph.
The experimental implementation is under specs/graph-state/domain/. Its independent executable
model exhausts bounded action schedules and emits nine negative-control traces plus positive
progress witnesses. PostgreSQL tests replay those traces, enforce immutable origins/requests,
and exercise ordinary writers, aliases, claimed recovery, membership and SQL-wait publication.
The model bounds and current evidence are recorded in its README and the progress ledger.
A root-domain lock is intentionally a measurable initial bottleneck; provider calls never hold it.
The prototype derives readiness from a consistent domain vector. Persisting cross-state stale
flags instead would require advancing the affected members' publication metadata in the same
transaction. Production interfaces remain unchanged; the follow-up decision and cost gate above
still apply.
I5 — Matched End-to-End Performance and Safety Evidence
Contract. A speed claim names its workload, semantics and comparator version. Resource-level grants, skipped refresh, smaller payloads or fewer safety checks must not be silently traded for speed. A faster result that violates I1 or misses desired changes is a failed run, not a sample. The earlier Python validation result (10,000 inputs: about 1.84 s to 66 ms) does not measure full planning, provider work or another product.
The first end-to-end runner now lives in tests/performance/graph_end_to_end.py, with a native
worker in graph_e2e_native.py and a shared logical fixture/offline oracle under tests/helpers/.
It exercises full-refresh single-writer plans and saved applies against PostgreSQL/FakeCloud with
the identical AWS executable bytes. Raw service/state observations, command outcomes, source/build
metadata and failed/interrupted attempts are retained. Its explicit interface profile is a native
Python API worker versus Terraform CLI; this is not a planner-only or nf CLI rendering benchmark.
The broader matrix below remains required; consult the progress ledger for which captures
actually ran. Live Stategraph testing is now authorized through the demo qualification above;
comparative claims remain unverified until matched captures pass their independent checks.
The runner also accepts --native-scopes full affected. Each scope gets its own resettable
fixture/account, and saved apply uses the public format-17/18 loader. A capture must retain both
requested and actual scope, planning-fallback reasons, complete manifest size, selected closure,
artifact byte categories, provider RPC counts and SQL payload-column counts. A fallback to full
is a distinct result; it cannot be credited as affected execution. Counter instrumentation and
artifact-size encoding are included in command elapsed time. Complete metadata still scales
with the estate, and selected payload counts do not establish an overall O(k) planner.
--planning-work-metrics now observes real closure callbacks, selector roles/waves and original
payload-batch reuse. Its independent plain-data checker reconstructs capture boundaries, refetches,
expansion and returned input coverage; it rejects missing/truncated observations and incompatible
profiles. The observer records identities/counts, not resource values. Its overhead is included
and forms a separate regression cohort. The 189-test gate and 18-attempt N=8 isolated/diamond
provider smoke pass on source 0d019b23…; E15 retains raw evidence and exact hashes. Affected
planning records one round, three closure view requests and one/four original payloads, respectively.
Full planning and saved apply invoke no affected closure; zero calls do not mean zero total work.
Role visits are not scan loops, and batch reuse is not a consumer cache-hit count. SQL scans/edge
loops, larger measured work profiles and the broader I5 matrix remain open. Earlier branch and
transport reports reproduce byte for byte; no historical measurement is relabeled.
The offline checker must verify final service/state observations under the actual inspection
policy, as well as matching saved-plan/apply scope. In an unrelated-drift workload, affected
planning deliberately preserves drift outside the closure while full planning reconciles it.
Report that difference without a speed ratio. Stable-cloud timing pairs may compare the two
policies only with their different drift-inspection coverage stated. Record fallback frequency,
and do not pool mixed actual scopes into one uncertainty estimate. These rules are executable
in tests/helpers/graph_e2e_metrics.py and graph_e2e_report.py, with negative controls for
missing counters, incomplete manifests, hidden fallback and substituted saved-artifact scope.
The isolated one-resource-update full-planning baseline now has seven successful measured pairs at N = 100, 1,000 and 10,000. At 10,000, Netherframe's median plan-plus-saved-apply time is 60.0972 s versus Terraform's 43.2193 s; the paired median ratio is 1.3918, with a seeded bootstrap 95% interval of 1.3564–1.4240. Netherframe is slower in every measured pair at that size. This is an interface-specific result on the recorded shared host and FakeCloud, with AWS provider 6.66.0 and PostgreSQL 16. It establishes neither a universal speedup nor a Stategraph comparison. The frozen source, raw observations, distinct fixture-initialization profile and interrupted prior initialization remain in the evidence. The broader workload matrix remains pending.
A subsequent current-source capture (20261109T093952-c33fbde3) measures one isolated update at
N = 100 with full and affected native planning plus Terraform. All three setups, three warm-ups
and 21 measured samples pass independent service/state checks. Median plan-plus-saved-apply times
are 3.0217 s native full, 2.8456 s native affected and 7.4856 s Terraform full. The paired
affected/full native ratio is 0.9428 (seeded bootstrap 95% interval 0.9419–0.9504). This is a
preliminary stable-cloud, single-writer result under differing inspection policies, with no
prior matching captures for a regression verdict. It does not extend to live AWS or Stategraph.
In each measured native plan, affected mode refreshes and plans one resource versus 100 under
full planning, and loads two resource payload rows versus 100. But it issues 90 body SQL queries
versus 37 and reads 606 summaries plus 606 origin entries through six complete metadata views.
The complete manifest remains 101 entries in both modes. Compact artifact size is about 170 KB
affected versus 701 KB full; actual file sizes also differ because the full artifact is indented.
These results support selected-payload/RPC savings and expose the retained O(N) metadata cost.
See tests/performance/results/graph_end_to_end_scoped_report.json and the progress ledger for
raw captures, counter definitions, rejected initial telemetry and remaining scale gates.
The same-source N = 1,000 capture (20261109T095052-3f61abc0) also passes all 27 setup/sample
attempts. Medians are 6.7940 s native full, 4.8443 s native affected and 9.6649 s Terraform full.
The paired affected/full native ratio is 0.7123 (95% bootstrap interval 0.7069–0.7172).
Affected planning still fetches two resource payload rows and performs one managed refresh/plan,
but loads 6,006 summaries and 6,006 origin entries; its compact artifact grows to about 1.446 MB.
The fixed selected payload does not make complete metadata or total planning cost independent
of estate size. At that checkpoint, N = 10,000 affected mode and the broader matrix remained open.
The same-source N = 10,000 capture (20261109T101440-56588cdc) now passes all 27 setup/sample
attempts and independent offline rechecks. Medians are 70.0595 s native full, 26.8948 s
native affected and 42.0960 s Terraform full. The paired affected/native-full ratio is
0.3841 (95% bootstrap interval 0.3839–0.3866); affected/Terraform is 0.6385
(0.6356–0.6416). Native full/Terraform is 1.6593 (1.6558–1.6626): full planning
remains slower in every pair. All seven affected samples remain affected without fallback.
Affected plan/apply fetch 2/12 resource payload rows versus 10,000/10,010 full. Planning still loads 60,006 summaries and 60,006 origin entries, and its compact proof section reaches about 11.295 MB. The complete manifest has 10,001 entries; compact total artifacts are about 14.236 MB affected and 68.664 MB full. Native setup/normalization costs about 1,840 seconds per policy, versus 182.40 seconds Terraform, and measured samples additionally require independently checked resets. Those costs remain separately recorded. This closes the one-change isolated-estate size series for this source/settings cohort, not the wider matrix below, O(k) total cost, stable tail latency, live-AWS behavior or Stategraph comparisons. The combined scoped report has nine comparisons, no failures/incomplete attempts and insufficient matching history for regression verdicts. The run README retains commands, raw hashes, environment and metric definitions.
After the payload-cache change, four-resource diamond and isolated correctness smokes
(20261109T132410-fa630417, 20261109T132715-9932ece5) pass all eighteen setup/sample attempts.
The diamond requests explicitly fall back to full because their configuration/context lacks
qualification; they do not demonstrate affected diamond planning. The isolated requests remain
affected and fetch one resource payload row during planning, while still reading six complete
metadata views. Each adapter has only one measured repetition, so these are not steady-state or
regression results. The isolated affected sample is slower than its full sample. The separate
graph_end_to_end_payload_cache_smoke_report.json retains actual scopes and fallback rates;
the earlier size-series results are unchanged.
With built-in expression qualification, capture 20261109T134957-0729703a measures chain, fork
and diamond patches at N = 100. All 81 setup/warm-up/sample attempts pass, and offline verification
rechecks all raw artifacts. Each topology consists of 25 independent four-resource components;
one root edit propagates to three consumers. These are not 100-node chains or unbounded fanout.
All 21 measured affected requests remain affected, fetching four payload rows and making four
managed refresh/planning calls versus 100 under full planning. Six complete metadata reads still
load 606 summaries/origin entries; affected planning issues 89 body SQL queries versus 37 full.
| Topology | Native full / affected median | Terraform full median | Affected/full paired ratio (95% bootstrap interval) |
|---|---|---|---|
| Chain | 3.2030 / 3.1978 s | 7.4919 s | 1.0007 (0.9977–1.0114) |
| Fork | 3.2804 / 3.2265 s | 7.5695 s | 0.9856 (0.9763–1.0100) |
| Diamond | 3.5086 / 3.2062 s | 7.4876 s | 0.9148 (0.9005–0.9176) |
Seven repetitions per adapter establish a preliminary observation, not stable tail latency.
Chain/fork intervals include one, so reduced RPC/payload work does not establish a latency gain
there. Full diamond apply makes 11–20 backend commit calls, including metadata work, while performing four provider
mutations in every repetition; the raw report retains its variable SQL/payload cost. No
planner-only causal speed claim follows. Native setup costs 9.11–9.56 s and Terraform 14.41–14.58 s;
each measured patch also has separately recorded resets. The frozen source digest, counter limits,
artifact sizes, all paired ratios and commands are in the capture README and
graph_end_to_end_derived_report.json. This is a separate source cohort from the earlier size
series. Wider workload/size/contention/failure gates remain open; live Stategraph timings stay
unverified. E17–E22 qualify only their stated correctness scopes.
The same frozen Python source also measures ten edited roots in capture
20261109T143216-06d98b34: N = 100 isolated resources and the same bounded chain/fork/diamond
components. The latter patches produce 40 resource updates, not ten. All 108 attempts pass;
the frozen and main offline reports agree on twelve distributions/comparisons with no failures
or incomplete attempts. All 28 measured affected requests remain affected.
| Topology | Native full / affected median | Terraform full median | Affected/full paired ratio (95% bootstrap interval) |
|---|---|---|---|
| Isolated | 3.5839 / 3.5911 s | 7.4429 s | 0.9996 (0.9982–1.0067) |
| Chain | 5.4415 / 6.0113 s | 7.6392 s | 1.0873 (1.0862–1.1295) |
| Fork | 5.3166 / 5.8108 s | 7.6334 s | 1.0949 (1.0929–1.0985) |
| Diamond | 5.5316 / 6.0395 s | 7.6707 s | 1.0893 (1.0811–1.0984) |
Affected execution is slower than native full in every dependent-fixture pair; those intervals exclude one. The isolated interval includes one. Affected planning still reduces payload reads and managed refresh/planning calls from 100 to 10 isolated or 40 dependent resources, but reads six complete metadata views. Its dependent compact artifacts are about 1.15–1.18 MB versus 1.19–1.31 MB full, so selected payloads yield only modest total compact-artifact savings here. Saved apply retains substantial SQL/payload work. Full diamond's commit-call count varies from 46 to 50 versus 40 affected; both perform 40 provider mutations. These are method-call counters, not counts of published rows. No planner-only causal attribution follows from the timing data.
Native setup costs 8.37–9.73 s and Terraform 14.36–14.96 s, with separately recorded resets.
The exact source/environment, counters, artifact sizes, raw hashes, commands and all paired ratios
are in the run README and graph_end_to_end_patch10_report.json. This extends the N = 100
small-patch matrix; it does not establish a universal affected-mode speedup, equal drift coverage,
stable p95 or a regression verdict. Larger dependent estates and the other workload families
below remain open. Live Stategraph timing comparisons remain unverified; the correctness
observations in E17–E22 do not supply performance samples.
After the index-integrity/startup fix, 20261109T153248-1d7c2706 passes an isolated/diamond
N = 100 ten-root smoke on frozen source 6f372cc7…: 18 setup/warm-up/measured attempts,
with one measured sample per adapter/topology. Both affected samples retain their scope and
load 10/40 planning payloads versus 100 full. Saved affected apply returns 130/760 payload rows
and issues 746/2,846 SQL queries; six planning metadata views still read 606 summaries/origins.
All actual service/state checks and raw-file hashes pass, and frozen/main offline reports agree.
The raw observations and graph_end_to_end_index_smoke_report.json establish this bounded
correctness/telemetry check, not a latency comparison: the seven-repetition minimum is unmet.
The subsequent repeated capture below measures the same frozen source; the broader matrix
remains open.
Capture 20261109T154230-1a4d994a completes the N = 1,000 ten-root isolated/chain/fork/diamond
cohort on that source: 108 passed attempts, twelve distributions/comparisons and no failed
or incomplete attempts. All raw files and hashes are imported; frozen/main offline reports
are byte-identical. Every measured affected request stays affected. Ten dependent root edits
produce 40 updates across bounded four-resource components.
| Topology | Native full / affected median | Terraform full median | Affected/full paired ratio (95% bootstrap interval) |
|---|---|---|---|
| Isolated | 7.4890 / 5.9304 s | 9.7596 s | 0.7899 (0.7876–0.7918) |
| Chain | 9.4474 / 9.3641 s | 9.7368 s | 0.9899 (0.9893–0.9941) |
| Fork | 9.7224 / 9.5451 s | 9.9658 s | 0.9793 (0.9663–0.9857) |
| Diamond | 12.5151 / 9.8517 s | 9.9312 s | 0.7917 (0.7867–0.8118) |
There are seven samples per adapter/topology. The chain difference is small and one chain pair is slower under affected planning. Native full is slower than Terraform in every diamond pair, with ratio 1.2616 (1.2519–1.2663); the affected/Terraform diamond interval 0.9865–1.0212 includes parity. Neither this result nor the earlier N=100 negative result permits a blanket speed claim. These are stable-cloud, interface-specific observations with different drift-inspection policies, not a live-AWS, p95 or Stategraph comparison. Regression history remains insufficient.
Affected planning fetches 10/40 payloads and makes 10/40 managed read/plan RPCs instead of 1,000,
but still issues 89 SQL queries versus 37 full and reads six complete metadata views containing
6,006 summaries/origins. Its compact plans cost 1.658–2.876 MB versus 6.973–9.094 MB full.
Saved affected apply still returns 130/790/680/760 payload rows by topology, reads two complete
metadata views and incurs fixed-grant/refencing work. Full diamond makes 151–173 backend commit
calls versus 40 affected while both perform 40 provider mutations; those calls include metadata
work and are not published-row counts. The raw report preserves the variation without a
planner-only causal attribution. Native setup costs 62.50–78.68 s versus 19.49–19.82 s Terraform;
resets remain separately recorded. Exact bytes, counters, source/environment and commands are in
the run README and graph_end_to_end_index_scale10_report.json.
The added database-latency harness is now functionally qualified. --database-latency-ms 0
uses the same Toxiproxy path as --database-latency-ms 10 (10 ms in each direction, no jitter,
toxicity 1); omission preserves the direct route. It records the actual image/server version,
query calibration, proxy settings before/after each attempt and worker database endpoints.
Version-3 offline checks bind those observations and the profile fingerprint into matching
semantics and refuse downgraded/mismatched captures. Zero-delay and delayed regression cohorts
remain separate. The proxy API/database ports are published only on host loopback.
The qualification passes 104 unit checks and two real PostgreSQL tests that disable the proxy,
observe connection failure, re-enable it and verify queries and cleanup. Initial failures are
retained: the server normalized the wildcard listener to [::]:8666; the corrected checker
accepts the two observed wildcard forms on the fixed port without relaxing route/toxic checks.
Actual-provider smokes at N=4 then pass all 18 setup/warm-up/sample attempts across native full,
native affected and Terraform, with independent service/state and offline v3 verification.
Each cell has only one measured sample, so these establish routing/correctness, not speed.
Evidence and exact source identities are in specs/graph-state/qualification/2026-11-09-i5-transport/.
Repeated transport measurements now complete the N=100 isolated one-update profile:
20261109T165249-39888368 (zero directional delay) and 20261109T165844-fde6b9f3
(10 ms each direction) pass 54 attempts, including seven measured samples per adapter/profile.
Both use frozen revision 417b8f20, source 13db5afe…, with no overlapping tests, builds or
other benchmarks. All 58 raw/result artifacts were copied and hash-checked; the main reporter
reproduces both frozen reports byte for byte. This extends E13 beyond the earlier smoke.
| Added delay per direction | Native full / affected median | Terraform median | Affected/full paired ratio (95% bootstrap interval) |
|---|---|---|---|
| 0 ms | 3.1962 / 3.0985 s | 7.7709 s | 0.9704 (0.9581–0.9709) |
| 10 ms | 12.2183 / 14.6302 s | 8.4181 s | 1.1910 (1.1875–1.1967) |
With added delay, affected is slower than full in every pair, and both native policies are slower than Terraform in every pair: full/Terraform 1.4663 (1.4403–1.4820) and affected/Terraform 1.7386 (1.7277–1.7660). At zero delay those ratios are 0.4118 (0.4094–0.4146) and 0.3978 (0.3945–0.4009). These are within-profile paired comparisons; the two delay profiles ran sequentially, not as randomized paired network experiments.
Affected still reads one planning payload and makes one managed read/plan RPC instead of 100,
but issues 89 plan and 197 saved-apply body queries versus 37 and 156 full. Its six planning
metadata views contain 606 summaries/origins; saved apply reads two more views and 13 payload
rows versus 110 full. Smaller payloads do not remove round trips or establish end-to-end O(k).
Compact plans are about 170 kB affected versus 701 kB full; both retain the complete 101-entry
manifest. Native setup rises from 9.28–9.88 s in the zero-delay profile to 148.26–149.69 s in
the delayed profile; Terraform setup is 15.08/16.00 s. Reset costs are separately recorded.
The exact counters and unavailable metrics remain in measured-verification.json and the raw
reports. These observations do not isolate a planner-only cause, establish WAN behavior, stable
p95, a regression-history verdict, or any Stategraph comparison. The wider I5 matrix stays open.
The end-to-end runner now also supports --workloads stale-branch. It observes an origin,
pins it for native execution, publicly applies an independent root edit and observes that
publication in cloud and state. It then plans and saved-applies a separate root edit while
retaining the older configuration for the first writer's component. Native literal/reference
witnesses and rendered Terraform descriptions establish the actual configuration; a separate
plain-data checker reconstructs both branch outcomes and requires native baseline retention
through saved apply. Branch preparation cost is recorded separately. A single-root fanout is
ineligible because this schedule needs independent edits.
Capability smoke 20261109T171626-b73144b0 passes 18 attempts on source 3cbe9009…:
N=8 isolated and two four-resource diamonds, three adapters, setup/warm-up/one sample per cell.
Native full/affected preserve both edits, including propagated descendant values. Terraform's
supported full-configuration path reconciles the newer independent component to the stale
configuration. Native plans update 1/4 resources, Terraform 2/8; raw final values verify those
outcomes. All requested affected scopes are retained. The six-distribution offline report passes;
45 new branch controls pass within the 149-case harness suite. Exact source and 21 artifact hashes
are in specs/graph-state/qualification/2026-11-09-i5-branch/.
The reporter emits no native/Terraform speed ratio for this workload, even if final values agree,
because retained-origin and full-configuration policies have different contracts. Native
full/affected cost comparisons still require seven matched samples; this smoke has only one.
Sequential publication does not establish concurrent-call or conflicting-edit safety; I1 retains
those gates. The repeated N=100 series now passes 108 attempts across all four topologies on
frozen 0aad8c08…, with the same source 3cbe9009…: warm-up plus seven repetitions per adapter.
All 110 artifacts are hash-checked and the frozen/main reports agree. Both native policies preserve
the newer edit; every Terraform sample reconciles it, so all eight cross-contract comparisons omit
a speed ratio. Native affected/full ratios and 95% bootstrap intervals are isolated 0.9577
(0.9486–0.9678), chain 1.0053 (0.9987–1.0210), fork 1.0094 (1.0001–1.0159), diamond 0.9072
(0.8968–0.9323). Chain includes parity and fork is slower. Preparation/reset remain separate;
seven samples do not establish p95 or regression history. Other sizes/workloads remain open,
and no Stategraph behavior is inferred from this native/Terraform capture.
Runtime-matched regression cohorts (E26). The offline reporter now includes Python version,
platform, CPU count and PostgreSQL image identity in its existing fixture/adapter/host/settings
match. Missing environment facts keep a capture out of regression history; source revisions may
differ intentionally. All 136 benchmark controls pass. A frozen-source N=8 smoke across the four
component topologies passes 36 setup/warm-up/sample attempts, with independent service/state
replay. This qualifies the harness, not repeated latency. The prepared N=10,000 one/ten-root
matrix still needs its complete captures and uncertainty reports. Source/build identity and the
exact commands are in specs/graph-state/qualification/2026-11-09-i5-large/.
The large series was interrupted for immediate performance diagnosis after 57 passed attempts (nine setups, six warm-ups, 42 measured); its raw artifacts and incomplete report are retained. The N=10,000 chain setup exposed a 1,606-second native normalization pass with zero provider apply calls and 10,000 row commits. Each commit transferred the complete grant and checked the full mapping twice in SQL. Schema 33 moves exact validation to grant installation and uses a database-maintained invalidation record at both mutation fences; footprint reads select only demanded keys and ancestors. Lease changes, missing certificates and certificate forgery fail closed, including invalidation during SQL waits. The upgrade validates existing grants rather than trusting them. A 1,000-resource diagnostic falls from 33.96 to 20.35 seconds with the same correctness checks. The bounded N=10,000 diagnostic completes normalization in 350.90 seconds (5.85 minutes), with all 10,000 commits, zero provider apply calls and matching final state/service observations. The historical 1,605.79-second pass and this instrumented diagnostic are single observations, not a repeated benchmark cell or comparative Stategraph claim. The full matrix remains stopped. The backend/admission/completion suite passes 528 tests, with two skipped.
Bounded reconciliation costs (E31). Run 20261110T061916-fd3d72b7 on frozen source
a9e27ec3… completes N=100 isolated no-op, one-replacement, one-deletion and output-only
workloads with a warm-up and seven samples per native full/affected and Terraform adapter.
All 108 attempts in these workloads independently replay; all 28 affected measurements remain
affected. Their paired affected/full ratios are 0.9441 (0.9372–0.9485), 0.9565
(0.9444–0.9648), 0.9582 (0.9451–0.9625) and 0.9498 (0.9368–0.9507), respectively.
Replacement/deletion preserve exact expected membership; output-only work changes the output
without changing resources. Affected no-op/output plans read no resource payloads, but still
read six complete metadata views and configure/read provider data sources.
The six-workload batch was stopped at 23 minutes before its 25-minute cap; three provider-setting
setups and one affected warm-up also verify, but its next warm-up is interrupted and unrelated
drift is unstarted. Original incomplete status and every started/completed record remain. The
frozen/main reports match and 165 harness tests pass. Only the four complete workload cells
qualify these preliminary measurements; no p95, general size/topology, regression-history or
Stategraph speed claim follows. The full large matrix remains stopped. Exact sources, commands,
counts and bounds are in specs/graph-state/qualification/2026-11-10-i5-reconciliation/README.md.
Provider-setting and drift costs (E32). A fresh two-workload run, 20261110T065039-2dba6181,
completes the N=100 families left unmeasured by E31, on the same frozen source a9e27ec3….
All 54 setup/warm-up/seven-repetition attempts independently replay; frozen/main reports match
and the process exits 0 within 15 minutes. A default-tag change correctly selects all 100
resources in affected mode and updates every service/state tag. Both native policies refresh
and apply 100 resources, while affected retains six complete metadata views and 89 plan SQL
queries versus 37 full. Its affected/full ratio is 1.1868 (1.1738–1.1894), and
affected/Terraform is 1.1640 (1.1597–1.1701): affected is slower in every pair.
For unrelated drift, affected selects one edited resource and preserves the uninspected external
change; full policies reconcile that change too. The report excludes all affected/full and
affected/Terraform speed pairs, and retains only the matched full/full comparison, 0.4082
(0.4072–0.4109). The differences in final cloud/state observations are required by the declared
inspection policy, not ignored by the checker. All requested affected samples remain affected.
The unchanged harness retains E31's 165 passing tests. Exact artifacts and limits are in
specs/graph-state/qualification/2026-11-10-i5-provider-drift/README.md. Wider matrix/metric
gates remain open, and the large benchmark stays stopped.
Concrete fanout 100 (E33). Run 20261110T071546-1bfba75a uses one producer and
100 consumers, hence 101 total resources. One root edit changes all 101 descriptions. All 27
setup/warm-up/seven-sample attempts independently replay on the same a9e27ec3… source as
E31/E32. Final cloud/state membership and propagated values agree; no native operation remains
unresolved. Every affected measurement stays affected and selects all 101 resources.
Median construction/plan/saved-apply times are 8.2479 s native full, 9.8713 s affected and
7.7124 s Terraform. Paired affected/full is 1.1996 (1.1890–1.2087), affected/Terraform
1.2789 (1.2728–1.2858), and full/Terraform 1.0681 (1.0512–1.0780); each numerator is slower
in every pair. Both native policies read/refresh/plan/apply all 101 resources, while affected
also reads six complete metadata views with 612 summaries/origins and makes 89 plan body SQL
queries versus 37 full. This is a concrete breadth cost, not an adversarial commit-order trace
or the larger/shared-value/scoped-input matrix. Frozen/main reports match, completion is observed
before nine minutes, and the large matrix remains stopped. Evidence is in
specs/graph-state/qualification/2026-11-10-i5-fanout100/README.md.
Concrete fanout 1,000 now has seven samples per adapter on the same frozen source (E34,
20261110T073744-27042145): one producer plus 1,000 consumers, with all 27 attempts independently
replayed. Median construction/plan/saved-apply costs are 60.4623 s native full, 91.3719 s native
affected and 12.1646 s Terraform. Affected/full is 1.5131 (95% interval 1.5017–1.5221),
affected/Terraform 7.5229 (7.4944–7.5280), full/Terraform 4.9545 (4.9423–5.0131); every numerator
is slower in every pair. Affected selects all 1,001 resources without fallback. Six planning metadata
views, 89 plan queries and 68,238 saved-apply queries remain, versus 37/68,191 queries under full.
All final membership/values agree, native rows are ready and unresolved operations are zero.
The process exits 0 in about 43 minutes under a 90-minute cap; frozen/current reports match.
See specs/graph-state/qualification/2026-11-10-i5-fanout1000/README.md. Fanout 10,000 and wider
scope/value/failure/writer gates remain open. This capture predates the new iterator instrumentation.
The saved-plan loading cost has a subsequent isolated fix (E36). Format-18 validation rebuilt
the whole manifest lookup and all planning-context hashes per executable node, producing N²
work. It now derives both maps once per decoded manifest and still verifies every node against
them; no shared cache, evidence check or artifact format changes. A structural regression fails
before the fix, and all 188 artifact/candidate/closure/selection tests pass afterward. Seven paired
offline loads of identical synthetic 1,001-resource artifacts improve median loading from
5.885 s to 0.676 s (updated/original paired median 0.1152), with complete encoded-result equality.
Source, fixtures, individual samples and the separate profile are retained in
specs/graph-state/qualification/2026-11-10-i5-artifact-validation/. This does not replace E34's
end-to-end measurements or qualify a new full-apply ratio. Its roughly 68,000 SQL queries per
native apply remain a separate cost to diagnose. The original large matrix remains stopped.
E37 isolates one of those database costs: repeated decompression of the complete admitted-plan
proof during target/action checks. Schema 34 stores exact write/auxiliary/action projections as
PostgreSQL-generated columns. They cannot be independently edited and follow admission changes;
the complete proof, permission semantics and ownership fences remain unchanged. A public one-row
commit in a 4,096-resource admission fails its SQL buffer budget before the fix and passes after.
All 547 backend/admission/completion/lifecycle tests pass, with two skips. Thirty isolated cases
retain seven query pairs and actual SQL plans before/after ANALYZE; at 10,000 resources, an
analyzed last-target action check changes from 9.347 to 1.618 ms, with buffers 439 to 19.
The generated fields add 93,582 stored bytes to that profile's 1,709,418-byte original admission.
Upgrade rewrites/backfills the runs table under a table lock; its deployment cost depends on
retained history. Write-set scans and commit ordering remain separate costs. Three current-source
1,001-resource provider smoke attempts pass independent state/service checks; the single measured
plan/apply takes 72.29 s, without an end-to-end speed claim. Source, raw attempts, query plans,
samples and rejected query-rewrite evidence are retained in
specs/graph-state/qualification/2026-11-10-i5-admission-projections/.
E38 completes the three N=1,000 one-root chain/fork/diamond cells on E37 source c4264025….
All 81 setup/warm-up/measured attempts pass independent replay, with seven repetitions per
adapter/topology. The batch exits 0 in about 36 minutes under a one-hour cap. Four-resource
components propagate one root edit into four writes; every native final state has 1,000 ready
objects and no unresolved operations. Affected stays affected and reads/plans four resources
versus 1,000 full. Median plan/apply times are 6.36/6.30/6.67 s affected, 7.44/7.39/9.73 s full
and 9.70/9.72/9.74 s Terraform for chain/fork/diamond. Affected/full paired ratios are
0.8529 (95% interval 0.8482–0.8618), 0.8485 (0.8422–0.8552) and 0.6860 (0.6761–0.6909).
Full/Terraform diamond includes parity (0.9918–1.0110). These stable-service observations use
separate FakeCloud accounts, the same provider binary and PostgreSQL server; affected refresh
still has narrower drift coverage. They do not pool historical sources or establish a paired
before/after optimization result, p95 or Stategraph speed claim. Exact source/raw hashes and the
full nine-comparison report are in specs/graph-state/qualification/2026-11-10-i5-one-root1000/.
E39 bounds future benchmark work through --max-run-seconds (default 3,600; at most 86,400).
The budget covers startup, setup, reset and verification as well as timed commands. After one
complete measured round, an estimate using each adapter's maximum full-attempt cost can stop
before further repetitions would exceed the remaining budget. Warm-ups and other fixture sizes/
topologies are not extrapolated. A deadline cancels current controller work, kills a running
command group, retains available partial output/failure evidence, writes a stop receipt and
exits 124. The reporter retains completed samples while marking the batch incomplete, including
stops before fixture startup. Teardown follows cancellation; an outer supervisor bounds an
unresponsive container runtime. Five regressions fail before these runner/reporter changes;
146 related tests pass afterward. Replaying E38 produces identical report bytes. Evidence is in
specs/graph-state/qualification/2026-11-10-i5-run-budget/; this harness control does not change
production provider timeouts or qualify more measured matrix cells. The full 10,000 matrix stays
stopped.
E40 qualifies an optional hosted adapter using --adapters stategraph and a private
--stategraph-config file. The supported TF_CMD boundary follows -chdir, verifies the installed
AWS binary, sets per-Terraform parallelism and records overlapping invocation intervals. Independent
checks bind those observations to measured command windows, owned state, immutable saved-plan
bytes and committed transaction receipts. Hosted RPC/SQL, closure/fallback and grant counters stay
unavailable; provider command counts are not provider RPC counts. Failed/uncertain applies prevent
further mutation of that fixture. Raw CLI output is hashed and credentials remain outside artifacts.
The first eight-resource smoke exposes an unsupported transaction-list option and a missing receipt
after no-op normalization. Its source and failed samples remain archived. Three regressions also
cover counting failed warm-ups; all 173 related tests pass after corrections. A fresh corrected
smoke exits 0 with setup/warm-up/measured attempts independently replayed on source f071cf37….
Actual CLI/server 3.2.28, provider hashes, explicit parallelism, service/state equality and owned
committed receipts are observed. The one measured sample is not a steady-state matrix cell.
Evidence: specs/graph-state/qualification/2026-11-10-i5-hosted-adapter/. The hosted service's
placement and unavailable database sizing differ from local PostgreSQL. Its distributions remain
separate; the reporter excludes hosted/local engine speed ratios and refuses to use missing server
facts as matched regression history. Broader hosted workloads and timing samples remain open.
E41 completes one repeated hosted timing cell on the same source f071cf37…: 100 isolated
resources, one edit/write, seven measured repetitions per adapter plus setup/warm-up. All 36
attempts and independent replay pass in 14.06 minutes under a twenty-minute sampling cap.
Plan/apply medians are 3.019 s native full, 2.897 s native affected, 7.519 s Terraform/local and
22.125 s Stategraph/hosted. These are separate deployment distributions; hosted/local engine
ratios remain excluded. Hosted reset and complete-attempt medians are 34.198 s and 62.497 s,
which demonstrates why the controller must budget more than the timed mutation. Native
full/affected complete attempts take 7.566/7.447 s; Terraform takes 24.880 s. Every final
100-object state matches service values/descriptions and outputs; native unresolved operations
are zero, affected reads one versus 100 full, and each native measured apply mutates one object.
Owned committed receipts, unchanged saved bytes, provider hashes and actual invocation windows
are verified for hosted attempts. All 353 source files and both CLI executables remain unchanged.
The source archive, raw evidence, exact local paired intervals and exclusions are in
specs/graph-state/qualification/2026-11-10-i5-hosted100/. Seven samples qualify no stable p95;
broader workloads, topology/size/concurrency and fault costs remain open. The full 10,000 matrix
remains stopped.
E42 adds the public native writer benchmark at tests/performance/graph_writers.py, with
immutable disjoint/shared-reader/conflicting/changing-input profiles for 1/2/4/8 actors. Each
actor has a separate process/backend session, a common start gate and the same retained origin;
all plans precede apply. Zero-wait resource admission and no saved-plan retry are explicit.
Actual provider-call/admission intervals, executable hashes, saved-byte receipts, cohort CPU/RSS,
service/state and exact SSM version increments support independent replay. Unexpected errors
poison the fixture; refused actors must send no mutation. Archived plan text is redacted with
its own digest; original-byte hashes bind the live before/after witness. Different accepted
outcomes are excluded from paired ratios; overlap is measured, never inferred from startup.
The 148-test suite and N=10/two-writer smoke pass: 24 attempts across all four families and
both scopes, independently replayed in 165.62 seconds under a ten-minute cap. Provider calls
remain serial across actors in this smoke. One measured sample qualifies no steady-state cell;
actual 1/4/8-actor captures, repeated N=100 costs and separately qualified Terraform/hosted writer
contracts remain required. Evidence: specs/graph-state/qualification/2026-11-10-i5-writers/.
E43 completes the native 1/2-actor N=100 timing matrix on E42's unchanged source: all 144
setup/warm-up/measured attempts pass, with seven measured samples in each of 16 cells. Sampling
finishes in 23.55 minutes within its thirty-minute cap; independent replay has no failed or
incomplete attempts. Compatible actors preserve both edits, and conflicting/changing-input
refusals send no mutation. Final service/state and exact SSM version increments agree. Raw
provider-call overlap is measured separately from concurrent process startup. Different accepted
writer outcomes are excluded from full/affected ratios, and seven matching pairs are required.
Evidence, distributions, intervals and exclusions are in
specs/graph-state/qualification/2026-11-10-i5-writers100/. This closes only the stated native
1/2-writer cells; actual 4/8-writer and separately qualified Terraform/hosted writer measurements
remain open. The full 10,000-resource matrix stays stopped.
E44's four/eight-writer N=10 smoke terminates after 366.77 seconds with 44 passed, two failed and two unstarted attempts. Full-scope changing-input consumers can be refused behind an older queued producer, leaving an accepted consumer subset. Final service/state matches that subset, but the declared all-consumers outcome check remains failed. No oracle relaxation or repeated timing qualification follows.
E45 requires both timing runners to stop the whole batch after preserving the first
failed setup, warm-up or measured attempt. Store raw evidence before cleanup, record
the failed attempt in run_stopped, and exit 1; deadline/forecast cancellation remains
exit 124. Expected contention refusals already validated by the cohort oracle are
not failed attempts. All 155 related tests pass. E44 spent 212.76 attempt-seconds
after its first failure; this continuation is now prevented. E43 also shows resets
consume 53.8% of complete measured-attempt time. Budget setup, resets and verification,
not just plan/apply. Per-invocation limits do not authorize an unbounded sequence of
captures: the wider campaign is paused under the user's one-day stop instruction.
Evidence and limitations are in specs/graph-state/qualification/2026-11-10-i5-fail-fast/
and specs/graph-state/qualification/2026-11-10-i5-writers48-smoke/.
Zero-wait writer contract correction (E60). E44's consumer-subset failures reproduce because its checker requires every consumer to succeed. The fair queue instead permits an older producer to block younger consumers while an earlier consumer holds its shared input. With zero-wait admission and no retries, only a consumer subset may succeed. The native queue regression passes, and the engine cancels a timed-out request before returning. Both original failures have exact service/state values and version increments for their actual accepted subsets.
Capture version 2 allows this outcome only with distinct observed admission owners, complete owner-bound queue diagnostics, the expected shared-input conflict and overlapping producer/consumer admission intervals. It still rejects a producer and consumer succeeding together, no successful actors, refused actors mutating, unexpected errors and incorrect state/service effects. Partial outcomes and their refused actors are explicit; they do not imply completion of every desired change. Different accepted sets remain excluded from ratios. Version-1 semantics, including E44's failed verdicts and the exact E43/E44 reports, remain unchanged.
All 108 writer/budget units and the PostgreSQL queue regression pass. A fresh N=10
four/eight-writer full/affected smoke passes twelve setup/warm-up/sample attempts
in about 96 seconds under a five-minute limit. The four-writer full sample observes
one accepted consumer and two younger consumers refused behind the producer;
eight-writer captures exercise producer-only and all-consumer outcomes. One sample
per cell establishes no repeated timing claim. Production policy is unchanged;
the wider campaign stays stopped. Evidence and exact bounds:
specs/graph-state/qualification/2026-11-10-i5-fair-queue/.
E46 follows the user's explicit request for a focused hosted 10,000-resource check.
Stategraph CLI/server 3.2.28 takes 148.48 seconds to plan initial creation; its apply
hits the 900-second command limit. The batch stops after 17.98 minutes without retries.
No unchanged-state or small-update sample is reached. Process counters show substantial
local Terraform work, including 44.66 GB of cumulative process writes, without proving
that every byte is a state-file write. All local processes terminate; the owned cloud
transaction is then explicitly aborted. This failed setup neither qualifies a timing
cell nor establishes Stategraph's equivalent normalization latency. Raw evidence and
scope limits: specs/graph-state/qualification/2026-11-10-i5-hosted10000/.
Harness seams. Keep tests/performance/graph_python.py, graph_postgresql.py and
graph_workloads.py as separate layers. Add an end-to-end runner under tests/performance/ that
constructs equivalent Netherframe and Terraform fixtures from the same logical graph and initial
cloud state. A Stategraph adapter uses its supported CLI/server and reports edition, CLI/server
builds and observable settings. It is an optional external prerequisite, not an assumed local
service or an undocumented server patch. Plain Terraform/OpenTofu is a separate baseline.
The optional planning-work observer has a qualified version-2 implementation (E35) in
specs/graph-state/qualification/2026-11-10-i5-selection-iterations/. It records actual yields
from named complete-metadata and worklist iterators, including owners, repeated visits and
completion, rather than deriving edge-work counts from selected roles. Its independent checker
reconstructs adjacency from recorded old/new/discovered edges and checks visits against that
adjacency and returned waves/roles. Callback/item budgets invalidate truncated measurements
without truncating planning. Version-1 archives retain unavailable iteration counters, and
version 2 has its own instrumentation cohort. Other Python loops, SQL execution plans/waits and
consumer-cache hits remain unobserved; this implementation alone does not complete their gates.
The 348-test suite and all 18 actual-provider smoke attempts pass independent checks on source
509bd0de…. For N=8, the isolated/diamond affected plans observe 222/368 metadata iterations,
6/33 worklist node visits and 0/32 edge visits across three selector calls. Distinct visited nodes
are 1/4 and edges 0/5 per captured view. These are named actual visits, not total planner work or
SQL loops. A separate disabled-observer diagnostic produces identical selections and timing
intervals including parity. One smoke repetition per cell does not qualify performance comparisons.
Bounded known-result outage cost (E66). One warm-up plus seven measured samples per app-X/resource-grant profile completes 16 independently checked attempts in 208.579 seconds, with no failed/incomplete attempts in that final series. Median instrumented explicit recovery takes 43.66/42.94 ms (observed ranges 38.44–50.21/40.63–46.90 ms), separate from the injected 5.25-second outage. Each recovery uses 53 body SQL requests, four completed write transactions and four read transactions, and publishes once without repeating the provider mutation. The original application reconnects first; the measured explicit recoverer uses the direct local database route.
Raw phase/process/SQL/RPC samples, source and executable hashes, warm-ups, command
receipts, separately labeled earlier fixture failures and an independent report are
in specs/graph-state/qualification/2026-11-13-i5-database-outage/. Instrumentation
and fixture startup are included in whole-command costs; observer polling is
separated from application/recovery SQL. A retained preliminary series mixed 16
commit-observer requests into its 69-request recovery counter; the final series fixes
attribution without changing production. Admission probes measure refusal-to-success
observations, not exact retained-hold lifetime. Server CPU/RSS, wait-event durations
and loaded-row/byte costs remain unmeasured. This supplies one repeated native
failure-cost profile, without a speedup, p95 or hosted-comparison claim; runner loss,
unknown outcomes, server failover and the wider matrix remain open.
A caller queued through recovery (E108). The outage fixture now has an optional independent direct client that submits one app-X ticket after expiry and the hold probes, then polls every 10 ms until recovery permits its grant. Each grant transaction observes its installed phase and the retained operation while still holding the app-row lock. Success requires the exact operation already committed under the actual recoverer; a later successful snapshot cannot repair premature admission. The caller then observes the exact ready row and releases its grant. These reads are observations, not changes to the production admission predicate.
One warm-up and seven measured attempts for each original app/resource ownership policy all pass: 16 attempts in 245.65 seconds. Median enqueue-to-grant times are 515.77/414.45 ms; last-refusal/first-success brackets are 50.55/46.32 ms. Contender traffic is separate: median 319/308 body SQL requests, including one extra receipt read per poll and post-grant inspection/cleanup. Recovery retains 53 requests and one publication in every sample, with no repeated provider mutation. The polling client's interference is included; these observations do not establish a speedup against the older non-queued fixture or an ordinary CLI waiting-policy cost.
Frozen replay verifies all attempts and six preliminary correctness captures;
226 unit/replay cases pass, including 74 new damaged queued histories and both
report formats. Evidence: specs/graph-state/qualification/2026-11-13-i5-recovery-queue/.
The request starts after expiry, so its wait is not the full outage/hold lifetime.
Publication and grant API intervals yield bounds, not exact database linearization
timestamps. Multiple waiters, notifications, unknown outcomes, other mutations,
server failover, hosted comparisons and broader initiative gates remain open.
Passive server waits during queued recovery (E109). E108's workload now has
an optional observer that inserts no lock holder. Sixteen attempts pass in 211.38
seconds (one warm-up/seven samples for each original ownership policy). PostgreSQL
logs four waits above 10 ms across the fourteen measured attempts: 10.555–30.659 ms,
all on the queued caller's application-row SELECT ... FOR UPDATE. A resource-policy
warm-up adds one 12.290-ms wait. Session birth/PID, SQL fingerprint, acknowledged log
markers and the next completed query bind each pair independently to that caller.
No above-threshold wait is logged in recovery's own SQL. Recovery medians are
46.557/45.732 ms and retain 53 body requests, one publication and no repeated mutation.
Seven observer SQL requests per attempt include four session-identity reads already
counted in the phase counters. Logs and payload-free body receipts add interference;
these timings are not a speed comparison with E108. Shorter waits, lightweight locks,
I/O, CPU attribution and exact hold lifetime remain unmeasured. The 347-test selection,
non-queued compatibility tests and frozen replay pass. Evidence:
specs/graph-state/qualification/2026-11-13-i5-recovery-waits/. Production is unchanged;
this qualifies repeated ordinary heavyweight-wait attribution for this bounded
workload, not zero contention or the broader I5 matrix.
Runner loss after an accepted mutation: timing smoke (E67). Four native create/update × full/affected captures preserve the existing independent HTTP, process-identity, retained-hold and recovery checks, adding monotonic phase timings, the live provider executable hash and database durability observations. All four pass without mutation replay in 96.750 seconds. Their fresh-worker recovery commands take 1.557–2.047 seconds; one observation per profile is not a repeated cost result. The benchmark timeout helper now terminates tracked workers in their own sessions, after a regression reproduced an orphaned worker under controller-only cleanup.
The cost audit also demonstrates an incomplete CPU counter: an unreaped descendant
uses 0.300 seconds while the current reaped-child counter records 0.027 seconds.
Correct CPU accounting, add worker SQL/RPC and unresolved-safe cost observations,
then collect the required repetitions before qualifying this family. The 223-test
selection passes, including 64 timing/build checks. Sources, all smoke observations,
the earlier pilot and both diagnostic controls are retained in
specs/graph-state/qualification/2026-11-13-i5-runner-loss/. No production recovery
change, comparative speedup, p95 or wider matrix completion follows.
Orphan CPU measurement correction (E68). The benchmark command helper now
uses an isolated Linux subreaper per command and records each wait4 receipt.
It includes adopted workers and descendants waited by their parents, separates
supervisor CPU, preserves unsuccessful exits, and refuses incomplete measurements.
Automatically reaped descendants and Docker server processes remain outside this
counter. The original child probe passes; 202 scoped tests also verify normal waits,
concurrent attribution, timeout cleanup and independent receipt rejection. A native
full/lost-create smoke passes in 21.617 seconds with 16.440577 waited CPU seconds,
including 0.697599 from adopted children. The exact killed provider's PID accounts
for 0.364774 of those seconds. The loss/recovery oracle still passes without mutation
replay. Source and receipts are retained in
specs/graph-state/qualification/2026-11-13-i5-process-accounting/.
Future outage capture version 3 binds and validates this method; historical version
2 counters are not relabeled. End-to-end regression histories distinguish the
measurement change. This removes the demonstrated orphan undercount for the tested
path; worker SQL/RPC counters, unresolved-safe costs and repetitions still gate the
failure-cost family. No production behavior or comparative performance claim changes.
Worker SQL/RPC costs across loss (E69). Cost format 3 records actual unary Provider stub calls and logged asyncpg graph transaction-body completions in every worker, with transaction outcomes and separate controller observation costs. PID, process birth and command intervals bind each trace. A killed worker's trace is an interrupted prefix, never a completed call or exact total. Framing, migrations, connection/session setup and pool traffic are excluded from body counts; client durations do not identify server wait events. Missing/torn traces and incorrect attribution fail qualification. All 334 scoped tests pass.
Four full/affected × create/update smoke profiles pass in 78.030 seconds. Each fresh
recovery worker records 75 body calls, five returned read transactions and seven
returned write-mode transactions, plus six Provider RPCs for create recovery or five
for update recovery. Convergence after recovered creates calls ApplyResourceChange
without an additional service mutation; the independent HTTP/version non-replay
gate remains required. Worker instrumentation must be removed from inherited provider
environment inputs: a failed development attempt demonstrated correct saved-plan
refusal when the per-invocation trace path changed that environment. Both failed
development attempts, successful raw traces and source are retained in
specs/graph-state/qualification/2026-11-13-i5-worker-costs/. These observations close
the instrumentation gap for this profile, not the repetition/unresolved-safe/server
cost gates or the wider I5 matrix. Production state/recovery behavior is unchanged.
Repeated runner-loss costs (E70). A bounded native series completes all 32 attempts in 604.616 seconds, with one warm-up and seven measured samples per full/affected create/update profile. Fresh command processes, accounts and databases, randomized round order, observed image digests/resource limits and database settings bind each sample. The controller preserves failed attempts and stops at the first failure, deadline or excessive forecast; it has a twenty-minute sampling limit and a two-minute allowance per attempt. An independent reporter rejects partial samples, changed process/raw receipts, reordered attempts and mixed cohorts. All 436 scoped tests pass, including controls that recompute hashes after changing environment facts.
Median recovery command times are 1.364/1.364/1.378/1.369 seconds for full create, affected create, full update and affected update. Every recovery records five returned read transactions and six/five actual Provider RPCs for create/update. Body SQL is 75 with seven returned write-mode transactions in 26 of 28 measured samples; two full/update samples contain an additional five-call write-mode transaction, producing 80 calls and eight such transactions. Its timing is consistent with ownership renewal, but the trace does not label backend methods, so that attribution remains an inference. Every sample passes the independent non-replay and retained-hold safety checks.
Exact samples, full command costs, immutable compressed histories, source reconstruction
and limits are in specs/graph-state/qualification/2026-11-13-i5-loss-repetitions/.
This closes repetitions for this bounded successful recovery path, not unresolved-safe
recovery costs, exact hold lifetime, server work, stable p95, the wider matrix or a
comparative speed claim. The large campaign stays stopped; production behavior is unchanged.
Unresolved-safe recovery observation (E71). The native loss fixture now exercises two failed-recovery reasons before successful explicit recovery: absent termination confirmation with no quiescence interval, and an exact, process-attributed HTTP AccessDeniedException on the real provider's GetParameter probe. All eight full/affected create/update profiles pass in 228.899 seconds under a six-minute cap. Each first recovery returns the exact operation as quarantined, retains its full exclusion footprint without resource publication, and refuses a newly invoked contender. Later recovery and convergence preserve the accepted effect without replay.
Cost format 4 binds the recovery policy, denied request/body/socket-write outcome,
twelve worker traces and separate controller queries. Unconfirmed attempts send no
object probe, though the current entry point still sends Configure/Stop. Denied-read
create/update attempts send six/five Provider RPCs, whose transport returns can carry
diagnostics. Refused recovery records 40–45 logged body calls, three completed read
transactions and five/six write-mode transactions; these do not advance the observed
resource frontier. All 557 scoped tests pass, including exact-fault, attribution and
retained-hold negative controls. Source and histories independently replay from
specs/graph-state/qualification/2026-11-13-i5-unresolved-recovery/.
One sample per profile, varying host load and post-capture-only client runtime facts
do not satisfy repeated cost qualification. Repetitions with complete environment
binding, server work and exact hold lifetime remain open. This adds benchmark
instrumentation; it does not change production recovery or resume the large campaign.
Repeated unresolved-safe recovery costs (E72). One randomized series completes all 64 attempts in 1,571.489 seconds, below its thirty-minute cap: eight warm-ups and seven measurements per reason/scope/action profile. Each command independently binds host, platform, Python, CPU count/affinity and interpreter executable hash to the controller, alongside the existing exact source/provider/fixture checks. Frozen and strengthened replay agree on every history and sample. Quarantined recovery medians are 1.177–1.184 seconds without termination confirmation and 1.266–1.300 seconds for denied reads. Fifty-two measured attempts use 40 body calls/three read/five write-mode returned transactions; four use 45 calls/three read/six write-mode transactions. All retain the exact operation and complete hold, publish no resource state and exclude the fresh contender. Later successful recovery uses 76–86 calls and converges without repeating the accepted service mutation.
Whole-command medians range from 21.597 to 22.242 seconds, with slower samples up to
35.687 seconds retained. The shared host's one-minute load varies from 7.54 to 27.90;
this does not establish a causal attribution, comparative speed or stable p95.
All 604 scoped tests pass. Post-capture controls fix an omitted per-command budget
check and a test's unsynchronized process-startup deadline; their original failures,
validation patch and exact captured source remain distinct in
specs/graph-state/qualification/2026-11-13-i5-unresolved-repetitions/.
This closes the repetition/runtime-binding gate for these two named quarantine
outcomes. Server costs, exact hold lifetime, other failure schedules and the full
I5 matrix remain open; production recovery and the stopped large campaign are unchanged.
Recovery initialization optimization (E73). The public recovery entry point no
longer lists unresolved operations merely to decide whether to load providers.
GraphRecovery retains the decision about kept receipts, termination and usable
identity; the provider adapter initializes once at the first actual object probe.
A run with no eligible probe does not start providers. A load failure leaves dependent
operations quarantined, and ownership loss propagates through refresh/locate/import.
Thirteen behavior cases cover these paths, including multiple operations, known and
unknown returns, kept responses and still-live processes despite caller confirmation.
All eight actual AWS-provider/FakeCloud full/affected create/update quarantine cases
pass in 179.495 seconds. Unconfirmed recovery sends zero provider RPCs and records
34 completed body calls with two read/four write-mode transactions. Denied reads use
39 calls with two read/five write-mode transactions; later recovery uses 75 calls.
Every quarantine retains its full hold, excludes a fresh contender and subsequently
recovers/converges without effect replay. The removed duplicate read and avoided
startup are structural; aggregate counts also depend on other work and renewal
scheduling. Single timings do not qualify a new speed ratio or distribution. All
930 scoped and 21 PostgreSQL recovery tests pass, including a valid synthetic Configure
receipt rejected by the optimization-specific evidence gate. Reconstructible evidence:
specs/graph-state/qualification/2026-11-13-i5-lazy-recovery/.
E72's earlier-source repeated costs remain unchanged; repeated costs for this source,
server metrics, exact hold lifetime and the wider I5 matrix remain open.
Direct database-container costs (E74). An opt-in observer now records cumulative Docker CPU counters and sampled container memory around the native loss/recovery workload. It issues no SQL. Each inspect/stats/inspect receipt binds the container, image, PID, start time, running state and restart count; replay rejects missing/reset counters, stale timestamps, clock jumps and incomplete windows. All workload events must lie inside the window; proxy setup is explicitly before it. The measurement excludes fixture/schema/adapter startup and teardown, includes database background work and snapshot brackets, and reports sampling API/time/CPU costs separately. Container memory usage/anon/file/shmem are named as such: none is asserted to be RSS.
All eight final full/affected create/update quarantine/recovery smokes pass in
269.651 seconds on source 634b87c9…. Whole-workload database CPU is 0.521–1.133
seconds; sampled peak container usage is 84.543–88.156 MiB. There are 156–331 samples
per case, with a maximum observed gap of 218.414 ms. Sampler thread CPU is material
at 0.313–1.230 seconds. One-minute host load spans 14.202–57.415; these are single
instrumented observations, with no timing ratio or p95 claim. Existing quarantine,
fresh-contender exclusion and no-effect-replay checks remain mandatory.
The controlled SQL workload measures 1.001416 database CPU-seconds and a real
container restart is independently rejected. All 323 scoped tests pass. An initial
window-checker failure and a later HTTP socket-attribution failure remain archived,
including the second series' two passes before it stopped. The complete fresh
eight-case series does not erase either failure. Source reconstruction and raw
replay are in specs/graph-state/qualification/2026-11-13-i5-server-costs/.
This adds direct server CPU/memory evidence for these named whole-workload windows;
server RSS, SQL waits/attribution, row-byte costs, exact hold lifetime, measurement
interference, repeated current-source costs and the wider I5 matrix remain open.
Production recovery and the stopped large-estate/hosted campaign are unchanged.
PostgreSQL process memory (E75). The opt-in server observer now also reads
smaps_rollup as the owned container's PostgreSQL user. It records per-process RSS
and PSS separately, binding the exact collector, container lifetime, namespace PID,
parent and birth ticks. RSS sums count shared pages repeatedly; PSS sums retain
proportional sharing semantics. A process that disappears during collection has an
explicit departure record, while a process first seen at the final enumeration is
reported as new. Neither receives invented zero-byte counters. Equal membership
at both endpoints is not an atomic snapshot or proof that no short-lived process
was missed. Collector API wall/thread CPU costs are separate; its in-container CPU
remains included in the cgroup counters, with no attempted subtraction.
All eight native full/affected create/update quarantine/recovery smokes pass in
176.892 seconds on source d2a5569b…. Sampled peak RSS sums are 108.059–110.070 MiB;
PSS sums are 45.263–46.037 MiB. The 140 collections include two departures and three
new processes at their endpoints; 136 have stable endpoint membership. Requested
one-second sampling has observed gaps up to 1.087 seconds and collections up to
82.266 ms. These are single instrumented observations, not exact lifetime peaks,
production sizing guidance or a timing comparison with E74. Existing loss/recovery
safety checks remain mandatory.
A separate live control holds three database sessions with bounded temporary data,
observes all three PIDs in six collections, and excludes them in four observations
after close. All 361 scoped tests pass. A reproduced sampler scheduling-error path
now records the error and disqualifies the capture; shutdown covers the memory
collector's full API-call bound. E68–E74 remain immutable. Source reconstruction,
controls and histories: specs/graph-state/qualification/2026-11-13-i5-server-memory/.
This adds bounded sampled RSS/PSS evidence. Wider/repeated memory profiles, SQL
lock waits, per-query/phase attribution, row/WAL bytes, exact hold lifetime and
observer interference/reliability remain open, as does the full I5 matrix.
Server-reported SQL lock waits (E76). An opt-in local observer records
PostgreSQL heavyweight-lock wait/acquisition logs with a 10-ms reporting threshold.
In each recovery profile it deliberately holds the retained dispatched operation
row, observes the blocked recovery query and releases the row 100 ms later. The
independent checker binds server wait duration to pg_locks.waitstart, blocking
transaction, exact retained operation/digest, backend PID/session and the first
matching completed worker SQL fingerprint. Acknowledged log markers and the CPU
observer's realtime/monotonic brackets bound the timeline. Missing pairs, damaged
log lines or impossible process/clock observations cannot qualify.
All eight native full/affected create/update quarantine/recovery smokes pass frozen
and strengthened replay after a 169.135-second capture on source 6f611647….
The injected server waits are 100.809–105.345 ms. Observer SQL is separately counted
at 81–85 requests per case; graph body-call counts exclude it. Server CPU includes
observer work. No other wait pairs appear in those marked intervals, which does
not establish zero other waits. Shorter waits, lightweight locks and I/O waits are
outside the measurement. The lowered deadlock/logging threshold changes overhead;
these controlled cases do not measure ordinary recovery latency or matched throughput.
All 414 scoped tests pass. Post-capture mutation tests exposed self-blocking,
invalid temporal observations and silently ignored unparseable log lines. Their
failures and fixes are retained separately from the unchanged native samples.
Both verifier versions reproduce the same results from the exact 397-file source,
with imported module identities checked. Evidence and reproduction:
specs/graph-state/qualification/2026-11-13-i5-sql-waits/.
This qualifies bounded server-wait attribution, not the repeated/ordinary contention
matrix, broader SQL/phase costs, row/WAL bytes or exact hold lifetime. Production
graph execution and the stopped large-estate/hosted campaign remain unchanged.
Repeated four/eight-writer costs (E77). A bounded native N=100 series completes
all 144 attempts across the four contention families, 4/8 actors and full/affected
planning: one setup, one warm-up and seven measurements per cell. Sampling takes
1,658.296 seconds under its 45-minute limit. Every sample checks accepted desired
changes, service/state version increments, ready rows, zero unresolved operations,
immutable saved plans, actual provider binary identity and refusal without mutation.
Frozen and current replay agree on all attempts; 109 writer/budget preflight tests
pass. Source c2a3d632… and all 397 files remain unchanged throughout capture.
Changing-input cohorts use E60's explicit zero-wait fair-queue contract, including four measured partial-consumer samples at four writers and six at eight writers. No measured sample shows overlapping mutating actors: a common process start gate does not establish provider/service overlap. Compatible disjoint/shared-reader comparisons have seven matched pairs each and affected/full ratios 0.9523–0.9629, with 95% bootstrap intervals below one. Conflicting/changing-input outcomes have insufficient matching actor sets for a ratio. Seven repetitions do not establish stable p95 or sustained throughput; E43's different-source 1/2-writer costs are not a current-source scaling baseline.
Observed frontier advancement equals recorded commit-method calls in every measured
sample; these are not published-row counts. For disjoint writes, full planning uses
31 plan and 146 apply body SQL calls per actor, while affected uses 83/187, with one
frontier advance per accepted edit in either mode. The remaining 52/41 extra calls
identify a planning/validation investigation, not a causal query-level attribution.
Client SQL counts exclude framing/setup and do not measure server waits.
Exact commands, raw captures, counter distributions and reproduction:
specs/graph-state/qualification/2026-11-13-i5-writers48/.
The named native four/eight-writer timing cells are now measured. Terraform/hosted
writer policies, deterministic-delay profiles, broader server/phase metrics and the
remaining I5 matrix stay open; the large-estate/hosted campaign remains stopped.
Batch planning metadata reads (E78). A minimal N=2 native reproduction has
E77's same 93 extra plan/apply SQL calls. Transaction-path receipts attribute the
planning excess to six complete metadata captures and the apply excess to two
captures plus additional admission/proof validation. PostgreSQL now reads each
complete metadata capture in one tagged-row UNION ALL statement. Selected
resource/output payloads keep their native columns and the same repeatable-read
transaction. Baseline scope/pin/history digests, complete index integrity,
unresolved holds, cleanup inventory and capture validation remain mandatory at
every existing validation point. No provider or publication boundary is removed.
For this interface, a fresh metadata-only read requires at least one database request and now uses one. Selecting resource and/or output payloads adds one request per kind. This does not reduce the complete metadata/topology scan to O(selected rows), or establish the minimum for a whole apply. JSON serialization, unresolved-operation recovery bodies and selected payload batching remain costs.
All 18 diagnostic attempts pass across the before/after N=2 reproduction and after-change N=100/four-writer disjoint cohort. Per actor, affected plan/apply SQL body calls fall from 83/187 to 29/169, versus unchanged full counts of 31/146. There is still one frontier advance per accepted edit; all four edits survive the N=100 cohort. This removes 72 of 93 excess calls, with no publication saving. Affected's remaining 23 apply calls arise from additional owned admission/proof checks, offset by cheaper selected-view reads. Those checks remain in place.
Validation covers 398 distinct PostgreSQL cases, including all 48 actual-provider
index-damage/control cases, and 251 core cases. The request regression fails before
the fix; private payloads, concurrent writes and retained holds remain covered.
Frozen replay verifies the 398-file source and unchanged independent safety
checkers. Exact commands, original failures, raw captures and limits:
specs/graph-state/qualification/2026-11-13-i5-planning-sql/.
One measured sample per scope with diagnostic instrumentation establishes request
counts, not a speedup, p95 or throughput claim. Repeated new-source timings,
database/serialization costs and the broader I5 matrix remain open.
Validate preparation once (E79). Engine call stacks identify an immediate
duplicate after prepare_graph_apply returns an affected plan. Preparation now
validates all successful exits, including existing grants; its caller removes
that duplicate and performs the fixed-admission guard inside the validation
callback before state reads. Checks before approval and retained provider
startup, and all dispatch/publication fences, remain. A manual already-held
full-plan grant now receives an additional early preparation check: the return
contract is consistent, but that path is not a request-count reduction.
All 15 before/after diagnostic attempts pass frozen replay. Fresh affected apply uses 157 SQL body calls, down from E78's 169, and 14 returned write-mode transactions instead of 15. Planning remains 29; fresh full mode stays 31/146. N=100/four-writer disjoint apply uses 628 calls and preserves all four edits with four frontier advances. Including E78, affected's combined count is 186 versus E77's 270 and full's 177. The remaining nine excess calls and full metadata scans remain investigation targets; these single instrumented samples do not establish latency improvement, p95 or throughput.
Validation passes 240 core and 142 actual-provider PostgreSQL cases. Native
controls require missing grants and affected plans lacking fixed admission to
fail before approval/mutation, preserving state and operation history. Broader
testing also exposes two normalization fixture failures on the frozen E77 runtime.
The corrected fixtures distinguish unqualified normalization (promotion required)
from qualified AWS 6.66 SSM empty-user-tags normalization (selection preserved),
with both observing the raw provider change. Production normalization is unchanged.
Source, original failures, exact commands, transaction paths and replay:
specs/graph-state/qualification/2026-11-13-i5-apply-validation/.
Repeated timings and the wider I5 matrix remain open; the stopped campaign stays stopped.
Read grant and coverage together (E80). Plan admission and validation previously read the exact-grant certificate and actual held leases separately. One statement now returns both, retaining SHARE locks on the actual lease rows. The run/app locks, coverage checks, initial ownership check and final fresh-clock/certificate fence remain. In particular, a statement that waits on a lease row may have an older certificate snapshot: the final fence must still reject invalidation committed during that wait. Legacy schemas retain their exact-set fallback.
The native request regression drops 11 → 10 body calls; 21 controls cover both grant policies, current/legacy grant checks, missing/extra/mode-edited/restored leases and a witnessed lease-row wait. All 513 scoped native PostgreSQL/provider tests pass. Frozen replay checks twelve new and twelve E79 comparison captures, with unchanged independent safety checkers. Fresh affected/full apply falls 157/146 → 153/143 SQL calls per actor; planning stays 29/31. Transaction counts and graph publications do not fall. N=100/four-writer affected apply uses 612 calls and retains four edits/four frontier advances. Its combined plan/apply count is 182 per actor versus full's 174: eight excess calls remain in this fixture.
For this read step, one request returns a fresh certificate and locked coverage;
that is not a lower bound for an entire validation or apply. These single
instrumented samples do not qualify latency, throughput, large estates or hosted
comparisons. Source, negative controls, all SQL paths and reproduction commands:
specs/graph-state/qualification/2026-11-13-i5-grant-coverage/.
Repeated current-source writer costs (E81). The ordinary writer harness, without the exploratory SQL/call-stack probe, completes all 72 attempts over N=100/four writers, four contention families and full/affected planning. Each of eight cells has one warm-up and seven measured samples. The run exits normally after a 758.978-second sampling receipt, below its 1,500-second cap; frozen replay checks the complete matrix against unchanged independent safety code.
Disjoint/shared-reader affected-to-full paired median ratios are 0.9768/0.9852, with seeded bootstrap 95% intervals 0.9688–0.9972 / 0.9831–0.9880. These are modest preliminary differences on stable FakeCloud, with different drift-inspection coverage stated. Conflicting/changing-input cases have zero/one matching accepted actor sets and cannot support a speed ratio. Three measured partial-consumer outcomes carry fair-queue witnesses; no measured sample observes overlapping mutating actors. This qualifies process-concurrency costs, not simultaneous cloud mutations, stable p95, a historical-source optimization speedup or 1-to-8 scaling.
Repeated disjoint cohort counts are 116/612 affected plan/apply body calls versus
124/572 full, with four edits/frontier advances in both modes. Affected planning
loads four resource payloads versus full's 400, but still captures 24 complete
metadata views/2,424 summary rows across the actors; apply adds eight/808. Client
CPU, sampled RSS, payload bytes and RPC counts retain their measurement scope.
Fewer body calls and selected payloads do not establish proportional server-work
savings or an O(selected rows) planner. Exact source, all raw samples, outcome-aware
comparisons and counter derivation:
specs/graph-state/qualification/2026-11-13-i5-current-writers4/.
Broader current-source cells and the remaining I5 gates stay open.
Reuse the final ownership capture (E82). Synchronous call paths locate six affected-planning metadata captures. Ownership lookup and the final closure sweep are combined by having the completed evaluation supply a final-view validator. It runs only after selection/input coverage converge, returns metadata from the same snapshot as owner lookup, and must pass capture and empty-payload checks before cached originals are merged. Final provider requalification remains. Legacy backends returning no view keep the separate read. The optional work observer records this combined capture and its independent checker still requires it.
Planning remains unleased. A publication during owner lookup previously could be observed by the later separate capture and restart planning; the combined snapshot can instead return a candidate that is stale by admission. A new native race verifies refusal before approval or a mutating RPC, preserving the newer publication and service value. No freshness-at-return or mutation authority follows from planning. Changes visible before the final snapshot still discard and restart the candidate. Admission, retained-provider and publication fences are unchanged.
All 15 diagnostic attempts pass frozen replay. Affected planning falls from six
to five complete captures, 29 to 28 SQL body calls, and seven to six
returned read-mode transactions per actor. Apply stays at 153 calls/two captures;
full stays 31/143. N=100/four-actor planning returns 2,020 summary rows instead of
2,424 and uses 112 calls; apply uses 612 and preserves four edits/frontier advances.
The complete scans remain O(estate), and no publication is removed. Validation
covers 257 core and 518 distinct native cases across the broad and targeted runs,
including legacy-return, expansion, observer, index and snapshot/admission races.
The earlier return-value assertion and two race-fixture corrections are retained.
Source, exact commands, original failures and scope:
specs/graph-state/qualification/2026-11-13-i5-final-planning-capture/.
These single instrumented samples establish counts, not a speedup; E81's repeated
timings remain attached to its earlier source. Broader I5 qualification remains open.
Separately timed simulated provider waits (E83). The native writer harness now accepts a finite 0–30-second pre-RPC delay for measured mutating calls, with setup and resets undelayed. Version-3 evidence binds that profile to every worker and checks the minimum wait, worker interval and prior granted admission. Actual gRPC intervals remain separately timed; injected waits cannot become actual provider overlap evidence. Historical version-1/2 replay remains supported, and E81's whole 72-attempt report is unchanged. All 231 scoped harness checks pass. Production backend/engine code remains exactly E82's implementation.
All 72 native attempts pass frozen replay: 24 delayed N=10 smoke attempts across all four families, 12 zero-delay compatible controls, and 36 N=100/two-writer attempts with two-second delays. The latter supplies one warm-up/seven measured samples for each disjoint/shared-reader and full/affected cell, in 415.318 seconds. All 28 measured samples preserve both edits with overlapping simulated pending operations and two frontier advances. None observes overlapping real RPCs. Conflicting/changing-input smoke cohorts refuse the incompatible actor without a mutation; these are not repeated conflict-cost or fairness measurements.
Disjoint full/affected plan-plus-apply medians are 6.458/6.328 seconds; shared-reader
medians are 6.472/6.327. Seven matched pairs give preliminary affected/full ratios
0.979916 (95% bootstrap 0.975779–0.985185) and 0.980442 (0.972782–0.993443).
Affected still uses 56 planning/306 apply body calls for the disjoint cohort versus
full's 62/286; shared-reader adds 12 apply calls in each mode. It retains ten complete
planning captures/1,010 summary rows and four apply captures/404 summaries. Waiting
concurrently does not remove those scans or publication/admission work. The zero
profile is smoke-only, so no delay/no-delay speed ratio follows. Wider delay values,
1/4/8-writer profiles, real provider/HTTP overlap, server attribution and broader I5
gates remain open. Source, exact commands, raw results and exclusions:
specs/graph-state/qualification/2026-11-13-i5-provider-delay/README.md.
Compatible delayed writers at 1/4/8 actors (E110). Current-source native captures complete twelve 100-resource disjoint/shared-reader × full/affected cells, with one warm-up and seven measured samples each. All 84 qualified samples preserve every edit: 364 updates, one publication per actor and no unresolved operation. 56 samples overlap simulated pending operations; one also records overlapping actual RPC intervals, recorded separately. Affected still uses nine more body SQL requests per actor despite substantially fewer resource payload reads.
The first one-writer batch stops at its forecast limit after 24 passing attempts;
its completed disjoint cells qualify, while its six partial shared-reader attempts
remain diagnostic. Five separate bounded runs finish the remaining families. All
126 actual attempts pass; the original stopped report remains incomplete and keeps
twelve unstarted attempts. Source/context archives, paired ratios and every raw
sample are independently replayable. All 366 focused tests pass,
including 144 last-actor corruptions replayed by the frozen checker. Evidence:
specs/graph-state/qualification/2026-11-13-i5-provider-delay-writers/.
These are preliminary within-count full/affected comparisons. Production and the
timing harness are unchanged; E83's historical two-writer cohort, delayed conflicts,
wider delays, HTTP/server attribution and broader I1–I5 gates remain separate.
Delayed conflicting writers and changing inputs (E111). Sixteen current-source 100-resource cells cover 1/2/4/8 actors and full/affected planning with a two-second pre-RPC delay, one warm-up and seven samples each. All 156 native attempts pass, including twelve smoke attempts; 112 measured cohorts admit 193 plans and refuse 227, preserving 225 exact provider effects and 225 graph publications. Refused actors make no mutation or graph commit; every final state is ready with zero unresolved operations. The 12 partial-consumer cohorts retain exact fair-queue refusal witnesses. Different accepted actor sets are excluded from paired speed ratios, and single-actor rows are baseline controls.
All 482 focused tests and 256 frozen accepted/refused-actor
corruptions pass. Source and the timing harness are identical to E110; simulated
pending work and actual RPC intervals remain separate. Evidence:
specs/graph-state/qualification/2026-11-13-i5-delayed-contention/.
This completes those delayed-contention cells, not sustained retry/liveness, wider
delay values, server attribution or the broader I5 matrix. Large/hosted campaigns
remain stopped; no whole-initiative completion or cross-engine speed claim follows.
In E111, every refused conflicting actor costs 47 apply body requests without a mutation or graph publication. At eight actors, refusals account for 329 of the 458/468 full/affected apply requests. The frozen verifier checks those counts; reducing this refusal cost remains an optimization opportunity, not a proven SQL minimum or a reason to weaken admission.
Combined first lease attempt (E112). The PostgreSQL backend now enqueues and tries the first grant in one owned transaction. It reuses the same ownership/app locks and the exact immutable ticket, retaining the final database-clock and complete-grant fence. Older waiters, unresolved operation footprints, recovery-role restrictions and the mutation marker still participate. A refusal keeps its ticket for diagnostics, polling or cancellation; other graph backends use the default separate-call implementation. There is no schema/protocol migration.
A real saved-apply diagnostic falls from 47 to 41 body SQL requests and from ten to nine transaction bodies per refused actor. The first enqueue/grant pair falls from 17 to 11 requests. The original N=100/eight-actor/two-second-delay conflicting fixture confirms 410/420 full/affected apply requests, versus E111's 458/468; planning remains 176/168, with exactly one mutation and publication per cohort. All 12 conflict/changing-input attempts pass, including setup and warm-ups. These are four smoke cells with one measured cohort each, not repeated latency qualification. Concurrent local validation activity also excludes a timing ratio.
Validation passes 789 core tests, 523 PostgreSQL tests (521 in the main run and two
FakeCloud transfer cases rerun with that fixture enabled), 48 broad-read create/update
tests, 574 oracle/harness tests and all 60 native conformance cases. Frozen replay
checks 56 positive conformance histories, four native wrong-wire tests, eight writer
cohorts and 256 corrupted observations. The shared SQL regression runs both app-wide
and resource-grant refusals; native tests cover lost replies, fair tickets and actual
expiry after the request or grant body. Evidence:
specs/graph-state/qualification/2026-11-13-i5-combined-admission/.
This does not establish a 41-request lower bound. Cancellation still costs ten requests; ending the run and retention cleanup cost another eleven. They remain separate optimization candidates with ownership and retention obligations intact. Broader I1–I5 requirements and the stopped large/hosted campaigns remain unchanged.
Publication row and WAL costs (E85). A separate opt-in storage observer now records state-scoped live row/column sizes, same-transaction tuple-counter deltas, body SQL calls and transaction-ID-tagged WAL records. Cluster WAL span, foreign or zero-XID records, framing and full-page images remain separate. Entry counter baselines prevent unflushed statistics from prior pooled-session work leaking into the result; natural-flush polling makes abort records readable without forcing a flush. Server lifetime, session, transaction, record-chain and COMMIT/ABORT checks refuse incomplete attribution. Observer queries are counted separately.
On unchanged production source, 22 native tests and 46 replay/control checks pass. Eighteen cells cover create/metadata normalization, 1/16/64 rows, and small, compressible or hashed 16 KiB values. These use synthetic provider results and real fenced backend publication. Checkpoint, foreign-writer, late rollback and SQL-error controls establish nonzero full-page images, separate unrelated WAL, retain failed work and refuse incomplete observations. No provider/cloud call or large-estate campaign was started. This is one diagnostic sample per cell, not a matched latency or full-apply qualification.
The measurements expose two concrete optimization candidates. Normalizing sixteen hashed rows uses 19 body SQL calls and 633,391 transaction WAL bytes, despite no change in current payload sizes; it appends 280,920 stored-value bytes of history. At sixty-four rows those values are 271 calls, 2,540,826 WAL bytes and 1,123,800 history bytes. The writer supplies complete JSONB for unchanged current payloads and complete history; preserving an unchanged external TOAST value merits a measured prototype without weakening history/recovery. The larger serialized batch also exceeds the existing 1 MiB cap and takes the serial fallback. Small 64-row batches remain at 20 creation/19 normalization calls; large ones use 335/271 while still publishing atomically once. A bounded SQL-chunk implementation inside that one fenced transaction should retain cross-chunk identity/conflict validation, one frontier advance, complete rollback and the final ownership check. Do not infer these direct-backend batch shapes from every apply scheduler run.
WAL bytes are not live-payload growth, disk-write bytes, flush counts or replicated
traffic. FPI/context, observer overhead, repeated profiles, end-to-end attribution
and the wider I5 matrix remain open. All 87 final/development captures, failures,
the 406-file frozen source and replay are retained in
specs/graph-state/qualification/2026-11-13-i5-write-bytes/README.md.
Unchanged current-payload storage (E86). Both the general resource writer and
eligible state-only bulk writer now reuse the existing JSONB datum when its full
representation is unchanged. Value changes take the normal incoming value; equal
JSONB values also compare text under C collation, preserving distinctions such as
1 versus 1.0. Every revision, complete history record, validation/invalidation
and final ownership fence remains. The native regression previously observed nine
current-entry TOAST chunk insertions/deletions per unchanged 16 KiB row; it now
observes zero. Changed-value and numeric/metadata representation controls pass.
The matched storage campaign has 128 passed attempts: 1/16-row small/hashed unchanged/changed cells, warm-up plus seven randomized pairs each. Its control executes E85's exact two writer functions in the same current harness. For one and sixteen unchanged hashed rows, median transaction-tagged WAL falls from 40,395 to 20,644 bytes and 635,065 to 326,078 bytes. Paired ratios are 0.511053 (95% bootstrap 0.510232–0.511053) and 0.513456 (0.512132–0.516024). SQL remains 18/19 body calls and each case still has one graph publication/SQL transaction. These are actual PostgreSQL storage measurements with synthetic provider results.
An initial unconditional text-comparison candidate showed a changed-large-batch
timing regression; the final value-difference fast path avoids that conversion.
Both candidates, their sources and all attempts are retained. All final
instrumented-time intervals include parity, so no latency/full-apply improvement
is claimed. History remains full, the 1 MiB batch cap still causes serial fallback,
and SQL chunking is a separate next candidate. The broader native tests and original
E85 diagnostic are rerun; 75 replay/control cases pass. Evidence, exact terminal
validation and limitations: specs/graph-state/qualification/2026-11-13-i5-payload-reuse/.
This closes a concrete write-amplification finding, not the wider I5 matrix.
Bounded SQL chunks in one publication (E87). Eligible creation and state-only publications now split encoded rows into SQL arrays of at most 1 MiB. They validate the entire cohort before writing, then write current rows and full history per chunk using the same connection, transaction and graph sequence. Operation resolution, invalidation and the final ownership fence remain collective. The 256-row eligibility bound is unchanged; a single oversized row or unsupported cohort still uses the general writer. Creation-completion batching remains disabled.
The original 64-row/16 KiB hashed case falls from 335 to 24 body SQL calls for creation, and 271 to 23 for normalization, retaining one publication and commit. For this app-X fixture the implementation uses 18 fixed calls plus two per chunk for creation, and 17 plus two per chunk for normalization. These are not fundamental SQL lower bounds: combining current/history work or other queries could reduce them further. One durable publication is already the minimum for this transition.
All 32 matched attempts pass: warm-up and seven randomized pairs per action against the exact E86 writer functions. Instrumented publication medians fall from 0.5283 to 0.4387 seconds for creation and 0.2200 to 0.1524 for normalization. Paired ratios are 0.8300 (95% bootstrap 0.7727–0.8591) and 0.6913 (0.6644–0.7237). Setup is excluded; SQL/WAL observation is included. WAL stays close because history remains full. No full-apply, provider, hosted, large-estate or stable-p95 claim follows.
Native controls cover app X/resource grants, visibility between chunks, Python and
SQL errors after the first chunk, final-fence expiry, last-row conflicts, and
cross-chunk dependency invalidation. Exact terminal validation, frozen source,
failed development attempts and paired replay are retained in
specs/graph-state/qualification/2026-11-13-i5-publication-chunks/.
The wider I5 matrix and five-initiative goal remain open.
Broad runtime read costs (E88). A separate native-only fixture introduces stack/app/undeclared runtime read contracts over an existing one-producer, 100-consumer fanout while keeping provider values unchanged. All 54 attempts pass: setup, warm-up and seven samples per profile and requested full/affected policy. Actual runtime declarations, saved-plan scope/input proofs and independently read original rows agree. Both policies use full planning, with explicit affected fallback; measured apply completes without provider mutations. This is a metadata introduction, not a steady-state no-op or successful broad-read initial creation.
Every measured apply makes 102 publications and 2,343 body SQL calls, loading
15,958 resource payload rows (about 54.36 MB of repeated JSON columns). Native-full
plan/apply medians are 9.7015/8.0499/7.8682 seconds for stack/app/opaque respectively;
requested-affected/full ratios are 1.0402/1.0139/1.0362. The first two intervals include
parity and the opaque profile shows small fallback overhead. No affected speedup,
cross-profile ratio, stable p95 or hosted comparison follows. Exact source and all
54 captures: specs/graph-state/qualification/2026-11-13-i5-read-contracts-repeated/;
the preceding smoke checkpoint retains failed and intermediate development captures.
Mutating broad-read workloads and the wider dependency/value/cache matrix remain open.
Scope-preserving normalization cohorts (E89). E88's per-resource publications came from the scheduler treating every broad input overlap as a dependency. The normalization queue now distinguishes concrete revisions from value and membership generations. Existing state-only writes may share a cohort when their expected-row evidence proves the watched generation is preserved. Concrete dependencies, creations, unknown counters and all storage validation/fencing retain their prior rules.
The 101-resource retest passes all 18 setup/warm-up/measured attempts. Each measured
apply uses five publications and 211 body SQL calls instead of 102 and 2,343;
loaded resource payload rows fall from 15,958 to 1,324–1,332. No provider mutation
occurs. Full planning/fallback and resource grants remain. Tests cover durable
acknowledgements, changed values/private/provider data, stale inputs, conflicts,
expiry, missing counters and the full hybrid path. There are 278 passing core and
66 native PostgreSQL tests. One measured sample per cell supports the structural
count result, not a latency ratio or optimum claim. Exact source, all failures,
captures and commands: specs/graph-state/qualification/2026-11-13-i5-scoped-normalization/.
Repeated scoped normalization costs (E90). The unchanged E89 implementation
passes 54 attempts with seven measured samples per profile/policy. Every measured
apply uses five publications, 211 body SQL calls and four complete snapshot reads;
resource payload rows range from 1,323 to 1,336. Full plan-plus-saved-apply medians
are 4.7230/4.3755/4.5832 seconds for stack/app/opaque. Requested-affected/full paired
medians are 1.0622/1.0592/1.0497; the stack interval includes parity, while the other
two show fallback overhead. Both policies still use full planning. This is repeated
current-source evidence, not an interleaved pre/post optimization ratio, stable p95
or global optimum. Exact frozen replay and limits:
specs/graph-state/qualification/2026-11-13-i5-scoped-repetitions/.
Required file effects on unchanged rows (E91). A shared-file workload exposed a resource-grant bug: coverage marked unchanged runtime nodes untouched, and saved apply cleared their configuration before executing required local effects. A two-resource PostgreSQL/FakeCloud case reported success with its file still absent; the one-resource in-memory reproduction fails in under a second. App-wide controls recreate the file. Coverage now retains evaluation and admission for nodes whose symbolic bodies are not concrete, while the state engine still elides identical publications. Older saved plans that omitted those bodies require a fresh plan. Newer branch-preserved intent remains protected.
The file fixture leaves provider values unchanged, shares one cache-key runtime
call across consumers, and checks a deterministic 1 MiB artifact independently of
its returned short value. The missing case deletes the file between fresh-process
plan and saved apply. Worker/parent file hashes, per-consumer original/admitted/
stored input proofs, actual cache eligibility decisions, body calls and written
bytes are separate observations. This covers large local files, not large graph
payloads, cross-process caches, atomic file writes or arbitrary effect durability.
The complete evidence and remaining gates are recorded in
specs/graph-state/qualification/2026-11-13-i5-shared-files/.
The corrected smoke passes 12 attempts; the unchanged 101-resource source passes
36 attempts with seven samples per file case/policy. Each measured apply makes
92 body SQL calls, loads 404 payload rows and publishes zero graph changes. It
writes the shared file once, with 99 positive cache eligibility decisions for 100
consumers. Full plan/apply medians are 3.8376 seconds with the file present and
3.7626 seconds after removal. These are separate workload distributions; their
paired full-fallback ratios measure policy overhead only. The 353 core, 66 focused
file/provenance (overlapping core) and eight native fallback checks pass. Larger
graph payloads, invalidation/reclamation costs and the wider matrix remain open.
Large shared graph values and discarded copies (E92). The production closure and PostgreSQL read paths now have matched synthetic-refresh measurements for 100/1,000 consumers of a shared 1 MiB flat or nested value, with stable captures and forced final-validation restarts. Two late inputs require three expansion waves per capture; an unrelated 2 MiB row must never be fetched. Each consumer's actual input revision and content hash is checked, including nested mutation isolation. Stored payloads are decoded once per capture and final validation loads no payloads. The plain-data checker reconstructs input ownership, query coverage, decoder/copy counts and actual selector work.
A two-consumer red test exposed a discarded stored-value copy before every
refreshed read. GraphPlanningView.read_version now supplies the complete loaded
row proof without copying that payload. Unloaded/tombstone proofs still require
expansion, and refreshed values remain detached per consumer. For 1,000 nested
consumers, seven matched pairs have stable median closure times 6.9516 → 4.9103 s
and restart medians 13.7945 → 9.9681 s. Paired median ratios are 0.7077
(95% bootstrap interval 0.7030–0.7562) and 0.7226 (0.7138–0.8489).
Stable SQL/publications stay 8/0; restart totals stay 61/1, including the injected
source publication. This is an instrumented planning-closure result, not provider
end-to-end speed or physical allocation bytes.
Flat strings do not show a general speedup: the separate 1,000-consumer restart
cohort is slower, with paired ratio 1.0484 (1.0154–1.2062). That negative result
remains qualified to its workload; attribution and repetition remain open.
The original matrix stops at its budget after 120 passing attempts; four cells
are complete. Separate bounded captures supply the other four cells with 64
passing attempts. All eight qualified cells have a warm-up and seven paired
samples, each within its own cohort; incomplete six-pair cells are not pooled.
434 core, 58 PostgreSQL view and 44 provider-pair cases pass, with the original
shared-schema index-choice test failure retained and its fresh-schema fixture
corrected. The 68 independent fixture/evidence/matrix checks and frozen replay
retain failed and interrupted development attempts. Evidence and remaining
SQL-plan, reclamation, wider fanout and full I5 gates:
specs/graph-state/qualification/2026-11-13-i5-large-values/.
Planning SQL and database-derived dependencies (E93). Schema 35 stores the exact ordering-dependency projection independently of provider attributes and reuses it in edge maintenance. Native controls preserve ordering-only edges, unknown-input fallback, deletion/recreation, private state, history, row versions and pinned captures through migration; older schemas retain their read expression. The migration rewrites the entries table under a table lock. Rewrite duration and publication/storage overhead remain separate unmeasured costs.
The bounded PostgreSQL 16.15 comparison uses 100/1,000 consumers, 16-byte/1 MiB
source values, a twice-as-large unrelated row and a null output. Five actual queries
have one warm-up and seven matched pairs before/after ANALYZE, completing in
18.8805 seconds. Prepared-statement identities and execution counters bind tail
EXPLAIN EXECUTE plans to the cached statements; matching modes include the
recorded post-analysis custom-to-generic transition. Large-value metadata reads
remove 404 buffer accesses in each profile. Fresh 100/1,000-consumer paired latency
ratios are 0.5569 (0.5087–0.5839) and 0.8517 (0.8412–0.8833). Selected payloads,
complete metadata/topology and input ownership agree; requests/publications do not
change. Identical-query controls include a slower observation, and small values
show no general speedup. These are warm-buffer read costs on one schema, not
whole-apply speed, cold-cache work, physical I/O bytes or schema-upgrade costs.
The original combined-test grant-budget failure is a row-visit measurement error:
29 retained runs favor valid two-buffer metadata scans. The corrected test bounds
lease rows and root buffers and still rejects legacy whole-grant expansion. The
combined sequence and controls pass 101 native cases; 142 checker/runner controls
and frozen replay bind the repeated evidence, including earlier failed probes and
the separately retained preliminary EXPLAIN series. Evidence and remaining
history/reclamation, provider end-to-end and wider I5 gates:
specs/graph-state/qualification/2026-11-13-i5-planning-sql-projections/.
Bounded selected payload reads (E94). An initial VALUES candidate regressed at 100 selected rows through a repeated nested-loop scan; its failing tests and measurements remain archived. The replacement uses equality for a singleton, hashed membership for bounded dense selections and indexed lateral lookups for sparse selections. At most 1,024 keys / 256 KiB of encoded key text take the bounded path; the density threshold is 1/16 of the complete per-kind population. Larger selections retain the general array path. This is a cost heuristic, not a change to selection semantics or a global optimality guarantee.
Complete metadata in the same repeatable-read snapshot proves absent keys without a payload query. Requested sets, tombstones, full inventory, exact row/private/input proofs and capture validation remain intact. An absent resource request takes one body SQL request instead of two; requesting both absent kinds on an empty state takes one instead of three. Existing reads retain one request per selected kind plus metadata; graph publication counts remain zero. Full metadata remains O(N+E).
Four matched PostgreSQL fixtures compare the exact frozen E93 planning method with the replacement, covering 100/1,000 consumers, small/large values, dense/10-key selections and fresh/analyzed statistics. Six warm-ups and seven measured pairs complete in 24.2359 seconds. Fresh 1,000-key paired ratios are 0.5218/0.4192; the 100-key regression is resolved. Sparse fresh reads use 30 rather than 103 buffer accesses. Analyzed sparse reads use more buffers (21→30) with lower fetch latency; custom/generic plan differences are recorded. A small subset case is slightly slower. No general speedup, stable tail or full-apply claim follows.
The absent candidate has no query samples, plan or fabricated zero-time ratio.
Independent checks bind omission to the complete view, and retain the old empty
query as a baseline-only series. Native planning and key-byte controls pass 85
cases; evidence suites pass 348. Frozen replay and retained failed candidate:
specs/graph-state/qualification/2026-11-13-i5-adaptive-payload-lookups/.
Larger sets, density crossover, wider history/cache/version profiles and full I5
gates remain open.
Bounded reclamation costs (E95). A local PostgreSQL 16.15 capture measures controlled deletion of derived observations separately from public history pruning, first with an origin pin and then after explicitly releasing it. Four revisions of 16/128 managed rows, 16-byte/16-KiB payloads, and an old dispatched/returned operation form eight profiles. One warm-up and seven samples per profile complete all 64 attempts in 127.42 seconds. Provider dispatch/return inputs are synthetic, and fixture SQL ages timestamps; this is storage evidence, not a provider failure-latency or automatic-cache-collector claim.
Each measured phase has one mutating transaction and zero graph publications.
Body SQL counts are 1 for derived eviction and 12 for each public prune. Pinned
pruning removes 2N intermediate versions and two terminal operations; released
pruning removes N original versions. Exact managed values/private bytes, pinned
origin values/intents, and the unresolved request/result/footprint survive their
respective retention obligations. An independent client using new run IDs is
refused app-X and held-resource-X grants after both prune phases. After unpinning,
the baseline-intent API refuses the released origin; this fixture does not then
call historical state_at or recover the operation.
For 128 rows with 16-KiB payloads, median instrumented phase times are
21.191/77.337/33.682 ms with a dispatched hold and 21.775/78.802/38.190 ms with a
returned hold. Median own-transaction WAL record bytes are 76,066/153,937/76,199
in both profiles. These phases perform different work; no speed ratio follows.
The timers include transaction observers and exclude setup, inventory scans,
admission probes and unpinning. Live row JSON byte deltas are not physical disk
space reclaimed. Four native cases, 161 combined evidence controls and frozen
replay bind the capture; earlier fixture/checker failures remain archived.
Checkpoint/history-density and concurrent pruning costs, actual-provider recovery,
automatic collection, VACUUM, cold caches, larger estates and wider I5 gates remain
open: specs/graph-state/qualification/2026-11-13-i5-reclamation/.
specs/graph-state/qualification/performance-matrix.md maps the dimensions below to exact
historical reports, smoke-only evidence, active captures and unmeasured requirements. Historical
source cohorts do not qualify the cost of subsequent implementation changes.
| Workload family | Required dimensions |
|---|---|
| Small patch, growing estate | N = 100, 1,000, 10,000; fixed 1/10-resource changes; isolated nodes, chains, forks and diamonds |
| Reconciliation | No-op, concrete update, replacement, deletion, changed outputs/provider settings, unrelated drift and stale-branch preservation |
| Dependency breadth | Fanout 100/1,000/10,000; concrete versus stack/app-scoped reads; known versus unknown provenance |
| Writer contention | 1/2/4/8 concurrent actors; disjoint writes, shared read-only producer, conflicting writes and changing shared inputs |
| Provider/transport cost | Simulated deterministic delays and real-provider runs reported separately; local database and a measured added-latency profile |
| Failure cost | Runner loss after dispatch, database outage and recovery; measure time blocked/recovered as well as successful throughput |
The I2 matrix must also distinguish unchanged shared producers, drifted boundary inputs, removed edges and unrelated graph partitions. Measure selection waves, newly visited nodes/edges, index queries, full-view restarts, digest/index maintenance per publication and compact-plan byte categories. Add high fanout over large shared values/files; report distinct input keys, payload-cache hits, repeated payload bytes, scan/loop counts and SQL plans for fresh and analyzed caches. Include a later wave that invalidates pruning and a missing local artifact despite equal stored outputs. Treat foreign embedded benchmark figures as hypotheses to reproduce on matched workloads, not measurements of Netherframe or a licensed Stategraph deployment. A saved-plan size improvement is a separate result from fewer provider RPCs. Include warm and invalid cache paths, and record cache reclamation without removing durable safety evidence. For a future I4 selection prototype, add a three-state chain, a two-producer join and whole-output enumeration before claiming transitive discovery; the existing bounded two-state protocol results do not cover these.
Use the same graph, effective configuration, resource count/payload, provider versions, refresh policy, initial cloud state, operation parallelism, client/database sizing and network placement. Reset fixtures between measured runs. Warm provider/module/schema caches equally or label runs cold; randomize paired run order. Drift-policy or concurrency-contract differences get separate rows, not one misleading speedup. Multi-state cases remain capability comparisons until I4 ships.
Measurements. Separate Python/HCL construction, manifest/diff, state reads, refresh, evaluation, provider planning, admission/wait, apply/provider calls, durable publication and recovery. Record wall-time samples, CPU, peak RSS, loaded rows/bytes, SQL query and wait time, provider RPC counts, grant size/mode, closure/fallback size, renewals, p50/p95 latency, conflict/replan rate and verified throughput. Where a commercial service does not expose a metric, mark it unavailable; do not infer server work from client latency. Capture frontier/ownership contention separately from provider time, because the current per-app commit counter serializes publication.
Evidence and gate. Use at least one warm-up and seven measured repetitions for steady-state latency comparisons. Publish raw samples, all failed/interrupted attempts, fixture/harness versions, source hashes, environment and commands under the performance results convention. Failed runs are excluded from success latency distributions but included in failure rate; correctness assertions gate every successful sample. A comparative speed claim requires a repeatable difference under matched settings and an uncertainty estimate, not the fastest sample. Seven repetitions are a minimum for a preliminary comparison, not sufficient evidence of stable tail latency; publish sample counts and collect enough observations for any p95 claim. For internal regressions, compare only matching fixtures/settings on the same host and use the existing 15%/prior-five baseline policy once enough comparable captures exist. Structural read/RPC bounds belong in regression tests; noisy wall-time thresholds do not.
Proposed Write-Path Redesign and Backend Reassessment
Status: bulk SQL and scheduler integration implemented, with one successful original 10,000-row retest, 2026-11-10; broader redesign and repeated performance qualification remain open. The user requested a return to the design after the large native and Stategraph observations. This proposal does not replace the safety contract or authorize restarting the paused qualification matrix.
What the evidence establishes. E26's historical native normalization made 10,000 graph commits and roughly 265,000 SQL queries with no provider mutations; the bounded optimized observation still took 350.90 seconds. E49 now repeats that real-provider fixture on the current combined implementation in 177.41 seconds, with 202 publications and 27,547 body SQL queries; details and limits follow below. E46's Stategraph creation apply timed out at 900 seconds and showed substantial local Terraform CPU/process I/O; no unchanged-state phase was reached. These observations do not establish the same root cause, a PostgreSQL capacity limit, or a general native-versus-Stategraph speed ratio.
Current implementation facts explain why a database swap alone is insufficient:
GraphStateEngineordinarily publishes each record in its own transaction.GraphStateBackend.commitalready accepts multiple writes. The initial PostgreSQL implementation performed per-write SQL inside that transaction; E47 adds a bounded set-based path for eligible existing-resource batches. Other writes retain that loop._commit_onincrements the shared app frontier before entry publication, dependency invalidation and operation resolution. That row stays locked until commit.- Admission permissions remain JSON projections; target membership work grows with their encoded set. The graph is already stored as rows with durable operation records.
Atomicity to preserve. A publication transaction must atomically validate authority and expected versions, publish resource/identity/edge changes and invalidations, resolve its operations, and record history and the commit receipt. Multi-query readers must use a consistent snapshot or version validation so they do not combine different publications. Acknowledgement follows durable database commit, with the configured storage/replication failure model made explicit. A whole apply still spans external provider calls and cannot become one ACID transaction merely by changing the state database. Durable dispatch, uncertain-outcome quarantine and claim-based recovery remain necessary. Database transaction retries must never re-execute an external provider mutation.
Recommended first prototype: preserve PostgreSQL, change publication shape.
- Canonical writes and semantic no-ops. Persist the complete canonical resource representation when its values, provenance and identity evidence are available. Avoid a later blanket normalization pass where this is possible. Skip an unchanged row only when its complete state/intent/provenance/context/status is unchanged and required version/authority checks still hold. A provider no-op alone is insufficient. Genuine metadata upgrades still publish, using the bulk path below.
- Set-based state-only publication. Start with bounded batches from one run and one immutable grant. Fetch and validate their rows/permissions together; publish entries, history and edge changes with set-based SQL; compute affected consumers over the combined delta. Bound batches by bytes as well as row count. A conflict rejects the entire batch, retaining the rejected input and diagnostic; it must not silently turn into partially accepted row writes. Keep separate bulk-metadata and provider-result workloads, since their scheduling/recovery requirements differ.
- Indexed permission lookup. Evaluate a transactionally maintained exact
(run, kind, target)permission relation instead of scanning a run-wide JSON set on every write. Immutable admission remains authoritative. Missing/stale projection rows fail closed; renewal, replacement, release, migration and tamper tests must establish exactness before this can replace the current projection. - Durable completion batching. After the state-only path is proven, collect independent returned results from the same run into small bounded commits. Each caller waits for its durable receipt; dependents cannot consume a merely queued result. Never hold a database transaction open while a provider runs. Preserve a durable returned-response record or equivalent recovery path while awaiting publication. A batch identity plus payload identity must distinguish safe retries from reuse with different contents after an ambiguous commit response.
- Reduce the serialized interval. Initially keep the modeled app frontier and amortize its lock across a batch. Move work out of that lock only where the lease, row and predicate guarantees prove it remains valid. Replacing the frontier with a SQL sequence is not equivalent: the existing model depends on committed ordering. Partitioned frontiers or database-native snapshot versions need a separate model and baseline/history/retention design before adoption.
The existing commit interface is the starting seam. Do not introduce another generic storage interface merely to rename the same row-by-row protocol. An optional coordinator near the database or a server-side publication function can reduce client round trips; neither is selected yet. Provider execution stays outside it. Large immutable payloads may later move behind durable content references, but adding object storage does not address the demonstrated overhead on 1 KiB fixture values.
Backend candidates. These are design assessments, not benchmark rankings.
| Candidate | Relevant guarantee/capability | Fit and cost for Netherframe |
|---|---|---|
| PostgreSQL with the revised write path | Atomic multi-row transactions, MVCC, constraints, indexes and durable WAL | Recommended reference prototype; preserve the current protocol and operational model while measuring transaction/query amplification directly. Transactions, durability |
| FoundationDB | Distributed ordered key-value storage with strictly serializable transactions | Strongest alternative for a distributed transactional core. We must implement graph/history indexes and qualify deployment, Python bindings and recovery. Transactions have a five-second lifetime, a 10,000,000-byte affected-data limit and 100,000-byte values. Our provider calls must remain outside transactions. Retaining a shared conflict key would retain contention. Transactions, limits |
| DynamoDB | Conditional item writes and atomic transactions within an account/Region | Viable managed AWS option for small publication groups. Its 100-item/4-MB transaction limits complicate large grants, graph invalidations and multi-entry atomic moves; splitting them is not equivalent to one transaction. Costs and extra indexes also need measurement. Transaction contract |
| SQLite in WAL mode | Atomic transactions and concurrent readers on one host; one writer at a time | Useful embedded baseline or a database behind one state-service writer. Sharing a WAL file among separate CI hosts is unsupported; replication/failover would become our responsibility. WAL |
| etcd | Transactional metadata/coordination store | Consider for small coordination facts rather than the whole history/payload store. It targets small values, defaults to 1.5-MiB requests and 2-GiB storage, with 8 GiB a suggested normal maximum. Splitting authority and publication across two stores adds protocol obligations. Limits |
A short decision gate before another end-to-end matrix. Use an already populated, validated fixture and report preparation separately. Measure unchanged-state inspection, a one-row publication, 10,000 genuine state-only metadata changes, and disjoint versus conflicting publishers. Measure transactions, SQL requests, transferred bytes, lock hold/wait time and durable acknowledgement latency, alongside correctness. The design targets zero resource/history writes for a semantic no-op and publication work proportional to changed rows plus genuinely affected edges, rather than the entire estate. Full refresh and a genuine all-consumer invalidation still legitimately require broad work.
Use a five-minute total diagnostic budget, stop on its first failure, and do not start providers or hosted creation for the storage-only cases. An initial performance target for discussion is under ten seconds for 10,000 1-KiB state-only updates on the pinned local database, with all fences/history enabled; it is a design target, not a promise (the first E47 observation below does not meet it). Crash before/after publication, lost commit replies, lease expiry while queued and conflicting batch members must preserve the existing outcomes. Compare an alternative backend only behind the same publication contract and failure cases, with equivalent durability and deployment placement. A faster bare key-value write is not equivalent to a qualified graph-state publication.
First prototype outcome (E47). The existing commit seam now selects bulk entry and history publication for 2–256 distinct existing canonical managed resources, with unchanged physical identity, provider/type and private state, and a 1-MiB SQL payload bound. Unsupported requests retain the general writer without splitting an atomic request. Admission, ownership/operation checks, expected versions, edge and semantic revision triggers, invalidation, frontier and final fencing remain in force. No schema change is required. Twelve new bulk cases and the selected existing suites cover 142 distinct checks, including whole-batch rollback, expiry after SQL, unknown ownership, admitted targets, transitive invalidation, disjoint publishers and no visibility/acknowledgement before durable commit.
In one storage-only diagnostic, 10,000 1-KiB chain resources in 128-row transactions
took 16.63 seconds with bulk SQL versus 34.28 seconds with the old SQL loop;
recorded SQL requests fell from 51,425 to 1,817. Both used 79 publications. The entire
diagnostic took 101.16 seconds including setup and verification, with no provider calls.
The sub-ten-second target remains unmet. This is a single sequential app-X observation,
not an end-to-end apply, resource-grant admission benchmark or Stategraph comparison.
At E47 the ordinary apply still published each node separately; E48 below implements
state-only grouping with durable per-node acknowledgement. Initial
canonicalization, indexed permissions and provider-result batching remain proposals.
Exact scope, source identity and results are in
the repository's specs/graph-state/qualification/2026-11-10-i5-bulk-publication/README.md (E47).
Scheduler integration (E48). Ordinary graph apply now prepares state-only no-op writes without changing cached state and queues compatible writes under the same run and admission. The queue bounds pending/in-flight rows to 128 and uses a conservative 1-MiB serialized budget, with a 20-ms maximum collection window and immediate flush when there are no scheduled peers. Backpressure precedes yielding execution capacity. Nodes and their consumers remain blocked until a durable receipt. Read/write overlaps are separated; provider operations and outputs retain their existing path. Queued cancellation removes a write, in-flight cancellation drains the outcome, and ambiguous replies stop the queue without an automatic retry. Existing journals retain attempted writes; stale publication results require replanning rather than successful acknowledgement.
A same-source real-provider 1,000-row normalization observation takes 12.13 seconds
versus 20.21 seconds with batching disabled: 21 versus 1,000 publications, 2,878 versus
26,644 transaction-body SQL requests, zero provider mutations, and 1,000 final ready rows.
Both final service/state checks pass. This is a single pair, not a percentile or a claim
about the old 10,000-row workload. A separate synthetic 10,000-row scheduler diagnostic
hits its five-minute cap after falling back to app X; final checks are not reached.
It stays failed, with no retry. At E48, large normalization remained an open gate
requiring a qualified fixture and a grant-mode witness before measured writes. See
specs/graph-state/qualification/2026-11-10-i5-normalization-batching/README.md for scope,
source identities, raw outcomes and validation. The broader campaign remains paused.
Original six-minute case retest (E49). At the user's request, the original 10,000-resource real-provider fixture is recreated: 2,500 chains of four SSM parameters, 1-KiB values, AWS 6.66.0/FakeCloud, local PostgreSQL 16.15, parallelism 10 and full planning. Normalization takes 177.41 seconds versus 350.90 seconds in the historical certified case, with 202 versus 10,000 publications and 27,547 versus 265,208 transaction-body SQL requests. This is 49.44% less observed elapsed time. Creation takes 470.93 seconds separately; setup, normalization and verification all finish in 658.12 seconds under the original 1,200-second cap.
The actual resource grant is checked before writes, exactly covering all 10,000 targets; an unexpected app-X fallback would stop publication. All publications retain the same admitted resource run/epoch. There are no provider mutations in normalization, all 10,000 final resources are ready, independent service/state values match, all 7,500 direct input revisions are current and no operations remain unresolved. Production source is unchanged throughout the capture. The comparison includes intervening permission-query improvements as well as bulk SQL and scheduler batching; there is no same-source disabled control at this size and only one sample per build.
The remaining work is material: full refresh/planning and admission precede publication,
and 7,500 consumer invalidations still use per-row writes. Canonical initial state,
indexed exact permissions and batched invalidation remain design work. Repeated
performance, provider-result batching and an equivalent hosted comparison remain open.
The E48 failed synthetic attempt stays failed and the wider matrix remains paused.
Exact source, grant, timings and checks are in
specs/graph-state/qualification/2026-11-10-i5-original-normalization/README.md.
Remaining-work diagnosis and next slices (E50). The E49 trace still contains 22,500 calls for 7,500 stale consumers: one row lock/read, full entry upsert and history insert each. That is 81.68% of body requests but 9.05 seconds of accumulated SQL time. Consumer discovery costs 10.67 seconds and admitted-target checks 9.90 seconds; the frontier increment costs only 0.83 seconds. These are overlapping query durations, not exclusive whole-apply shares.
- Add bounded status-only consumer publication inside
_mark_stale_inputs' existing transaction: collective locks/CAS, minimal updates, complete set-based history and returned versions. Preserve transitive waves, output/scope semantics, planning-context clearing and the final fence. A small probe reproduces 24 fixed calls plus three per consumer; require a request budget based on chunks/waves and equivalent history, readiness, rollback and late-expiry outcomes before promotion. - Add a batch-aware admitted-membership query. Expanding the authoritative permission array once takes 7.47 ms versus 89.37 ms for 80 late targets in an isolated 10,000-target probe, but is slower for one target (7.46 versus 1.46 ms). Keep the cheap single-target path; measure the crossover and qualify auxiliary/wrong-kind/action/empty/re-admission cases. This SQL-only prototype precedes a persistent indexed permission relation.
- Instrument batch flush reasons and byte occupancy before changing scheduling. E49 has 101 small 16/17-row commits. A queue-only probe reproduces large/small alternation from a shared pending/in-flight budget. Extending collection from 20 to 200 ms reduces commits but increases total time. Evaluate bounded double buffering or refill-aware collection with unchanged durable acknowledgement, memory bounds, cancellation and read/write separation.
Canonical initial state has a concrete additional lead: in two eight-resource
real-provider runs, every row's first unchanged publication changes SSM tags from
null to an empty map. Root publication then invalidates consumers; some consumer
input evidence also narrows. The next unchanged apply makes zero publications.
Investigate a provider-qualified create/refresh canonicalization and stable initial
input capture; do not globally equate null and empty collections or discard changed
provenance. This is not yet a canonicalization fix or a measured 10,000-row steady case.
The first reverse-edge consumer-query prototype is slower than the existing GIN
lookup and is rejected; exact-key and broad-scope paths need a better query shape.
Reusing locked old rows within one transaction and selecting version-only input
columns are secondary opportunities. No production code changes in E50. Probe source,
plans, initial harness failure, positive/negative results and release gates are in
specs/graph-state/qualification/2026-11-10-i5-remaining-sql/README.md.
Implemented storage follow-up (E51). PostgreSQL now publishes evaluated stale
consumers in bounded groups inside the producer's existing transaction. Each group
locks/checks versions, updates only status/revision/publication metadata, and inserts
complete history from the database rows. Unchanged entry/input columns are not assigned,
so their reverse-edge triggers do not repeat. The existing changed_inputs decision,
transitive waves, output handling, scope/enumeration semantics and final ownership fence
remain authoritative. Chunks hold at most 128 rows and 64 KiB of target descriptors;
this bounds statement parameters, not history payloads or transaction size. All chunks
roll back with the producer on a late conflict or ownership loss.
Older schemas and rows needing canonical-document, identity/private-column or sensitivity repair retain the ordinary writer before any bulk changes. Compatibility tests exposed the identity/name repair requirement during review; the final implementation preserves that behavior explicitly. Complete private data, masked history, semantic counters and planning-context clearing are covered against both writer paths.
Admission membership expands the authoritative write/auxiliary arrays once for batches of at least 64 targets; smaller checks retain the existing containment query. The threshold is conservative, not a measured universal crossover. Exact kind/key membership, possible actions, generated-column fallback, renew/release and re-admission semantics remain checked within the owned transaction. No schema migration or additional durable permission relation is introduced.
The final PostgreSQL regression selection passes 583 checks with two skips. One
same-source sequential 10,000-resource storage pair takes 50.82 seconds with the
ordinary paths versus 32.27 seconds with the changes; body requests fall from 25,866
to 3,648 with 128 publications each. All 7,500 invalidations and final state/input checks
pass. Control runs first and includes one ownership renewal; these are observed phase
timings, not isolated component costs or a percentile estimate. An eight-resource
provider compatibility smoke also passes. Exact source, raw outcomes and limits are
in specs/graph-state/qualification/2026-11-10-i5-sql-batching/README.md. This slice does
not change queue buffering, provider tag normalization or provider-result commits. The
original 177.41-second real-provider case has not been rerun with E51; storage timings
must not be presented as a new end-to-end result or a Stategraph comparison.
Fresh-creation follow-up (E52). Initial setup is now a first-class measurement: an empty state, actual provider creates, no normalization warm-up, and independent state/service checks. Eligible successful creates share bounded final publications. Each provider response is still written durably before queueing; resource rows, complete history, operation stages and frontier commit together, and every caller waits for that durable transaction. Eligibility uses the existing canonical-identity and authoritative-input contracts; unsupported records, partial errors, replacements, updates, imports and deletes retain their existing path. A cohort captures its owner and admission, excludes read/write overlaps, and retains failed attempted writes in recovery journals without automatic retry. Queued but unattempted creates retain their durable returned operations. PostgreSQL fault tests cover both app-X and resource grants.
Creation uses the normalization queue's 128-row/1-MiB/20-ms bounds in its own queue, but retains execution slots until publication. The first implementation released them: its 1,000-resource comparison reduced publications from 1,001 to 208 while slowing creation from 38.44 to 41.95 seconds. More outstanding operations increased contention and repeated ledger decoding. That variant is rejected. A two-slot regression test catches four callers entering before the earlier publication is durable; the corrected queue keeps only two. The worker requires no execution slot.
SQL changes skip known-empty row reads and the duplicate dispatch request fetch. Unadmitted app-X dispatch also reuses the ownership transaction's locked admission status instead of querying empty plan permissions; admitted runs retain that check. Within a transaction holding the app-row lock, object validation reuses the unresolved ledger read for footprint validation; it still queries current entry candidates for each write. No reservation, dispatch or publication can enter during that reuse; return/abort can only relax the captured evidence. This is not a cross-transaction cache. A three-create regression drops repeated ledger reads from 16 to 7. Consumer lookup groups reverse-edge targets and broad observers separately, then applies the unchanged input-change oracle. Cold/shared-statistics regressions reject the earlier per-target query that multiplied a poor index choice by the number of targets.
The final same-source 1,000-resource pair takes 40.29 versus 32.90 seconds, 61,386 versus 41,783 body requests and 1,001 versus 303 publications. Observed read/write transactions fall from 4,009 to 3,311; each path still performs 1,000 provider mutations. The original-size fresh 10,000-resource creation takes 375.50 seconds versus E49's historical 470.93, with 416,732 versus 612,748 requests and 3,005 versus 10,001 publications. Every value, input revision, ready row, committed response and independent service/state check passes. The large run observes 33,024 read/write transactions, including 30,000 separate reserve, dispatch and return transactions. It is a historical comparison, not a same-source control at that size. The smaller result is one sequential pair; neither is a percentile, WAN or Stategraph claim. The final dispatch guard passes 302 creation/admission checks; earlier broader selections pass 218 (two skips) and 553 backend/provider checks.
Remaining implementation slices, in priority order:
- Bulk SQL inside creation cohorts. Publications are grouped, but operation locks, resource inserts, history inserts and final operation transitions still loop per row. Add a bounded multi-operation lock/read and bulk insert/transition path, preserving each request/response binding, expected revision, incarnation, mutation counter, private data and masked history. Validate all candidates and intra-cohort identity collisions before writes; retain the existing writer for unsupported/mixed records. Gate with equivalent complete snapshots/history and last-row conflict, expiry and lost-reply schedules. Do not split the atomic publication to meet statement bounds.
- Reduce reserve/dispatch serialization. Each resource still takes three durable operation transactions before publication and two app-row locks for reserve/dispatch. Investigate grouped operation metadata transactions or a narrower proven exclusion boundary. A provider call must never start before its own durable dispatch receipt; every request keeps its exact footprint, owner, stage and preconditions. Preserve alias/generated-name, negative-read, replacement, cancellation and recovery exclusion. Keep raw returned responses durable immediately. More parallel tasks or a longer collection timer are not accepted without lower end-to-end time and bounded outcomes.
- Stable first-refresh representation. The eight-resource fixture still writes
metadata on its first unchanged apply. AWS 6.66 SSM returns
tags=Nonefrom create and{}from refresh; explicitly configuring{}does not fix it. A diagnostic-only canonicalization leaves two publications because deeper nodes replace retained planned-ancestor inputs with direct reads. Define provider/type/version-specific semantic equivalence and fresh-evaluation provenance replacement separately. Preserve cached, opaque, provider-config and saved-plan evidence. Gate with zero corrective publications immediately after creation, plus real drift and stale-reader controls. - Avoid redundant provider planning only with evidence. The original fresh fixture performs two PlanResourceChange and two ValidateResourceTypeConfig calls per resource. Reuse only a qualified plan whose resolved configuration, schema/provider identity, private state and input evidence are unchanged. Nodes consuming newly created values still need their actual apply-time configuration. Measure RPC reductions separately from SQL and preserve saved-plan/refusal behavior.
Exact source, rejected variants, query traces, transaction/cohort counts and correctness
receipts are in specs/graph-state/qualification/2026-11-10-i5-initial-creation/README.md.
The ten-second target, zero first-refresh corrections and broader hosted performance
claims remain open.
First-Principles Write Limits and Optimization Plan (E53)
This is a derivation and proposed implementation contract, not a new performance result. E52's fresh 10,000-resource creation remains the measured baseline: 375.50 seconds, 416,732 body SQL requests, 33,024 read/write transactions and 3,005 graph publications. No database replacement is necessary to remove most of this protocol overhead. The exact count optimum depends on dependency visibility, response durability latency, outstanding-operation capacity and serialized bytes.
Count the right things. Let N be provider mutations, G their actual
state-consumption DAG, H its longest chain in mutations, and L the number of
operations with nonempty input evidence. Let C be active execution slots, W
the permitted authorized-but-unpublished operation window, B a cohort's resource
capacity and M its serialized byte budget. Distinguish:
| Quantity | Meaning | What batching can change |
|---|---|---|
Q_body |
Counted client SQL calls inside the instrumented transaction body | Set-based SQL or a server routine can reduce calls without reducing transactions |
T |
Committed database transactions | Durable facts for different operations can share a transaction |
P |
Published graph frontiers | One frontier can cover many resource/history/receipt changes |
R |
Causally sequential database acknowledgement rounds | Transport pipelining cannot remove a dependency on an earlier acknowledgement |
F |
WAL flushes | Several transactions can share a flush; F is not T |
The E52 logger excludes BEGIN, COMMIT, connection housekeeping and the combined
SET LOCAL call before each write transaction. Its grouped query inventory is one
call below Q_body in each final capture; retain that discrepancy rather than
silently claiming a perfect per-query reconciliation. Capture full protocol traffic
and server execution separately in the next instrumentation slice. Summed SQL
durations overlap across callers and include waits; they are not a wall-time breakdown.
PostgreSQL's synchronous durability and shared flushes
also explain why a transaction count is not a physical flush count. Disabling
synchronous commit would weaken the pre-provider durability contract.
The irreducible ordering is two durable facts per mutation, not four transactions.
For each operation i, under our existing external-provider architecture:
durable authorization A_i < mutating provider RPC_i < durable completion Z_i
The first fact binds the owner/epoch, exact request, footprint, expected state and
input evidence before external effects are allowed. The second retains the actual
outcome and eventually publishes acknowledged state. They cannot be the same
transaction: the provider is outside PostgreSQL and must run after the first commit.
These are 2N causally placed facts, not necessarily 2N distinct transactions.
Independent operations can share both kinds of fact, and one transaction can complete
earlier operations while authorizing other, already-ready operations. Neither
2N nor 2 * ceil(N/B) is a universal transaction lower bound. No transaction
should remain open across a provider RPC. Unknown outcomes still require quarantine;
batching does not create exactly-once cloud effects.
Reserve and dispatch can become one arm transaction at the final prepared-call seam. All request construction and pre-call checks must precede it, with current state/input/identity/grant validation inside it. This removes the separately durable known-unsent reservation state on the fast path; a crash after arming and before send remains conservatively ambiguous, as it already is after today's dispatch commit. Operations needing an earlier protected reservation keep the existing path.
Return and publication can share a complete transaction, but a publication
conflict must not erase the raw provider response. A candidate implementation records
raw responses in the outer transaction, attempts atomic publication inside a
savepoint, and commits the responses as RETURNED if publication is rejected.
Return structured rejection receipts instead of throwing away the outer transaction.
The same isolation is required for failed arms in a mixed transaction. Ownership
loss or failure of the entire transaction still uses the retained-response journal
and existing recovery protocol. A lost commit reply must be resolved by operation ID,
attempt and request digest before any retry; it never licenses another provider call.
Publication lower bound under today's dependency visibility. A child consumes
its parent's published state. Therefore a publication's mutations must form an
antichain of G: a parent and its child cannot be created in the same publication.
At most B_eff = min(B, W) operations fit, with bytes potentially reducing it further.
For uniform sizes and sufficient bytes:
P_resource >= max(H, ceil(N / B_eff))
The proof is direct: a chain needs distinct ordered publications, and capacity needs
enough publications to hold all mutations. This bound is necessary, not sufficient
for every DAG. A root, four leaves and a final join need four publications at capacity
two, although both H and ceil(N/2) are three. The exact count is the smallest
ordered partition into capacity-feasible antichains. Summing ceil(level_size/B_eff)
over levels is a feasible construction, not a general optimum. For nonuniform records,
also require each cohort's serialized bytes to fit M; ceil(total_bytes/M) is
another necessary bound when every record fits. Oversized singleton exceptions
must be modeled separately. A 1-KiB resource value is not a 1-KiB request/history record.
E52 has 2,500 independent four-node chains: N=10,000, H=4, L=7,500.
Creation retains its execution slot until publication, so today W=C=10;
the configured 128-row ceiling cannot produce a 128-create cohort. The observed
3,005 publications contain 3,004 resource cohorts and one literal revision="v0"
output publication. Earlier E52 prose calls the latter metadata; the trace shows an
output, not an app-metadata update. A separately published literal output is not a
fundamental extra frontier: it can join a resource cohort if its contract and capacity
permit. Dependent outputs need their own visibility analysis.
| Ideal count schedule for this fixture | Resource publications | Separate arm/complete transactions | Mixed transactions |
|---|---|---|---|
| Window/capacity 10 | 1,000 | 2,000 | 1,001 |
| Window/capacity 128, sufficient bytes | 79 | 158 | 80 |
| Unlimited window/capacity/bytes | 4 | 8 | 8 |
These are achievable mathematical schedules under the stated model, not measured targets or guarantees for arbitrary provider arrival times. They exclude lifecycle, planning reads, renewal, faults and auxiliary output work, and permit outcomes to collect before a shared durable completion. Mixed transactions have capacity for both one completion cohort and one arm cohort, including their combined bytes. At capacity 128, 80 publications is a level-barrier construction; 79 is attainable by putting all roots, then all second nodes, and so on in consecutive 128-node chunks. A chunk may cross a level boundary using unrelated chains. Every parent is in a much earlier chunk. At capacity 10 the same construction gives 1,000 chunks.
In a mixed schedule, initially arm chunk 1; then complete chunk j and arm chunk
j+1; finally complete the last chunk. Child requests may only use parents committed
before their arm transaction. That condition holds for the 10/128 constructions
because there are many independent chains between parent and child chunks. It fails
when each unlimited chunk is a complete level, requiring separate transactions there.
With strict published-parent-before-child-preparation semantics and separate uniform
arm/completion caps, necessary bounds include:
T_hot >= max(2H, ceil(N/B_arm) + 1, ceil(N/B_complete) + 1)
A chain alternates A, Z, A, Z; the last authorization needs a later completion,
and the first completion needs an earlier authorization. These bounds are attained
by the fixture schedules above, but not by every DAG or byte/window constraint.
The small model's root/four-leaves/join example needs seven transactions although
this expression gives six. Speculatively preparing a child from a returned parent
and committing parent completion plus child authorization together would weaken
the strict ordering to Z_parent <= A_child. That is another interface and proof
obligation; its unlimited four-level ideal would be five transactions, not eight.
It is outside the recommended first implementation.
Prompt raw-response durability is a separate constraint. The current path starts
persisting each returned response immediately, before publication collection. If
returns are staggered and each must become durable before waiting for another, the
worst-case receipt count remains N. We cannot promise the table's mixed counts while
also promising prompt individual receipts for every arrival schedule. Group already
pending returns when possible; do not extend their memory-only window just to hit a
count target. A local durable journal could protect a larger collection window, but
then local writes/flushes and recovery transfer are real costs, and machine-loss
semantics differ from PostgreSQL durability. This is a Pareto tradeoff between count,
latency and exposure, not a free optimization. With current separate receipts, even
perfect publication filling leaves T_hot = 3N + P_resource = 31,000 at capacity ten.
One final publication is possible only with a different visibility contract.
If children read a durable private execution view, provider outcomes can be staged
and a final generation/pointer switch can expose all rows together. Then a successful
nonempty initial apply can have P=1, despite H=4. Staging still needs request and
result durability; the bytes and row work remain, and public readers no longer see
incremental ready state. Recovery, partially successful applies, retained footprints,
cross-run reads, generation-qualified revisions and visibility of outputs all need
new rules. A zero-change converged apply has P=0. Neither one-shot execution nor
atomic SQL implies one transaction for external effects. Do not replace the current
incremental protocol with private staging as an incidental batching optimization.
The current SQL slope, derived from the implementation and E52 traces. For
eligible fresh app-X creates without faults, reserve and dispatch each use 11 body
calls plus two when inputs are nonempty; raw return uses six. Resource publication
uses six calls per resource, 14 per cohort, plus two for a cohort with inputs.
Let P_in count those input-bearing cohorts. Thus:
Q_hot = 34N + 4L + 14P_resource + 2P_in
T_rw = 3N + P_graph + renewals + 7 [the two recorded E52 captures only]
For 10,000 resources, P_resource=3,004 and P_in=2,254 give Q_hot=416,564;
the remaining 168 calls belong to output/lifecycle/read/renewal accounting, including
the one-call counter discrepancy. At 1,000 resources the same formula gives 41,680
and a remainder of 103. This is a fixture-specific accounting model, not a formula
for arbitrary actions, scoped grants or failure paths. Uniform full ten-result
cohorts give Q_hot=385,500, saving only 31,064 calls (about 7.5% of measured body
calls) and 2,004 transactions. Filling the queue cannot remove the dominant 34N+4L
term. Operation locking, row/history insertion, identity checks and stage transitions
need set-based treatment, as do reserve/dispatch validation and repeated ledger reads.
SQL-call optimum is an interface choice. There is no database-independent
minimum number of SQL statements: one server routine can execute many internal
statements; a protocol message can carry multiple commands or transactions. State
explicitly what is counted. Under a proposed one-command-per-atomic-batch adapter,
the hot write path can approach Q_submit = T_hot: one submitted server command
per arm/complete/mixed transaction, plus separate reads and lifecycle costs.
Consequently the table's 1,001/80/8 transaction schedules could have the same numbers
of hot-path command submissions under that adapter. They do not imply 1,001/80/8
internal statements, WAL flushes, full-apply requests or today's Q_body measurements.
Materializing arbitrary N resource records and E dependency edges still requires
at least proportional record work and payload transfer; a routine must not merely
hide the same per-row SQL loop behind a smaller client counter.
Pipelining can reduce network waits, but cannot remove client-side data dependencies. A server routine must also preserve post-lock visibility and a fresh clock at the final fence. Putting everything in one giant CTE is not an equivalent proof: data-modifying CTEs share a snapshot. A suitably tested volatile function can obtain fresh snapshots for internal queries. Preserve lock order, current grant checks, tail fencing and commit acknowledgement explicitly; returned rows alone are not a successful commit receipt.
Implementation sequence and acceptance contracts. Put scheduling behind a deep
operation-write module at the engine/backend seam. The caller's interface should be
arm(prepared_call) -> durable_dispatch_receipt and
complete(receipt, raw_outcome, prepared_write) -> durable_completion_receipt.
The latter distinguishes published, durably returned but unpublished, rejected and
uncertain outcomes. PostgreSQL and the existing in-memory backend are adapters;
an internal advance(arms, completions) may combine compatible work. Callers must
not know SQL batch sizes, savepoints, lock scheduling or transport packaging.
- Repair accounting, then bulk the existing protocol. Record complete wire-call,
body-call, transaction, publication, serialized-byte and queue-delay counts;
distinguish active RPCs from authorized/returned/unpublished operations. Bulk
operation locks and request reads, current rows and identity candidates, row/history
inserts and final stage transitions. The no-fault app-X creation publication budget
is at most 22 body calls (
14 + 6 + 2), independent of cohort size, replacing14 + 6k + 2forkresources with inputs. This is an implementation budget to verify, not an observed result. Preserve intra-cohort identity/footprint conflicts, exact private data, mutation revisions, inputs and complete history. Do not skip checks just because initial state was empty: our own earlier creates make it nonempty. - Fuse and batch authorization. Prepare immutable requests before entering the arm queue. Validate them as a bounded set under one authoritative exclusion and ownership transaction; insert dispatched operations and return individual receipts. A batch may contain only mutually compatible operations with already committed inputs. Retain the earlier-reservation path where needed. Never substitute a cached empty-state/app-X certificate for same-run alias, negative-read or current-input checks. This removes a complete validation/locking pass per operation and amortizes the remaining pass, attacking the dominant slope rather than just publications.
- Fuse completion without sacrificing raw returns. Implement the savepoint and durable receipt design above, including a return-only path on publication rejection. Drain already queued responses promptly; retain separate immediate receipts when assembling/publishing a cohort would delay them. Use bounded queues with completion priority and renewal fairness, and avoid coupling a slow sibling to every caller's result durability. Cancellation after submission must drain/resolve the transaction.
- Combine independent completions and arms; then package server commands. Preserve per-operation acknowledgement, prevent failed arms from discarding returned results, and acknowledge no new provider call before the mixed commit. Move validated set-based decisions into a server routine only when its snapshots, fences and errors are equivalent. Compare internal statements, row visits, lock time, WAL and end-to-end time as well as client submissions. Keep the reference adapter as an oracle.
- Tune the window after reducing ledger cost. Treat
C,W, row/byte caps and collection latency separately. IncreasingWcan approach larger antichain batches without increasing provider concurrency, but the rejected E52 yielding variant already shows that it can slow the run. Flush when it releases critical-path work, reaches a bound or hits a latency deadline; never wait for a full cohort whose missing work depends on that cohort. Measure the Pareto curve instead of optimizing publication count alone. Fold eligible literal outputs into a final cohort. - Finish the one-shot contract. Qualify create/read canonical representation and replacement of planned-ancestor provenance with actual direct reads, so the first unchanged apply has zero corrective publications. Reuse unchanged provider planning evidence only when resolved inputs, private state, provider/schema identity and configuration are identical. The observed 20,000 plan and 20,000 validation RPCs remain a separate source of work even if SQL reaches its count optimum.
Fresh-create provenance checkpoint (E61). A qualified, fully evaluated live create now replaces speculative planned ancestors with its actual recorded reads. Concrete reviewed inputs, carried cache provenance and provider configuration reads remain authoritative; stale cache evidence still refuses before an effect. The complete-evaluation indication resets before every evaluation and is never saved as plan permission. Detached saved plans, opaque/unqualified contexts, partial values, runtime checks and non-create actions retain the previous conservative behavior. A saved plan with its live app can qualify only through a new complete evaluation.
The four-node AWS 6.66.0 SSM chain retains three direct inputs instead of six ancestor
inputs, under app-wide and resource grants. Eight native cases, 263 targeted units
and all 60 hybrid conformance tests pass. The separate zero-correction gate remains
expected to fail because SSM's create/read tag representation still differs; private
data, service versions and mutation revisions remain checked. No provider semantic
normalization, reduced fixed grant, new timing ratio or complete one-shot guarantee
follows. Evidence: specs/graph-state/qualification/2026-11-10-i5-fresh-create-inputs/.
Qualified first-refresh representation (E62). AWS 6.66.0 SSM now has a separate
storage representation contract: a stored explicit tags=null remains null when
ReadResource returns an explicitly empty tag map. Only that field/type/release is
qualified. Nonempty maps, absent/unknown values, tags_all, private bytes and
identity data retain their observed values. Managed refresh, drift and recovery
share the adapter; protocol responses and durable Apply receipts remain raw.
The policy fingerprint participates in planning evidence, so policy changes cannot
reuse an earlier review. Existing states can require a one-time context update.
The first unchanged apply now adds zero corrective publications in 24 actual
provider cases: four-node description/tag chains, app/resource grants, full/affected
planning, and omitted/empty/populated/default/ignored/duplicate-default tags.
Independent SSM reads verify physical tags, values and version one. Other native
gates verify raw response preservation, real tag addition/removal/change and
default-tag drift repair, and the unqualified path's four corrective publications.
Missing plugins and different releases remain conservative. Unqualified refresh
boundary/deletion ordering and saved-target runtime revocation remain required.
The rule and pinned source review are in
specs/graph-state/qualification/aws-ssm-refresh.md; run evidence is in
specs/graph-state/qualification/2026-11-10-i5-refresh-representation/.
This closes the known first-refresh tag gap for the qualified fixture, not every
one-shot requirement: detached/opaque/check provenance, reuse of provider plan and
validation RPCs, completion/authorization scheduling and larger matched timings
remain separate work. No new speed ratio or live AWS/Stategraph result follows.
Original-size one-shot regression (E63). The E62 source now passes the original
10,000-resource fixture with 2,500 four-node chains, 1-KiB values and concurrency 10,
without a normalization warm-up. Fresh creation takes 212.706 seconds, 138,678 body
SQL requests, 15,037 read/write transactions and 2,209 publications. The first
unchanged full apply takes 68.260 seconds, 120 body requests and zero publications.
All 10,000 ready rows, 7,500 direct inputs, retained operation receipts and independent
service values/version-one observations agree before/after. Actual admission takes
the exact zero-write basis (app: IS), not app X. The whole attempt, including
setup and verification, finishes in 306.691 seconds under a twelve-minute cap.
The historical original unchanged apply took 350.895 seconds and made 10,000
publications; E49 took 177.407 seconds and made 202. This is one different-source
regression capture, not a repeated paired speedup or a completed I5 matrix cell.
It still performs 10,000 provider reads, plans and validations during full unchanged
inspection. Inclusive refresh/evaluation/intent timers are 19.883/30.393/10.563
seconds; counted SQL time is 1.290 seconds. Further unchanged-path work therefore
targets safe planning-evidence reuse and complete-manifest cost. Creation still has
10,000 separate return transactions and 20,000 plan/validation calls; E53's write
scheduling obligations remain. Evidence and explicit measurement limits:
specs/graph-state/qualification/2026-11-10-i5-one-shot10000/.
Exact provider-plan reuse prototype (E64). An explicitly enabled successful
validation/plan carries a request/result proof into apply and saved plans. The
prototype initially stayed disabled: correctness passed, but those elapsed-time pilots
did not beat the existing path. The qualified path is enabled by the 2026-11-16
follow-up after repeated creation-time improvements; see the current AWS SSM
planning qualification and planning_execution_20261116.json. Immutable fingerprint caching remains enabled. The request binds the actual
serialized validation and plan RPC payloads, protocol/resource/identity schemas,
qualified runtime/namespace and policies; the result binds planned values, unknown
marks, private bytes, identity and replacement decisions. Real encoded RPC requests are
observed without rebuilding them during planning; the apply-side proof check runs
in a worker thread. Schema observations at validation/planning and qualified
runtime observations around the pair must agree. Apply checks its newly evaluated inputs and current
prior state against the proof before reusing it. A provider profile must separately
opt into deterministic validation; only the restricted AWS 6.66.0 SSM profile does.
Computed outputs can remain unknown without requiring an identical RPC. Unknown inputs, changed context/schema/private data or a mismatched result retain validation and final planning, including the existing inconsistency checks. Runtime checks, provenance, saved-plan admission and operation/publication fences remain independent. Replacement still validates before deleting, and its new-object request has its own proof. Restarted clients must reproduce the observed context and schemas.
For N newly created resources and U resources whose planning inputs cannot be
reused, this path makes N + U validation/plan calls for ordinary creation. The
qualified four-node description chain has U = 0; an ARN chain has U = 3; absent
qualification or rejected evidence has U = 4. This counts provider RPCs, not the
local encoding/hashing work needed to prove equality. Full unchanged inspection
still refreshes, validates and plans each row. The first unchanged request has a
prior object where creation had null, so it cannot reuse the creation request merely
because configuration is unchanged. Persisting later no-op proofs or qualifying an
Apply-to-no-op implication would be separate work. Evidence:
specs/graph-state/qualification/2026-11-10-i5-plan-reuse/.
The first E64 candidate cut creation plans/validations from 20,000 to 10,000 at N=10,000, but increased creation time from the historical E63 212.706 seconds to 239.173 and unchanged inspection from 68.260 to 89.014. Its duplicate proof encoding is rejected and archived. Observing actual requests and caching immutable fingerprints reduces that overhead, but the subsequent same-source N=1,000 pilot still favors the reference at the production 20-ms window:
| Mode | Creation seconds | Body SQL requests | Publications | Plan / validation RPCs |
|---|---|---|---|---|
| Reference, 20 ms | 18.423 | 13,262 | 196 | 2,000 / 2,000 |
| Reuse, 20 ms | 20.227 | 13,713 | 224 | 1,000 / 1,000 |
| Reference, 40 ms | 20.999 | 10,963 | 119 | 2,000 / 2,000 |
| Reuse, 40 ms | 19.845 | 10,325 | 101 | 1,000 / 1,000 |
The 40-ms reuse run reaches the resource-publication count bound for the current retained-slot policy: 100 ten-resource cohorts, plus one separate literal output. It still loses on elapsed time. These single diagnostic points do not establish a repeated speed ratio or a global optimum; they explicitly separate the count objective from elapsed time. Every attempt preserves all direct inputs, returned results, ready rows and independent service versions; first unchanged inspection makes zero publications. Keep reuse disabled and production at 20 ms. Next work must reduce proof overhead and the scheduling/ledger costs together, then pass matched elapsed-time gates; do not promote either prototype solely for fewer RPCs, SQL requests or publications. The wider matrix remains stopped.
Adapter-local durable-return grouping (E65). A subsequent timer-free prototype groups already-queued raw responses inside the PostgreSQL adapter, including arrivals during its existing ownership checks. It preserves each operation's checks and the transaction's final fence, performs no publication and leaves the 20-ms publication window unchanged. Already-queued cohorts of 1, 10 and 64 responses use six SQL body requests and one transaction. Seventeen targeted native checks cover exact results, ownership/tail failures, cancellation, bounds and retained emergency journals.
Three alternating N=1,000 diagnostic pairs reduce median SQL requests from 13,575 to 9,960 and write transactions from 1,483 to 861; median publications rise from 212 to 222. Paired creation-time ratios are 0.940, 1.065 and 1.018 on a shared host with varying load. This does not establish an elapsed-time win or complete an I5 repetition cell. All first-unchanged inspections retain identical snapshots/operation results, 750 direct inputs, service version one and zero publications.
More decisively, a controlled operation-row lock exposes a progress regression.
While the first return is visibly waiting in PostgreSQL, the reference acknowledges
another operation's response and an independent read observes it as returned.
The candidate's shared queue holds that second response, leaving it dispatched
through the observation interval. Both complete after the lock is released; this
is not observed data loss. A permanent PostgreSQL regression test fails under the
candidate and passes with production, alongside eight grant-loss/expiry checks.
Reject the prototype without changing production. Future
return grouping must preserve independent progress under unrelated operation waits,
in addition to exact receipts, fences, cancellation retention and matched elapsed-time
gates. The passing controls, deliberately failing candidate test, preliminary variants
and all six matched captures are in
specs/graph-state/qualification/2026-11-13-i5-return-coalescing/.
Required gates include last-item conflicts, aliases within/across batches, changed or negative inputs, expiry during row waits, renewal fairness, partial provider errors, cancelled queue items, failed publication retaining raw responses, crash before/after arm, mixed-arm rejection after successful provider results, lost commit replies and idempotent receipt lookup. Compare complete state/history/recovery outcomes through the module interface, not just counts. Keep unsupported identities/actions and scoped grant behavior on the reference path until separately qualified. No timer, concurrency increase or durability relaxation is accepted on a smaller count alone.
Elapsed time also has independent lower bounds: aggregate provider work divided by
C, the longest actual dependency path (including its mandatory durable acknowledgements),
serialized database decision work, and bytes divided by effective transport/storage
throughput. These overlap, so their maximum is a lower bound; their sum usually is not.
No new seconds estimate follows from the SQL formulas. The optimization objective is
lowest measured initial-apply time subject to the existing safety and response-durability
constraints, with counts explaining the result.
E53's reproducible model and derived accounting check 256 small DAG/capacity combinations, the counterexamples and constructive 10,000-node schedules. They are finite consistency checks supporting the derivation, not production concurrency proofs, byte-capacity qualification or timing evidence.
Bulk Resource Publication Implementation (E54)
The first E53 SQL slice is implemented for bounded cohorts of fresh, qualified, successful returned creates. Raw responses still become durable individually before publication; queue timing, retained execution slots and the one-frontier transaction remain unchanged. PostgreSQL reads and locks the cohort's operation records together, checks every owner/attempt/stage, validates current rows and canonical ownership in sets, inserts resource rows and complete history with set-based SQL, then finalizes the operation receipts together. Existing reverse-edge maintenance, stale-input publication, row triggers and final ownership fencing remain inside that transaction. Every proposed resource participates in identity collision checking before any insert, including identities learned from returned provider results.
The fast writer requires absent rows, canonical identities, successful returned creates, unique addresses and bounded payloads (256 rows / 1 MiB at the SQL seam; the orchestration queue retains its tighter existing limits). Singletons, tombstone recreation, unsupported/mixed records, recovery and oversized payloads retain the general writer; fallback does not split an atomic publication. The bounded operation lock/read also applies to general multi-operation commits, with the same ownership and final-stage checks.
| Resources in one publication | E52 writer body SQL calls | Bulk writer body SQL calls | Publications / write transactions |
|---|---|---|---|
| 2 | 26 | 20 | 1 / 1 |
| 10 | 74 | 20 | 1 / 1 |
| 64 | 398 | 20 | 1 / 1 |
| 128 | 782 | 20 | 1 / 1 |
These are actual PostgreSQL storage-only captures with 1-KiB values and alternating
binary private state, one sequential old/new pair per size. Setup, reserve, dispatch
and durable return are excluded from the counted publication. Complete state,
version and history hashes match between writers, and every receipt is committed.
No latency distribution follows from these pairs. The measured no-input publication
formula changes from 6k+14 to 20; input-bearing fresh cohorts retain the existing
input-validation work. The unchanged E52 cohort trace would therefore save 41,976
calls, projecting 374,756 total rather than 416,732, if every corresponding
cohort remains eligible and all other work stays equal. This is a count projection,
not a new 10,000-resource capture or elapsed-time claim.
The actual eight-resource AWS 6.66/FakeCloud smoke passes service/state checks through initial creation and two unchanged applies. Creation uses 430 body SQL calls and five publications (the previous smoke used 454 and five). The first unchanged apply still needs four corrective publications and 206 calls; the second needs zero and 108. E53's representation/provenance work remains open.
Validation covers exact general-writer equivalence, binary private state, sensitive
history, per-operation versions, constant requests at 2/10/64 rows, rollback after
row/history writes, tail expiry, lost replies, returned aliases, last-item preconditions,
missing operations, stale owners, input edges and later stale propagation, and both
payload-limit fallbacks. Backend/admission/convergence suites and creation/core queue
checks pass. This slice does not yet fuse reserve/dispatch or return/publication,
increase batch occupancy, or implement the proposed mixed transaction/server routine.
The count captures, source, real-provider smoke and validation logs are retained in
specs/graph-state/qualification/2026-11-10-i5-bulk-creation-sql/.
Fused and Batched Creation Authorization (E55)
Fresh creates with qualified, known physical identities now prepare their operation
locally and authorize it immediately before the mutating provider call. This path is
limited to ordinary, unadmitted whole-app apply ownership. It requires absent rows,
complete input evidence, no extra write footprint and bounded requests. Resource
grants, tombstone recreation, updates, replacements, imports, deletes, generated or
unqualified identities and oversized requests retain reserve followed by dispatch.
Third-party graph adapters opt in through supports_creation_arms; the default is off.
GraphStateEngine.begin_operation(..., prepare_create=True) prepares a request snapshot
when eligible. Final configuration validation and provider planning finish before the
executor submits it to arm_creations. The backend independently checks eligibility;
the client flag grants no authority. The queue retains execution slots, accepts at most
128 requests within its conservative 1-MiB budget, and collects for at most 2 ms when
other execution peers exist. Database/backpressure waits are additional. Its worker
needs no execution slot. Collection separates direct read/write dependencies; the
authoritative cohort check rejects incompatible physical-object and input footprints.
Shared reads and commuting concrete edge patches retain existing compatibility rules.
PostgreSQL arms a cohort in one ownership transaction: lock the app decision row,
check quarantine, read current target/input rows as sets, validate the combined
footprint against held grants and unresolved operations, apply the existing input
and object oracles to each request and all proposed peers, then insert every operation
directly as dispatched. The normal tail fence runs after those writes and before
commit. No transaction spans a provider RPC. The acknowledgement arrives only after
every operation is durable. Rows retain exact request digests, full footprints,
owner/epoch, provider PID and dispatch timestamps; the existing mutation-start trigger
still prevents later plan/grant replacement.
The in-memory adapter provides a reference implementation: reserve/dispatch checks under one lock with rollback of the entire cohort on failure. Cross-adapter tests compare its retained requests and receipts with the ordinary protocol. PostgreSQL's no-output-input fixtures require at most 11 body requests for 1, 10 or 64 authorizations, in one write transaction. Previously each resource needed two transactions and 22 body requests, plus four calls when it had resource inputs. The set reader absorbs those resource-input reads; output inputs can add one query. Counters still exclude transaction framing, protocol settings and connection housekeeping.
There is no durable reserved state on this fast path. A final planning failure or
cancelled queued request creates no operation row and sends no mutation. Finishing
such a local operation marks it locally aborted, preventing later submission.
Cancellation after SQL starts drains its acknowledgement before the caller exits.
A crash after authorization and before the provider call conservatively leaves a
dispatched operation, as the existing dispatch-before-call window already does.
An ambiguous authorization reply stops every affected caller before provider dispatch;
there is no automatic retry or fallback. Any committed operation rows keep their full
quarantine coverage. Raw provider responses still become durable individually as soon
as they return, and final publications retain E54's bulk writer.
Final-source matched 1,000-resource initial creation. Source
fd18a1bd326069877d7809f4bbad32a231573a4882fc411489fccf7ca724436b
uses the original four-node-chain fixture, AWS 6.66/FakeCloud, PostgreSQL 16 and
parallelism ten, with no normalization warm-up. The control disables creation arms
only; bulk resource publication remains enabled in both paths.
| Metric | Separate reserve/dispatch | Fused/cohort authorization |
|---|---|---|
| Measured apply interval | 29.74 s | 18.50 s |
| Body SQL requests | 37,571 | 13,369 |
| Read/write transactions | 3,309 | 1,479 |
| Graph publications | 302 | 200 |
| Provider mutations | 1,000 | 1,000 |
The optimized run uses 272 authorization cohorts, 1,000 separate return transactions, 200 publication transactions and seven lifecycle transactions; both paths have eight read-only transactions. Every object, input revision, ready row, committed response and independent state/service check passes. The publication reduction is observed scheduler behavior after reducing authorization contention; it is not a new guaranteed cohort size. This is one sequential matched pair, not a distribution or p95.
Original-size capture and exact source limit. The immediately preceding source
83ee79f8011b7c0db3b04d354dcfbfd668d7aedd97b5a40a0a3e02b10ad3256f
completed fresh 10,000-resource creation in 218.96 seconds, with 141,730 body
requests, 15,177 write transactions and 2,349 graph publications. It uses 2,814
authorization cohorts, 10,000 return transactions and seven renewals. All 10,000
provider creates, ready rows, revision-one state, exact inputs, committed responses
and independent service/state hashes pass. The enclosing phase takes 219.05 seconds;
the 218.96-second interval matches the earlier benchmark's measurement boundary.
E52's 375.50-second, 416,732-request, 33,024-transaction result is historical, not a
same-source large control. The subsequent source change only marks a finished local
preparation aborted instead of leaving it eligible for resubmission. Its focused
checks and the final 1,000-resource pair pass; the large run is explicitly retained
under its preceding source, not labeled a final-source rerun. No WAN, Stategraph or
general topology speed ratio follows.
The earlier eight-resource actual-provider smoke uses 274 SQL body calls and five publications, versus E54's 430 and five. Its first unchanged apply still corrects metadata in four publications; canonical first-refresh representation remains open. The initial 1,000-resource pair is retained separately (29.48 / 18.81 seconds), not substituted for the final-source pair.
Regression gates cover cohort aliases and duplicates, last-item absence/input conflicts,
negative reads, in-cohort dependencies, unresolved siblings, owner release retaining
quarantine, administrative roles, resource-grant fallback, duplicate submissions, tail
expiry, exact request/receipt equivalence, provider calls blocked until acknowledgement,
lost replies, cancellation before/during SQL, closed-request resubmission, changed
prepared requests and unsupported/payload fallbacks. The broader backend/admission/engine
and hybrid selections pass 860 tests with two skips before the cancellation correction;
the final focused selection passes 90. Exact source, captures and validation are retained
in specs/graph-state/qualification/2026-11-10-i5-creation-authorization/.
The remaining fixed transaction slope is chiefly individual durable returns. E53's completion/savepoint design is the next candidate, subject to prompt response durability and failure-retention gates. SQL transport consolidation, better cohort occupancy, duplicate provider planning and first-refresh corrections remain separate work.
Opportunistic Durable Completion (E56)
Protocol implemented; performance promotion rejected. PostgreSQL keeps
supports_creation_completions = False after the matched original-size fixture
regressed elapsed time and publication count. Ordinary applies retain E55. The
qualification harness explicitly selects the candidate; the reference adapter and
backend entry point remain available for correctness and subsequent optimization work.
The next write-path slice combines raw-response retention with publication when a
useful batch is already available. It applies to qualified fresh creates that used
E55 authorization under ordinary unadmitted app X. Third-party adapters opt in through
supports_creation_completions; other actions, identities, grants and provider errors
keep the existing return/publication protocol.
Response storage does not wait for preparation or peers. A completion captures the raw state, private data and identity, then submits it before asynchronous state-row construction. A one-use slot lets the storage adapter take any prepared row without waiting. The coordinator has no collection timer. It drains currently available responses in bounded cohorts, with at most one opportunistic publisher and one independent return-only worker. Responses arriving during a slow publication can still become durable. Backpressure and oversized responses use immediate individual storage. Resource slots remain occupied until publication, preserving the configured in-flight window.
The queue accepts at most 128 responses with a 1-MiB raw-value budget. Publication also bounds the combined row count and conservative raw/write/history representation. These are implementation bounds, not claims about exact wire bytes. Cancellation shields accepted responses, including those still queued when a sibling cancels the walk; the owning context closes and drains the worker before releasing ownership.
Retain first, attempt publication second. PostgreSQL locks the original operation
records, verifies their owner/epoch, dispatched stage, address, action and immutable
request digest, then updates the raw outcomes as a set. It reads the digest column
instead of retransferring and hashing every complete request body. Any prepared
publication runs inside a savepoint. The app-frontier lock uses NOWAIT: contention
commits a return-only receipt and leaves publication to the existing queue. Publication
validation still applies the full operation, object, footprint, input, row/history,
invalidation and final fencing rules. A rejected publication rolls back the savepoint
and returns a structured rejection only after committing the raw responses as
RETURNED. The original response of an already-returned operation is never replaced.
Whole-transaction failure or ownership loss retains all new raw responses in the existing per-run recovery journal. A lost reply never automatically retries a completion or provider call; recovery checks the operation identity and retained receipt. No SQL transaction spans a provider RPC. PostgreSQL and the in-memory adapter share receipt tests, including rollback after every publication write has already executed. Return-only cohorts use at most six SQL body requests for 1, 10 or 64 responses. The tested 10/64-row fused publication budget is at most 24 body requests in one write transaction; savepoint commands are transaction framing and counted separately from that body budget.
Join ready work instead of publishing small fragments. Initial prototypes reduced transaction counts but split publications and could increase elapsed time. The final coordinator attempts fusion when prepared rows can cover the occupied execution window. It can borrow compatible creates whose raw responses are already durable and whose publication queue has not started them. Each borrowed caller waits for the same shared receipt; an unsuccessful opportunistic attempt returns its row to its original queue and collection deadline. Closing or failing that queue leaves the durable operation recoverable. Borrowing preserves row/byte bounds and does not increase provider parallelism. This policy is not a proof of optimal scheduling or a fixed batch size.
The successful-run accounting is now:
write transactions = authorization cohorts + completion cohorts
+ individual return fallbacks + separate publications
+ lifecycle transactions + renewals
graph publications = publications inside completion + separate publications
A completion may publish both new outcomes and already-returned rows. Its publication row count can therefore exceed its newly retained response count. All rows still have their original response, input evidence, operation identity and durable history.
Measured-candidate matched 1,000-resource initial creation. Source
c06098e531ed3871da5745c058818dab2b28abead991beb50b60e00720277b85
uses AWS 6.66/FakeCloud, PostgreSQL 16, four-node chains, 1-KiB values and parallelism
ten. The control disables completion support only; E54 publication batching and E55
authorization batching remain enabled in both paths. Regression tests finished before
measurement began.
| Metric | Individual returns | Batched/opportunistic completion |
|---|---|---|
| Measured apply interval | 19.09 s | 19.35 s |
| Body SQL requests | 13,486 | 10,815 |
| Read/write transactions | 1,488 | 1,075 |
| Graph publications | 202 | 199 |
| Provider mutations | 1,000 | 1,000 |
The optimized sample uses 252 authorization cohorts, 617 completion cohorts, 199 separate publications and seven lifecycle transactions; neither path renews during this interval, and both have eight read-only transactions. No cohort in this sample publishes inside completion: the measured reduction comes from batched raw-response storage, not a claim that fusion occurred in the provider fixture. Shared adapter and queue tests separately establish fused publication, including new responses combined with already-returned rows. Every provider object, ready row, exact input revision, committed outcome and independent state/service hash passes. This pair reduces request and transaction counts while elapsed time is essentially flat; it does not establish a speedup, percentile or general topology ratio.
The broad regression selection passes 874 tests with two skips; the final response-drain
selection passes 36 after adding the parent-cancellation guard. Earlier prototypes and
the first timing pair overlapped testing or used superseded policies; they are not the
final timing evidence. The final-source captures, driver, source delta and verification
are retained in specs/graph-state/qualification/2026-11-10-i5-creation-completion/.
Matched original 10,000-resource case and rejection. Both phases run on that same measured source and fixture, sequentially after regression testing, with a 15-minute overall cap. Both finish and pass all 10,000 object, ready-row, revision-one, exact-input, committed-response and independent service/state checks.
| Metric | Individual returns | Completion candidate |
|---|---|---|
| Measured apply interval | 219.38 s | 231.99 s |
| Body SQL requests | 142,026 | 130,801 |
| Read/write transactions | 15,208 | 12,635 |
| Graph publications | 2,344 | 2,620 |
| Provider mutations | 10,000 | 10,000 |
The control uses 2,850 authorization cohorts, 10,000 individual returns, 2,344 publications, seven lifecycle transactions and seven renewals. The candidate uses 2,823 authorization cohorts, 7,178 completion cohorts, 2,620 publications and the same lifecycle/renewal counts. Both have eight read-only transactions. This large sample also produces zero fused publications: safe opportunistic fusion is available but does not fill a usable window in this fixture. Response batching reduces body requests by 7.9% and write transactions by 16.9%, while publications increase 11.8% and elapsed time increases 5.8%. The request savings do not translate into faster apply. The candidate produces smaller publication groups and adds coordination; this pair does not isolate how much time each contributes. It is an observed regression, not a general latency model or a guarantee about other topologies.
The final workspace changes the PostgreSQL default to disabled; its source manifest is retained separately from the exact measured candidate. A replay driver explicitly selects either mode, and a small actual-provider smoke checks both after that gate. No new large run is mislabeled as the default-disabled source. Further promotion requires a common scheduling design that fills publication cohorts without delaying raw receipts, followed by another matched original-size gate. Fewer transactions alone do not meet the optimization objective. First-refresh correction and the wider transport/latency/Stategraph matrix remain open.
Path to the Orchestration Target
The target remains approximately 2.2 seconds for 10,000 resources, four-node chains, concurrency ten, and the instantaneous provider. It is not a shipped capability. Preserve the real authorization, identity, provenance, operation, and durable-publication semantics in every candidate. The current investigation replaces expansion of the wider qualification matrix; earlier evidence remains historical and intact.
Implemented next slice: bounded raw-return batches. Qualified fresh creates under an original whole-app apply may collect ready successful responses for up to two milliseconds before submitting a cohort, with at most 128 accepted responses and one MiB of raw payload. An already-busy receipt worker can add queue time; the collection window is not a durability-latency guarantee. The existing fenced completion primitive validates every operation's exact identity and dispatched request and records each result separately in one transaction, with publication disabled. Acknowledgement follows durable commit. Publication and dependent execution still wait for their existing graph commit. Queue overflow, oversized responses, unsupported operations and incomplete results retain the individual path. Accepted receipts drain under cancellation; ambiguous replies retain recovery evidence without automatic replay. The previously slower combined receipt-and-publication mode remains disabled.
Receipt batching cannot establish 100× by itself. Before this slice, the 256.385-second capture spent 36.165 seconds outside execution. If those phases remain unchanged, even eliminating execution entirely leaves that floor—over 16 times the target. The floor is conditional on unchanged work, not an intrinsic limit of Python or PostgreSQL. CPU and SQL timer sums overlap and cannot be substituted for that exclusive wall partition.
The next designs should be evaluated in this order, with explicit stopping conditions rather than an open-ended sequence of small speedups:
| Candidate | Concrete implementation seam | Decision gate |
|---|---|---|
| Reduce repeated Python preparation | Build indexed plan/intent data once; use immutable prepared requests and response representations; measure traversals, copies and serialized bytes at each boundary. Preserve actual dependency reads and current-state validation. | Planning, intent capture and finalization must fit their share of 2.2 seconds. If they alone exceed the total budget, a storage-only replacement cannot deliver the target. |
| Bounded coordination window with PostgreSQL bulk commands | Separate provider-call concurrency from the bounded count/bytes awaiting durable receipts and publication. Keep ten provider calls, but allow a larger independent durable cohort. Move a whole validated batch across the database boundary; retain per-operation records, precondition checks and initial/tail fences. | Demonstrate a material reduction in serial durable decisions and end-to-end time on the original case. A lower SQL count without lower elapsed time does not pass. Slow-provider, cancellation and dependency progress must remain bounded. |
| Authoritative durable-log coordinator | Represent an admitted batch's operation facts, graph mutations and frontier advancement in one atomic durable log transaction; serve reads from the committed logical state while physical indexes may be derived. Prototype first with the same protocol and failure model. PostgreSQL and RocksDB-backed implementations are alternatives at this seam. | The coordinator must replay the same state/receipts and enforce identity, read preconditions, fencing and unresolved footprints before dispatch/publication. Compare the same dummy workload with durable acknowledgements and equivalent crash/replication assumptions. Do not select it from key-value throughput alone. |
| Native processing of immutable batches | Retain the Python API; move only measured CPU-heavy validation, encoding or graph kernels behind a coarse batch boundary. | First show that CPU remaining on the critical path prevents the budget after redundant work is removed. Measure conversion and boundary costs too. A language rewrite is not a multiplier for SQL round trips or durable waits. |
Under the earlier policy with execution slots held until publication, a cohort contains at most ten resources. At least 1,000 authorization batches, 1,000 return batches and 1,000 publications are then needed for this 10,000-create workload under the separate three-stage protocol, even with perfect packing. This is a bound on that protocol and scheduling policy, not a universal lower bound. For illustration, a separately bounded window of 128 independent resources could pack each of the four 2,500-resource levels into 20 cohorts: 80 per stage. Byte bounds, actual readiness and safety constraints may require more. This illustration does not authorize removing resource-level guards or increasing the benchmark's provider concurrency.
RocksDB supplies atomic multi-key batches; synchronous WAL-backed writes are needed for the corresponding durable acknowledgement. Those primitives do not implement Netherframe's admission or ownership protocol. Conditional reads need transactional conflict protection or a correctly fenced single decision owner, not an unchecked read followed by an atomic write batch. See RocksDB basic operations and transaction conflict checks. PostgreSQL asynchronous commit changes the crash-durability promise and is not an equivalent optimization for this comparison; its normal synchronous commit acknowledges WAL durability. See PostgreSQL commit durability.
No backend is selected by this plan. The retained return-batching slice measured 166.729 seconds, 84,229 SQL requests, 5,632 transactions and 1,515 publications for 10,000 verified creates, versus 256.385 seconds before this slice. These single samples came from a busy shared host; the exact speedup remains provisional. Use its exclusive phase costs, CPU, batch sizes and durable decision counts to choose the next bounded experiment. A publication-readiness shortcut was tested at 1,000 resources and left out after an inconclusive/slower run; that evidence is preserved rather than promoted to a performance claim.
Measured follow-up: a bounded creation pipeline. The retained implementation
separates unfinished create nodes from execution capacity. An original unadmitted
whole-app graph apply using creation authorization receives a creation window of
max(128, parallelism); this workload keeps provider concurrency ten. Acquire the
whole-node permit before preparation and execution capacity, retain it through
all durable stages and node completion, and yield execution capacity only during
accepted authorization, raw-return and publication waits. Per-stage row/byte
bounds still apply. The whole-node count limit is not a one-MiB total memory
limit. Unsupported, admitted and custom executors retain their prior behavior.
Never release dependencies before their producer's durable publication.
The wider window initially regressed: full-queue waiters repeatedly woke one another, and ownership guards compared every independent pair. The queue now signals backpressure once per blocking episode. A transaction-local object candidate index preserves same-run versus foreign allocation rules and feeds the existing pairwise checks; unknown ownership retains a full scan. Immutable runtime/profile/namespace fingerprint work is reused separately, after live eligibility checks. These are algorithm changes, not waived authority checks.
The final adjacent 1,000-resource control/candidate measured 20.883/14.863 seconds, 8,008/1,664 SQL requests, 525/119 transactions, and 154/30 publications. Preparation stayed near 3.5 seconds while execution fell from 17.403 to 11.338 seconds. One adjacent pair on a busy host is not a stable speedup guarantee. The original 10,000-resource case measured 170.520 seconds, 15,676 SQL requests, 1,112 transactions and 277 publications; all resources, operation receipts and dependency revisions verified. The earlier run took 166.729 seconds. The new large run began at a one-minute load average of about 77 on 24 logical CPUs, so code and host effects are not isolated.
Acknowledgement latency is a material tradeoff: in the adjacent pair, raw receipt median/p95 increased from 13/25 ms to 125/258 ms, and publication acknowledgement from 98/128 ms to 628/1,068 ms. Acknowledgements still follow durable commit; more outstanding outcomes can coexist. Report these overlapping latency distributions separately from exclusive phase costs.
Operation-fact reconstruction investigation. In that pipeline pair, operation-snapshot calls fell 332 to 60, but decoded rows increased 1,698 to 3,810. The follow-up measured 29,744 object-claim reconstructions at 1,000 resources, using 3.754 inclusive thread CPU seconds, versus 0.557 seconds constructing operation records from about 24 million request JSON characters. These timers overlap and are not additive wall-time attribution. A request cache across transactions was not introduced: pure proof work was the larger measured target.
Measured proof changes. ObjectLocator.identity_and_leases derives both
from one checked reading of current values. Small hierarchical lease calculations
use a bounded 2,048-entry cache keyed by immutable demands; return a new mapping
to every caller. The cache bypasses more than 16 demands, 64 path components or
4,096 component characters and unusual key/mode subclasses. It never caches an
operation record, mutable request, grant or current-state authorization decision.
Owner, epoch, stage, attempt, recovery, unresolved holds and input revisions
remain freshly checked at their existing transaction boundaries.
An alternating-order pure-kernel test reduced median CPU from 0.504 to 0.373 seconds for 5,000 calls on 100 request variants, with identical claims. Cold unique keys expose an 8–9% cache overhead relative to identity-only evaluation; reuse is not universally beneficial. The adjacent 1,000-resource pair improved 15.155 to 14.477 seconds, with SQL requests increasing 1,646 to 1,820 as cohort sizes changed. The first large pair regressed 140.408 to 164.986 seconds. A reverse-order pair in fresh processes measured 171.960 seconds control and 165.115 candidate, with 158.364/153.941 client CPU seconds. Shared-host load varied substantially; keep all samples and do not claim a stable large speedup. Both changes preserve the deterministic work-count and state/receipt checks; 1,182 regression tests passed, with two skips.
The fresh-process candidate made 15,825 SQL requests, 1,120 transactions and 282 publications, compared with control 15,705/1,112/279. Raw durable receipt median/p95 was 112/177 ms, versus 128/185 ms; publication acknowledgement was 664/1,203 ms, versus 731/1,276 ms. These are overlapping latency observations, not exclusive phase costs. No batching, concurrency, SQL durability, publication or acknowledgement rule changed.
Next experiment: allocation and proof lifetime. Collection callbacks measured 26.537 thread CPU seconds in candidate GC, versus 22.545 seconds in the control. Worker collections alone used 13.286 seconds and collected zero cyclic objects. The cache had 264,695 hits and 80,001 misses (76.8%) and retained at most 2,048 entries. This establishes costly collection work, not its exact allocation source or a causal cache penalty. Profile allocation sites and collection generations before changing memory policy. Keep process-wide GC enabled.
Use a bounded immutable prepared-operation representation to share static facts among binding, contract and footprint calculations in one preparation scope; measure slotted immutable values and fewer temporary locators/resource rows. Preserve canonical request/digest equality and fresh validation at each subsequent fenced stage. A candidate cross-transaction reuse mechanism would additionally need a digest verified by the current transaction, immutable-request mutation audits and full-read/full-scan differential checks. Legacy or unknown evidence must retain the full path. Narrow database projections are a later option if profiles show their remaining cost justifies them.
The latest large candidate still spends 38.361 seconds outside execution and is about 75.1 times the 2.2-second target. This conditional phase floor exceeds the entire target by 17.4 times. Preparation and allocation must change alongside durable-command granularity; neither a storage swap nor native provider transport removes that work. A native batch kernel or durable-log coordinator remains an option only behind the same provider, workload, authorization and crash-durability requirements. Neither is selected by this pass.
Delivery Order and Claim Ledger
- I1 first: normalize existing evidence and add missing adversarial schedules. This supplies the oracle and fault controls for every later optimization.
- I5 baseline: capture current full-planning behavior before I2 changes it. Begin I3's per-type qualification independently; no broad provider support claim is a prerequisite for I2.
- I2: manifest/partial-view seam, shadow selection, concrete opt-in, then broader closures. Each slice must pass I1 and publish I5 costs/fallbacks before the next widens eligibility.
- I3: release contracts one type/version range at a time after their native evidence gate.
- I4: record the domain decision and prototype/model first. Production cross-state mutation remains a separate gated extension, not an incidental feature of scoped planning.
The claim ledger is specs/graph-state/claims.md. It separates publication, patch conflicts,
branch intent, physical exclusion, quarantine, recovery, selected planning, identity qualification,
the bounded domain prototype and measured cost claims. Its evidence index binds recorded bases
to content hashes and distinguishes exact frozen benchmark revisions from dirty working-copy
captures. Live Stategraph testing is authorized; the ledger must distinguish demo access and
adapter qualification from an independently verified comparative claim.
Maintain the ledger with: claim ID, scope and assumptions, implementation revision, test/model
case IDs, reference workloads, evidence artifact paths, known exclusions and status
(proposed, implemented, verified, or not comparable). Existing delivery evidence does not
automatically verify an extended scope. In particular, keep separate claims for SQL publication
atomicity, patch serializability, physical-object exclusion, stale-branch safety, recovery and
planning cost. The ledger must not collapse them into "ACID infrastructure" or "better guarantees"
without naming the dimension and evidence.
Other Future Work
- Shared leases at plan time for earlier conflict feedback, without lengthening approval-held grants by accident.
- Sharding the commit counter only with a replacement definition and proof of a stable frontier; independent sequence allocation alone does not preserve commit order.
- Measure schema 33's grant validation and targeted footprint reads under the wider I5 matrix. Admitted-plan membership and serialized publication remain potential large-plan costs; retain exact admission and fencing checks when optimizing them.
Open Questions
- Resolved: default TTL is 120 seconds and renewal defaults to one quarter of the TTL, strictly
below it.
operation_quiescencehas no default unless a provider apply timeout is explicitly configured; otherwise recovery needs termination evidence. Long-running calls do not expire merely because they exceed the renewable ownership TTL. - Resolved: use
nf.baselineby default, with--baseline <file|sequence|run>for overrides. The file is scoped to backend type, state ID and lineage; CI can maintain it or pass a selector. Earlier alternatives were a branch-cut hook or the frontier recorded with the last deploy of the merge base. - Contract chosen: portable provider identity contracts (above), with explicit chosen/allocated semantics and actual namespace facts. Broader provider/type coverage and import normalization are qualified per type under I3; unsupported types cannot gain concurrent mutation permission.
- Resolved: several apps keyed by
state_idcan share one schema. - Scope fixed for current delivery: independent app states do not share a transaction domain. I4 defines the decision gate for an extension; sharing a schema is not cross-state coordination.
Acceptance Criteria
- Two runs whose patches touch different entries apply concurrently and both changes land.
- Two runs that change the same entry's intent differently: the second is refused naming the first.
- A branch with a pinned baseline neither reverts nor deletes a newer change silently.
- No mutating RPC on an object overlaps another mutation of it, across the fault-injection suite, including calls longer than TTL and crashes at every operation stage.
- Every crash leaves a durable recovery path; resolution to committed/aborted requires sufficient outcome and termination evidence. Without it, the operation remains quarantined rather than promising unconditional recovery progress.
- TLC checks the intended design; each regression configuration fails its named invariant.
nf state history <address>shows every change with actor, run, baseline, intent and operation.- Extensions are accepted separately through I1–I5 and the claim ledger. None is considered shipped solely because the original protocol's acceptance tests pass.