VB-1778: The season’s targets against the labour budget: a season that does not fit is seen at its start
Status: done (2026-11-27)
Priority: 2
Size: M
Arch: plans
Phase: implement
Design ref: design.md section 7, The levy and own hours (The labour budget); Plans at four scales (The season); docs/plans/four-scales/README.md, 3.3 (The coupling, horizon by horizon), section 6 answer 2
Touches: sim/levies (budget, fit, say); sim/seasonal (reviewTargets, lowerTargets); sim/estimate (workOfTarget); sim/hands (plannedHelp); sim/day (allot); sim/service (serveWhereShort); sim (plans); tests/levies.js
Goal: A parent’s levy is the budget its child plan runs within, and a household sees at a season’s start that its plan does not fit
Acceptance criteria:
The labour budget of a household for a season (sim/levies): the sum of its members’ levies (levyOf) over the season’s days, less the days of its outer levies (8 work hours each; today the days owed of sim/days) and the levy of its known stays away and dated grants, computed at the season’s first review and when membership, a grant or an outer levy changes; read by Sim.plans beside the season’s steps.
Each season step’s hours left (left: lo, mid, hi, by the head’s estimate; VB-1752) is set against the budget; a season that does not fit is seen at its first review and answered by the head’s default author in design.md’s order (A season that does not fit): hands asked (help in the window, sim/hands, and a servant at the moving round, counted on only when given), then a target lowered, the step whose yield an hour is lowest first while it is below DEMAND.weight times an hour’s worth (never for an absence shorter than the step’s window), then the rest demanded day by day (VB-1779); a standing grant is not renewed by a head short of hours; which, and when, said in a line of the record.
A check on a constructed household: a season whose targets’ hours exceed its budget is flagged at its first review and answered; one that fits is left alone.
Cost: 200 households × 4 seasons a year × about 30 rows (about 500 reads a day at the late reference); no pass of its own.
The gate (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.
Reported in the PR from the same output, not gated: hungry household-days and deaths by hunger in the six runs, before and after, and the work counters (node tests/counters.js, --update with the entries listed); the result kept (--out) as the next task’s base.
Notes:
25 Nov 2026: Path step 6 (review of 25 Nov, B1): the mechanism that couples the plans of the levels had no task. VB-1764 draws it; VB-1767’s outer days come off it.
25 Nov 2026, VB-1759 (design.md, The levy and own hours): the order of answers is design.md’s A season that does not fit; the budget counts stays away and dated grants out.
27 Nov 2026, Kim (project thread): the budget is the season’s total with a breakdown by thirds of a season (4 game days each, a game day standing for about a week): each third’s levy hours set against the target hours due in it, so a short third (early, mid or late spring) is seen at the season’s first review and answered in the same order. The levy itself stays hours a day. The core loop (Kim): a day is short and tasks long, so the third, not the day, is the grain at which a plan’s fit is judged.
27 Nov 2026, VB-1778 (decisions): the head pair, not levied, count in the budget at the adult row times their hands (the plan is theirs and
they work it; counted out, every couple’s season would be short). A step is due by its game week: a routine’s at the earliest window its
open tasks close in (sim/hands windowEnd), else its last day; fit is judged cumulatively, the hours due by each week’s end against the
budget to it. Lowered only: the fields and made goods (a field at FIELDS.expect × barley’s yield less its seed a year; a good at custom’s
worth); never the seed (held back first), the woodpile or the hay (custom gives them no worth). Help planned is spread over the window’s
days and asked at the morning’s ask beside the day’s own shortfall; a servant wanted at the year’s moving round counts the household short.
Not built, nothing to count: stays away and dated grants (VB-1763), so the budget takes none out and no grant renewal reads plan.fit.short
yet; the absence rule of the lowering waits on them too. Daily chores (the meal, water) are in no step’s left until opened, so the
budget is generous: a season is short only where its targets alone exceed it.
Cost: budgetReckoned 0.020, fitJudged 0.020, fitRow 0.19 a pawn-day (tests/counters.js); one fit a household a season, no pass.
Gate (founders, populous; seeds 7, 11, 42; 10 years) holds against docs/gate/base.json: hungry household-days 0/5/0/158/106/180 (base 0/5/0/192/119/173), deaths by hunger 0 (base 0), stuck 0, unexplained 0; kept as the next base. tests/asks.js updated on purpose: its autumn season judged to fit, so the tar target is the asks’ alone.
27 Nov 2026, revision (review F1-F10): a field’s yield is sim/estimate fieldYield, read by the fit and the demand alike (no seed taken off); planned help is capped by the shortfall and by the step’s hours left; a year’s outer days are spread over the seasons to their due date; a whole store is lowered by whole units; the played head is told only. The gate was not run again after the revision: its numbers above are of ffbdc9d6.