diff --git a/AGENTS.md b/AGENTS.md index d90cee39a..a05699f09 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -273,7 +273,7 @@ stops startup instead of leaving a healthy-looking partial schema, and application code must not compensate for a missing table. Period leftover pairs (ADR 0017 / 0018 / 0048 / 0049 / 0119 / 0158 / 0162 / -0163 / 0164 / 0182 / 0185 / 0201 / 0233 / 0266 / 0267 / 0268 / 0269 / 0270 / 0271 / 0272 / 0273 / 0274 / 0275 / 0276 / 0277 / 0278 / 0279 / 0280 / 0281 / 0282 / 0283 / 0284 / 0285 / 0286 / 0287 / 0288 / 0289 / 0290 / 0291 / 0292 / 0293 / 0294 / 0295 / 0296 / 0297 / 0298 / 0299 / 0300 / 0301) are computed in `lineageweave/leftover_pairs.py` from the +0163 / 0164 / 0182 / 0185 / 0201 / 0233 / 0266 / 0267 / 0268 / 0269 / 0270 / 0271 / 0272 / 0273 / 0274 / 0275 / 0276 / 0277 / 0278 / 0279 / 0280 / 0281 / 0282 / 0283 / 0284 / 0285 / 0286 / 0287 / 0288 / 0289 / 0290 / 0291 / 0292 / 0293 / 0294 / 0295 / 0296 / 0297 / 0298 / 0299 / 0300 / 0301 / 0302) are computed in `lineageweave/leftover_pairs.py` from the residual after a real GRM/GPCM score, never invented. Distances are Euclidean on the two-dimensional Gabriel leftover map; missing cells stay out of the factorization. Closest and farthest post–criterion pairs @@ -470,6 +470,12 @@ compares leftover pairs can match the pair-row `rank` badge; a missing, negative non-integer rank omits that leftover-map comparison rank badge and does not invent rank from plotted coordinates, leftover-map distance, or the count of unused axes. The strip does not gain the leftover-map graphic. +ADR 0302 captions grouping comparison leftover-pair buttons with persisted leftover-map +coordinates `ξ` / `ζ` through formatLeftoverMapCoordinates so a buyer who +compares leftover pairs can match the pair-row coordinate badge; a missing or +non-finite axis omits that leftover-map comparison coordinates badge and does not +invent coordinates from leftover-map rank, leftover-map distance, leftover-map +reconstruction, or leftover residual. The strip does not gain the leftover-map graphic. When `R`, `R̂`, `U`, `x`, `s`, and `e` are finite, `e + s + x = 1`. When `Y`, `E`, and `R` are finite, `Y − E = R`. When `R`, `R̂`, and `U` are @@ -510,6 +516,8 @@ Grouping comparison leftover expected (ADR 0300) captions grouping comparison le buttons with persisted leftover expected `E`. Grouping comparison leftover-map rank (ADR 0301) captions grouping comparison leftover-pair buttons with persisted leftover-map rank. +Grouping comparison leftover-map coordinates (ADR 0302) captions grouping comparison leftover-pair +buttons with persisted leftover-map coordinates `ξ` / `ζ`. Item complete-case coverage (ADR 0282) captions the leftover-map graphic with how many scored criteria entered the map. Item complete-case coverage on the pair list (ADR 0285) diff --git a/ARCHITECTURE.md b/ARCHITECTURE.md index d9a09dd66..59caa9e1c 100644 --- a/ARCHITECTURE.md +++ b/ARCHITECTURE.md @@ -693,6 +693,8 @@ ADR 0300 captions grouping comparison leftover-pair buttons with persisted lefto expected `E` through formatLeftoverMapExpected. ADR 0301 captions grouping comparison leftover-pair buttons with persisted leftover-map rank through formatLeftoverMapRank. +ADR 0302 captions grouping comparison leftover-pair buttons with persisted leftover-map +coordinates `ξ` / `ζ` through formatLeftoverMapCoordinates. Click a post marker or a pair button opens that post. Those ADRs are the normative mathematical, storage, and display contracts. Leftover-map axis share @@ -721,8 +723,9 @@ incomplete item coverage (ADR 0292), leftover-map reconstruction `R̂` (ADR 0297), leftover residual `R` (ADR 0298), leftover observed `Y` (ADR 0299), leftover expected `E` -(ADR 0300), and leftover-map rank -(ADR 0301); +(ADR 0300), leftover-map rank +(ADR 0301), and leftover-map coordinates `ξ` / `ζ` +(ADR 0302); `POST .../rebuild` scores every grouping kind (post_admin). `make seed` folds A-100/B-200 Event Lineage fixtures (and the Riverbend calendar post) that already have constructed IRT cells into the same shared diff --git a/CHANGELOG.d/2.59.0-leftover-map-compare-coordinates.md b/CHANGELOG.d/2.59.0-leftover-map-compare-coordinates.md new file mode 100644 index 000000000..a1c06ee5d --- /dev/null +++ b/CHANGELOG.d/2.59.0-leftover-map-compare-coordinates.md @@ -0,0 +1,19 @@ +## 2.59.0 — Leftover-map coordinates on grouping comparison strip pair rows + +- Caption leftover-map coordinates `ξ` / `ζ` on grouping comparison strip leftover-pair + buttons through formatLeftoverMapCoordinates (ADR 0302). After `make seed`, + closest and farthest leftover pairs sit above the member list with grouping + comparison leftover-pair buttons that match leftover-map coordinates on the + pair row; click a post marker or a pair button opens that post. A missing or + non-finite axis omits that leftover-map comparison coordinates badge and keeps + leftover-map rank when that rank is a non-negative integer, leftover expected `E` + when finite, leftover observed `Y` when finite, leftover residual `R` when finite, + leftover-map unexplained leftover `U` when finite, leftover-map cross share `x` + when finite, leftover-map unexplained leftover share `s` when finite, leftover-map + explained leftover share `e` when finite, leftover-map reconstruction `R̂` when + finite, leftover-map distance `d`, plus the strip coverage notes. Rank-0 origin + cells still name `ξ (0.00, 0.00) ζ (0.00, 0.00)` when those axes are finite. + Do not invent coordinates from leftover-map rank, leftover-map distance, or + leftover-map reconstruction. A finite negative leftover is shown, never clamped. + The strip does not gain the leftover-map graphic. Never invent a leftover score. + Never invent a theta. No new columns. diff --git a/CHANGELOG.md b/CHANGELOG.md index e629ee998..3394eb039 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,64 @@ All notable changes to this project are documented here. Format follows ### Added +- Period leftover pairs now caption grouping comparison leftover-pair + buttons with persisted leftover-map coordinates `ξ` / `ζ` through + formatLeftoverMapCoordinates (ADR 0302 / v2.59.0). After `make seed`, + closest and farthest leftover pairs sit above the member list with the + Gabriel biplot of already-named coordinates, leftover-map axis share when + finite, axis ticks that match `ξ (x, y) ζ (x, y)` on the pair row, pair + segments that match `d` on the pair row, pair segments that match `R̂` on + the pair row, pair segments that match `R̂²/R²` on the pair row, pair + segments that match `U²/R²` on the pair row, pair segments that match + `2R̂U/R²` on the pair row, pair segments that match `U` on the pair row, + pair segments that match `R` on the pair row, pair segments that match + `Y` on the pair row, pair segments that match `E` on the pair row, pair + segments that match leftover-map rank on the pair row, a plot caption + that matches leftover-map complete-case coverage above the pair list, a + plot caption that matches leftover-map item complete-case coverage, a + plot caption that matches leftover-map incomplete post coverage, a plot + caption that matches leftover-map incomplete item coverage, a pair-list + note that matches leftover-map post complete-case coverage, a pair-list + note that matches leftover-map item complete-case coverage, a pair-list + note that matches leftover-map incomplete post coverage, a pair-list + note that matches leftover-map incomplete item coverage, a grouping + comparison note that matches leftover-map post complete-case coverage, + a grouping comparison note that matches leftover-map item + complete-case coverage, a grouping comparison note that matches + leftover-map incomplete post coverage, a grouping comparison note + that matches leftover-map incomplete item coverage, grouping comparison + leftover-pair buttons that match leftover-map reconstruction `R̂` on the + pair row, grouping comparison leftover-pair buttons that match + leftover-map explained leftover share `e` on the pair row, grouping + comparison leftover-pair buttons that match leftover-map unexplained + leftover share `s` on the pair row, grouping comparison leftover-pair + buttons that match leftover-map cross share `x` on the pair row, + grouping comparison leftover-pair buttons that match leftover-map + unexplained leftover `U` on the pair row, grouping comparison leftover-pair + buttons that match leftover residual `R` on the pair row, grouping + comparison leftover-pair buttons that match leftover observed `Y` on the + pair row, grouping comparison leftover-pair buttons that match leftover + expected `E` on the pair row, grouping comparison leftover-pair buttons + that match leftover-map rank on the pair row, and grouping comparison + leftover-pair buttons that match leftover-map coordinates `ξ` / `ζ` on + the pair row; click a post marker or a pair button opens that post. A + missing or non-finite axis omits that leftover-map comparison coordinates + badge and keeps leftover-map rank when that rank is a non-negative integer, + leftover expected `E` when finite, leftover observed `Y` when finite, + leftover residual `R` when finite, leftover-map unexplained leftover `U` + when finite, leftover-map cross share `x` when finite, leftover-map + unexplained leftover share `s` when finite, leftover-map explained leftover + share `e` when finite, leftover-map reconstruction `R̂` when finite, + leftover-map distance `d`, plus the strip coverage notes. Rank-0 origin + cells still name `ξ (0.00, 0.00) ζ (0.00, 0.00)` when those axes are finite. + Do not invent coordinates from leftover-map rank, leftover-map distance, + leftover expected, leftover observed, leftover residual, leftover-map + reconstruction, leftover-map unexplained leftover, leftover-map post + coverage, leftover-map item coverage, leftover-map incomplete post coverage, + leftover-map incomplete item coverage, or the count of unused axes. A finite + negative leftover is shown, never clamped. The strip does not gain the + leftover-map graphic. Never invent a leftover score or a theta. No new columns. + - Period leftover pairs now caption grouping comparison leftover-pair buttons with persisted leftover-map rank through formatLeftoverMapRank (ADR 0301 / v2.58.0). After `make seed`, diff --git a/CLAUDE.md b/CLAUDE.md index 93024ff65..122bf0b15 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -49,7 +49,7 @@ cutoff. Global Ask optional `knowledge_cutoff` uses the same cover Create/start endpoint rules (ADR 0017 / 0021), tie-vs-miss similarity (ADR 0026), R&R catalog ids (ADR 0019 / 0027), leftover pairs -(ADR 0048–0164 / 0182 / 0185 / 0201 / 0233 / 0266 / 0267 / 0268 / 0269 / 0270 / 0271 / 0272 / 0273 / 0274 / 0275 / 0276 / 0277 / 0278 / 0279 / 0280 / 0281 / 0282 / 0283 / 0284 / 0285 / 0286 / 0287 / 0288 / 0289 / 0290 / 0291 / 0292 / 0293 / 0294 / 0295 / 0296 / 0297 / 0298 / 0299 / 0300 / 0301), occupational construct catalog search +(ADR 0048–0164 / 0182 / 0185 / 0201 / 0233 / 0266 / 0267 / 0268 / 0269 / 0270 / 0271 / 0272 / 0273 / 0274 / 0275 / 0276 / 0277 / 0278 / 0279 / 0280 / 0281 / 0282 / 0283 / 0284 / 0285 / 0286 / 0287 / 0288 / 0289 / 0290 / 0291 / 0292 / 0293 / 0294 / 0295 / 0296 / 0297 / 0298 / 0299 / 0300 / 0301 / 0302), occupational construct catalog search (ADR 0257), the text-channel embedding swap and cosine clamp (ADR 0190), per-edge channel-score persistence (ADR 0195), token-backed status notices (ADR 0220), diff --git a/docs/adr/0302-leftover-map-compare-coordinates.md b/docs/adr/0302-leftover-map-compare-coordinates.md new file mode 100644 index 000000000..2fb578f41 --- /dev/null +++ b/docs/adr/0302-leftover-map-compare-coordinates.md @@ -0,0 +1,240 @@ +# ADR 0302 — Name leftover-map coordinates on grouping comparison strip pair rows + +**Decision status:** Accepted +**Date:** 2026-08-31 + +Amends leftover pairs on the grouping comparison strip +([ADR 0149](0149-leftover-pairs-on-comparison-strip.md)), leftover-map +coordinates ([ADR 0267](0267-leftover-map-coordinates.md)), leftover-map +coordinate ticks ([ADR 0270](0270-leftover-map-coordinate-ticks.md)), leftover-map +rank on grouping comparison strip pair rows +([ADR 0301](0301-leftover-map-compare-rank.md)), leftover expected on grouping +comparison strip pair rows +([ADR 0300](0300-leftover-map-compare-expected.md)), leftover observed on +grouping comparison strip pair rows +([ADR 0299](0299-leftover-map-compare-observed.md)), leftover residual +on grouping comparison strip pair rows +([ADR 0298](0298-leftover-map-compare-residual.md)), leftover-map unexplained leftover +on grouping comparison strip pair rows +([ADR 0297](0297-leftover-map-compare-unexplained.md)), leftover-map cross share +on grouping comparison strip pair rows +([ADR 0296](0296-leftover-map-compare-cross-share.md)), leftover-map unexplained +leftover share on grouping comparison strip pair rows +([ADR 0295](0295-leftover-map-compare-unexplained-share.md)), leftover-map +explained leftover share on grouping comparison strip pair rows +([ADR 0294](0294-leftover-map-compare-explained-share.md)), leftover-map +reconstruction on grouping comparison strip pair rows +([ADR 0293](0293-leftover-map-compare-reconstruction.md)), leftover-map +incomplete item coverage on the grouping comparison strip +([ADR 0292](0292-leftover-map-compare-incomplete-item.md)), leftover-map +incomplete post coverage on the grouping comparison strip +([ADR 0291](0291-leftover-map-compare-incomplete-post.md)), leftover-map item +complete-case coverage on the grouping comparison strip +([ADR 0290](0290-leftover-map-compare-item-coverage.md)), leftover-map +complete-case coverage on the grouping comparison strip +([ADR 0289](0289-leftover-map-compare-coverage.md)), leftover residual +disclosure ([ADR 0162](0162-leftover-residual-disclosure.md)), leftover +observed `Y` / expected `E` ([ADR 0163](0163-leftover-observed-expected.md)), leftover-map unexplained leftover persistence ([ADR 0182](0182-leftover-map-unexplained.md)), +leftover-map reconstruction persistence +([ADR 0201](0201-leftover-map-reconstruction.md)), leftover-map rank +([ADR 0164](0164-leftover-map-rank.md)), leftover-map rank on pair segments +([ADR 0280](0280-leftover-map-segment-rank.md)), and leftover-map graphic display +([ADR 0268](0268-leftover-map-graphic-display.md)). Independent of leftover-map +post complete-case coverage fail-closed on the pair list +([ADR 0288](0288-leftover-map-list-post-coverage-helper.md)), leftover-map +incomplete item coverage on the pair list +([ADR 0287](0287-leftover-map-list-incomplete-item.md)), leftover-map incomplete +post coverage on the pair list +([ADR 0286](0286-leftover-map-list-incomplete-post.md)), leftover-map item +complete-case coverage on the pair list +([ADR 0285](0285-leftover-map-list-item-coverage.md)), leftover-map incomplete +item coverage on the graphic display +([ADR 0284](0284-leftover-map-plot-incomplete-item.md)), leftover-map incomplete +post coverage on the graphic display +([ADR 0283](0283-leftover-map-plot-incomplete.md)), leftover-map item +complete-case coverage on the graphic display +([ADR 0282](0282-leftover-map-plot-item-coverage.md)), leftover-map complete-case +coverage on the graphic display +([ADR 0281](0281-leftover-map-plot-coverage.md)), leftover expected on pair +segments ([ADR 0279](0279-leftover-map-segment-expected.md)), leftover observed +on pair segments ([ADR 0278](0278-leftover-map-segment-observed.md)), leftover +residual on pair segments ([ADR 0277](0277-leftover-map-segment-residual.md)), +leftover-map unexplained leftover on pair segments +([ADR 0276](0276-leftover-map-segment-unexplained-leftover.md)), leftover-map +cross share on pair segments ([ADR 0275](0275-leftover-map-segment-cross-share.md)), +leftover-map unexplained leftover share on pair segments +([ADR 0274](0274-leftover-map-segment-unexplained-share.md)), leftover-map +explained leftover share on pair segments +([ADR 0273](0273-leftover-map-segment-explained-share.md)), leftover-map +reconstruction on pair segments +([ADR 0272](0272-leftover-map-segment-reconstruction.md)), leftover-map +distance on pair segments ([ADR 0271](0271-leftover-map-segment-distance.md)), +leftover-map axis share on the graphic display +([ADR 0269](0269-leftover-map-axis-share-plot.md)), leftover-map +cross share persistence ([ADR 0185](0185-leftover-map-cross-share.md)), leftover-map +unexplained leftover share persistence +([ADR 0233](0233-leftover-map-unexplained-share.md)), leftover-map explained leftover +share persistence ([ADR 0266](0266-leftover-map-explained-share.md)), and leftover-map +axis share persistence ([ADR 0148](0148-leftover-map-axis-share.md)). + +## Context + +ADR 0267 already persists two-axis Gabriel person coordinates +`ξ_{1:2}` and item coordinates `ζ_{1:2}` on leftover pair rows so +`R̂ = ξ_{1:2} · ζ_{1:2}` and `d = ‖ξ_{1:2} − ζ_{1:2}‖` stay +auditable. ADR 0270 already names those coordinates as leftover-map +graphic-display axis ticks. ADR 0301 already captions persisted leftover-map +rank on grouping comparison leftover-pair buttons. The strip pair button still +does not name `ξ` / `ζ`, so a buyer who compares leftover pairs can treat +leftover-map rank, leftover expected `E`, leftover observed `Y`, leftover +residual `R`, leftover-map unexplained leftover `U`, leftover-map cross share +`x`, leftover-map unexplained leftover share `s`, leftover-map explained leftover +share `e`, leftover-map reconstruction `R̂`, or leftover-map distance `d` as +leftover-map location even after the pair list and graphic already name +`ξ (x, y) ζ (x, y)`. Hiding coordinates on the strip lets a rank-0 origin +cell with `d 0.00` and `rank 0` vanish from leftover-map location without a +next action. + +This increment captions persisted leftover-map coordinates on each grouping +comparison leftover-pair button through formatLeftoverMapCoordinates. It does +not add columns. It does not recompute coordinates from leftover-map rank, +leftover-map distance, leftover expected, leftover observed, leftover residual, +leftover-map reconstruction, leftover-map explained leftover share, leftover-map +unexplained leftover share, leftover-map cross share, leftover-map unexplained +leftover, or the count of unused axes. It does not persist leftover-map inner +product, cosine, or length as separate columns. Do not invent a leftover score. +Do not invent a theta. + +The dashboard stack already used neighbouring leftover facts under other +numbers. This protected increment uses **0302** so it does not collide with +leftover-map rank on grouping comparison strip pair rows (0301), leftover +expected on grouping comparison strip pair rows (0300), leftover observed on +grouping comparison strip pair rows (0299), leftover residual on grouping +comparison strip pair rows (0298), leftover-map unexplained leftover on grouping +comparison strip pair rows (0297), leftover-map cross share on grouping +comparison strip pair rows (0296), leftover-map unexplained leftover share on +grouping comparison strip pair rows (0295), leftover-map explained leftover share +on grouping comparison strip pair rows (0294), leftover-map reconstruction on +grouping comparison strip pair rows (0293), leftover-map rank on pair segments +(0280), leftover-map coordinate ticks (0270), leftover-map coordinates (0267), +leftover-map graphic display (0268), leftover expected on pair segments (0279), +leftover observed on pair segments (0278), leftover residual on pair segments +(0277), leftover residual disclosure (0162), leftover observed `Y` / expected `E` +(0163), leftover-map rank persistence (0164), leftover-map reconstruction +persistence (0201), or the dashboard stacks. + +## Decision + +On the grouping comparison strip, caption each leftover pair button with +the same persisted leftover-map coordinates formatter as the pair-row +`ξ (x, y) ζ (x, y)` badge, next to leftover-map rank, leftover expected `E`, +leftover observed `Y`, leftover residual `R`, leftover-map unexplained leftover +`U`, leftover-map cross share `x`, leftover-map unexplained leftover share `s`, +leftover-map explained leftover share `e`, leftover-map reconstruction `R̂`, +and leftover-map distance `d`. Use the distinct accessible name +`Leftover map comparison coordinates` so the strip badge is not the graphic +tick (`leftover-map axis {axis} tick {value}`). A missing or non-finite axis +omits that leftover-map comparison coordinates badge and keeps leftover-map +rank when that rank is a non-negative integer, leftover expected `E` when finite, +leftover observed `Y` when finite, leftover residual `R` when finite, leftover-map +unexplained leftover `U` when finite, leftover-map cross share `x` when finite, +leftover-map unexplained leftover share `s` when finite, leftover-map explained +leftover share `e` when finite, leftover-map reconstruction `R̂` when finite, +leftover-map distance `d`, the strip leftover-map post coverage note, leftover-map +item coverage note, leftover-map incomplete post note, leftover-map incomplete +item note, leftover pairs, and any leftover-map captions on the pair list and +graphic. Rank-0 origin cells still name `ξ (0.00, 0.00) ζ (0.00, 0.00)` when +those persisted coordinates are finite. A finite negative leftover on neighbouring +badges is shown, never clamped. Do not invent coordinates from leftover-map rank, +leftover-map distance, leftover expected, leftover observed, leftover residual, +leftover-map reconstruction, leftover-map unexplained leftover, leftover-map +explained leftover share, leftover-map unexplained leftover share, leftover-map +cross share, leftover-map post coverage, leftover-map item coverage, leftover-map +incomplete post coverage, leftover-map incomplete item coverage, or the count of +unused axes. Do not add the leftover-map graphic to the strip. Click a leftover +pair on the strip to open that post. + +Do not add SQL. Do not edit shipped migrations. Do not persist inner +product, cosine, or length as separate columns. Do not invent a leftover +score. Do not invent a theta. + +## Consequences + +After `make seed`, the grouping comparison strip names persisted leftover-map +post complete-case coverage, persisted leftover-map item complete-case +coverage, persisted leftover-map incomplete post coverage, and persisted +leftover-map incomplete item coverage on each grouping row when +leftoverMapCoverageCounts / leftoverMapItemCoverageCounts / +leftoverMapIncompletePostCount / leftoverMapIncompleteItemCount return usable +integers, then names leftover pairs with leftover-map distance `d`, persisted +leftover-map reconstruction `R̂` when finite, persisted leftover-map +explained leftover share `e` when finite, persisted leftover-map unexplained +leftover share `s` when finite, persisted leftover-map cross share `x` +when finite, persisted leftover-map unexplained leftover `U` when finite, +persisted leftover residual `R` when finite, persisted leftover observed +`Y` when finite, persisted leftover expected `E` when finite, persisted +leftover-map rank when that rank is a non-negative integer, and persisted +leftover-map coordinates `ξ` / `ζ` when all four axes are finite. +Closest and farthest leftover pairs still sit above the member +list with the leftover-map graphic display; click a post marker or a pair +button opens that post. +Hidden posts stay hidden. When `Y`, `E`, and `R` are finite, `Y − E = R`. +When `R`, `R̂`, and `U` are finite, `U + R̂ = R`. +When `R`, `R̂`, `U`, `x`, `s`, and `e` are finite, `e + s + x = 1`. +When coordinates, reconstruction, and distance are finite, `R̂ = ξ · ζ` +and `d = ‖ξ − ζ‖`. + +## Related + +Independent of leftover interaction-map persistence, leftover-criterion +evaluation landing, leftover residual disclosure, leftover-map +complete-case coverage persistence, leftover-map axis share persistence, +leftover pairs on the grouping comparison strip, leftover-map complete-case +coverage on the grouping comparison strip, leftover-map item complete-case +coverage on the grouping comparison strip, leftover-map incomplete post +coverage on the grouping comparison strip, leftover-map incomplete item +coverage on the grouping comparison strip, leftover-map reconstruction on +grouping comparison strip pair rows, leftover-map explained leftover share +on grouping comparison strip pair rows, leftover-map unexplained leftover +share on grouping comparison strip pair rows, leftover-map cross share on +grouping comparison strip pair rows, leftover-map unexplained leftover on +grouping comparison strip pair rows, leftover residual on grouping +comparison strip pair rows, leftover observed on grouping comparison strip +pair rows, leftover expected on grouping comparison strip pair rows, +leftover-map rank on grouping comparison strip pair rows, leftover-map inner +product, leftover-map cosine, leftover-map length, leftover-map graphic +display, leftover residual on pair segments, leftover observed on pair +segments, leftover expected on pair segments, leftover-map rank on pair +segments, leftover-map unexplained leftover on pair segments, leftover-map +unexplained leftover persistence, leftover-map cross share on pair segments, +leftover-map cross share persistence, leftover-map unexplained leftover share +on pair segments, leftover-map unexplained leftover share persistence, +leftover-map explained leftover share on pair segments, leftover-map explained +leftover share persistence, leftover-map reconstruction on pair segments, +leftover-map reconstruction persistence, leftover-map item complete-case +coverage on the graphic display, leftover-map item complete-case coverage on +the pair list, leftover-map incomplete post coverage on the graphic display, +leftover-map incomplete post coverage on the pair list, leftover-map incomplete +item coverage on the graphic display, leftover-map incomplete item coverage on +the pair list, leftover-map post complete-case coverage fail-closed on the pair +list, leftover-map rank persistence, leftover-map coordinate persistence, and +leftover-map coordinate ticks. + +## References + +Jeon, M., Jin, I. H., Schweinberger, M., & Baugh, S. (2021). Mapping +unobserved item–respondent interactions: A latent space item response +model with interaction map. *Psychometrika, 86*(2), 378–403. +https://doi.org/10.1007/s11336-021-09762-5 +(LSIRM interaction `−γ‖ξ_j − ζ_i‖` after main effects +`α_j − β_i`; typically `p = 2` for the interaction map. Leftover-map +coordinates are persisted Gabriel person `ξ_{1:2}` and item `ζ_{1:2}` +after IRT main effects. Grouping comparison leftover-map coordinates name +those persisted positions on the strip pair row only when +formatLeftoverMapCoordinates returns a usable badge. Rank-0 origin cells +still name `ξ (0.00, 0.00) ζ (0.00, 0.00)` when those axes are finite. +When finite, `R̂ = ξ · ζ` and `d = ‖ξ − ζ‖`.) + +Gabriel, K. R. (1971). The biplot graphic display of matrices with +application to principal component analysis. *Biometrika, 58*(3), +453–467. https://doi.org/10.1093/biomet/58.3.453 diff --git a/docs/product-technical-gap-baseline.md b/docs/product-technical-gap-baseline.md index e61ebedf6..62676381d 100644 --- a/docs/product-technical-gap-baseline.md +++ b/docs/product-technical-gap-baseline.md @@ -1,5 +1,24 @@ # Product & Technical Gap Baseline +> Exact-head loop overlay: 2026-08-31 02:20 KST. Protected `main` is +> `cb187cadee5fb6c46d8a944815ccc154a1e028d1`. Writes work. Do not +> self-approve. #838 leftover-map rank on grouping comparison leftover-pair +> buttons (v2.58.0 / ADR 0301) is `6c7c66f`, stacked on #837 @ `e6638a8`. +> Next buyer increment on this cycle: leftover-map coordinates `ξ` / `ζ` +> on grouping comparison leftover-pair buttons (ADR 0302 / v2.59.0) +> delivered locally on `feat/leftover-map-compare-coordinates-v2590`. +> Caption each strip leftover-pair button through +> formatLeftoverMapCoordinates with distinct aria-label +> `Leftover map comparison coordinates`. UI-only; no new columns. Missing +> or non-finite axis omits that badge independently of rank, `E`, `Y`, `R`, +> `U`, `x`, `s`, `e`, `R̂`, `d`, and coverage notes. Rank-0 origin cells +> still name `ξ (0.00, 0.00) ζ (0.00, 0.00)` when those axes are finite. +> Do not invent coordinates from leftover-map rank, leftover-map distance, +> or leftover-map reconstruction. Stack onto #838. Leave open for +> independent review. Do not squash-merge. Issues #79 and #87 stay open. +> #96 is already closed. Do not merge #808 without independent APPROVE. + + > Exact-head loop overlay: 2026-08-31 02:10 KST. Protected `main` is > `cb187cadee5fb6c46d8a944815ccc154a1e028d1`. Writes work. Do not > self-approve. #837 leftover expected `E` on grouping comparison diff --git a/frontend/package.json b/frontend/package.json index 25c6ec845..3dca0ef53 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -1,7 +1,7 @@ { "name": "frontend", "private": true, - "version": "2.58.0", + "version": "2.59.0", "type": "module", "scripts": { "dev": "vite", diff --git a/frontend/src/App.test.tsx b/frontend/src/App.test.tsx index 6d0be1309..15580f204 100644 --- a/frontend/src/App.test.tsx +++ b/frontend/src/App.test.tsx @@ -940,6 +940,10 @@ describe("App, authenticated", () => { observed_response: 2.4, expected_response: 2.0, leftover_map_rank: 1, + leftover_map_person_axis_1: 0.5, + leftover_map_person_axis_2: 0.1, + leftover_map_item_axis_1: 0.5, + leftover_map_item_axis_2: -0.02, }, ], leftover_map_coverage: { @@ -4481,6 +4485,21 @@ describe("App, authenticated", () => { "Leftover map comparison rank", ), ).toHaveLength(1); + expect( + within(screen.getByLabelText("Grouping comparison")).queryByLabelText( + /leftover-map axis/, + ), + ).not.toBeInTheDocument(); + expect( + within(screen.getByLabelText("Grouping comparison")).getByLabelText( + "Leftover map comparison coordinates", + ), + ).toHaveTextContent("ξ (+0.50, +0.10) ζ (+0.50, −0.02)"); + expect( + within(screen.getByLabelText("Grouping comparison")).getAllByLabelText( + "Leftover map comparison coordinates", + ), + ).toHaveLength(1); expect( screen.getByRole("button", { name: /open leftover closest pair from comparison: specification revision requested/i, @@ -4531,6 +4550,11 @@ describe("App, authenticated", () => { name: /open leftover closest pair from comparison: specification revision requested/i, }), ).not.toHaveTextContent("rank "); + expect( + screen.getByRole("button", { + name: /open leftover closest pair from comparison: specification revision requested/i, + }), + ).not.toHaveTextContent("ξ"); expect( screen.getByRole("button", { name: "Compare Business unit (PU): Demo Report High, mean θ 0.81" }), ).toHaveTextContent("mean θ 0.81"); @@ -4595,6 +4619,11 @@ describe("App, authenticated", () => { name: /open leftover closest pair from comparison: public post/i, }), ).toHaveTextContent("rank 1"); + expect( + screen.getByRole("button", { + name: /open leftover closest pair from comparison: public post/i, + }), + ).toHaveTextContent("ξ (+0.50, +0.10) ζ (+0.50, −0.02)"); await waitFor(() => expect(fetchMock).toHaveBeenCalledWith( expect.stringContaining("/api/reports/thread_group/2026-W02"), diff --git a/frontend/src/App.tsx b/frontend/src/App.tsx index 70382f62b..d3d32cfad 100644 --- a/frontend/src/App.tsx +++ b/frontend/src/App.tsx @@ -171,6 +171,10 @@ import { formatLeftoverMapRank, LEFTOVER_MAP_COMPARE_RANK_LABEL, } from "./leftoverMapRank"; +import { + formatLeftoverMapCoordinates, + LEFTOVER_MAP_COMPARE_COORDINATES_LABEL, +} from "./leftoverMapCoordinates"; import "./App.css"; const AdminPanel = lazy(() => import("./components/AdminPanel").then((module) => ({ default: module.AdminPanel }))); @@ -4112,6 +4116,12 @@ function ReportsPanel({ const observed = formatLeftoverMapObserved(pair.observed_response); const expected = formatLeftoverMapExpected(pair.expected_response); const rank = formatLeftoverMapRank(pair.leftover_map_rank); + const coordinates = formatLeftoverMapCoordinates( + pair.leftover_map_person_axis_1, + pair.leftover_map_person_axis_2, + pair.leftover_map_item_axis_1, + pair.leftover_map_item_axis_2, + ); return (
  • ) : null} + {coordinates ? ( + + {coordinates} + + ) : null}
  • ); diff --git a/frontend/src/components/LeftoverPairList.tsx b/frontend/src/components/LeftoverPairList.tsx index b5a62c8ea..d99242a50 100644 --- a/frontend/src/components/LeftoverPairList.tsx +++ b/frontend/src/components/LeftoverPairList.tsx @@ -101,7 +101,9 @@ export type LeftoverPairListProps = { * this pair list. ADR 0300 names persisted leftover expected on grouping * comparison leftover-pair buttons, not this pair list. ADR 0301 names * persisted leftover-map rank on grouping comparison leftover-pair - * buttons, not this pair list. Every badge still + * buttons, not this pair list. ADR 0302 names persisted leftover-map + * coordinates on grouping comparison leftover-pair buttons, not this + * pair list. Every badge still * renders together before opening the named post. */ export function LeftoverPairList({ diff --git a/frontend/src/i18n.test.ts b/frontend/src/i18n.test.ts index 047e33459..ff57dc970 100644 --- a/frontend/src/i18n.test.ts +++ b/frontend/src/i18n.test.ts @@ -90,6 +90,7 @@ describe("i18n", () => { "Leftover map comparison observed", "Leftover map comparison expected", "Leftover map comparison rank", + "Leftover map comparison coordinates", "Leftover-map graphic item coverage", "Leftover map item coverage", "Leftover map incomplete posts", @@ -547,6 +548,19 @@ describe("i18n", () => { }, ); + it.each([ + ["ko", "잔여 지도 비교 좌표"], + ["zh", "残差地图比较坐标"], + ["ja", "残差マップの比較座標"], + ["vi", "Tọa độ so sánh bản đồ phần dư"], + ] as const)( + "formats leftover map comparison coordinates label in %s", + (locale, expected) => { + setLocale(locale); + expect(t("Leftover map comparison coordinates")).toBe(expected); + }, + ); + it.each([ ["ko", "잔여 지도 그림 기준 포함 범위"], ["zh", "残差图图形准则覆盖范围"], diff --git a/frontend/src/i18n.ts b/frontend/src/i18n.ts index d60a438da..c304c0c5e 100644 --- a/frontend/src/i18n.ts +++ b/frontend/src/i18n.ts @@ -281,6 +281,7 @@ const TRANSLATIONS: Partial>> = { "Leftover map comparison observed": "잔여 지도 비교 관측", "Leftover map comparison expected": "잔여 지도 비교 기대", "Leftover map comparison rank": "잔여 지도 비교 순위", + "Leftover map comparison coordinates": "잔여 지도 비교 좌표", "Leftover map item coverage": "잔여 지도 기준 포함 범위", "Leftover map incomplete posts": "잔여 지도 불완전 글", "Leftover map incomplete items": "잔여 지도 불완전 기준", @@ -900,6 +901,7 @@ const TRANSLATIONS: Partial>> = { "Leftover map comparison observed": "残差地图比较观测", "Leftover map comparison expected": "残差地图比较期望", "Leftover map comparison rank": "残差地图比较秩", + "Leftover map comparison coordinates": "残差地图比较坐标", "Leftover map item coverage": "残差地图准则覆盖范围", "Leftover map incomplete posts": "残差地图不完整帖文", "Leftover map incomplete items": "残差地图不完整准则", @@ -1540,6 +1542,7 @@ const TRANSLATIONS: Partial>> = { "Leftover map comparison observed": "残差マップの比較観測", "Leftover map comparison expected": "残差マップの比較期待", "Leftover map comparison rank": "残差マップの比較階数", + "Leftover map comparison coordinates": "残差マップの比較座標", "Leftover map item coverage": "残差マップの基準対象範囲", "Leftover map incomplete posts": "残差マップの不完全投稿", "Leftover map incomplete items": "残差マップの不完全基準", @@ -2159,6 +2162,7 @@ const TRANSLATIONS: Partial>> = { "Leftover map comparison observed": "Quan sát so sánh bản đồ phần dư", "Leftover map comparison expected": "Kỳ vọng so sánh bản đồ phần dư", "Leftover map comparison rank": "Hạng so sánh bản đồ phần dư", + "Leftover map comparison coordinates": "Tọa độ so sánh bản đồ phần dư", "Leftover map item coverage": "Phạm vi tiêu chí bản đồ phần dư", "Leftover map incomplete posts": "Bài không đầy đủ trên bản đồ phần dư", "Leftover map incomplete items": "Tiêu chí không đầy đủ trên bản đồ phần dư", diff --git a/frontend/src/leftoverMapCoordinates.test.ts b/frontend/src/leftoverMapCoordinates.test.ts index 95acbd551..78535621f 100644 --- a/frontend/src/leftoverMapCoordinates.test.ts +++ b/frontend/src/leftoverMapCoordinates.test.ts @@ -2,6 +2,7 @@ import { describe, expect, it } from "vitest"; import { formatLeftoverMapCoordinatePair, formatLeftoverMapCoordinates, + LEFTOVER_MAP_COMPARE_COORDINATES_LABEL, } from "./leftoverMapCoordinates"; describe("formatLeftoverMapCoordinates", () => { @@ -24,6 +25,11 @@ describe("formatLeftoverMapCoordinates", () => { expect(formatLeftoverMapCoordinates(0, 0, 0, Number.POSITIVE_INFINITY)).toBeNull(); expect(formatLeftoverMapCoordinates(0, Number.NEGATIVE_INFINITY, 0, 0)).toBeNull(); }); + + it("keeps the grouping comparison coordinates label distinct from the graphic tick label", () => { + expect(LEFTOVER_MAP_COMPARE_COORDINATES_LABEL).toBe("Leftover map comparison coordinates"); + expect(LEFTOVER_MAP_COMPARE_COORDINATES_LABEL).not.toBe("leftover-map axis {axis} tick {value}"); + }); }); describe("formatLeftoverMapCoordinatePair", () => { diff --git a/frontend/src/leftoverMapCoordinates.ts b/frontend/src/leftoverMapCoordinates.ts index 3382f7882..d133bd9bd 100644 --- a/frontend/src/leftoverMapCoordinates.ts +++ b/frontend/src/leftoverMapCoordinates.ts @@ -5,6 +5,9 @@ import { formatSignedLeftoverValue } from "./leftoverMapUnexplained"; export const LEFTOVER_MAP_COORDINATES_ACTION = "Leftover map places this post at ξ {person} and the criterion at ζ {item} after IRT main effects. Open this post to read {criterion}."; +export const LEFTOVER_MAP_COMPARE_COORDINATES_LABEL = + "Leftover map comparison coordinates"; + const PERSON_BADGE = "\u03BE"; const ITEM_BADGE = "\u03B6"; diff --git a/frontend/src/leftoverMapPlotLayout.ts b/frontend/src/leftoverMapPlotLayout.ts index f5b1326e9..92cac92eb 100644 --- a/frontend/src/leftoverMapPlotLayout.ts +++ b/frontend/src/leftoverMapPlotLayout.ts @@ -28,8 +28,9 @@ * (ADR 0297), grouping comparison leftover residual * (ADR 0298), grouping comparison leftover observed * (ADR 0299), grouping comparison leftover expected - * (ADR 0300), and grouping comparison leftover-map rank - * (ADR 0301) caption the pair list or the grouping comparison strip, + * (ADR 0300), grouping comparison leftover-map rank + * (ADR 0301), and grouping comparison leftover-map coordinates + * (ADR 0302) caption the pair list or the grouping comparison strip, * not this graphic layout. */ diff --git a/pyproject.toml b/pyproject.toml index 7dce87421..2c7de2211 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "lineageweave" -version = "2.58.0" +version = "2.59.0" description = "Reconstructs git-branch-style lineage DAGs from scattered short records using multi-channel score fusion and LLM adjudication." readme = "README.md" license = { text = "MIT" }