Skip to content

Quilt backend: watch the substrate run while you play (5-opcode kernel, chain cells, Q toggle, witness export) - #1

Merged
SuperInstance merged 3 commits into
mainfrom
quilt-backend
Sep 22, 2026
Merged

SuperInstance merged 3 commits into
mainfrom
quilt-backend

Conversation

@SuperInstance

Copy link
Copy Markdown
Owner

Fleet fork addition for the Cocapn ecosystem. The city gets a live quilt substrate: every building/agent BINDs, every dependency and walk LINKs, every fire/sparkle/rocket/status is an EFFECT, the scene is a VIEW, frames TICK — all as prev_hash-chained cells with the fleet canary. Press Q (or ◈) and a phosphor pane streams the backend while you play; export the witness JSONL and it replays in kev-substrate-competition's harness/replay.py.

Respect for the original: city.js/effects.js/agents.js/controls.js byte-identical; the bridge wraps from outside; index.html +8 marked lines; creator credit guarded by a regression test. Upstream files otherwise untouched. 10/10 node --test green; CI fixed to actually run tests (npm ci had no lockfile; lint step was a no-op).

kimi1 added 3 commits September 22, 2026 16:56
…n cells, backend toggle (Q), witness export

Fork addition (upstream game modules byte-identical; bridge wraps from
outside, index.html +8 marked lines):

- app/quilt/kernel.mjs — vendored minimal quilt kernel: BIND/LINK/
  EFFECT/VIEW/TICK/FORGET, prev_hash chain (FNV-1a-64 UTF-8 bytes,
  genesis 0x0000000000000000), fleet canary verified, honest FORGET on
  trim, witness() export in kev harness JSONL shape (this toy is a
  witness-log producer for kev-substrate-competition's replay.py).
- app/quilt/bridge.mjs — wraps City/EffectsManager/AgentManager from
  outside: buildings/agents BIND, dependencies+walks LINK, fires/
  sparkles/rockets/status EFFECT, scene VIEW, aggregate TICK every 30th
  frame.
- app/quilt/pane.js — the 'see the backend in production' toggle (Q or
  ◈ button): phosphor pane, live cell tail, opcode counters, coherence,
  chain head, witness.jsonl export.
- tests/quilt.test.mjs — 10 tests, node --test, zero deps: canary byte
  law, genesis chaining, tamper->coherence drop, honest FORGET, witness
  field-for-field harness interop + replay-verify, wrapper fidelity
  (originals still run, order intact), tick cadence, creator-credit
  regression guard.
- CI made real: npm ci -> npm install (no lockfile existed, ci failed
  by construction), lint no-op -> npm test.
…onstruction); matrix to node 22 only (20 deprecated on runners)
…n bash — pre-existing upstream failure, now a harmless placeholder)
@SuperInstance
SuperInstance merged commit b62b908 into main Sep 22, 2026
2 checks passed
@SuperInstance
SuperInstance deleted the quilt-backend branch September 22, 2026 09:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant