Status: done (2026-11-26) Priority: 2 Size: M Arch: plans Phase: implement Design ref: design.md section 7, Plans at four scales (The task as a plan); docs/plans/four-scales/README.md, 3.2 (What it removes and keeps) and 3.9 (Removed); BACKLOG.md, How this backlog works (Refactor rules) Touches: sim/agents (start, release, complete, deposit, arrived, ended, freeHands, stopWorkFor, sideEnded); sim/kinds (KINDS, carriedOn); sim/lying (fetchKey, fetchKind, fetchWork); sim/clock; sim/jobs (lookForWork); sim/fit; tests/lib/invariants.js Goal: One way a task goes on, the method, with nothing left of the phase machine Acceptance criteria:
agent.journey ‘walk’/’rest’, the walk home agent.homeward; the invariants restated; the 15 fields, the fetch kinds and j.plot remain, carried by VB-1820 and VB-1821; K.stack, K.load, j.common went with VB-1750): the job phases go, work, back, home, road as a pawn’s state for a task (the invariants restated over legs and goals; an away pawn’s journey keeps a state under its own name, VB-1562’s invariant restated with it); the 15 control fields (load stack back carry to deliver again stages reload setDown fetch setOut carted inside trip) from every KINDS record; the fetch kinds; the inline cases of agents.ended and complete (K.stack, K.load, j.plot, j.common).docs/plans/four-scales/README.md, 3.10), by one command: npm run verify green (a test that asserted the old behaviour updated on purpose, never skipped or quarantined, and named in the PR), and node tools/gate.js --base <the last recorded result> passing (VB-1774): no settlement extinct by hunger or collapsed (VB-1774’s bound), no more tasks held over 48 hours than the base, the stocks’ unexplained no larger.node tests/counters.js, --update with the entries listed); the result kept (--out) as the next task’s base.node tests/lint.js, node tests/ownership.js); a kind’s fields counted before and after.FORMAT raised (sim/saves): a save of an older build is refused, as docs/architecture/modules.md (Saves) says; no migration is written. A save holding a pawn mid-phase is one of these; the late-save fixture is rebuilt (node tools/fixtures.js make) for the cost criteria that read it.
Notes:a.load > 0) is the old ‘back’ (VB-1750: a load is only ever hauled); the walk home is a flag, agent.homeward, not the route’s end (a stroll to the house tile is not one); an away pawn’s walk keeps its state as agent.journey.j.plot). Lint: sim/agents exports 28 to 27.--update); small-y5 and small-y40 rebuilt at FORMAT 6.