diff --git a/docs/architecture/THE-PROVING-GROUND.md b/docs/architecture/THE-PROVING-GROUND.md index efdf8c1dda..289448c95a 100644 --- a/docs/architecture/THE-PROVING-GROUND.md +++ b/docs/architecture/THE-PROVING-GROUND.md @@ -143,6 +143,75 @@ Workload sources: Cormac owns turning these into the scenario suite (HOW-A-MIND section 10). +## 4a. The data shapes + +Every part of the proving ground reads these, so each is defined once (Cormac, the workloads owner). They are +derived from the capture records' own fields (request and response records in `fixtures/prompt-captures`, +schema 4; the field list is in `~/.continuum/evidence/2026-10-30-read-loops/README.md`). + +**`ActReduction`, one per act, built on the node that holds the capture (P9):** + +| Group | Fields | +|---|---| +| Identity | persona, room, request, session, cycle, build sha, captured-at, cause and cause root (ids, not content) | +| Request | context window, max tokens, purpose (enum); system prompt `{tokens, hash}`; each message `{role, tokens, hash}`; each tool `{name, schema hash, tokens}` | +| Response | finish (enum); usage `{input, output}`; timing `{cached, prefill tokens, prefill ms, decode tokens, decode ms}`; each tool call `{name, args fingerprint}`; reasoning `{tokens, hash}` and text `{tokens, hash}` kept apart (a cut inside thinking is not an answer) | +| Request budget | the reasoning budget actually sent. The engine adds it after capture, so for evidence before it was captured the reducer joins `delib.act.reasoning_budgeted` by persona and time; going forward the capture records it (Fable) | +| Allocation | the act's allocation receipt: `claims [{source, floor, want, granted}]`, `unallocated`, `turnover`, joined from `delib.window.flex` and `delib.view.sized`; and `view messages` from the capture (count and tokens per item, no words). This is the mechanism a known-bad fails on, not only its symptom | +| Delivery | elapsed ms, wire attempts, error kind (enum) | + +- Token counts use the serving model's own tokenizer, recorded by model id **and** tokenizer artifact identity + (revision and hash), so a reduction reproduces exactly (Codex). +- **Unknown is explicit.** A timing, usage or budget the capture did not record is `Unavailable`, never zero: + a zero is a measurement. +- **Every joined field carries its provenance.** A field joined from probes by persona and time (the sent + reasoning budget, the allocation receipt) is `Exact` (one request matched), `Ambiguous` (several concurrent + requests could match) or `Unresolved` (none matched). An ambiguous join is never resolved by guessing: + concurrent requests get no attributed budget or allocation, and a known-bad that needs it on those acts + says so. New captures bind their receipts by request id plus epoch and allocation, so going forward every + join is `Exact` (Codex). +- `args fingerprint` is the hash of the tool codec's canonical arguments: MIND-CONTEXT invariant 4's + fingerprint. Repeats are visible in a reduction without any of the words. +- A reduction carries outcome kinds (section 7 of HOW-A-MIND: edit applied, message sent, PR opened, move made, + tool error, unfulfilled) as typed values reported by the producer, never read from text. + +**The text check (P9, enforced by type and test, not by review).** A reduction is accepted only if every +string field belongs to a closed set: ids, tool names, model ids, enum values and hashes. Everything else is a +number. The reducer's output type has no free-text field, and a test feeds it a capture with planted words +and asserts that none survive. A stray string fails the build, so no reviewer has to catch it. + +**The scenario file (P5):** + +| Field | Contents | +|---|---| +| name | | +| kind | `Scenario`, or `KnownBad { incident, policy revision }` | +| world | node profile references: the existing measured profile type, carrying its measured memory and capability domains (device, unified, RAM, disk, CPU; prefill and decode rates; the decode knee), each with the timestamp it was measured, and the engine's slot geometry (`n_slots`, `n_ctx_slot`, `kv_unified`) so a slot layout is data. A domain never measured is marked unmeasured. The person's timeline (apps, messages, patience) | +| workload | reduction-set references, and which minds and acts each one replays | +| events | typed events with their times | +| policy | a revision, or overrides to it | +| pass | `[{metric, criterion}]` | + +- A criterion is an invariant (`== 0`, never) or a comparison with a named, measured baseline. A threshold + someone picked is refused, as R1 requires. +- A `KnownBad` file states the criterion the prover must report as failing. + +**Home.** The types live in one small crate, `continuum-proving-types` (serde, ts-rs bindings, no logic). +The T0/T1 harness (Fable), the grid world (Codex) and the reducer (Cormac) all depend on it, so no shape is +defined twice. + +**First files: the known-bad suite** + +| Known-bad | Evidence | Fails on | +|---|---|---| +| The 12,288 reply cap | `2026-10-30-read-loops/` (M5, ab0466601) | the view's `unallocated` = 0 with a turnover every act (the mechanism); repeats per resident-hour (the symptom) | +| The 963 grant with the 1,024 think budget | `2026-10-30-think-cuts/` (M5, b7879d85c), with `core-probes-since-2130Z.log` for the sent budget | a sent reasoning budget above the grant; identical cut-think stops; writes per hour | +| Four fixed slots | the same directory, `engine-58057.log` and `engine-args.txt` | a hot writer cut while other slots idle | +| 49,152 on another machine | `2026-10-28-working-window/` (the M5 basis), run on a smaller swept profile | turnovers per act on that profile | +| The 48k to 32k live-rate window | the residents' `.prev` capture segments, 2026-10-28 (no frozen directory) | turnovers per act | +| Kimi's 100,704-token turn | **not found in the available captures or log rotations; likely rotated out** (Codex searched the current and previous captures, the core and probe rotations and the saved evidence on the 5090, where the oldest ends after 2026-10-30 11:27 local; that does not prove every archive exhausted). Until a recurrence is captured it is a labelled **synthetic** workload (P3), built from the measured description: input 335k, output 100,704, window 101,120, about 2 cycles an hour of 8 to 10 minutes | act seconds; lane time held | +| An unfulfilled act repeated (#5604, resident 75ece751) | her card 6c55f7a7 | repeats of an unfulfilled act | + ## 5. What it measures and what passes Every run reports the same metrics as the live health line and the 15-minute read, from the same receipts.