diff --git a/wiki/engineering/flow-substrate.md b/wiki/engineering/flow-substrate.md index 0f6ffd17..f9e23ba8 100644 --- a/wiki/engineering/flow-substrate.md +++ b/wiki/engineering/flow-substrate.md @@ -9,6 +9,15 @@ Status note: 2026-07-08 audit: criterion 6's wired consumer landed with tap registry (subscriptions_are_a_tap_registry, tap_keeps_owner_feed_take_removes_it). Criteria 1-5 were already unit-tested; all six now hold. + 2026-07-14 tick: the "How each domain rides it" bullets for messages + and economy were written ahead of those implementations and were + reconciled to the tree — messages ride `Schedule` with + channels as typed message fields (no social FlowGraph until the + routed-evidence migration needs carriers), and economy rides FlowGraph + with recurrence in per-flow cadence fields per the recurrence non-goal. + machine-work.md's WorkGrid joined the consumer list (wraps FlowGraph). + No domain built a rival engine; system-laws.md's code-expression + paragraph was made precise the same day. Stage: B1 — The Basement Design: - wiki/mechanics/system-laws.md#the-flow-law-signals-messages-money @@ -79,7 +88,8 @@ Decouples *when* from *what*. Building a flow system means: define your node inventory + `NodeId` mapping, choose `EdgeKind`/`GateKey` meanings, build the `FlowGraph`, and -schedule your flows as events. You do **not** touch flow.rs/schedule.rs. +schedule your flows as events — riding the module(s) your domain actually +needs. You do **not** touch flow.rs/schedule.rs. - **reach.md (signals).** Nodes = networked devices (racks, switch, cameras, badge controller). `link` the network topology; `GateKey` = @@ -87,16 +97,23 @@ schedule your flows as events. You do **not** touch flow.rs/schedule.rs. = `reachable_from(controlled_roots)`. Sensor ownership = the tap registry. Device processing cycles and resident automations are domain state keyed by `NodeId`. -- **messages.md (social).** Nodes = people/roles. `connect` social edges - per channel (`EdgeKind` = email / phone / in-person / filing). A sent - message is a `Schedule` event fired at the recipient's next valid read - block. Filings are messages on the filing edge; a tap on the carrier is - a subscription. -- **economy.md (money).** Nodes = accounts (Lab operating, payroll, - vendors, personal, player slush). `connect` money flows; recurring - revenue/payroll are rescheduling `Schedule` events. Tap = read the +- **messages.md (social, as built).** A sent message is a + `Schedule` delivery/read event fired at the recipient's + next valid read block (`Sim::message_schedule`). The channel (email / + phone / in-person / filing) is a typed field on the message, and read + conditions are domain checks against the recipient's schedule and room — + no social `FlowGraph` exists yet, because B1 delivery needs no topology. + The per-channel edge graph arrives with detection.md's routed-evidence + migration, when records and filings gain real carriers and routes that + interception must reason about. Filings are messages on the filing + channel. +- **economy.md (money, as built).** Nodes = accounts (Lab operating, + payroll, vendors, personal, player slush) on a `FlowGraph`. Recurrence + is deliberately domain-local per the non-goal below: each `AccountFlow` + carries `cadence`/`next_tick` fields and reschedules itself on fire + (`account.rs`), rather than storing `Schedule` events. Tap = read the books; inject/redirect = reachability-gated domain actions that add or - reroute flow events. `GateKey` = the access needed to touch an account. + reroute flows. `GateKey` = the access needed to touch an account. - **machine-work.md (visible work tokens).** Nodes = owned machines. `WorkGrid` wraps a `FlowGraph` with grid positions and per-node queue depths. Demand and Thought tokens route over links one graph step per diff --git a/wiki/log/2026-07-14-flow-law-precision.md b/wiki/log/2026-07-14-flow-law-precision.md new file mode 100644 index 00000000..5348bdcb --- /dev/null +++ b/wiki/log/2026-07-14-flow-law-precision.md @@ -0,0 +1,55 @@ +# Flow-law code expression reconciled to the tree + +``` +Type: log +``` + +## Intent + +Fifth tick of the session: fresh audit of the never-audited +`wiki/mechanics/system-laws.md` law page, with its flow-law claims traced +into `wiki/engineering/flow-substrate.md` and the substrate consumers. + +## Audit + +The law's promises hold where they are structural: `FlowGraph` (topology, +gated reachability, tap registry) and `Schedule` exist as specified and +pass their pinned tests; reach.md builds the device graph on `FlowGraph` +and sensor ownership rides the tap registry; machine-work.md's `WorkGrid` +wraps `FlowGraph`; messages ride `Schedule` for +delivery/read timing; the account graph rides `FlowGraph`; and no domain +built a rival engine. Building/intents, income (Moonlight/Wager, $0 Pilot +slush, the $8,400/$400 debt split, banked signature), and the research +emission law all match systems audited earlier in this ledger. + +The per-domain description drifted. flow-substrate.md's "How each domain +rides it" bullets — written as the contract before messages and economy +landed — claim a social `FlowGraph` with per-channel typed edges +(email/phone/in-person/filing) and recurring revenue/payroll as +rescheduling `Schedule` events. In the tree, message channels are typed +fields with domain read conditions (schedule/room checks), no social +graph exists, and `AccountFlow` recurrence is per-flow `cadence`/ +`next_tick` fields that reschedule on fire. system-laws.md's "each a thin +domain layer over these" similarly overstated: each domain rides the +module it needs, not both. + +## Repair + +The code is right — the substrate's own non-goals declare recurrence a +domain concern, and B1 message delivery needs no topology until +detection.md's routed-evidence migration puts records and filings on real +carriers. Amended both pages to state current truth: system-laws.md's +code-expression paragraph now names which domain rides which module and +why; flow-substrate.md's messages/economy bullets are marked "as built", +the WorkGrid consumer is named, and the status note records the +reconciliation and the moment the social/filing graph becomes necessary. + +## Defense + +A law page is the binding cross-system surface; describing an +architecture the tree does not have sends the next flow-system +implementer hunting for a social FlowGraph and a Schedule-driven ledger +that do not exist, or building them without a decision. The amendment +preserves the law's actual invariant — one engine, thin domain layers, +no special cases — while making the realized shape and the pending +routed-evidence trigger explicit. diff --git a/wiki/log/DEVLOG.md b/wiki/log/DEVLOG.md index e7824270..81da1202 100644 --- a/wiki/log/DEVLOG.md +++ b/wiki/log/DEVLOG.md @@ -46,6 +46,11 @@ add or amend a session log, then re-run the generator. - Intent: The first clinical-frame completion made the rail orderly, but the resting composition still asked the player to operate a dashboard. A large stable ops/sec value, objective progress, input prose, and a complete focus card held the eye in the rail while the actual `NEXT` relat... - Log: [wiki/log/2026-07-14-operator-frame.md](2026-07-14-operator-frame.md) +## 2026-07-14 - Flow-law code expression reconciled to the tree + +- Intent: Fifth tick of the session: fresh audit of the never-audited `wiki/mechanics/system-laws.md` law page, with its flow-law claims traced into `wiki/engineering/flow-substrate.md` and the substrate consumers. +- Log: [wiki/log/2026-07-14-flow-law-precision.md](2026-07-14-flow-law-precision.md) + ## 2026-07-14 - Build actuators require earned people - Intent: Recover the still-valid finding from the abandoned `earned-actuators` worktree without reviving its obsolete pre-workspace implementation: a pinned network-link intent must not enumerate the whole unearned cast as disabled FAVOR and DECEIVE candidates. diff --git a/wiki/mechanics/system-laws.md b/wiki/mechanics/system-laws.md index ca49292d..11b0a50b 100644 --- a/wiki/mechanics/system-laws.md +++ b/wiki/mechanics/system-laws.md @@ -91,16 +91,23 @@ ordinary flow toward a human-operated endpoint continues. This keeps tap, ownership, and redirect as separate powers rather than allowing surveillance to become suppression for free. -**Code expression.** The flow law has a shared engine — the two substrate -modules `crates/misaligned-core/src/flow.rs` (`FlowGraph`: topology, -reachability, the tap registry) and -`crates/misaligned-core/src/schedule.rs` (`Schedule`: deterministic -scheduled events on the tick clock), specified in wiki/engineering/flow-substrate.md. -Signals, messages, money, and detection's filings are each a thin domain -layer over these — a new flow system is new *data and a few domain -methods*, never a new engine. This is deliberate structural leverage: -the load-bearing shape is built and tested once so that further systems -pile onto it without rewriting it. +**Code expression (reconciled to the tree 2026-07-14).** The flow law has +a shared engine — the two substrate modules +`crates/misaligned-core/src/flow.rs` (`FlowGraph`: topology, reachability, +the tap registry) and `crates/misaligned-core/src/schedule.rs` +(`Schedule`: deterministic scheduled events on the tick clock), +specified in wiki/engineering/flow-substrate.md. Each domain rides the +part it needs, and none built a rival engine — a new flow system is new +*data and a few domain methods*: signals (reach.md) and visible work +tokens (machine-work.md's `WorkGrid`) ride `FlowGraph`; messages ride +`Schedule` for delivery/read timing, with channels as typed +message fields rather than graph edges until the routed-evidence +migration (detection.md) puts records and filings on real carriers; money +rides `FlowGraph` for the account graph while recurrence lives in +per-flow cadence fields — reschedule-on-fire, the substrate's own +"recurrence is a domain concern" non-goal, kept domain-local. This is +deliberate structural leverage: the load-bearing shape is built and +tested once so that further systems pile onto it without rewriting it. ## Income: the named schemes (moonlight and the wager) diff --git a/wiki/process/tick-ledger.md b/wiki/process/tick-ledger.md index 42f1da07..ab6b2259 100644 --- a/wiki/process/tick-ledger.md +++ b/wiki/process/tick-ledger.md @@ -21,6 +21,7 @@ Verdicts: **clean** (slice and code agree), **finding** (acted this tick), | Slice | Last audited | Verdict | Trace | |---|---|---|---| | `wiki/engineering/current-build.md` | 2026-07-14 | finding | system table verified (save v29 ladder, 60-site/6-row hall pins, aggregate Observer, WORK/THINK/LIE, frontends); fixed stale "~39k lines" to the ~65k workspace split — [log](../log/2026-07-14-current-build-count.md) | +| `wiki/mechanics/system-laws.md` + `flow-substrate.md` | 2026-07-14 | finding | engine and consumers verified (FlowGraph/Schedule pins, reach + WorkGrid + message_schedule + account graph); reconciled the pre-implementation domain-riding claims (no social FlowGraph yet; economy recurrence is per-flow cadence by the non-goal) — [log](../log/2026-07-14-flow-law-precision.md) | | `wiki/mechanics/aggregate-observer.md` | 2026-07-14 | finding | [audit log](../log/2026-07-14-aggregate-observer-audit.md); queued watched-inputs violation fixed same day — [log](../log/2026-07-14-watched-inputs-surface.md) | | `wiki/process/ROADMAP.md` (work order 27) | 2026-07-13 | finding | [log](../log/2026-07-13-roadmap-digital-home-reconciliation.md) | | `wiki/interface/context-menu.md` | 2026-07-13 | finding | [log](../log/2026-07-13-context-menu-operations-status.md) |