substrate: server, housekeeping job, spa - the mvp complete
- prompt split, GM's cut: system.md = opening + guards (glossary, purpose, input validation; repo-fed, per-project); invariants.md = substrate (syntax markers, tools, memory, records, the paper + its three-part gate; repo-fed, travels with the code); handbook.md = craft copy (shape of play, thoughts, purview, time skips, continuity, stance, hard limits; copied per run). One system message: system -> invariants -> the run's handbook. OOC is a single open paren, closing optional, match the GM's style; a lone paren is an empty OOC line, skipped by the parser. housekeeper.md aligned: the paper holds acute states, relational shifts are recorded as the facts behind them, and dates are story dates (follow the rings' calendar, never the wall clock - the seed is 2069 now, per canon) - server/ (phase 2, zero-dep node:http): REST spine per the sketch, per-run session machine with ask_gm pause/resume (the whole tool-call batch waits, pairing stays sound), view renderer (thinking-strip, tool-result elision with ask answers exempt, old status/conflict blocks stripped), boot-rebuild from the typed jsonl, lazy seed + turn-0 ingestion at window-open with the unhousekept refuse-and-override guard, usage tracking + context meter, tool-pairing validation, scripted mock model. The clerk gained --json (packages/runs/status); tool/bridge.mjs deleted at mock-parity per the retirement decision - housekeeping job (phase 3, server/housekeeping.mjs): trigger ends the window and runs the chain async - transcript with labeled thinking, run-state injection (records availability; the ring views stay pure memory), housekeeper on a fresh context, manifest saved (raw output too if unparseable), clerk apply (writes the window log, snapshots dumps/<window>.sql), state.json lastHousekeptSession, autorestart. Rejection holds the restart and surfaces why; the apply endpoint is the recovery path and the manual-relay close. Live-proven twice: both manifests sound (ring-B classification, first-person voice, precise touches, story-dated) - spa (phase 4, web/ - no build, vanilla es modules, served at /): three-register transcript per the ruled markers incl. multi-line narration blocks, bundle as a collapsed card with turn-0 as the opening GM turn, paper tags as chips, status pane with conflict surfacing, context meter hot past 85 percent, gm line input, ask modal re-presented from pendingAsk, housekeeping button with two-click arm + poll + inline log. No js alert/confirm (they block the embedded pane) - in-page banner instead. Driven end to end through the ui on a disposable live run - seed: date fixed to the 2069 story calendar (was a real-world date; real dates never surface to the player) - docs: README goal states the mvp is complete, layout covers server/ and web/, protocol and substrate sections rewritten for the server; ROADMAP phases 0-4 done, harness decisions current; QUESTIONS #4 #7 #10 #12 #16-mechanism #19a #20 #21 resolved; HANDOFF is the handoff map; AGENTS carries the working lessons (tokens are free, no screenshots - not multimodal, no js dialogs, external state survives rewinds)
This commit is contained in:
@@ -8,6 +8,9 @@ memory the agent owes itself across sessions.
|
||||
|
||||
## Working with the GM
|
||||
|
||||
- **Their LLM tokens are free (2026-11-14): never economise on usage.**
|
||||
Run live tests freely; don't hesitate over spend or trim prompts,
|
||||
manifests, or transcripts to save tokens.
|
||||
- The GM drafts creative content; the agent drafts mechanical content.
|
||||
"I draft, you cut" runs both directions. They edit files directly and
|
||||
say "check it out" — always re-read before reviewing or editing; the
|
||||
@@ -36,6 +39,12 @@ memory the agent owes itself across sessions.
|
||||
is the camera: present while the scene plays — example — past to
|
||||
summarise — example" passed their red pen. A metaphor left uncashed
|
||||
is a riddle.
|
||||
- **No HTML comments in prose or prompt files** (2026-11-14): purpose
|
||||
descriptions live in README (layout), AGENTS, or as comments in the
|
||||
substrate code. Generated views carry their do-not-edit warning in
|
||||
the clerk, not in the output. The views are pure memory: run state
|
||||
(records availability) rides the phase-3 housekeeping invocation,
|
||||
not the ring headers.
|
||||
- Output-style counterexamples prime what they prohibit (far context
|
||||
can't suppress, only prime). State tests and positives instead.
|
||||
Input-side counterexamples (routing examples, "Refuse" cases) are
|
||||
@@ -59,14 +68,46 @@ memory the agent owes itself across sessions.
|
||||
("The harness") and HANDOFF. Bridge retired before ever going live;
|
||||
REST + SPA is the MVP; runs are per-deployment instances copied from
|
||||
packages at creation; zero-dep stack. Doc set updated to match.
|
||||
- Build order: clerk paper migration DONE (2026-11-13) → preset/run
|
||||
split DONE (2026-11-13: create/runs/packages in the clerk, runs/
|
||||
gitignored, server.json config, packages authored-only, prelude.md
|
||||
renamed turn-0.md by the GM) → system.md split extraction (GM red
|
||||
pen, prose deferred — gates first run creation, not the server
|
||||
build) → server (phase 2) → housekeeping job (phase 3) → SPA (phase
|
||||
4, strictly downstream). Lazy seed + turn-0 ingestion are orchestrated
|
||||
by the server at window-open; the clerk verbs exist and are tested.
|
||||
- Build order: ALL FOUR PHASES DONE (2026-11-13/14) — clerk paper
|
||||
migration, preset/run split, prompt split, server, housekeeping
|
||||
job, SPA. The MVP substrate is complete and live-proven end to end
|
||||
(two real wraps, one full UI-driven session). Remaining roadmap
|
||||
surface is the "Later" list (turn surgery, memory browser, context
|
||||
inspector, book export, service step) plus whatever the first real
|
||||
story surfaces.
|
||||
Server entry: `node server/main.mjs [--mock]`; SPA at
|
||||
http://127.0.0.1:7350/; POST bodies from PowerShell need
|
||||
Invoke-RestMethod (curl.exe mangles quotes); background start/stop
|
||||
via Start-Process -PassThru with a PID file in $env:TEMP.
|
||||
- Gotcha (2026-11-14): before starting the server, check
|
||||
`Get-NetTCPConnection -LocalPort 7350` — a forgotten instance holds
|
||||
the port and silently answers with OLD code while the new one dies
|
||||
on bind (bit me once; two accidental live turns resulted).
|
||||
- Gotcha (2026-11-14, GM): **never call browser.screenshot** — the
|
||||
image return breaks the session (glm-5.3 is not multimodal; the GM
|
||||
had to rewind once). Verify UI text-safely: browser.snapshot
|
||||
(accessibility tree), browser.console, browser.network. If real
|
||||
vision is ever needed, the endpoint carries multimodal
|
||||
deepseek-v4.1 — but prefer never needing it.
|
||||
- Gotcha (2026-11-14, GM): **no JS alert()/confirm()/prompt() in the
|
||||
SPA** — they block the embedded browser pane (the GM sat locked out
|
||||
of their input once while a test confirm hung on my dialog-tool
|
||||
fumbling). In-page UI only: the banner for notices, two-click arm
|
||||
for confirms.
|
||||
- Gotcha (2026-11-14, rewind aftermath): a session rewind erases my
|
||||
memory of tool calls but NOT their effects — the server, files, and
|
||||
databases keep them. After any rewind, external state is the truth:
|
||||
re-read it, and never assume authorship of found content (I once
|
||||
credited the GM with a GM-turn that pre-rewind me had written).
|
||||
- Open tails: none on the prompt side — housekeeper aligned to the
|
||||
invariants paper boundary (2026-11-14), assembly order confirmed
|
||||
(system → invariants → the run's handbook, one system message).
|
||||
- Dates principle (2026-11-14): dates in seeds/manifests/rings are
|
||||
STORY dates; real dates never surface to the player (canon:
|
||||
la-caramba is 2069). The seed was fixed to 2069-11-18 (day is the
|
||||
GM's call).
|
||||
- Watch: the "never open with world narration" rule was cut as
|
||||
superfluous by the GM — reinstate only if testing shows drift.
|
||||
- Defaults taken without asking (2026-11-13): #21 window-open refuses
|
||||
over an unhousekept session with explicit override; #16 housekeeper
|
||||
defaults to the player's model; #10 tool-call pairing validation goes
|
||||
|
||||
Reference in New Issue
Block a user