araharah-executor
72703d26ec
test(06-01): add failing GPS-fix snap suite S1-S6 (RED)
...
- Exact-node hit, mid-edge closer-endpoint projection, nameId resolution
(named + unnamed-null halves), bbox-margin honest miss, oneway direction
ignored, WeakMap grid memoization (build-counter + structural greps)
2026-10-24 12:09:18 +08:00
araharah-executor
1ce35907d5
feat(06-01): CSR graph codec + committed mini-graph fixture + RouteStep.kind (GREEN)
...
- graph.ts: decodeGraph/encodeGraph over the pinned little-endian CSR
layout; header magic+version+exact byte-size validation BEFORE any view
allocation (T-06-03/T-06-03b fail-honest null); zero-copy typed-array
views; street-name pool with UNNAMED_NAME_ID sentinel
- header padded 60 -> 64 bytes so f64 views are 8-byte aligned — unaligned
Float64Array throws RangeError, making plan-literal offsets incompatible
with the plan's own zero-copy law (documented deviation; field
order/content/endian unchanged; consumers inherit via encodeGraph)
- build-mini-graph.mjs + committed mini-graph.bin: hand-built 5x5 grid,
25 nodes, 80 directed edges, 3 named streets, exactly ONE oneway pair,
two speed classes (60/30 km/h) — the A* ground truth (G7 pins it)
- types.ts: RouteStep gains optional kind (8 turn kinds) — Engine A
populates it (06-01); fixture-world steps stay empty arrays (D-10)
2026-10-24 12:07:17 +08:00
araharah-executor
53740944b8
test(06-01): add failing CSR graph codec suite G1-G8 (RED)
...
- Pinned-layout gates: round-trip, bad magic/version/truncated -> null,
zero-copy view mutation, name pool, committed mini-graph fixture pin
- Each case lazy-imports ../src/graph.ts — ERR_MODULE_NOT_FOUND is the
red state (fixture-source.test.mjs pattern)
2026-10-24 12:05:16 +08:00
araharah-executor
6c0880b4db
feat(05-02): offline corpus tolerance gate — measurePairs core + CLI + in-suite RT1-RT10 (GREEN)
...
- routing/scripts/route-corpus.mjs: the shared measurement core (exported
measurePairs) + CLI reporter in the gazetteer-corpus.mjs shape — one
measurement, two reporters, no drift
- RT1 corpus size 10..20; RT2 schema + RT2b mechanical D-12 proof (every
committed origin equals its gazetteer landmark within 1e-4 deg); RT3 route
shape; RT4 probe exclusion (national-museum never a destination); RT5
haversine-vs-summary band [0.85, 1.10] + bbox+0.05; RT6 speed [1.0, 30] m/s;
RT7 codec round-trip per route; RT8 ODbL header surfaces; RT9 gz budget
(measured 16576 B / 102400 B); RT10 alternatives floor (8 pairs / floor 4)
- fully offline: zero network in the measurement path (T-05-05); pair ids and
measurements printed, never geometry strings (D-15); fixed escalation
ladder on failure (--only repair -> regenerate -> re-gate)
- suite: 35 passed, 0 failed; npm run routing:corpus exits 0; typecheck clean
2026-10-24 05:19:55 +08:00
araharah-executor
63ef408197
test(05-02): add failing offline corpus tolerance gate suite RT1-RT10 (RED)
...
- one test per check, mirroring search/test/corpus.test.mjs: the suite imports
measurePairs from routing/scripts/route-corpus.mjs IN-PROCESS (never spawns
the CLI) — one measurement, two reporters, no drift
- RED: the measurement core does not exist yet -> 10 named ERR_MODULE_NOT_FOUND
failures; the committed dataset itself is already green material (task 1)
- fully offline by construction: zero network in the measurement path (T-05-05)
2026-10-24 05:18:16 +08:00
araharah-executor
4e89cff552
feat(05-02): pinned golden-pair corpus + OSRM-demo fetch tool + populated committed dataset (GREEN)
...
- routing/test/fixtures/golden-pairs.json: the hand-authored 15-pair pinned
corpus (D-02/D-12) — origins AND destinations are gazetteer landmarks,
klBbox + 100 KB gz budget + probe id + alternatives floor pinned
- routing/scripts/fetch-route-fixtures.mjs: the maintainer build tool
(overpass-topup.mjs pattern) — D-12 boundary in the header, pre-flight
public-coordinate proof against the gazetteer (1e-4 deg), mandatory
User-Agent, 1200 ms inter-request delay, one retry on network/5xx,
collect-then-write, --only=<pairId> single-pair repair merge
- routing/src/data/route-fixtures.json: 15 real OSRM-demo pairs committed
(1-3 verbatim polyline6 routes each; 8 pairs carry >= 2 alternates),
ODbL header fields preserved (T-05-06)
- loader-env L3 armed (RED commit 01b0ed6 ) + C6 re-pinned from the empty-seed
state to the populated corpus (05-01 documented both as 05-02 handoffs)
- npm delegates: root routing:fixtures; routing fixtures + corpus scripts
2026-10-24 05:17:01 +08:00
araharah-executor
01b0ed6884
test(05-02): tighten loader-env L3 to require pair 1 serving at pinned origin (RED)
...
- L3 previously pinned the 05-01 empty-seed state (honest null at the pinned origin)
- it now asserts the default fixture source SERVES pair 1 (kl-tower-to-kl-sentral)
at its pinned public origin and resolves honest null ~300 m away (outside the
200 m tolerance, D-03)
- RED until plan 05-02 populates the committed fixture dataset
2026-10-24 05:14:15 +08:00
araharah-executor
3e0c5e3eb4
feat(05-01): geo math + fixture RoutingSource backend + public API
...
- geo.ts: haversineM + deriveCumulativeDistanceM (D-07 snapped-progress field)
- fixture-source.ts: backend #1 — ORIGIN_TOLERANCE_M=200 matching law,
honest-null pending semantics (D-03), defensive pair skip at index build,
lazy memoized index (LAW 1), static JSON import (LAW 2), zero
logging/storage/network (LAW 3, D-12)
- index.ts: named-export public surface, subpath-with-extension import law
- loader proven in three environments (bare Node 24, esbuild, Vite-family)
2026-10-24 05:03:07 +08:00
araharah-executor
0599ffe14f
test(05-01): add failing fixture-source + loader-env suites (F1-F8, L1-L3)
...
- synthetic injected datasets only — never the network, never the committed file
- F3 pins the 200 m haversine tolerance boundary; F6 the defensive pair skip
- F7 the lazy-index source gate (LAW 1); L2 the esbuild inline marker
2026-10-24 05:02:08 +08:00
araharah-executor
4acb878c33
feat(05-01): polyline6 codec (pure, zero-dependency)
...
- standard encoded-polyline algorithm at 1e6 precision, double math
(no int32 shifts) so no coordinate range wraps silently
- decode THROWS on truncated varints — never partial/NaN points (T-05-02)
- round-trip law encode(decode(s)) === s proven on all vectors incl.
the external live-OSRM geometry (RESEARCH Finding 1)
2026-10-24 05:01:13 +08:00
araharah-executor
9b66f90a4b
test(05-01): add failing polyline6 codec vectors (P1-P8)
...
- hand-derived vectors from the plan's <polyline_vectors> block
- external live-OSRM demo geometry (RESEARCH Finding 1) as ground truth
- P7 pins the truncated-varint refusal law (T-05-02)
2026-10-24 05:00:32 +08:00
araharah-executor
c92a955272
feat(05-01): RoutingSource contract + day-one route model + fixture seed schema
...
- types.ts: the D-01 backend-ladder seam (fixture -> wasm-router -> valhalla),
D-03 null contract documented on the interface, D-07 day-one fields
(RouteStep typed + RouteGeometry.cumulativeDistanceM, GUID-05/06 obligation)
- route-fixtures.json: committed EMPTY seed with the ODbL header
(license/attribution/notice, T-05-06) — plan 05-02 populates it
2026-10-24 04:59:45 +08:00
araharah-executor
69b6a20350
test(05-01): scaffold routing workspace with failing contract suite
...
- fifth npm workspace @araharah/routing (buildless TS, search/ precedent)
- root delegates routing:test / routing:typecheck / routing:corpus
- C1-C6 RED: contract gates fail while src/types.ts + seed are absent
2026-10-24 04:59:17 +08:00