Status: done (2026-11-16)
Priority: 3
Size: S
Design ref: none (cost; AGENTS.md, Rules for cost 6). src/sim/jobs.js: score, urgency, bid, planRound, lookUp, offered
Goal: The planning round scores each open job for each idle pawn that may take it (bid, score), and a pawn looking up from its work scores its household’s jobs again (lookUp). A score’s dearest part is the job’s urgency (urgency(st, j, c)), which takes no pawn: the same job is weighed again for every pawn that bids on it. Work a job’s urgency out once a round and read it for each bid.
Acceptance criteria:
allot, sim/jobs) and one round of help (helpRound, offered), a job’s urgency is worked out at most once; nothing is kept past the call, in st or beside it. (Reworded 15 Nov: planRound, bid for a household’s own work and lookUp are gone since VB-466.)node tools/same.js --base REF --scenario founders,heirs,populous prints same. If an urgency turns out to change within a round (an assignment earlier in the round moving a store it reads), the task says which, and keeps those worked out each time.allot, score and helpRound, and the year lines.
Notes:planRound 6.9, of it bid 1.9 with score 0.95 and urgency about half of that; score over all its callers 1.8, of it urgency 1.1; under lookUp, score 1.1 with urgency 0.7. About 3,000 bids a game day (matchBid 22 a living pawn-day).spareUrgency (sim/kinds) through spareDays and spareFood (sim/pot), and reserved (sim/stores).assign), which Kim set aside on 15 November.15 Nov 2026 (merge of main into the head’s day and blocks branch): the head’s day (VB-466) replaced the round of bids for a household’s work and the hourly look up: allot weighs each member for each task once when the day is allotted (21 pairs a pawn-day), and the switch test reads the fits it already has. Criteria 1 and 3 reworded to that; the saving is smaller than measured in the note above (after the merge, populous small, seed 7: urgency 1.5% and score 2.4% of Sim.advance).
urgency(st, j, c, memo) reads and fills a Map the caller makes: allot makes one for its pairs and its switch test, helpRound one for offered and its bids (score, bid, offered take it as a last argument). It lives in the call and is dropped with it; nothing in st or the closure. No urgency was seen to change within an allotment or a round (the work commands of allot come after its pairs are scored; assign after all bids), and same.js agrees.node tools/same.js --scenario founders,heirs,populous (seeds 7, 42, tiny, 2 years) prints same. Populous tiny seed 7, 4 years, year lines (pop 134, 139, 144, 147) as before by same. Criterion 3 not met in part: times are not measured while the machine is shared (task rules); only the after run of --report perf was taken (202 ms/day, a description, no before). The nightly bench holds the comparison.