TheYuchen commited on
Commit ·
5eaeee3
1
Parent(s): b2b80a0
Claims-to-features map (claims-map): TopBar overlay
Browse filesA reader arriving from the paper should not rediscover where each
claim lives. New static overlay next to the TopBar Tour button: one
row per claim (seeded replay, anytime steering, transformation
vocabulary, uncertainty-in-provenance, multiverse, honest comparison,
theater overlay, provenance-backed figures) with where to see it and
the ?scenario= URL that boots its figure state. Content mirrors the
shipped list in docs/EVIDENCE_WORKBENCH.md. Esc/backdrop close,
self-contained component.
frontend/src/components/ClaimsMap.tsx
ADDED
|
@@ -0,0 +1,163 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
// Claims→features map (marker: claims-map).
|
| 2 |
+
//
|
| 3 |
+
// A reader arriving from the paper (or a reviewer skimming the live
|
| 4 |
+
// deployment) should not have to rediscover where each claim lives.
|
| 5 |
+
// This is a small STATIC overlay: one row per paper claim — claim,
|
| 6 |
+
// where to see it in the UI, and the one-URL scenario that boots the
|
| 7 |
+
// exact seeded state the claim's figure is exported from. Content
|
| 8 |
+
// mirrors the shipped list in docs/EVIDENCE_WORKBENCH.md; if a claim
|
| 9 |
+
// changes there, change it here.
|
| 10 |
+
//
|
| 11 |
+
// Self-contained by design (trigger + overlay in one component, local
|
| 12 |
+
// state only): the TopBar mounts it next to the Tour button and no
|
| 13 |
+
// other surface needs to know it exists.
|
| 14 |
+
|
| 15 |
+
import { useEffect, useState } from "react";
|
| 16 |
+
import { ListChecks, X } from "lucide-react";
|
| 17 |
+
import { APP_NAME } from "../lib/anon";
|
| 18 |
+
|
| 19 |
+
interface ClaimRow {
|
| 20 |
+
claim: string;
|
| 21 |
+
where: string;
|
| 22 |
+
scenarios: string[]; // scenario keys, rendered as ?scenario= links
|
| 23 |
+
}
|
| 24 |
+
|
| 25 |
+
const ROWS: ClaimRow[] = [
|
| 26 |
+
{
|
| 27 |
+
claim: "Seeded replay — every run is archived with its root seed and replays bit-exactly",
|
| 28 |
+
where: "History tab: replay (⚲) any row; seed chip on the fidelity card",
|
| 29 |
+
scenarios: ["F4"],
|
| 30 |
+
},
|
| 31 |
+
{
|
| 32 |
+
claim: "Anytime evidence steering — the 95% interval narrows live; a precision target stops the run",
|
| 33 |
+
where: "Evidence theater (auto-opens on streaming runs); toolbar “target ±pp”; funnel on the fidelity card",
|
| 34 |
+
scenarios: ["F0", "F3"],
|
| 35 |
+
},
|
| 36 |
+
{
|
| 37 |
+
claim: "Transformation vocabulary — uniform before→after signatures for every step, plugins included",
|
| 38 |
+
where: "Delta-strip glyphs on canvas nodes and result cards; gate-level circuit diff in the signature card",
|
| 39 |
+
scenarios: ["F1", "F5"],
|
| 40 |
+
},
|
| 41 |
+
{
|
| 42 |
+
claim: "Uncertainty in provenance — lineage nodes are distributions (evidence mass, certainty funnels)",
|
| 43 |
+
where: "History tab: dot area = shots executed, replicate bands with pooled-CI funnels, fork edges",
|
| 44 |
+
scenarios: ["F4"],
|
| 45 |
+
},
|
| 46 |
+
{
|
| 47 |
+
claim: "Multiverse analysis — every configuration as a small multiple with Δ vs the baseline",
|
| 48 |
+
where: "Multiverse workspace (toggle top-left of the canvas)",
|
| 49 |
+
scenarios: ["F2"],
|
| 50 |
+
},
|
| 51 |
+
{
|
| 52 |
+
claim: "Honest comparison — intervals instead of scalars; overlap is called out as not-evidence",
|
| 53 |
+
where: "Compare tab (tick two runs in History, or A/B two multiverse cards)",
|
| 54 |
+
scenarios: ["F6"],
|
| 55 |
+
},
|
| 56 |
+
{
|
| 57 |
+
claim: "Same rule, different draws — two replays of one configuration overlaid in the theater",
|
| 58 |
+
where: "Compare tab → “overlay in theater” (same configuration, both runs traced)",
|
| 59 |
+
scenarios: ["F7"],
|
| 60 |
+
},
|
| 61 |
+
{
|
| 62 |
+
claim: "Provenance-backed figures — every export regenerates bit-exactly from its own metadata",
|
| 63 |
+
where: "Camera buttons on the canvas, multiverse board, evidence pane and theater (SVG + PNG + sidecar)",
|
| 64 |
+
scenarios: ["F0"],
|
| 65 |
+
},
|
| 66 |
+
];
|
| 67 |
+
|
| 68 |
+
export function ClaimsMapButton() {
|
| 69 |
+
const [open, setOpen] = useState(false);
|
| 70 |
+
|
| 71 |
+
useEffect(() => {
|
| 72 |
+
if (!open) return;
|
| 73 |
+
const h = (e: KeyboardEvent) => {
|
| 74 |
+
if (e.key === "Escape") setOpen(false);
|
| 75 |
+
};
|
| 76 |
+
window.addEventListener("keydown", h);
|
| 77 |
+
return () => window.removeEventListener("keydown", h);
|
| 78 |
+
}, [open]);
|
| 79 |
+
|
| 80 |
+
return (
|
| 81 |
+
<>
|
| 82 |
+
<button
|
| 83 |
+
type="button"
|
| 84 |
+
className="btn-ghost"
|
| 85 |
+
onClick={() => setOpen(true)}
|
| 86 |
+
title="Map of the system's research claims: what each one is, where to see it, and the scenario URL that boots its figure state"
|
| 87 |
+
aria-label="Open claims-to-features map"
|
| 88 |
+
>
|
| 89 |
+
<ListChecks className="w-3.5 h-3.5" />
|
| 90 |
+
<span className="hidden sm:inline">Claims</span>
|
| 91 |
+
</button>
|
| 92 |
+
{open && (
|
| 93 |
+
<div
|
| 94 |
+
className="fixed inset-0 z-50 flex items-center justify-center p-4 sm:p-8"
|
| 95 |
+
role="dialog"
|
| 96 |
+
aria-modal="true"
|
| 97 |
+
aria-label={`${APP_NAME} claims-to-features map`}
|
| 98 |
+
data-marker="claims-map"
|
| 99 |
+
>
|
| 100 |
+
<div
|
| 101 |
+
className="absolute inset-0 bg-canvas/85 backdrop-blur-sm"
|
| 102 |
+
onClick={() => setOpen(false)}
|
| 103 |
+
/>
|
| 104 |
+
<div className="relative panel w-full max-w-3xl max-h-[88vh] flex flex-col overflow-hidden shadow-[0_40px_80px_-20px_rgba(0,0,0,0.6)]">
|
| 105 |
+
<div className="flex items-center gap-2 px-4 py-3 border-b border-edge shrink-0">
|
| 106 |
+
<ListChecks className="w-4 h-4 text-accent" />
|
| 107 |
+
<span className="text-sm font-semibold text-ink">
|
| 108 |
+
Claims → where to see them
|
| 109 |
+
</span>
|
| 110 |
+
<span className="text-[11px] text-mute hidden sm:inline">
|
| 111 |
+
each scenario URL boots the exact seeded state
|
| 112 |
+
</span>
|
| 113 |
+
<button
|
| 114 |
+
type="button"
|
| 115 |
+
onClick={() => setOpen(false)}
|
| 116 |
+
aria-label="Close claims map"
|
| 117 |
+
className="ml-auto w-8 h-8 rounded-md border border-edge bg-surface/80 text-mute hover:text-ink transition flex items-center justify-center"
|
| 118 |
+
>
|
| 119 |
+
<X className="w-4 h-4" />
|
| 120 |
+
</button>
|
| 121 |
+
</div>
|
| 122 |
+
<div className="flex-1 overflow-y-auto p-4">
|
| 123 |
+
<table className="w-full text-[12px] leading-relaxed">
|
| 124 |
+
<thead>
|
| 125 |
+
<tr className="text-mute text-left text-[10px] uppercase tracking-wider">
|
| 126 |
+
<th className="font-normal pb-1.5 pr-3">claim</th>
|
| 127 |
+
<th className="font-normal pb-1.5 pr-3">where</th>
|
| 128 |
+
<th className="font-normal pb-1.5">boot</th>
|
| 129 |
+
</tr>
|
| 130 |
+
</thead>
|
| 131 |
+
<tbody>
|
| 132 |
+
{ROWS.map((r) => (
|
| 133 |
+
<tr key={r.claim} className="border-t border-edge/50 align-top">
|
| 134 |
+
<td className="py-2 pr-3 text-ink">{r.claim}</td>
|
| 135 |
+
<td className="py-2 pr-3 text-mute">{r.where}</td>
|
| 136 |
+
<td className="py-2 whitespace-nowrap">
|
| 137 |
+
{r.scenarios.map((k, i) => (
|
| 138 |
+
<a
|
| 139 |
+
key={k}
|
| 140 |
+
href={`?scenario=${k}`}
|
| 141 |
+
className="text-accent hover:underline font-mono"
|
| 142 |
+
title={`Boot ?scenario=${k} (reloads the app into that figure state)`}
|
| 143 |
+
>
|
| 144 |
+
{i > 0 ? " · " : ""}
|
| 145 |
+
{k}
|
| 146 |
+
</a>
|
| 147 |
+
))}
|
| 148 |
+
</td>
|
| 149 |
+
</tr>
|
| 150 |
+
))}
|
| 151 |
+
</tbody>
|
| 152 |
+
</table>
|
| 153 |
+
<p className="mt-3 text-[11px] text-mute">
|
| 154 |
+
Full design rationale and the encoding decisions behind each
|
| 155 |
+
view: <span className="font-mono">docs/EVIDENCE_WORKBENCH.md</span> in the repository.
|
| 156 |
+
</p>
|
| 157 |
+
</div>
|
| 158 |
+
</div>
|
| 159 |
+
</div>
|
| 160 |
+
)}
|
| 161 |
+
</>
|
| 162 |
+
);
|
| 163 |
+
}
|
frontend/src/components/TopBar.tsx
CHANGED
|
@@ -1,6 +1,7 @@
|
|
| 1 |
import { useApp } from "../lib/store";
|
| 2 |
import { Activity, Compass, PanelLeft, PanelRight, Zap } from "lucide-react";
|
| 3 |
import { APP_NAME, APP_TAGLINE } from "../lib/anon";
|
|
|
|
| 4 |
import { ThemeSwitcher } from "./ThemeSwitcher";
|
| 5 |
import { TipIcon } from "./TipIcon";
|
| 6 |
|
|
@@ -139,6 +140,7 @@ export function TopBar({
|
|
| 139 |
<span className="hidden sm:inline">Tour</span>
|
| 140 |
</button>
|
| 141 |
)}
|
|
|
|
| 142 |
<ThemeSwitcher />
|
| 143 |
{mobile && onOpenRightDrawer && (
|
| 144 |
<button
|
|
|
|
| 1 |
import { useApp } from "../lib/store";
|
| 2 |
import { Activity, Compass, PanelLeft, PanelRight, Zap } from "lucide-react";
|
| 3 |
import { APP_NAME, APP_TAGLINE } from "../lib/anon";
|
| 4 |
+
import { ClaimsMapButton } from "./ClaimsMap";
|
| 5 |
import { ThemeSwitcher } from "./ThemeSwitcher";
|
| 6 |
import { TipIcon } from "./TipIcon";
|
| 7 |
|
|
|
|
| 140 |
<span className="hidden sm:inline">Tour</span>
|
| 141 |
</button>
|
| 142 |
)}
|
| 143 |
+
<ClaimsMapButton />
|
| 144 |
<ThemeSwitcher />
|
| 145 |
{mobile && onOpenRightDrawer && (
|
| 146 |
<button
|