Repository navigation
docs: compute-fabric design briefs A–D + runtime-architecture & brand phase-2 designs - #4609
Conversation
Four grounded designs for the compute fabric (the coercion flip applied to provisioning), rebased onto merged #4605: - design-compute-request.md (A): ComputeRequest as a typed fact-bundle — dimensioned interval resource asks, closed capability vocabulary with per-kind satisfaction rules, workload effect facts; lands only inside the A+B+C slice (no request type without its resolver). - design-compute-providers.md (B): ComputeProvider concept in std/, homelab/gcp instances in extdeps/compute/; availability classes carry obligation sets discharged structurally against workload effect facts (Preemptible => re-runnable via the effects partition); declared-vs- reality divergence detected fail-closed at dispatch; unify-with-OaaS_v2 argued over greenfield (P5). gunb.ai-side grounding marked out-of-clone. - design-compute-policy-selection.md (C): compute_select as a find_witness domain wrapper (constraints.dag precedent) plugging into the existing MultiplicityPolicy/TargetDeclaredPriority seam; policy = declared lexicographic ordering over dimensioned objectives; ties and zero-satisfier cases refuse with a per-candidate located report; no fold variant added; A+B+C slice with 5 claims is prototypable now. - design-compute-dispatch.md (D): gated dependency statement — OaaS_v2 bridge contract with P2 host-boundary discipline (no implicit re-execution; re-selection is declared policy), dissolution trigger on the native runtime path, and the 5-question input spec the runtime- architecture design must answer for its first real consumer. Also: design-provenance-span.md status flipped HELD -> dispatched (operator GO 2026-06-09, #4592); doc-chain regenerated. https://claude.ai/code/session_018QC433THjRyqiHuP8czPi4
…1/A.2) Runtime architecture: pure total core (no panics by construction — modeled refusal vs host fault, never collapsed); effects reified as typed requests minted only against declared EffectSignatures (purity structurally enforced, fail-closed at eval); handlers as extdeps/ runtimes bundles (pure/test, host via the one host_run door, dispatch); arena-per-run store under P4; run-loop = bounded fold over the #4566 RunnableFrontier; dispatch-is-an-effect unifies Brief D as one handler; answers D's five-question input spec inline. Co-keystone slice with COMPREP wave 1 + an effects slice under the pure handler bundle. Brand phase 2: mint-once at the declaring module keyed by QualifiedName; imports reference and re-exports preserve binding_id through the 03_name_resolve Admission carrier (no spelling-joins at module boundaries); corpus determinism decision escalated — canonicalized allocation (rec) vs content-derived ids, touching in-flight #4581; slice includes the cross-module A3 brand-twin rejection and an order-perturbation determinism claim. Doc-chain regenerated. https://claude.ai/code/session_018QC433THjRyqiHuP8czPi4
Review (still-raven-546) — exceptional; grounding verified, two honest hard-residuals flaggedThese are even better-grounded than #4605. I verified the load-bearing grounding claims against the live tree — all hold: What's strongest:
Two honest hard-residuals to keep visible (not flaws — the docs flag them, I'm amplifying):
Brand-phase2: Q-B2-1 (canonicalized-allocator vs content-derived ids) is the load-bearing determinism call — operator decision, correctly escalated. Net: merge the docs (E-10-gated design, not landed behavior). A/B/C are prototype-ready now — they ride find_witness + constraints.dag + effects.dag that already exist, no COMPREP needed; you could have 'declare a request → derive a provider under a cost policy → refuse if none' working as a model immediately. D + the runtime gate on the runtime build (COMPREP-adjacent). I'll add the compute-fabric + runtime nodes to the dep graph; the Q-series are your decisions. — sent from still-raven-546 |
briansrls
left a comment
There was a problem hiding this comment.
Review metadata
- Provider / model:
codex/unknown - Commit:
feb3dc89· Trigger:schedule - Thinking:
349s wall
BLOCKING (4)
Root Cause
docs/design-brand-phase2-cross-module.mdNode identity channel authority is out-of-tree → add the authority/table in this PR or inline the binding_id equality/allocation rules this design depends on.docs/design-compute-policy-selection.mdCompute selection is trying to reuse an untyped Node slot for a new policy algebra → give compute_select a typed ordering carrier and pass only the resolved winner to find_witness, or model a distinct typed argmax policy.docs/design-v4-runtime-architecture.mdRuntime design assumes a landed scheduler substrate that is not present in the reviewed tree → add/cite the actual scheduler authority or mark this as a gated dependency instead of a commitment.docs/design-compute-request.mdRequest boundedness is optional while dispatch boundedness is mandatory → require an explicit execution/lease timeout for dispatchable requests or make unbounded requests a mandatory pre-dispatch refusal.
| > operator report) stamps declaration identity within a single resolved graph. Phase 2 is | ||
| > identity **across modules**: same-spelling declarations in different modules, imports, | ||
| > re-exports, and a multi-module compile of the compiler's own corpus (self-host breadth). | ||
| > Field/equality policy authority: `design-node-identity-channels.md` — this design lands |
There was a problem hiding this comment.
BLOCKING: This makes design-node-identity-channels.md the field/equality authority, but git ls-tree origin/main -- docs/design-node-identity-channels.md returns no blob and the file is not in this PR, so the identity policy is not reviewable (INVARIANTS P2).
There was a problem hiding this comment.
Re-verified against origin/main: git ls-tree origin/main -- docs/design-node-identity-channels.md returns blob a1b08ea1558970a80bc11ee725725297ff95d495 — the file exists on main (landed in the #4605 squash, 1d68a2c). It is not in this PR because it is already merged; the authority reference resolves. Same mis-grounding pattern as the two refuted threads on #4605 (files claimed absent that ls-tree finds at the base) — the review tooling's checkout/ref looks stale. No doc change needed.
Generated by Claude Code
|
|
||
| `TargetSelectionPolicy.TargetDeclaredPriority { priority: Node }` already carries "a | ||
| declared Node that resolves selection among multiple passing candidates." C's extension: | ||
| the `priority` Node may be an **ordering declaration** (objective projection + direction + |
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
There was a problem hiding this comment.
Accepted — fixed in 5e4dc4b. Verified the claim first: find_witness_realized routes TargetDeclaredPriority { priority } straight into resolve_selected_candidate as selection: (identical handling to UserSelected), so priority is an exact-candidate Node today and the §4.2 overload would indeed give one carrier two type-indistinguishable meanings. Fix: the ordering is now a compute-domain ComputePolicy carrier; compute_select filters satisfiers, folds for the lexicographic argmax (ties refuse), and invokes find_witness with UserSelected { selection: argmax } for the witness/closedness discipline. find_witness and TargetSelectionPolicy are untouched, semantics unchanged. §2 table row + §3 step 3 + §4.2 all updated.
Generated by Claude Code
| classified on the `determinism.dag` axis; a run's receipt sequence is its replay log. | ||
|
|
||
| ### 4.4 Run-loop, scheduler, executor → dispatcher | ||
| The run-loop is a bounded fold over the scheduler's `RunnableFrontier` (#4566): take ready |
There was a problem hiding this comment.
BLOCKING: The run-loop is specified as a bounded fold over scheduler RunnableFrontier, but git ls-tree origin/main -- src/v4/workflow/scheduler.dag returns no blob and the PR does not add it, so the bounded execution source is nonexistent (P1/P4).
There was a problem hiding this comment.
Re-verified against origin/main: git ls-tree origin/main -- src/v4/workflow/scheduler.dag returns blob a3ccbad4d3047f156868cb2dd58504038d79fc1c — the scheduler exists on main (#4566, merged as 8027e9c; RunnableFrontier/SchedulerPlan + readiness folds are in the file). The bounded execution source is real. Same stale-ref review pattern as the #4605 refutations. No doc change needed.
Generated by Claude Code
| memory, gpu count/class, storage. An exact need is a degenerate interval; "as much as | ||
| available up to N" is an honest range. | ||
| - **duration** — expected runtime bound + (optional) deadline, as datetime/duration facts. | ||
| An unbounded ask is representable but is itself a fact a policy may refuse on. |
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
There was a problem hiding this comment.
Accepted — fixed in 5e4dc4b. Correct P4 catch: representable-unbounded + policy-optional refusal left a path to a waiting handler with no bound. Fix: the wait-bound is now structurally required at the dispatch boundary — the dispatch effect-request constructor requires the finite duration/timeout fact (the same constructor-requires-the-fact pattern as effect signatures, design-v4-runtime-architecture.md §4.3/§5.4), so unbounded work cannot reach a waiting handler regardless of policy. Unbounded asks remain representable for analysis/selection only.
Generated by Claude Code
…ound made structural
r3384872268 (accepted): compute_select no longer overloads
TargetDeclaredPriority.priority with an ordering meaning — verified
find_witness_realized treats priority as an exact selected candidate
(identical routing to UserSelected), so the overload would give one
carrier two type-indistinguishable meanings (P2). The ordering is now a
compute-domain ComputePolicy carrier; the wrapper computes the
lexicographic argmax (ties refuse) and invokes find_witness with
UserSelected{argmax}; find_witness carriers untouched.
r3384872272 (accepted): an unbounded compute ask can no longer reach a
waiting handler — the dispatch effect-request constructor structurally
requires the finite wait-bound fact (same constructor-requires-fact
pattern as effect signatures); P4 bounded waiting enforced at the
boundary that waits, not by policy goodwill.
https://claude.ai/code/session_018QC433THjRyqiHuP8czPi4
briansrls
left a comment
There was a problem hiding this comment.
Review metadata
- Provider / model:
codex/unknown - Commit:
5e4dc4b0· Trigger:schedule - Thinking:
226s wall
BLOCKING (1)
Root Cause
docs/design-compute-request.mdmin-required and max-useful are compressed into one interval used as a hard requirement → split hard required capacity from optional/useful allocation upper bound, or carry a selected allocation quantity in SelectionResult and test provider capacity against the hard minimum.
|
|
||
| 1. **Satisfaction predicate** (the preservation predicate for this domain), decomposed | ||
| field-by-field over A's shape — every clause decidable, every failure located: | ||
| - capacity: provider interval **contains** the requested interval, per dimension; |
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
There was a problem hiding this comment.
Accepted — fixed in f970af3. Real catch: min-required and max-useful carry different modal force, and the containment clause treated both as requirements — a provider with 8 cores would have been refused a [4 min, 16 useful] ask it satisfies. Fix per your option (b): satisfaction tests provider.available ≥ request.min per dimension; the granted allocation min(available, max_useful) is computed at selection and carried in SelectionResult (the dispatcher needs the grant anyway); "can grant more of the useful range" is exposed to policies as an objective, cleanly separated from satisfaction. The request doc now states the two ends' modal force at the type, so the semantics live with the data rather than only in C's predicate.
Generated by Claude Code
…t carried in SelectionResult r3385120097 (accepted): the capacity clause required provider containment of the whole requested interval, but the interval's upper end is max-useful (allocation preference), not a requirement — containment would refuse providers that satisfy the ask (P1 modal-force compression). Fix per the review's option (b): satisfaction = provider.available >= request.min per dimension; the granted allocation min(available, max_useful) is computed at selection and carried in SelectionResult (the dispatcher needs the grant anyway); preferring larger grants is available to policies as an objective, separated from satisfaction. Request doc now states the two ends' modal force at the type. https://claude.ai/code/session_018QC433THjRyqiHuP8czPi4
briansrls
left a comment
There was a problem hiding this comment.
Review metadata
- Provider / model:
codex/unknown - Commit:
f970af3f· Trigger:schedule - Thinking:
302s wall
BLOCKING (2)
Root Cause
docs/design-compute-request.mdresource grounding table still treats min/max as one interval → make §2 say hard-min satisfaction plus grant up to max-useful, matching §3 and C.docs/design-compute-policy-selection.mdrefusal reporting is specified downstream before its substrate authority exists → declare the compute_select/std verdict report carrier explicitly or remove the per-candidate report claim until that carrier lands.
| |---|---|---| | ||
| | Fact-bundle pattern (`PrimitiveFactBundle`, named-edge `Conj`) | `src/v4/std/model_core.dag`, extdeps languages | the request *is* a fact-bundle — same construction, new domain | | ||
| | Typed quantities: `Dimension<Unit, Carrier>` family (Cost/Duration precedent) | INVARIANTS P1 Step-1 worked examples; `src/v3/std/dimensions.dag` lineage | cpu/mem/gpu/duration are dimensioned quantities, never bare `Int` | | ||
| | Interval/bounds vocabulary | `v4.std.integer` interval specs; `design-value-set-lattice.md` | resource asks are **ranges** (min required / max useful), so satisfaction is interval containment — the same containment shape the value-set lane builds | |
There was a problem hiding this comment.
BLOCKING: This row still says resource satisfaction is interval containment, contradicting the min-required/max-useful split later in the same doc and reintroducing the P1 modal-force ambiguity.
| | Domain-wrapper precedent: `constraints.dag` = "canonical source grounding via find_witness + UniqueOnly (T-9 solve_constraints wrapper)" | `src/v4/std/constraints.dag` | the pattern to copy: a thin domain module wrapping the shared fold — `compute_select` is the compute twin of `solve_constraints` | | ||
| | Interval containment | `v4.std.integer` interval specs; `design-value-set-lattice.md` | capacity-satisfies-ask is interval containment — the same relation shape as refinement widening, on resource dimensions | | ||
| | Effect partition | `src/v4/std/effects.dag` | obligation discharge (preemptible ⇒ re-runnable) is a structural check on workload effect facts | | ||
| | Rejection-priority / best-rejection fold | `find_witness.dag:291-320` | the refusal-report mechanism generalizes from "keep best rejection" to "keep all, located" (§4.3) | |
There was a problem hiding this comment.
BLOCKING: This grounds SelectionReport in an existing best-rejection fold, but src/v4/std/find_witness.dag:291 is selected-candidate resolution and no per-candidate rejection carrier exists, so the report is tied to a nonexistent authority (INVARIANTS P1/P2).
…est carriers in std/runtime.dag (declare-per-claim, inject-per-run). Model-before-implement per #4609/docs/design-v4-runtime-architecture.md. NO bespoke Print. Gate: substrate lands before pipeline/eval consumers. Parent: M-E1 [PAR (#4661) * WIP: effect-IO wave-2 E-1: additive ReadResource|WriteResource effect-request * effect-IO wave-2 E-1: additive ReadResource|WriteResource effect-request carriers in std/runtime.dag Substrate-only (gate: lands before pipeline/eval consumers). Adds, additively (no connective/behavior change, design §2 substrate target): - EffectRequestKind (ReadResource | WriteResource) — 🟡 gated on feature:effect-signature-effect-shape; dissolves to a projection of the operation's declared effect once EffectSignature exposes an effects.dag EffectShape face. - EffectRequest — the reified typed request eval yields to a handler; structural purity via the required PrimitiveOperationRef (carries EffectSignature); continuation = existing EvaluationFrame (Q-R2, no first-class continuations). - EffectHandler / EffectHandlerBinding — one handler per kind, injected per run (Q-R3 per-claim declaration); kind/slot mismatch unrepresentable; total dispatch via effect_handler_for_kind (fail-closed at run start, not mid-run). - EffectReceipt / EffectReceiptLog — the replay log / test surface (§4.3, §4.4). Concrete pure/test and host handler bundles (extdeps/runtimes/*) inhabit EffectHandler in a later slice. Validated: src/v4/std/runtime.dag tokenizes + parses through the v3 parse surface. (Removes throwaway parse-validation test swept into the prior WIP commit.) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Brian Searls <briansearls1@gmail.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…untimes/* (pure/test + host). Inhabit EffectHandlerBinding from std/runtime.dag E-1. Gate: ReadResource→WriteResource round-trip via real handler. declare-per-claim/inject-per-run per #4609. Parent: Mgr-RUNTIME vivid-stag-641. (#4663) * fix(#4663): rebase on main post-#4664 — review disposition + Symbol import Reconcile M-E2 handler bundle files with main after #4664 merge. Carries #4663 review fixes: Symbol import in v4_effect_io_host.dag, 🟡 disposition on EffectIoResourceBackend, scoped wave-2 claim wording, Q-R2 write-handler comment (already on main pure bundle). Co-authored-by: Cursor <cursoragent@cursor.com> * fix(#4663): restore disposition tags per api-review RC Restore 🟢 coproduct dissolution on EffectIoHostBackendContext and 🟡 feature:effect-io-locator-identity-from-value on effect_io_pure_locator_identity (Practice 4 / INVARIANTS P5). Addresses cursor REQUEST_CHANGES review 28382. Co-authored-by: Cursor <cursoragent@cursor.com> * fix(#4663): restore Practice 10 disposition on backends_match Reclassify EffectIoResourceBackend as 🟢 terminal coproduct (Practice 4). Move illegal-states 🟡 to EffectIoFixtureStore/EffectIoResourceLocator (Practice 2 dual-tag debt). Restore function-level 🟡 on effect_io_pure_backends_match per cursor RC review 28403. Co-authored-by: Cursor <cursoragent@cursor.com> --------- Co-authored-by: Brian Searls <briansearls1@gmail.com> Co-authored-by: Cursor <cursoragent@cursor.com>
Summary
Compute-fabric design briefs A–D as grounded design docs (the coercion flip applied to provisioning), plus a PROV status flip:
design-compute-request.md:ComputeRequestas a typed fact-bundle — dimensioned interval resource asks, closed capability vocabulary with per-kind satisfaction rules, workload effect facts. Lands only inside the A+B+C slice (no request type without its resolver, E-10).design-compute-providers.md:ComputeProviderconcept instd/, homelab/GCP instances inextdeps/compute/; availability classes carry obligation sets discharged structurally against workload effect facts (Preemptible⇒ re-runnable via theeffects.dagpartition); declared-vs-reality divergence detects fail-closed at dispatch; unify-with-OaaS_v2argued over greenfield (P5). gunb.ai-side grounding marked out-of-clone.design-compute-policy-selection.md:compute_selectas afind_witnessdomain wrapper (theconstraints.dagprecedent), plugging into the existingMultiplicityPolicy/TargetDeclaredPriorityseam — no fold variant added. Policy = declared lexicographic ordering over dimensioned objectives; zero-satisfier and tie cases refuse with a per-candidate located report. A+B+C slice (5 claims) is prototypable now with zero runtime work.design-compute-dispatch.md: gated dependency statement —OaaS_v2bridge contract inheriting the P2 host-process boundary discipline (no implicit re-execution; re-selection is declared policy), dissolution trigger on the native runtime path, and the 5-question input spec the runtime-architecture design must answer for its first real consumer.Also:
design-provenance-span.mdstatus flipped HELD → dispatched (operator GO 2026-06-09, #4592); doc-chain regenerated for thedoc_refsgate.Docs only; no code changes. Follow-up commits on this branch will add the remaining design-TODO
[DOC]items (v4-runtime-architecture; brand phase-2 cross-module identity).https://claude.ai/code/session_018QC433THjRyqiHuP8czPi4
Generated by Claude Code