mlx-bun 0.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +362 -0
- package/THIRD_PARTY_LICENSES.md +41 -0
- package/bin/mlx-bun.mjs +32 -0
- package/docs/curve-designer.html +303 -0
- package/docs/design/adapters-end-to-end.md +201 -0
- package/docs/design/compat-cli-surface-design.md +227 -0
- package/docs/design/docs-reorg-plan.md +152 -0
- package/docs/design/hlg-sampling.md +340 -0
- package/docs/design/memory-system.md +339 -0
- package/docs/design/optimization_plan.md +344 -0
- package/docs/design/parallel-slots.md +515 -0
- package/docs/design/runtime-isolation.md +247 -0
- package/docs/design/segmented-backward-training.md +508 -0
- package/docs/investigations/chunk-finetune-experiment.md +84 -0
- package/docs/investigations/curve-bisector-routing.md +123 -0
- package/docs/investigations/curve-runs/bisector-route.json +98 -0
- package/docs/investigations/curve-runs/bisector-trace.json +1393 -0
- package/docs/investigations/curve-runs/curve-terrain.json +1179 -0
- package/docs/investigations/curve-runs/curve-terrain.svg +42 -0
- package/docs/investigations/curve-terrain.html +105 -0
- package/docs/investigations/expert-offload-single-user-moe.md +292 -0
- package/docs/investigations/hlg-ab.html +34 -0
- package/docs/investigations/hlg-explorer.html +238 -0
- package/docs/investigations/hlg-figs/cliff.svg +1 -0
- package/docs/investigations/hlg-figs/cross.svg +1 -0
- package/docs/investigations/hlg-figs/edges.svg +1 -0
- package/docs/investigations/hlg-figs/k20-grids.svg +1 -0
- package/docs/investigations/hlg-figs/k20-peaks.svg +1 -0
- package/docs/investigations/hlg-figs/lw-curve.svg +1 -0
- package/docs/investigations/hlg-figs/terrain.svg +1 -0
- package/docs/investigations/hlg-report.html +262 -0
- package/docs/investigations/hlg-runs/hlg-ab.json +149 -0
- package/docs/investigations/hlg-runs/hlg-blind-prompts.md +87 -0
- package/docs/investigations/hlg-runs/hlg-blind.json +107 -0
- package/docs/investigations/hlg-runs/hlg-cliff.json +197 -0
- package/docs/investigations/hlg-runs/hlg-cross.json +505 -0
- package/docs/investigations/hlg-runs/hlg-edge.json +388 -0
- package/docs/investigations/hlg-runs/hlg-eval1.json +25 -0
- package/docs/investigations/hlg-runs/hlg-frontier.json +86 -0
- package/docs/investigations/hlg-runs/hlg-grid.json +242 -0
- package/docs/investigations/hlg-runs/hlg-grid2.json +343 -0
- package/docs/investigations/hlg-runs/hlg-lw-coarse.json +110 -0
- package/docs/investigations/hlg-runs/hlg-map.json +383 -0
- package/docs/investigations/hlg-runs/run0-original.log +159 -0
- package/docs/investigations/hlg-runs/runA-recommended.log +131 -0
- package/docs/investigations/hlg-runs/runAA-cliff-cpm5.log +26 -0
- package/docs/investigations/hlg-runs/runAB-grid2-e4b.log +18 -0
- package/docs/investigations/hlg-runs/runAC-peak-e4b-partial.log +25 -0
- package/docs/investigations/hlg-runs/runAD-ab-samples.log +8 -0
- package/docs/investigations/hlg-runs/runAE-edge-e4b.log +51 -0
- package/docs/investigations/hlg-runs/runAF-logit-calibration.log +10 -0
- package/docs/investigations/hlg-runs/runAG-eval-config2.log +16 -0
- package/docs/investigations/hlg-runs/runB-gain-variants.log +192 -0
- package/docs/investigations/hlg-runs/runC-pivots.log +162 -0
- package/docs/investigations/hlg-runs/runD-oetf.log +132 -0
- package/docs/investigations/hlg-runs/runE-eotf.log +162 -0
- package/docs/investigations/hlg-runs/runF-shaper-working.log +86 -0
- package/docs/investigations/hlg-runs/runG-shaper-sweep.log +101 -0
- package/docs/investigations/hlg-runs/runH-wsweep.log +176 -0
- package/docs/investigations/hlg-runs/runI-asweep.log +176 -0
- package/docs/investigations/hlg-runs/runJ-knobmap.log +49 -0
- package/docs/investigations/hlg-runs/runK-frontier.log +19 -0
- package/docs/investigations/hlg-runs/runL-widemap.log +65 -0
- package/docs/investigations/hlg-runs/runM-frontier-emb.log +15 -0
- package/docs/investigations/hlg-runs/runN-verify.log +116 -0
- package/docs/investigations/hlg-runs/runO-frontier-seed5000.log +15 -0
- package/docs/investigations/hlg-runs/runP-grid-AxSm.log +15 -0
- package/docs/investigations/hlg-runs/runQ-grid-tgW.log +15 -0
- package/docs/investigations/hlg-runs/runR-blind-transcript.log +79 -0
- package/docs/investigations/hlg-runs/runS-cross-coherence.log +33 -0
- package/docs/investigations/hlg-runs/runT-cross-cpm5.log +33 -0
- package/docs/investigations/hlg-runs/runU-cross-12b.log +33 -0
- package/docs/investigations/hlg-runs/runV-lw-e4b.log +22 -0
- package/docs/investigations/hlg-runs/runW-lw-12b.log +22 -0
- package/docs/investigations/hlg-runs/runX-lw-cpm5.log +22 -0
- package/docs/investigations/hlg-runs/runY-cliff-e4b.log +26 -0
- package/docs/investigations/hlg-runs/runZ-cliff-12b.log +26 -0
- package/docs/investigations/hlg-sampling-investigation.md +970 -0
- package/docs/investigations/lab-build-journal.md +157 -0
- package/docs/investigations/pi-builtin-investigation.md +308 -0
- package/docs/investigations/starter-model-port-handoff.md +323 -0
- package/docs/planning/IDEAS.md +26 -0
- package/docs/planning/PRODUCT_ROADMAP.md +426 -0
- package/docs/planning/ResearchTopics.md +119 -0
- package/docs/planning/chunk-task-roadmap.md +77 -0
- package/docs/planning/journal.md +155 -0
- package/docs/reference/distribution.md +121 -0
- package/docs/reference/embedding.md +168 -0
- package/docs/reference/library-api.md +153 -0
- package/docs/reference/server-api.md +224 -0
- package/docs/reference/server-config.md +243 -0
- package/docs/segmented-backward-handoff.md +148 -0
- package/package.json +68 -0
- package/src/anthropic.ts +491 -0
- package/src/chat-template.ts +186 -0
- package/src/cli.ts +1075 -0
- package/src/config.ts +229 -0
- package/src/curve-sampler.ts +122 -0
- package/src/dataset/generators.ts +1087 -0
- package/src/dataset/index.ts +12 -0
- package/src/dataset/job.ts +81 -0
- package/src/dataset/llm.ts +71 -0
- package/src/dataset/registry.ts +528 -0
- package/src/download.ts +283 -0
- package/src/eval/README.md +86 -0
- package/src/eval/kl-prompts.ts +29 -0
- package/src/eval/kl.ts +294 -0
- package/src/eval/quality-db.ts +92 -0
- package/src/eval/runner.ts +102 -0
- package/src/eval/score.ts +49 -0
- package/src/eval/tasks/bfcl.ts +500 -0
- package/src/eval/tasks/gsm8k.ts +85 -0
- package/src/eval/tasks/hashhop.ts +109 -0
- package/src/eval/tasks/humaneval.ts +252 -0
- package/src/eval/tasks/ifeval.ts +354 -0
- package/src/eval/tasks/mmlu.ts +145 -0
- package/src/evaldb.ts +199 -0
- package/src/expert-offload-build.ts +77 -0
- package/src/expert-offload.ts +61 -0
- package/src/expert-trace.ts +67 -0
- package/src/fit.ts +254 -0
- package/src/generate.ts +451 -0
- package/src/harness-pi.ts +177 -0
- package/src/hf-push.ts +628 -0
- package/src/index.ts +22 -0
- package/src/jobs/db.ts +139 -0
- package/src/jobs/index.ts +29 -0
- package/src/jobs/job-entry.ts +106 -0
- package/src/jobs/runner.ts +304 -0
- package/src/jobs/sse.ts +114 -0
- package/src/jobs/types.ts +58 -0
- package/src/kv-store.ts +185 -0
- package/src/lora.ts +314 -0
- package/src/md-modules.d.ts +7 -0
- package/src/mlx/array.ts +237 -0
- package/src/mlx/autograd.ts +267 -0
- package/src/mlx/checkpoint.ts +116 -0
- package/src/mlx/compile.ts +158 -0
- package/src/mlx/custom-vjp.ts +140 -0
- package/src/mlx/ffi.ts +433 -0
- package/src/mlx/metal-kernel.ts +130 -0
- package/src/mlx/ops.ts +707 -0
- package/src/mmap.ts +90 -0
- package/src/model/batched-mask.ts +204 -0
- package/src/model/batched-rotating.ts +300 -0
- package/src/model/compiled-decode.ts +681 -0
- package/src/model/factory.ts +27 -0
- package/src/model/fingerprint.ts +33 -0
- package/src/model/flash-attention.ts +674 -0
- package/src/model/fused-decode-kernel.ts +305 -0
- package/src/model/fused-geglu-kernel.ts +87 -0
- package/src/model/gemma4-base.ts +1616 -0
- package/src/model/gemma4.ts +1012 -0
- package/src/model/generated/gemma4-12b.ts +526 -0
- package/src/model/generated/gemma4-26b.ts +500 -0
- package/src/model/generated/gemma4-e4b.ts +757 -0
- package/src/model/generated/index.ts +18 -0
- package/src/model/minicpm5.ts +278 -0
- package/src/model/qwen3-delta.ts +224 -0
- package/src/model/qwen3_5.ts +429 -0
- package/src/model/support.ts +46 -0
- package/src/native-pack.ts +152 -0
- package/src/pi-provider.ts +95 -0
- package/src/pi-terminal.ts +264 -0
- package/src/pi-web.ts +924 -0
- package/src/preflight.ts +123 -0
- package/src/prompt-cache.ts +113 -0
- package/src/quantize/allocator.ts +627 -0
- package/src/quantize/calibration.ts +180 -0
- package/src/quantize/config-writer.ts +132 -0
- package/src/quantize/index.ts +57 -0
- package/src/quantize/job.ts +136 -0
- package/src/quantize/quantizer.ts +462 -0
- package/src/quantize/safetensors-writer.ts +171 -0
- package/src/quantize/sensitivity.ts +234 -0
- package/src/registry.ts +336 -0
- package/src/responses.ts +774 -0
- package/src/safetensors.ts +158 -0
- package/src/sampler.ts +517 -0
- package/src/serve/batch-scheduler.ts +362 -0
- package/src/serve/generation-gateway.ts +160 -0
- package/src/server.ts +1891 -0
- package/src/spec/drafter.ts +261 -0
- package/src/spec/generate.ts +221 -0
- package/src/status-page.html +497 -0
- package/src/tokenizer.ts +38 -0
- package/src/tool-call.ts +242 -0
- package/src/train/dataset.ts +461 -0
- package/src/train/export.ts +32 -0
- package/src/train/forward.ts +229 -0
- package/src/train/index.ts +43 -0
- package/src/train/job.ts +148 -0
- package/src/train/lora-params.ts +194 -0
- package/src/train/loss.ts +342 -0
- package/src/train/merge.ts +195 -0
- package/src/train/optimizer.ts +176 -0
- package/src/train/rank.ts +101 -0
- package/src/train/segmented.ts +520 -0
- package/src/train/trainer.ts +600 -0
- package/src/tui.ts +161 -0
- package/src/vision/embedder.ts +168 -0
- package/src/vision/preprocess.ts +247 -0
- package/src/vision/prompt.ts +158 -0
- package/src/vision/siglip.ts +599 -0
- package/src/web/app.html +2471 -0
- package/src/web/skills/web-research/SKILL.md +44 -0
- package/src/web/skills.ts +59 -0
- package/src/web-tools.ts +426 -0
- package/src/weights.ts +91 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
<!doctype html><html lang="en"><head><meta charset="utf-8">
|
|
2
|
+
<meta name="viewport" content="width=device-width,initial-scale=1"><title>HLG A/B samples</title><style>
|
|
3
|
+
:root{--text:#1f2937;--text2:#475569;--text3:#94a3b8;--bg:#f7f9fc;--card:#fff;--bd:#e2e8f0;--grid:#f1f5f9}
|
|
4
|
+
*{box-sizing:border-box}
|
|
5
|
+
body{margin:0;background:var(--bg);color:var(--text);font:15px/1.6 -apple-system,BlinkMacSystemFont,"Segoe UI",ui-sans-serif,system-ui,sans-serif;-webkit-font-smoothing:antialiased}
|
|
6
|
+
.wrap{max-width:1240px;margin:0 auto;padding:34px 22px 100px}
|
|
7
|
+
h1{font-size:25px;margin:0 0 3px;letter-spacing:-.02em}
|
|
8
|
+
.sub{color:var(--text2);font-size:14.5px;max-width:780px;margin:0 0 8px}
|
|
9
|
+
.legend{display:flex;flex-wrap:wrap;gap:14px;margin:14px 0 26px;font-size:13px}
|
|
10
|
+
.legend .c{display:flex;gap:8px;align-items:baseline;background:var(--card);border:1px solid var(--bd);border-radius:10px;padding:8px 13px}
|
|
11
|
+
.legend .dot{width:10px;height:10px;border-radius:3px;flex:none;position:relative;top:1px}
|
|
12
|
+
.legend b{font-weight:700}.legend .d{color:var(--text3);font-size:12px}
|
|
13
|
+
.card{background:var(--card);border:1px solid var(--bd);border-radius:14px;padding:18px 20px;margin:0 0 20px;box-shadow:0 1px 2px rgba(15,23,42,.04),0 10px 30px -24px rgba(15,23,42,.2)}
|
|
14
|
+
.q{font-size:12px;text-transform:uppercase;letter-spacing:.06em;color:var(--text3);font-weight:700}
|
|
15
|
+
.qt{font-size:16px;font-weight:600;margin:3px 0 16px}
|
|
16
|
+
.cols{display:grid;grid-template-columns:repeat(3,1fr);gap:16px}
|
|
17
|
+
@media(max-width:900px){.cols{grid-template-columns:1fr}}
|
|
18
|
+
.col h3{font-size:13px;margin:0 0 9px;display:flex;align-items:center;gap:8px}
|
|
19
|
+
.col h3 .dot{width:9px;height:9px;border-radius:3px}
|
|
20
|
+
.col h3 .d{font-weight:400;color:var(--text3);font-size:11.5px}
|
|
21
|
+
.samp{font-size:13.5px;color:#0f172a;background:var(--grid);border-radius:9px;padding:9px 11px;margin:0 0 8px;border-left:3px solid transparent}
|
|
22
|
+
.samp .n{color:var(--text3);font-weight:700;font-size:11px;margin-right:6px}
|
|
23
|
+
.note{font-size:13px;color:var(--text3);margin-top:28px;border-top:1px solid var(--bd);padding-top:14px}
|
|
24
|
+
</style></head>
|
|
25
|
+
<body><div class="wrap">
|
|
26
|
+
<h1>HLG sampling — side-by-side samples</h1>
|
|
27
|
+
<p class="sub">The same prompts, sampled three ways on <b>gemma-4-e4b-it-OptiQ-4bit</b> (3 samples each, fixed seeds). Only the
|
|
28
|
+
sampling method changes. Read down a column to feel each sampler's character; read across to compare on one prompt.</p>
|
|
29
|
+
<div class="legend"><div class="c"><span class="dot" style="background:#64748b"></span><div><b>Default recipe</b> <span class="d">the model's recommended sampler — T=1, top-p=0.95, top-k=64</span></div></div><div class="c"><span class="dot" style="background:#2563eb"></span><div><b>HLG base</b> <span class="d">A=0.35, s_m=0.7, target_gap=15, W=6</span></div></div><div class="c"><span class="dot" style="background:#0891b2"></span><div><b>HLG loose-A</b> <span class="d">A=0.01 (the diversity-leaning shoulder), rest as base</span></div></div></div>
|
|
30
|
+
<div class="card"><div class="q">creative</div><div class="qt">Write the first sentence of a short story about a lighthouse keeper who discovers something strange in the fog.</div><div class="cols"><div class="col"><h3><span class="dot" style="background:#64748b"></span>Default recipe<span class="d">A</span></h3><div class="samp" style="border-left-color:#64748b"><span class="n">1</span>The fog, a thick, greasy blanket that clung to the granite tower like a shroud, always held secrets, but this morning, it delivered something far stranger than the usual drift of unseen seabirds.</div><div class="samp" style="border-left-color:#64748b"><span class="n">2</span>The thick, soupy fog that perpetually hugged the granite tower seemed to thicken further that night, muffling the roar of the ocean until it felt less like the sea and more like a vast, wet sigh, and then he saw it—a perfectly smooth, obsidian sphere bobbing just beyond the reach of his lantern beam.</div><div class="samp" style="border-left-color:#64748b"><span class="n">3</span>The fog, a thick, clammy shroud clinging to the granite tower, seemed to pulse with an unnatural life as Silas scanned the churning grey expanse.</div></div><div class="col"><h3><span class="dot" style="background:#2563eb"></span>HLG base<span class="d">B</span></h3><div class="samp" style="border-left-color:#2563eb"><span class="n">1</span>The fog, a thick, clammy blanket that swallowed the beam of the lamp, usually brought with it the familiar scent of salt and damp stone, but tonight, a faint, metallic tang drifted in, something utterly alien against the backdrop of the churning grey.</div><div class="samp" style="border-left-color:#2563eb"><span class="n">2</span>The fog, a thick, clammy blanket that swallowed the beam of the old tower, pressed against Silas’s windowpane, and it was in that suffocating grey that he first saw the impossible.</div><div class="samp" style="border-left-color:#2563eb"><span class="n">3</span>The fog, a thick, clammy shroud that swallowed the horizon whole, seemed to press against the glass of the lantern room, and it was in that oppressive whiteness that Silas first saw the impossible flicker.</div></div><div class="col"><h3><span class="dot" style="background:#0891b2"></span>HLG loose-A<span class="d">C</span></h3><div class="samp" style="border-left-color:#0891b2"><span class="n">1</span>The fog, a thick, milky blanket that clung to the granite cliffs like wet wool, always held secrets, but this evening, something decidedly out of place drifted through its milky shroud.</div><div class="samp" style="border-left-color:#0891b2"><span class="n">2</span>The relentless, clinging fog had been his only constant companion for three lonely weeks, until tonight, when a splash of unnatural emerald light pierced the milky grey swirling just beyond the tower's narrow beam.</div><div class="samp" style="border-left-color:#0891b2"><span class="n">3</span>The thick, soupy fog that clung to the coast had been a familiar, monotonous blanket for Elias for three years, but this morning, something broke through it.</div></div></div></div><div class="card"><div class="q">continuation</div><div class="qt">Complete this thought in a vivid, original way: 'The strangest thing about human memory is'</div><div class="cols"><div class="col"><h3><span class="dot" style="background:#64748b"></span>Default recipe<span class="d">A</span></h3><div class="samp" style="border-left-color:#64748b"><span class="n">1</span>'The strangest thing about human memory is **how it doesn't archive life; it remixes it.** It’s less a library and more a chaotic, brilliant tapestry where the scent of old rain from a childhood picnic might instantly trigger the bittersweet ache of a grief felt last week, seamlessly weaving the textures of two entirely different selves into a single, shimmering, unreliable present.'</div><div class="samp" style="border-left-color:#64748b"><span class="n">2</span>'The strangest thing about human memory is **how it doesn't catalog events, but rather *re-forges* them—a warm, unreliable tapestry woven from the brilliant threads of feeling, the frayed edges of suggestion, and the perfectly smooth, utterly fictional comfort of what we desperately wish had happened.**'</div><div class="samp" style="border-left-color:#64748b"><span class="n">3</span>'The strangest thing about human memory is **how it feels less like a recording and more like an act of tireless, beautiful, and often treacherous reconstruction.** It's not a dusty film reel; it's a restless alchemist's laboratory, where yesterday's sunlight is re-mixed with today's doubt, and the ghosts of forgotten moments shimmer into the present, always slightly rearranged, always colored by the urgent, vibrant necessity</div></div><div class="col"><h3><span class="dot" style="background:#2563eb"></span>HLG base<span class="d">B</span></h3><div class="samp" style="border-left-color:#2563eb"><span class="n">1</span>'The strangest thing about human memory is **how it doesn't archive; it *re-weaves*. It’s not a library where you pull a perfect volume from the shelf, but a loom where every recollection is re-threaded with the anxieties, the triumphs, and the sheer, messy passage of time, making the past less a fixed photograph and more a perpetually shifting, emotionally charged watercolor.**'</div><div class="samp" style="border-left-color:#2563eb"><span class="n">2</span>'The strangest thing about human memory is **how it doesn't archive; it *re-weaves*. It’s not a pristine library of moments, but a tapestry constantly being re-spun by the present, where the sharp edges of yesterday soften, the crucial details bleed into the background noise, and the emotional resonance of a forgotten Tuesday can suddenly bloom with the blinding, illogical clarity of a perfect, remembered sunset.**'</div><div class="samp" style="border-left-color:#2563eb"><span class="n">3</span>'The strangest thing about human memory is **how it doesn't archive events; it *re-weaves* them, a tapestry where the scent of rain from a childhood summer can suddenly bleed into the sharp, metallic tang of a present-day anxiety, making us believe we are recalling a perfect moment when, in reality, we are just listening to the echo of a feeling.**'</div></div><div class="col"><h3><span class="dot" style="background:#0891b2"></span>HLG loose-A<span class="d">C</span></h3><div class="samp" style="border-left-color:#0891b2"><span class="n">1</span>'The strangest thing about human memory is **how it acts like a kaleidoscope of forgotten dreams, capable of reassembling a perfect, polished vista of a past moment—a scent, the slant of light through a childhood window, the exact timbre of a forgotten argument—only to reveal, upon closer inspection, that the very foundation of that flawless image is made of shimmering, ill-fitting glass.**'</div><div class="samp" style="border-left-color:#0891b2"><span class="n">2</span>'The strangest thing about human memory is **how it doesn't catalog the past like a library, but rather re-authors it in the dusty, flickering spotlight of the present, leaving behind echoes of who we were, rather than the immutable blueprint of what actually occurred.**'</div><div class="samp" style="border-left-color:#0891b2"><span class="n">3</span>'The strangest thing about human memory is **how it acts less like a meticulously filed archive, and more like a perpetually haunted attic—a chaotic, dust-mote-filled space where forgotten sunlight sometimes illuminates a moment with such blinding, visceral clarity that you can still smell the rain on the cobblestones of a life you've long since left behind.**'</div></div></div></div><div class="card"><div class="q">factual</div><div class="qt">In one sentence, what causes the seasons on Earth?</div><div class="cols"><div class="col"><h3><span class="dot" style="background:#64748b"></span>Default recipe<span class="d">A</span></h3><div class="samp" style="border-left-color:#64748b"><span class="n">1</span>The seasons on Earth are caused by the tilt of the planet's axis as it revolves around the Sun.</div><div class="samp" style="border-left-color:#64748b"><span class="n">2</span>The Earth's tilt on its axis as it revolves around the Sun is what causes the seasons.</div><div class="samp" style="border-left-color:#64748b"><span class="n">3</span>The Earth's axial tilt of approximately 23.5 degrees as it orbits the sun causes the changing seasons.</div></div><div class="col"><h3><span class="dot" style="background:#2563eb"></span>HLG base<span class="d">B</span></h3><div class="samp" style="border-left-color:#2563eb"><span class="n">1</span>The seasons on Earth are caused by the tilt of the Earth's axis as it revolves around the Sun.</div><div class="samp" style="border-left-color:#2563eb"><span class="n">2</span>The seasons on Earth are caused by the tilt of the planet's axis as it revolves around the Sun.</div><div class="samp" style="border-left-color:#2563eb"><span class="n">3</span>The Earth's axial tilt, combined with its revolution around the Sun, causes the changing seasons.</div></div><div class="col"><h3><span class="dot" style="background:#0891b2"></span>HLG loose-A<span class="d">C</span></h3><div class="samp" style="border-left-color:#0891b2"><span class="n">1</span>The seasons on Earth are caused by the tilt of the planet's axis as it revolves around the Sun.</div><div class="samp" style="border-left-color:#0891b2"><span class="n">2</span>The Earth's tilt on its axis combined with its revolution around the Sun causes the changing seasons.</div><div class="samp" style="border-left-color:#0891b2"><span class="n">3</span>The Earth's axial tilt of approximately 23.5 degrees combined with its orbit around the sun is what causes the seasons.</div></div></div></div><div class="card"><div class="q">explain</div><div class="qt">Explain in two sentences why the sky is blue.</div><div class="cols"><div class="col"><h3><span class="dot" style="background:#64748b"></span>Default recipe<span class="d">A</span></h3><div class="samp" style="border-left-color:#64748b"><span class="n">1</span>The sky appears blue because of a phenomenon called Rayleigh scattering, where the Earth's atmosphere scatters shorter, blue-wavelength sunlight more effectively than longer, red wavelengths. This scattered blue light reaches our eyes from all directions, making the sky look blue.</div><div class="samp" style="border-left-color:#64748b"><span class="n">2</span>The sky appears blue because of a phenomenon called Rayleigh scattering. Sunlight, when entering the Earth's atmosphere, is scattered by nitrogen and oxygen molecules, with the shorter, blue wavelengths being scattered more effectively in all directions.</div><div class="samp" style="border-left-color:#64748b"><span class="n">3</span>The sky appears blue because of a phenomenon called Rayleigh scattering. This causes shorter, blue wavelengths of sunlight to be scattered more effectively by the molecules in the Earth's atmosphere than longer, red wavelengths.</div></div><div class="col"><h3><span class="dot" style="background:#2563eb"></span>HLG base<span class="d">B</span></h3><div class="samp" style="border-left-color:#2563eb"><span class="n">1</span>The sky appears blue because of a phenomenon called Rayleigh scattering. This process causes shorter, blue wavelengths of sunlight to be scattered more effectively by the molecules in the Earth's atmosphere than longer, redder wavelengths.</div><div class="samp" style="border-left-color:#2563eb"><span class="n">2</span>The sky appears blue because of a phenomenon called Rayleigh scattering. This occurs when sunlight enters the Earth's atmosphere and its shorter, blue-wavelength light is scattered more effectively by the tiny molecules of the atmosphere than the longer, redder wavelengths.</div><div class="samp" style="border-left-color:#2563eb"><span class="n">3</span>The sky appears blue because of a phenomenon called Rayleigh scattering. This process causes shorter, blue wavelengths of sunlight to be scattered more effectively by the molecules in the Earth's atmosphere than longer, red wavelengths.</div></div><div class="col"><h3><span class="dot" style="background:#0891b2"></span>HLG loose-A<span class="d">C</span></h3><div class="samp" style="border-left-color:#0891b2"><span class="n">1</span>The sky appears blue because of a phenomenon called Rayleigh scattering, where molecules of oxygen and nitrogen in the atmosphere scatter shorter, higher-energy blue wavelengths of sunlight more effectively than longer wavelengths. This scattering effect spreads the blue light across the entire sky, making it appear blue to our eyes.</div><div class="samp" style="border-left-color:#0891b2"><span class="n">2</span>The sky appears blue because of a phenomenon called Rayleigh scattering. This scattering of sunlight by the Earth's atmosphere preferentially scatters shorter, blue wavelengths of light across the sky in all directions.</div><div class="samp" style="border-left-color:#0891b2"><span class="n">3</span>The sky appears blue because of a phenomenon called Rayleigh scattering. This causes shorter, blue wavelengths of sunlight to be scattered more effectively by the molecules in the Earth's atmosphere than longer, red wavelengths.</div></div></div></div><div class="card"><div class="q">lateral</div><div class="qt">Give one unusual but genuinely plausible use for a paperclip, in a sentence.</div><div class="cols"><div class="col"><h3><span class="dot" style="background:#64748b"></span>Default recipe<span class="d">A</span></h3><div class="samp" style="border-left-color:#64748b"><span class="n">1</span>A tightly rolled paperclip can serve as a surprisingly effective, miniature shim to stabilize a slightly wobbly piece of delicate electronic equipment.</div><div class="samp" style="border-left-color:#64748b"><span class="n">2</span>A sturdy paperclip could be fashioned into a temporary, improvised fishing hook to snag small aquatic life during an emergency outing.</div><div class="samp" style="border-left-color:#64748b"><span class="n">3</span>A paperclip can be bent into a surprisingly effective, miniature fishing hook for retrieving small, lost items from narrow crevices.</div></div><div class="col"><h3><span class="dot" style="background:#2563eb"></span>HLG base<span class="d">B</span></h3><div class="samp" style="border-left-color:#2563eb"><span class="n">1</span>A paperclip could be bent into a makeshift, temporary hook to retrieve a dropped earring from a narrow drain.</div><div class="samp" style="border-left-color:#2563eb"><span class="n">2</span>A paperclip could be meticulously straightened and used as a temporary, fine-gauge shim to level a slightly wobbly antique picture frame.</div><div class="samp" style="border-left-color:#2563eb"><span class="n">3</span>A paperclip could be bent into a makeshift, temporary antenna to boost a weak radio signal during an outdoor emergency.</div></div><div class="col"><h3><span class="dot" style="background:#0891b2"></span>HLG loose-A<span class="d">C</span></h3><div class="samp" style="border-left-color:#0891b2"><span class="n">1</span>A paperclip could be bent into a miniature, temporary hook to retrieve a dropped earring from a tight spot behind a piece of furniture.</div><div class="samp" style="border-left-color:#0891b2"><span class="n">2</span>A paperclip, carefully bent, can serve as a makeshift, temporary shim to level a slightly uneven tripod leg on a camera in a pinch.</div><div class="samp" style="border-left-color:#0891b2"><span class="n">3</span>A paperclip can be bent into a surprisingly effective, albeit makeshift, reset pin for a jammed electronic device.</div></div></div></div><div class="card"><div class="q">voice</div><div class="qt">Describe the feeling of a city at 3am in one vivid sentence.</div><div class="cols"><div class="col"><h3><span class="dot" style="background:#64748b"></span>Default recipe<span class="d">A</span></h3><div class="samp" style="border-left-color:#64748b"><span class="n">1</span>The city at 3 am hums with a spectral energy, a mélange of distant sirens, the rhythmic sigh of cooling concrete, and the isolated echoes of late-night human solitude.</div><div class="samp" style="border-left-color:#64748b"><span class="n">2</span>The city at 3 am hums with a skeletal, phosphorescent energy, a vast, tired beast breathing slowly between the last echoes of the day's clamor and the relentless arrival of dawn.</div><div class="samp" style="border-left-color:#64748b"><span class="n">3</span>The city breathes a ragged, neon-streaked sigh of lonely industry, a vast, half-asleep beast illuminated by the spectral glow of forgotten streetlights.</div></div><div class="col"><h3><span class="dot" style="background:#2563eb"></span>HLG base<span class="d">B</span></h3><div class="samp" style="border-left-color:#2563eb"><span class="n">1</span>The city at 3 am is a vast, hushed beast, exhaling the metallic scent of cooling asphalt under the lonely, sodium-orange glow of forgotten streetlights.</div><div class="samp" style="border-left-color:#2563eb"><span class="n">2</span>The city at 3 am is a vast, humming beast, exhaling the cool, metallic scent of asphalt and the lonely, rhythmic sigh of distant sirens against a backdrop of deep, bruised indigo.</div><div class="samp" style="border-left-color:#2563eb"><span class="n">3</span>The city at 3 am is a vast, breathing beast, its neon veins pulsing with the ghosts of late-night revelers and the low, rhythmic hum of the sleeping concrete.</div></div><div class="col"><h3><span class="dot" style="background:#0891b2"></span>HLG loose-A<span class="d">C</span></h3><div class="samp" style="border-left-color:#0891b2"><span class="n">1</span>The city at 3 am hums with a solitary, neon-drenched exhaustion, a low thrum of secrets and forgotten sirens weaving through the skeletal geometry of sleeping giants.</div><div class="samp" style="border-left-color:#0891b2"><span class="n">2</span>The city at 3 am hums with a skeletal, phosphorescent energy, a vast, hushed beast whose only movements are the lonely sweep of headlights across slick asphalt and the distant, rhythmic sigh of the ventilation units.</div><div class="samp" style="border-left-color:#0891b2"><span class="n">3</span>The city breathes a humid, neon-tinged quiet, a skeletal monument to forgotten daytime revelry under a velvet-black sky.</div></div></div></div>
|
|
31
|
+
<p class="note">Generated by <code>scripts/hlg-ab.ts</code> → <code>scripts/hlg-ab-html.ts</code>. Notice how <b>HLG base</b> tends to
|
|
32
|
+
converge on a single strong continuation (lower diversity — the tight shoulder concentrates on the high-probability path), while
|
|
33
|
+
<b>HLG loose-A</b> spreads out — the same behavior the diversity sweeps measured, here in plain text.</p>
|
|
34
|
+
</div></body></html>
|
|
@@ -0,0 +1,238 @@
|
|
|
1
|
+
<!doctype html><html lang="en"><head><meta charset="utf-8">
|
|
2
|
+
<meta name="viewport" content="width=device-width,initial-scale=1">
|
|
3
|
+
<title>HLG Sampling Explorer — real logits</title>
|
|
4
|
+
<style>
|
|
5
|
+
:root{--text:#1f2937;--text2:#475569;--text3:#94a3b8;--bg:#f7f9fc;--card:#fff;--bd:#e2e8f0;
|
|
6
|
+
--accent:#2563eb;--accent2:#0891b2;--pos:#16a34a;--warn:#d97706;--danger:#dc2626;--grid:#eef2f7;--gray:#94a3b8;}
|
|
7
|
+
*{box-sizing:border-box}
|
|
8
|
+
html,body{height:100%;margin:0;overflow:hidden}
|
|
9
|
+
body{background:var(--bg);color:var(--text);font:13px/1.4 -apple-system,BlinkMacSystemFont,"Segoe UI",ui-sans-serif,system-ui,sans-serif;-webkit-font-smoothing:antialiased}
|
|
10
|
+
.app{height:100vh;display:grid;grid-template-columns:minmax(380px,42%) 1fr;gap:14px;padding:14px}
|
|
11
|
+
.panel{background:var(--card);border:1px solid var(--bd);border-radius:12px;padding:12px 14px;box-shadow:0 1px 2px rgba(15,23,42,.04),0 10px 30px -24px rgba(15,23,42,.2);min-height:0;overflow:auto}
|
|
12
|
+
.controls{display:flex;flex-direction:column}
|
|
13
|
+
h1{font-size:15px;margin:0;letter-spacing:-.01em}
|
|
14
|
+
.topbar{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-bottom:7px}
|
|
15
|
+
.presets{display:flex;flex-wrap:wrap;gap:5px;margin-left:auto}
|
|
16
|
+
.presets button{font:600 11px/1 inherit;padding:6px 9px;border:1px solid var(--bd);background:var(--card);border-radius:7px;cursor:pointer;color:var(--text2)}
|
|
17
|
+
.presets button:hover{border-color:var(--accent);color:var(--accent)}
|
|
18
|
+
.presets button.reset{color:var(--danger);border-color:#f3d6d6}
|
|
19
|
+
.presets button.copy{background:var(--accent);color:#fff;border-color:var(--accent)}
|
|
20
|
+
.distsel{display:flex;gap:5px;margin-bottom:8px;flex-wrap:wrap}
|
|
21
|
+
.distsel button{font:600 11px/1 inherit;padding:6px 9px;border:1px solid var(--bd);background:var(--grid);border-radius:7px;cursor:pointer;color:var(--text2)}
|
|
22
|
+
.distsel button.on{background:var(--accent);color:#fff;border-color:var(--accent)}
|
|
23
|
+
.copyrow{display:flex;gap:6px;align-items:center;margin-bottom:9px}
|
|
24
|
+
.copyrow input{flex:1;font:11px/1.3 ui-monospace,SFMono-Regular,Menlo,monospace;border:1px solid var(--bd);border-radius:7px;padding:6px 8px;background:var(--grid);color:#0f172a}
|
|
25
|
+
.copyrow .ok{font-size:11px;font-weight:700;color:var(--pos);min-width:46px}
|
|
26
|
+
.grid2{display:grid;grid-template-columns:1fr 1fr;gap:6px 16px;align-content:start}
|
|
27
|
+
.gh{grid-column:1/-1;font-size:10px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:var(--text3);margin:6px 0 0;border-top:1px solid var(--bd);padding-top:7px}
|
|
28
|
+
.gh:first-child{border-top:none;padding-top:0;margin-top:0}
|
|
29
|
+
.cell label{display:flex;justify-content:space-between;align-items:baseline;font-size:11.5px;font-weight:600;gap:6px}
|
|
30
|
+
.cell label .v{font-weight:700;color:var(--accent);font-variant-numeric:tabular-nums;font-size:12px}
|
|
31
|
+
.cell input[type=range]{width:100%;accent-color:var(--accent);height:16px;cursor:pointer;margin:1px 0 0}
|
|
32
|
+
.figs{display:flex;flex-direction:column;gap:8px}
|
|
33
|
+
.figs .panel{padding:8px 12px}
|
|
34
|
+
.fh{font-size:10px;text-transform:uppercase;letter-spacing:.06em;color:var(--text2);font-weight:700;margin:0 0 2px}
|
|
35
|
+
.fh small{font-weight:400;text-transform:none;letter-spacing:0;color:var(--text3)}
|
|
36
|
+
svg{width:100%;height:auto;display:block}
|
|
37
|
+
.legend{display:flex;gap:13px;flex-wrap:wrap;font-size:10.5px;color:var(--text2);margin-top:3px}
|
|
38
|
+
.legend span{display:inline-flex;align-items:center;gap:5px}.legend i{width:14px;height:3px;border-radius:2px;display:inline-block}
|
|
39
|
+
.readouts{display:grid;grid-template-columns:repeat(4,1fr);gap:7px;margin-top:6px}
|
|
40
|
+
.ro{background:var(--grid);border-radius:7px;padding:5px 8px}
|
|
41
|
+
.ro .k{font-size:9px;text-transform:uppercase;letter-spacing:.04em;color:var(--text3)}
|
|
42
|
+
.ro .val{font-size:14px;font-weight:700;font-variant-numeric:tabular-nums}
|
|
43
|
+
@media(max-width:820px){.app{grid-template-columns:1fr;height:auto;overflow:auto}html,body{overflow:auto}}
|
|
44
|
+
</style></head>
|
|
45
|
+
<body>
|
|
46
|
+
<div class="app">
|
|
47
|
+
<div class="panel controls">
|
|
48
|
+
<div class="topbar"><h1>HLG Explorer · real logits</h1>
|
|
49
|
+
<div class="presets">
|
|
50
|
+
<button data-preset="base">Base</button><button data-preset="loose">Loose-A</button>
|
|
51
|
+
<button data-preset="sharp">Sharp</button><button data-preset="base" class="reset">Reset</button>
|
|
52
|
+
<button id="copyBtn" class="copy">Copy Values</button>
|
|
53
|
+
</div>
|
|
54
|
+
</div>
|
|
55
|
+
<div class="distsel" id="distsel"></div>
|
|
56
|
+
<div class="copyrow"><input id="cfgField" readonly spellcheck="false"><span class="ok" id="copyOk"></span></div>
|
|
57
|
+
<div class="grid2" id="grid"></div>
|
|
58
|
+
</div>
|
|
59
|
+
<div class="figs">
|
|
60
|
+
<div class="panel">
|
|
61
|
+
<div class="fh">Transfer curve <small>· real tokens mapped on by their logits — watch them pile into the toe</small></div>
|
|
62
|
+
<div id="curve"></div>
|
|
63
|
+
<div class="legend"><span><i style="background:var(--accent)"></i>OETF</span><span><i style="background:var(--accent2)"></i>after γ</span><span><i style="background:var(--text3)"></i>temp (linear)</span><span><i style="background:var(--warn);height:8px;width:8px;border-radius:50%"></i>tokens</span></div>
|
|
64
|
+
<div class="readouts" id="readouts"></div>
|
|
65
|
+
</div>
|
|
66
|
+
<div class="panel">
|
|
67
|
+
<div class="fh">Distribution over the full 262k vocab <small>· x = rank (log) · y = probability (log)</small></div>
|
|
68
|
+
<div id="dist"></div>
|
|
69
|
+
<div class="legend"><span><i style="background:var(--gray)"></i>raw softmax</span><span><i style="background:var(--pos)"></i>default recipe (top-p·top-k)</span><span><i style="background:var(--accent)"></i>HLG</span><span><i style="background:var(--warn);height:9px;width:2px"></i>W reaches here</span></div>
|
|
70
|
+
<div class="readouts" id="distro"></div>
|
|
71
|
+
</div>
|
|
72
|
+
</div>
|
|
73
|
+
</div>
|
|
74
|
+
|
|
75
|
+
<script src="hlg-figs/hlg-logits.js"></script>
|
|
76
|
+
<script>
|
|
77
|
+
const DISTS = (window.REAL_LOGITS||[]).map(d=>({...d, sorted:Float64Array.from(d.sorted)}));
|
|
78
|
+
let di = DISTS.length? DISTS.findIndex(d=>d.tag==="creative") : -1; if(di<0) di=0;
|
|
79
|
+
|
|
80
|
+
const DEF = { window:8, A:0.35, sM:0.7, targetGap:15, refGap:4, lw:1200, xM:0.55, yM:0.5, xFloor:0.2, yFloor:0.18, p:2.0, T:1.0, topP:0.95, topK:64 };
|
|
81
|
+
const PRESETS = { base:{...DEF}, loose:{...DEF,A:0.01}, sharp:{...DEF,targetGap:40,sM:2.0,A:0.2} };
|
|
82
|
+
const P = {...DEF};
|
|
83
|
+
|
|
84
|
+
const GROUPS = [
|
|
85
|
+
{h:"HLG — primary", items:[
|
|
86
|
+
{k:"window",label:"W — window (nats)",min:1,max:40,step:0.5},
|
|
87
|
+
{k:"A",label:"A — shoulder",min:0.01,max:5,step:0.01},
|
|
88
|
+
{k:"sM",label:"s_m — mid slope",min:0.05,max:6,step:0.05},
|
|
89
|
+
{k:"targetGap",label:"target_gap",min:4,max:50,step:1},
|
|
90
|
+
{k:"lw",label:"L_W (γ)",min:0,max:6,step:0.02,log:true},
|
|
91
|
+
{k:"refGap",label:"refGap",min:1,max:20,step:0.5},
|
|
92
|
+
]},
|
|
93
|
+
{h:"HLG — geometry", items:[
|
|
94
|
+
{k:"xM",label:"x_M",min:0.3,max:0.8,step:0.01},{k:"yM",label:"y_M",min:0.3,max:0.7,step:0.01},
|
|
95
|
+
{k:"xFloor",label:"x_floor",min:0.05,max:0.45,step:0.01},{k:"yFloor",label:"y_floor",min:0.05,max:0.45,step:0.01},
|
|
96
|
+
{k:"p",label:"p — mid power",min:1.2,max:4,step:0.05},
|
|
97
|
+
]},
|
|
98
|
+
{h:"Default recipe (the standard sampler)", items:[
|
|
99
|
+
{k:"T",label:"temperature",min:0.1,max:2,step:0.05},{k:"topP",label:"top-p",min:0.1,max:1,step:0.01},{k:"topK",label:"top-k",min:1,max:512,step:1},
|
|
100
|
+
]},
|
|
101
|
+
];
|
|
102
|
+
const ALL = GROUPS.flatMap(g=>g.items);
|
|
103
|
+
const lwToS=lw=>Math.log10(lw), sToLw=s=>Math.pow(10,s);
|
|
104
|
+
|
|
105
|
+
function buildGrid(){
|
|
106
|
+
const c=document.getElementById("grid"); c.innerHTML="";
|
|
107
|
+
for(const g of GROUPS){ const h=document.createElement("div"); h.className="gh"; h.textContent=g.h; c.appendChild(h);
|
|
108
|
+
for(const s of g.items){ const d=document.createElement("div"); d.className="cell";
|
|
109
|
+
d.innerHTML=`<label>${s.label}<span class="v" id="v_${s.k}"></span></label><input type="range" id="s_${s.k}" min="${s.min}" max="${s.max}" step="${s.step}" value="${s.log?lwToS(P[s.k]):P[s.k]}">`;
|
|
110
|
+
c.appendChild(d);
|
|
111
|
+
d.querySelector("input").addEventListener("input",e=>{P[s.k]=s.log?sToLw(parseFloat(e.target.value)):parseFloat(e.target.value); render();});
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
function buildDistSel(){
|
|
116
|
+
const c=document.getElementById("distsel"); c.innerHTML="";
|
|
117
|
+
if(!DISTS.length){ c.innerHTML='<span style="color:var(--danger);font-size:11px">hlg-logits.js not loaded — run scripts/hlg-capture-logits.ts</span>'; return; }
|
|
118
|
+
DISTS.forEach((d,i)=>{ const b=document.createElement("button"); b.textContent=`${d.tag} · ${d.entropyBits}b`; if(i===di)b.className="on";
|
|
119
|
+
b.addEventListener("click",()=>{di=i; buildDistSel(); prep(); render();}); c.appendChild(b); });
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
// ---- shaper ----
|
|
123
|
+
function geom(){
|
|
124
|
+
const {xM,yM,xFloor,yFloor,p,sM,A,lw,window:W,targetGap,refGap}=P;
|
|
125
|
+
const dxf=xM-xFloor, kc=(yM-sM*dxf-yFloor)/Math.pow(dxf,p), sFloor=sM+kc*p*Math.pow(dxf,p-1);
|
|
126
|
+
const det=-Math.pow(xFloor,4), ec=(yFloor*2*xFloor-xFloor*xFloor*sFloor)/det, fc=(Math.pow(xFloor,3)*sFloor-yFloor*3*xFloor*xFloor)/det;
|
|
127
|
+
const yPeak=yM+A*Math.log(1+(sM/A)*(1-xM)), gamma=1.2+0.42*Math.log10(Math.max(lw,1e-3)/1000);
|
|
128
|
+
const oetfS=x=>{let y; if(x>=xM)y=yM+A*Math.log(Math.max(1+(sM/A)*(x-xM),1e-9)); else if(x>=xFloor)y=yM-sM*(xM-x)-kc*Math.pow(Math.max(xM-x,0),p); else y=ec*x*x*x+fc*x*x; return Math.max(y,0);};
|
|
129
|
+
const shapeS=x=>Math.pow(Math.max(oetfS(x)/yPeak,1e-9),gamma);
|
|
130
|
+
const xRef=Math.max(0,Math.min(1,1-refGap/W)), outScale=targetGap/Math.max(1e-6,1-shapeS(xRef));
|
|
131
|
+
return {gamma,yPeak,outScale,xRef,oetfS,shapeS};
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
// ---- per-distribution prep ----
|
|
135
|
+
let D=null;
|
|
136
|
+
function logsumexp(arr,n){ let m=-1e30; for(let i=0;i<n;i++) if(arr[i]>m)m=arr[i]; let s=0; for(let i=0;i<n;i++) s+=Math.exp(arr[i]-m); return m+Math.log(s); }
|
|
137
|
+
function prep(){
|
|
138
|
+
if(!DISTS.length){ D=null; return; }
|
|
139
|
+
const d=DISTS[di], s=d.sorted, V=s.length, lmax=s[0];
|
|
140
|
+
const rawLse=logsumexp(s,V);
|
|
141
|
+
// log-spaced sample ranks for rendering (+ dense head)
|
|
142
|
+
const ranks=new Set(); for(let i=0;i<64;i++) ranks.add(i);
|
|
143
|
+
const N=360, lV=Math.log10(V); for(let i=0;i<=N;i++) ranks.add(Math.min(V-1,Math.round(Math.pow(10,(i/N)*lV))-0+0));
|
|
144
|
+
const sr=[...ranks].filter(r=>r<V).sort((a,b)=>a-b);
|
|
145
|
+
D={s,V,lmax,rawLse,sr,tag:d.tag,ent:d.entropyBits};
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
// ---- distribution computations ----
|
|
149
|
+
function probsAt(g){
|
|
150
|
+
const {s,V,lmax,rawLse,sr}=D, {shapeS,outScale}=g, W=P.window;
|
|
151
|
+
// raw
|
|
152
|
+
const raw=sr.map(r=>Math.exp(s[r]-rawLse));
|
|
153
|
+
// HLG: only tokens within W of top leave the toe; rest are the constant toe value
|
|
154
|
+
let inWin=0; const thr=lmax-W; while(inWin<V && s[inWin]>thr) inWin++;
|
|
155
|
+
const toeShaped=outScale*shapeS(0);
|
|
156
|
+
const shapedOf=r=>{ if(r>=inWin) return toeShaped; const x=Math.max(0,Math.min(1,(s[r]-lmax)/W+1)); return outScale*shapeS(x); };
|
|
157
|
+
let mx=toeShaped; for(let i=0;i<inWin;i++){ const v=shapedOf(i); if(v>mx)mx=v; }
|
|
158
|
+
let Z=(V-inWin)*Math.exp(toeShaped-mx); for(let i=0;i<inWin;i++) Z+=Math.exp(shapedOf(i)-mx);
|
|
159
|
+
const hlgLse=mx+Math.log(Z);
|
|
160
|
+
const hlg=sr.map(r=>Math.exp(shapedOf(r)-hlgLse));
|
|
161
|
+
// default recipe: temp → full softmax → keep top-p ∩ top-k → renormalize
|
|
162
|
+
const T=P.T; const scaled=new Float64Array(V); for(let i=0;i<V;i++) scaled[i]=s[i]/T;
|
|
163
|
+
const sLse=T===1?(rawLse):logsumexp(scaled,V);
|
|
164
|
+
let cum=0, mset=V; for(let i=0;i<V;i++){ cum+=Math.exp(scaled[i]-sLse); if(cum>=P.topP){ mset=i+1; break; } }
|
|
165
|
+
const keep=Math.max(1,Math.min(Math.round(P.topK),mset));
|
|
166
|
+
let dZ=logsumexp(scaled.subarray(0,keep),keep);
|
|
167
|
+
const def=sr.map(r=>r<keep?Math.exp(scaled[r]-dZ):0);
|
|
168
|
+
return {raw,hlg,def,inWin,keep,hlgTop1:Math.exp(shapedOf(0)-hlgLse)};
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
// ---- curve panel ----
|
|
172
|
+
const CW=560,CH=210,ML=42,MR=14,MT=15,MB=30;
|
|
173
|
+
const cx=x=>ML+x*(CW-ML-MR), cy=(y,ym)=>MT+(1-y/ym)*(CH-MT-MB);
|
|
174
|
+
const poly=(fn,ym,n=140)=>{let d="";for(let i=0;i<=n;i++){const x=i/n;d+=(i?"L":"M")+cx(x).toFixed(1)+" "+cy(fn(x),ym).toFixed(1)+" ";}return d;};
|
|
175
|
+
function drawCurve(g){
|
|
176
|
+
const {oetfS,yPeak,shapeS}=g, oetfN=x=>Math.max(0,oetfS(x)/yPeak);
|
|
177
|
+
let ym=1; for(let i=0;i<=140;i++){const x=i/140; ym=Math.max(ym,oetfN(x),shapeS(x));} ym=Math.min(ym,8);
|
|
178
|
+
let s=`<svg viewBox="0 0 ${CW} ${CH}" font-family="inherit">`;
|
|
179
|
+
s+=`<rect x="${cx(0)}" y="${MT}" width="${cx(P.xFloor)-cx(0)}" height="${CH-MT-MB}" fill="#fde2e2" opacity=".5"/><rect x="${cx(P.xFloor)}" y="${MT}" width="${cx(P.xM)-cx(P.xFloor)}" height="${CH-MT-MB}" fill="#fff3d6" opacity=".5"/><rect x="${cx(P.xM)}" y="${MT}" width="${cx(1)-cx(P.xM)}" height="${CH-MT-MB}" fill="#dcfce7" opacity=".5"/>`;
|
|
180
|
+
s+=`<text x="${(cx(0)+cx(P.xFloor))/2}" y="${MT+11}" text-anchor="middle" font-size="9" fill="#b91c1c">toe</text><text x="${(cx(P.xFloor)+cx(P.xM))/2}" y="${MT+11}" text-anchor="middle" font-size="9" fill="#92400e">mid</text><text x="${(cx(P.xM)+cx(1))/2}" y="${MT+11}" text-anchor="middle" font-size="9" fill="#166534">shoulder</text>`;
|
|
181
|
+
for(let f=0;f<=1.0001;f+=0.25){const yv=f*ym; s+=`<line x1="${ML}" y1="${cy(yv,ym)}" x2="${CW-MR}" y2="${cy(yv,ym)}" stroke="var(--grid)"/>`;}
|
|
182
|
+
s+=`<line x1="${cx(0)}" y1="${cy(0,ym)}" x2="${cx(1)}" y2="${cy(1,ym)}" stroke="var(--text3)" stroke-width="1.3" stroke-dasharray="5 4"/>`;
|
|
183
|
+
for(const xv of [P.xFloor,P.xM]) s+=`<line x1="${cx(xv)}" y1="${MT}" x2="${cx(xv)}" y2="${CH-MB}" stroke="var(--text3)" stroke-dasharray="2 3" opacity=".6"/>`;
|
|
184
|
+
s+=`<path d="${poly(oetfN,ym)}" fill="none" stroke="var(--accent)" stroke-width="2.2"/><path d="${poly(shapeS,ym)}" fill="none" stroke="var(--accent2)" stroke-width="2.2"/>`;
|
|
185
|
+
// real tokens: top 80 mapped on by logit
|
|
186
|
+
if(D){ const n=Math.min(80,D.V); for(let r=0;r<n;r++){ const x=Math.max(0,Math.min(1,(D.s[r]-D.lmax)/P.window+1)); s+=`<circle cx="${cx(x)}" cy="${cy(shapeS(x),ym)}" r="${r===0?3.4:2.4}" fill="var(--warn)" stroke="#fff" stroke-width="0.8" opacity="${r===0?1:0.7}"/>`; } }
|
|
187
|
+
s+=`<text x="${(ML+CW-MR)/2}" y="${CH-3}" text-anchor="middle" font-size="9.5" fill="var(--text2)">signal x (1 = top token · 0 = ≥W nats below)</text>`;
|
|
188
|
+
if(g.gamma<0) s+=`<text x="${(ML+CW-MR)/2}" y="${MT+28}" text-anchor="middle" font-size="11" font-weight="700" fill="var(--danger)">γ<0 — ranking inverts (incoherent)</text>`;
|
|
189
|
+
s+=`</svg>`; document.getElementById("curve").innerHTML=s;
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
// ---- distribution panel (log rank × log prob) ----
|
|
193
|
+
const DW=560,DH=210,DL=44,DR=12,DT=12,DB=30, PLO=-7;
|
|
194
|
+
function dx(r){ return DL+(Math.log10(r+1)/Math.log10(D.V))*(DW-DL-DR); }
|
|
195
|
+
function dy(p){ const lp=p>0?Math.log10(p):PLO; return DT+(1-(Math.max(lp,PLO)-PLO)/(0-PLO))*(DH-DT-DB); }
|
|
196
|
+
function linePath(arr){ let d="",started=false; for(let i=0;i<D.sr.length;i++){ const r=D.sr[i],p=arr[i]; if(p<=0){started=false;continue;} d+=(started?"L":"M")+dx(r).toFixed(1)+" "+dy(p).toFixed(1)+" "; started=true; } return d; }
|
|
197
|
+
function drawDist(pr){
|
|
198
|
+
if(!D){ document.getElementById("dist").innerHTML='<div style="padding:30px;text-align:center;color:var(--text3)">no real logits loaded</div>'; document.getElementById("distro").innerHTML=""; return; }
|
|
199
|
+
let s=`<svg viewBox="0 0 ${DW} ${DH}" font-family="inherit">`;
|
|
200
|
+
for(let e=0;e>=PLO;e--){ const yy=dy(Math.pow(10,e)); s+=`<line x1="${DL}" y1="${yy}" x2="${DW-DR}" y2="${yy}" stroke="var(--grid)"/><text x="${DL-5}" y="${yy+3}" text-anchor="end" font-size="8" fill="var(--text3)">1e${e}</text>`; }
|
|
201
|
+
for(let e=0;Math.pow(10,e)<D.V;e++){ const xx=dx(Math.pow(10,e)); s+=`<line x1="${xx}" y1="${DT}" x2="${xx}" y2="${DH-DB}" stroke="var(--grid)"/><text x="${xx}" y="${DH-DB+12}" text-anchor="middle" font-size="8" fill="var(--text3)">${e===0?"1":"1e"+e}</text>`; }
|
|
202
|
+
s+=`<text x="${(DL+DW-DR)/2}" y="${DH-2}" text-anchor="middle" font-size="9" fill="var(--text2)">token rank (sorted by logit) →</text>`;
|
|
203
|
+
// W reach marker
|
|
204
|
+
let inWin=pr.inWin; s+=`<line x1="${dx(inWin)}" y1="${DT}" x2="${dx(inWin)}" y2="${DH-DB}" stroke="var(--warn)" stroke-width="1.6" stroke-dasharray="3 2"/>`;
|
|
205
|
+
s+=`<line x1="${dx(pr.keep)}" y1="${DT}" x2="${dx(pr.keep)}" y2="${DH-DB}" stroke="var(--pos)" stroke-width="1.2" stroke-dasharray="2 3" opacity=".7"/>`;
|
|
206
|
+
s+=`<path d="${linePath(pr.raw)}" fill="none" stroke="var(--gray)" stroke-width="2"/>`;
|
|
207
|
+
s+=`<path d="${linePath(pr.def)}" fill="none" stroke="var(--pos)" stroke-width="2"/>`;
|
|
208
|
+
s+=`<path d="${linePath(pr.hlg)}" fill="none" stroke="var(--accent)" stroke-width="2"/>`;
|
|
209
|
+
s+=`</svg>`; document.getElementById("dist").innerHTML=s;
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
function cfgJSON(){ return JSON.stringify({window:P.window,A:P.A,sM:P.sM,targetGap:P.targetGap,refGap:P.refGap,lw:Math.round(P.lw),xM:P.xM,yM:P.yM,xFloor:P.xFloor,yFloor:P.yFloor,p:P.p}); }
|
|
213
|
+
function render(){
|
|
214
|
+
for(const sl of ALL){ const el=document.getElementById("v_"+sl.k); if(!el)continue;
|
|
215
|
+
el.textContent = sl.k==="lw"?Math.round(P.lw).toLocaleString():(Number.isInteger(P[sl.k])?P[sl.k]:P[sl.k].toFixed(2)); }
|
|
216
|
+
const g=geom(); drawCurve(g);
|
|
217
|
+
const ro=[["γ",g.gamma.toFixed(2)],["out_scale",g.outScale.toFixed(1)],["tokens in W",D?probsAt(g).inWin:"—"],["x_ref",g.xRef.toFixed(2)]];
|
|
218
|
+
let pr=null; if(D){ pr=probsAt(g); drawDist(pr);
|
|
219
|
+
const dr=[["HLG top-1",(pr.hlg[0]*100).toFixed(1)+"%"],["raw top-1",(pr.raw[0]*100).toFixed(1)+"%"],["default keeps",pr.keep],["W reaches rank",pr.inWin]];
|
|
220
|
+
document.getElementById("distro").innerHTML=dr.map(([k,v])=>`<div class="ro"><div class="k">${k}</div><div class="val">${v}</div></div>`).join("");
|
|
221
|
+
}
|
|
222
|
+
// curve readouts (recompute inWin cheaply)
|
|
223
|
+
const ro2=[["γ",g.gamma.toFixed(2)],["out_scale",g.outScale.toFixed(1)],["tokens in W",pr?pr.inWin:"—"],["dist",D?`${D.tag} (${D.ent}b)`:"—"]];
|
|
224
|
+
document.getElementById("readouts").innerHTML=ro2.map(([k,v])=>`<div class="ro"><div class="k">${k}</div><div class="val" style="font-size:${String(v).length>8?11:14}px">${v}</div></div>`).join("");
|
|
225
|
+
document.getElementById("cfgField").value=cfgJSON();
|
|
226
|
+
}
|
|
227
|
+
function applyPreset(n){ Object.assign(P,PRESETS[n]); for(const sl of ALL){ const inp=document.getElementById("s_"+sl.k); if(inp) inp.value=sl.log?lwToS(P[sl.k]):P[sl.k]; } render(); }
|
|
228
|
+
function copyValues(){ const txt=cfgJSON(), ok=document.getElementById("copyOk"); const done=()=>{ok.textContent="Copied!";setTimeout(()=>ok.textContent="",1600);};
|
|
229
|
+
if(navigator.clipboard&&navigator.clipboard.writeText) navigator.clipboard.writeText(txt).then(done,()=>{fb(txt);done();}); else {fb(txt);done();} }
|
|
230
|
+
function fb(t){ const f=document.getElementById("cfgField"); f.focus(); f.select(); try{document.execCommand("copy");}catch(e){} }
|
|
231
|
+
|
|
232
|
+
buildGrid(); buildDistSel(); prep();
|
|
233
|
+
document.querySelectorAll(".presets button[data-preset]").forEach(b=>b.addEventListener("click",()=>applyPreset(b.dataset.preset)));
|
|
234
|
+
document.getElementById("copyBtn").addEventListener("click",copyValues);
|
|
235
|
+
document.getElementById("cfgField").addEventListener("click",e=>e.target.select());
|
|
236
|
+
render();
|
|
237
|
+
</script>
|
|
238
|
+
</body></html>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg viewBox="0 0 920 450" xmlns="http://www.w3.org/2000/svg" role="img" aria-labelledby="t d" font-family="ui-sans-serif,system-ui,sans-serif"><title id="t">HLG cliff resolution — two shapes</title><desc id="d">Fine junk% gradient through the target_gap cliff (a graded ramp, position shifts by vocab) and the W lower edge at high A (a sharp model-invariant edge near 7.5), three models.</desc><text x="460" y="30" text-anchor="middle" font-size="16.5" font-weight="700" fill="var(--text-primary,#1f2937)">Fine cliff resolution — the coarse grid jumped over two different shapes</text><text x="460" y="49" text-anchor="middle" font-size="11.5" fill="var(--text-secondary,#6b7280)">unit steps · mean canary junk% (K=5 seeds) · the transition the 8/12 and 5/10 jumps hid</text><text x="244" y="42" text-anchor="middle" font-size="14" font-weight="700" fill="var(--text-primary,#1f2937)">target_gap cliff — a graded ramp</text><text x="244" y="58" text-anchor="middle" font-size="10.5" fill="var(--text-secondary,#6b7280)">base (A=0.35, s_m=0.7, W=6) · position shifts by vocab</text><line x1="44" y1="380" x2="444" y2="380" stroke="var(--border,#e5e7eb)" stroke-opacity="0.6"/><text x="36" y="384" text-anchor="end" font-size="10" fill="var(--text-tertiary,#9ca3af)">0%</text><line x1="44" y1="291.17647058823525" x2="444" y2="291.17647058823525" stroke="var(--border,#e5e7eb)" stroke-opacity="0.6"/><text x="36" y="295.17647058823525" text-anchor="end" font-size="10" fill="var(--text-tertiary,#9ca3af)">10%</text><line x1="44" y1="202.35294117647058" x2="444" y2="202.35294117647058" stroke="var(--border,#e5e7eb)" stroke-opacity="0.6"/><text x="36" y="206.35294117647058" text-anchor="end" font-size="10" fill="var(--text-tertiary,#9ca3af)">20%</text><line x1="44" y1="113.52941176470588" x2="444" y2="113.52941176470588" stroke="var(--border,#e5e7eb)" stroke-opacity="0.6"/><text x="36" y="117.52941176470588" text-anchor="end" font-size="10" fill="var(--text-tertiary,#9ca3af)">30%</text><line x1="44" y1="371.11764705882354" x2="444" y2="371.11764705882354" stroke="var(--positive,#16a34a)" stroke-width="1.2" stroke-dasharray="5 3" stroke-opacity="0.8"/><text x="444" y="367.11764705882354" text-anchor="end" font-size="9.5" fill="var(--positive,#16a34a)">coherent <1%</text><line x1="44" y1="380" x2="44" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="44" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">7</text><line x1="110.66666666666666" y1="380" x2="110.66666666666666" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="110.66666666666666" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">8</text><line x1="177.33333333333331" y1="380" x2="177.33333333333331" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="177.33333333333331" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">9</text><line x1="244" y1="380" x2="244" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="244" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">10</text><line x1="310.66666666666663" y1="380" x2="310.66666666666663" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="310.66666666666663" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">11</text><line x1="377.33333333333337" y1="380" x2="377.33333333333337" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="377.33333333333337" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">12</text><line x1="444" y1="380" x2="444" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="444" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">13</text><text x="244" y="416" text-anchor="middle" font-size="11" fill="var(--text-secondary,#6b7280)">target_gap →</text><path d="M44.0 131.3 L110.7 104.6 L177.3 229.0 L244.0 371.1 L310.7 371.1 L377.3 380.0 L444.0 380.0" fill="none" stroke="#2563eb" stroke-width="2.5" stroke-opacity="0.9"/><circle cx="44" cy="131.29411764705884" r="3" fill="#2563eb"/><circle cx="110.66666666666666" cy="104.64705882352942" r="3" fill="#2563eb"/><circle cx="177.33333333333331" cy="229" r="3" fill="#2563eb"/><circle cx="244" cy="371.11764705882354" r="3" fill="#2563eb"/><circle cx="310.66666666666663" cy="371.11764705882354" r="3" fill="#2563eb"/><circle cx="377.33333333333337" cy="380" r="3" fill="#2563eb"/><circle cx="444" cy="380" r="3" fill="#2563eb"/><path d="M44.0 166.8 L110.7 229.0 L177.3 344.5 L244.0 371.1 L310.7 380.0 L377.3 380.0 L444.0 380.0" fill="none" stroke="#d97706" stroke-width="2.5" stroke-opacity="0.9"/><circle cx="44" cy="166.8235294117647" r="3" fill="#d97706"/><circle cx="110.66666666666666" cy="229" r="3" fill="#d97706"/><circle cx="177.33333333333331" cy="344.4705882352941" r="3" fill="#d97706"/><circle cx="244" cy="371.11764705882354" r="3" fill="#d97706"/><circle cx="310.66666666666663" cy="380" r="3" fill="#d97706"/><circle cx="377.33333333333337" cy="380" r="3" fill="#d97706"/><circle cx="444" cy="380" r="3" fill="#d97706"/><path d="M44.0 300.1 L110.7 371.1 L177.3 371.1 L244.0 362.2 L310.7 380.0 L377.3 380.0 L444.0 380.0" fill="none" stroke="#0891b2" stroke-width="2.5" stroke-opacity="0.9"/><circle cx="44" cy="300.05882352941177" r="3" fill="#0891b2"/><circle cx="110.66666666666666" cy="371.11764705882354" r="3" fill="#0891b2"/><circle cx="177.33333333333331" cy="371.11764705882354" r="3" fill="#0891b2"/><circle cx="244" cy="362.2352941176471" r="3" fill="#0891b2"/><circle cx="310.66666666666663" cy="380" r="3" fill="#0891b2"/><circle cx="377.33333333333337" cy="380" r="3" fill="#0891b2"/><circle cx="444" cy="380" r="3" fill="#0891b2"/><text x="704" y="42" text-anchor="middle" font-size="14" font-weight="700" fill="var(--text-primary,#1f2937)">W edge @ A=100 — a sharp cliff</text><text x="704" y="58" text-anchor="middle" font-size="10.5" fill="var(--text-secondary,#6b7280)">channel closes abruptly 7→8 in all three</text><line x1="504" y1="380" x2="904" y2="380" stroke="var(--border,#e5e7eb)" stroke-opacity="0.6"/><text x="496" y="384" text-anchor="end" font-size="10" fill="var(--text-tertiary,#9ca3af)">0%</text><line x1="504" y1="291.17647058823525" x2="904" y2="291.17647058823525" stroke="var(--border,#e5e7eb)" stroke-opacity="0.6"/><text x="496" y="295.17647058823525" text-anchor="end" font-size="10" fill="var(--text-tertiary,#9ca3af)">10%</text><line x1="504" y1="202.35294117647058" x2="904" y2="202.35294117647058" stroke="var(--border,#e5e7eb)" stroke-opacity="0.6"/><text x="496" y="206.35294117647058" text-anchor="end" font-size="10" fill="var(--text-tertiary,#9ca3af)">20%</text><line x1="504" y1="113.52941176470588" x2="904" y2="113.52941176470588" stroke="var(--border,#e5e7eb)" stroke-opacity="0.6"/><text x="496" y="117.52941176470588" text-anchor="end" font-size="10" fill="var(--text-tertiary,#9ca3af)">30%</text><line x1="504" y1="371.11764705882354" x2="904" y2="371.11764705882354" stroke="var(--positive,#16a34a)" stroke-width="1.2" stroke-dasharray="5 3" stroke-opacity="0.8"/><text x="904" y="367.11764705882354" text-anchor="end" font-size="9.5" fill="var(--positive,#16a34a)">coherent <1%</text><line x1="504" y1="380" x2="504" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="504" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">3</text><line x1="561.1428571428571" y1="380" x2="561.1428571428571" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="561.1428571428571" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">4</text><line x1="618.2857142857142" y1="380" x2="618.2857142857142" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="618.2857142857142" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">5</text><line x1="675.4285714285714" y1="380" x2="675.4285714285714" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="675.4285714285714" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">6</text><line x1="732.5714285714286" y1="380" x2="732.5714285714286" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="732.5714285714286" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">7</text><line x1="789.7142857142858" y1="380" x2="789.7142857142858" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="789.7142857142858" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">8</text><line x1="846.8571428571429" y1="380" x2="846.8571428571429" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="846.8571428571429" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">9</text><line x1="904" y1="380" x2="904" y2="384" stroke="var(--text-tertiary,#9ca3af)"/><text x="904" y="397" text-anchor="middle" font-size="10" fill="var(--text-secondary,#6b7280)">10</text><text x="704" y="416" text-anchor="middle" font-size="11" fill="var(--text-secondary,#6b7280)">window (W) →</text><path d="M504.0 166.8 L561.1 157.9 L618.3 202.4 L675.4 131.3 L732.6 237.9 L789.7 380.0 L846.9 380.0 L904.0 380.0" fill="none" stroke="#2563eb" stroke-width="2.5" stroke-opacity="0.9"/><circle cx="504" cy="166.8235294117647" r="3" fill="#2563eb"/><circle cx="561.1428571428571" cy="157.94117647058823" r="3" fill="#2563eb"/><circle cx="618.2857142857142" cy="202.35294117647058" r="3" fill="#2563eb"/><circle cx="675.4285714285714" cy="131.29411764705884" r="3" fill="#2563eb"/><circle cx="732.5714285714286" cy="237.88235294117646" r="3" fill="#2563eb"/><circle cx="789.7142857142858" cy="380" r="3" fill="#2563eb"/><circle cx="846.8571428571429" cy="380" r="3" fill="#2563eb"/><circle cx="904" cy="380" r="3" fill="#2563eb"/><path d="M504.0 149.1 L561.1 149.1 L618.3 166.8 L675.4 220.1 L732.6 264.5 L789.7 380.0 L846.9 380.0 L904.0 380.0" fill="none" stroke="#d97706" stroke-width="2.5" stroke-opacity="0.9"/><circle cx="504" cy="149.05882352941177" r="3" fill="#d97706"/><circle cx="561.1428571428571" cy="149.05882352941177" r="3" fill="#d97706"/><circle cx="618.2857142857142" cy="166.8235294117647" r="3" fill="#d97706"/><circle cx="675.4285714285714" cy="220.11764705882354" r="3" fill="#d97706"/><circle cx="732.5714285714286" cy="264.52941176470586" r="3" fill="#d97706"/><circle cx="789.7142857142858" cy="380" r="3" fill="#d97706"/><circle cx="846.8571428571429" cy="380" r="3" fill="#d97706"/><circle cx="904" cy="380" r="3" fill="#d97706"/><path d="M504.0 282.3 L561.1 282.3 L618.3 300.1 L675.4 344.5 L732.6 362.2 L789.7 380.0 L846.9 380.0 L904.0 380.0" fill="none" stroke="#0891b2" stroke-width="2.5" stroke-opacity="0.9"/><circle cx="504" cy="282.29411764705884" r="3" fill="#0891b2"/><circle cx="561.1428571428571" cy="282.29411764705884" r="3" fill="#0891b2"/><circle cx="618.2857142857142" cy="300.05882352941177" r="3" fill="#0891b2"/><circle cx="675.4285714285714" cy="344.4705882352941" r="3" fill="#0891b2"/><circle cx="732.5714285714286" cy="362.2352941176471" r="3" fill="#0891b2"/><circle cx="789.7142857142858" cy="380" r="3" fill="#0891b2"/><circle cx="846.8571428571429" cy="380" r="3" fill="#0891b2"/><circle cx="904" cy="380" r="3" fill="#0891b2"/><line x1="310" y1="436" x2="330" y2="436" stroke="#2563eb" stroke-width="2.5"/><circle cx="320" cy="436" r="3" fill="#2563eb"/><text x="336" y="440" font-size="11" fill="var(--text-secondary,#6b7280)">e4b</text><line x1="410" y1="436" x2="430" y2="436" stroke="#d97706" stroke-width="2.5"/><circle cx="420" cy="436" r="3" fill="#d97706"/><text x="436" y="440" font-size="11" fill="var(--text-secondary,#6b7280)">12B</text><line x1="510" y1="436" x2="530" y2="436" stroke="#0891b2" stroke-width="2.5"/><circle cx="520" cy="436" r="3" fill="#0891b2"/><text x="536" y="440" font-size="11" fill="var(--text-secondary,#6b7280)">CPM5</text></svg>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg viewBox="0 0 960 658" xmlns="http://www.w3.org/2000/svg" role="img" aria-labelledby="t d" font-family="ui-sans-serif,system-ui,sans-serif"><title id="t">HLG coherence geometry across three models</title><desc id="d">Cross-pair coherence grids for e4b, 12B and CPM5. The sharpness cluster (s_m×tg, A×tg) replicates across all three; the window axis (s_m×W, A×W) tracks vocab size — the two Gemmas agree, CPM5 diverges.</desc><text x="480" y="26" text-anchor="middle" font-size="17" font-weight="700" fill="var(--text-primary,#1f2937)">Does the geometry generalize? Cross-pair coherence across 3 models</text><text x="480" y="46" text-anchor="middle" font-size="12" fill="var(--text-secondary,#6b7280)">green = coherent · red ✗ = canary broke · each grid is 4×4 over the break-spanning ranges</text><text x="288" y="78" text-anchor="middle" font-size="13" font-weight="700" fill="var(--text-primary,#1f2937)">e4b</text><text x="288" y="93" text-anchor="middle" font-size="9.5" fill="var(--text-tertiary,#9ca3af)">Gemma · 262k</text><text x="518" y="78" text-anchor="middle" font-size="13" font-weight="700" fill="var(--text-primary,#1f2937)">12B</text><text x="518" y="93" text-anchor="middle" font-size="9.5" fill="var(--text-tertiary,#9ca3af)">Gemma · 262k</text><text x="748" y="78" text-anchor="middle" font-size="13" font-weight="700" fill="var(--text-primary,#1f2937)">CPM5</text><text x="748" y="93" text-anchor="middle" font-size="9.5" fill="var(--text-tertiary,#9ca3af)">Llama · ~73k</text><rect x="14" y="108" width="932" height="244" rx="8" fill="var(--positive,#16a34a)" fill-opacity="0.05" stroke="var(--positive,#16a34a)" stroke-opacity="0.35"/><text x="26" y="124" font-size="12" font-weight="700" fill="var(--positive,#16a34a)">Replicates across all 3 — the sharpness cluster</text><text x="150" y="180" text-anchor="end" font-size="12.5" font-weight="600" fill="var(--text-primary,#1f2937)">s_m × target_gap</text><rect x="262" y="146" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="281" y="146" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="300" y="146" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="146" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="262" y="165" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="177.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="165" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="300" y="165" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="165" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="262" y="184" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="196.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="184" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="289.75" y="196.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="300" y="184" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="184" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="262" y="203" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="215.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="203" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="289.75" y="215.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="300" y="203" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="203" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><text x="256" y="184" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)" transform="rotate(-90 256 184)">s_m →</text><text x="300" y="233" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)">tg →</text><rect x="492" y="146" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="511" y="146" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="530" y="146" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="146" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="492" y="165" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="177.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="165" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="530" y="165" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="165" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="492" y="184" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="196.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="184" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="519.75" y="196.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="530" y="184" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="184" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="492" y="203" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="215.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="203" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="519.75" y="215.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="530" y="203" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="203" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><text x="486" y="184" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)" transform="rotate(-90 486 184)">s_m →</text><text x="530" y="233" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)">tg →</text><rect x="722" y="146" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="741" y="146" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="760" y="146" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="146" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="722" y="165" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="741" y="165" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="760" y="165" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="165" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="722" y="184" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="730.75" y="196.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="741" y="184" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="749.75" y="196.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="760" y="184" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="184" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="722" y="203" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="730.75" y="215.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="741" y="203" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="749.75" y="215.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="760" y="203" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="203" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><text x="716" y="184" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)" transform="rotate(-90 716 184)">s_m →</text><text x="760" y="233" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)">tg →</text><text x="150" y="298" text-anchor="end" font-size="12.5" font-weight="600" fill="var(--text-primary,#1f2937)">A × target_gap</text><rect x="262" y="264" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="276.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="264" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="300" y="264" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="264" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="262" y="283" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="295.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="283" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="289.75" y="295.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="300" y="283" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="283" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="262" y="302" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="314.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="302" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="300" y="302" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="302" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="262" y="321" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="333.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="321" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="289.75" y="333.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="300" y="321" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="321" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><text x="256" y="302" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)" transform="rotate(-90 256 302)">A →</text><text x="300" y="351" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)">tg →</text><rect x="492" y="264" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="276.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="264" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="530" y="264" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="264" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="492" y="283" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="295.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="283" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="530" y="283" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="283" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="492" y="302" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="314.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="302" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="530" y="302" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="302" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="492" y="321" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="333.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="321" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="519.75" y="333.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="530" y="321" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="321" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><text x="486" y="302" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)" transform="rotate(-90 486 302)">A →</text><text x="530" y="351" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)">tg →</text><rect x="722" y="264" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="730.75" y="276.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="741" y="264" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="760" y="264" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="264" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="722" y="283" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="730.75" y="295.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="741" y="283" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="760" y="283" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="283" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="722" y="302" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="730.75" y="314.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="741" y="302" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="760" y="302" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="302" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="722" y="321" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="730.75" y="333.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="741" y="321" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="749.75" y="333.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="760" y="321" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="321" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><text x="716" y="302" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)" transform="rotate(-90 716 302)">A →</text><text x="760" y="351" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)">tg →</text><rect x="14" y="366" width="932" height="244" rx="8" fill="var(--accent,#2563eb)" fill-opacity="0.05" stroke="var(--accent,#2563eb)" stroke-opacity="0.35"/><text x="26" y="382" font-size="12" font-weight="700" fill="var(--accent,#2563eb)">Vocab-dependent — the window axis (Gemmas agree, CPM5 diverges)</text><text x="150" y="438" text-anchor="end" font-size="12.5" font-weight="600" fill="var(--text-primary,#1f2937)">s_m × W</text><rect x="262" y="404" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="416.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="404" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="300" y="404" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="404" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="262" y="423" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="435.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="423" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="300" y="423" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="423" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="262" y="442" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="454.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="442" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="289.75" y="454.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="300" y="442" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="442" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="262" y="461" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="473.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="461" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="289.75" y="473.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="300" y="461" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="461" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><text x="256" y="442" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)" transform="rotate(-90 256 442)">s_m →</text><text x="300" y="491" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)">W →</text><rect x="492" y="404" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="416.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="404" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="530" y="404" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="404" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="492" y="423" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="435.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="423" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="530" y="423" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="423" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="492" y="442" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="454.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="442" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="519.75" y="454.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="530" y="442" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="442" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="492" y="461" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="473.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="461" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="519.75" y="473.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="530" y="461" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="461" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><text x="486" y="442" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)" transform="rotate(-90 486 442)">s_m →</text><text x="530" y="491" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)">W →</text><rect x="722" y="404" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="741" y="404" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="760" y="404" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="404" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="722" y="423" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="741" y="423" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="760" y="423" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="423" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="722" y="442" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="741" y="442" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="760" y="442" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="442" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="722" y="461" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="741" y="461" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="760" y="461" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="461" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><text x="716" y="442" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)" transform="rotate(-90 716 442)">s_m →</text><text x="760" y="491" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)">W →</text><text x="150" y="556" text-anchor="end" font-size="12.5" font-weight="600" fill="var(--text-primary,#1f2937)">A × W</text><rect x="262" y="522" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="534.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="522" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="300" y="522" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="522" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="262" y="541" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="553.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="541" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="300" y="541" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="541" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="262" y="560" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="572.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="560" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="300" y="560" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="560" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="262" y="579" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="270.75" y="591.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="281" y="579" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="289.75" y="591.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="300" y="579" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="319" y="579" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><text x="256" y="560" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)" transform="rotate(-90 256 560)">A →</text><text x="300" y="609" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)">W →</text><rect x="492" y="522" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="534.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="522" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="530" y="522" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="522" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="492" y="541" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="553.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="541" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="530" y="541" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="541" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="492" y="560" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="572.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="560" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="519.75" y="572.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="530" y="560" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="560" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="492" y="579" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="500.75" y="591.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="511" y="579" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="519.75" y="591.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="530" y="579" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="549" y="579" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="557.75" y="591.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><text x="486" y="560" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)" transform="rotate(-90 486 560)">A →</text><text x="530" y="609" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)">W →</text><rect x="722" y="522" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="741" y="522" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="760" y="522" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="522" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="722" y="541" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="741" y="541" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="760" y="541" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="541" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="722" y="560" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="730.75" y="572.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="741" y="560" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="760" y="560" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="560" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="787.75" y="572.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="722" y="579" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="730.75" y="591.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="741" y="579" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="749.75" y="591.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><rect x="760" y="579" width="17.5" height="17.5" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><rect x="779" y="579" width="17.5" height="17.5" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="787.75" y="591.25" text-anchor="middle" font-size="10" fill="#b91c1c">✗</text><text x="716" y="560" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)" transform="rotate(-90 716 560)">A →</text><text x="760" y="609" text-anchor="middle" font-size="9" fill="var(--text-tertiary,#9ca3af)">W →</text><g transform="translate(26,644)"><rect x="0" y="-11" width="14" height="14" rx="2" fill="var(--positive,#16a34a)" fill-opacity="0.22" stroke="var(--positive,#16a34a)" stroke-opacity="0.4"/><text x="20" y="0" font-size="11" fill="var(--text-secondary,#6b7280)">coherent</text><rect x="100" y="-11" width="14" height="14" rx="2" fill="#ef4444" fill-opacity="0.34" stroke="#ef4444" stroke-opacity="0.4"/><text x="120" y="0" font-size="11" fill="var(--text-secondary,#6b7280)">canary broke</text><text x="240" y="0" font-size="11" font-style="italic" fill="var(--text-tertiary,#9ca3af)">Same red pattern across columns = the curve, not the model.</text></g></svg>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg viewBox="0 0 860 536" xmlns="http://www.w3.org/2000/svg" role="img" aria-labelledby="t d" font-family="ui-sans-serif,system-ui,sans-serif"><title id="t">HLG edge texture</title><desc id="d">Break-rate across the four transition zooms at K=20: the gate cliffs are soft probabilistic ramps, the L_W low wall is a hard threshold at gamma 0, the high wall is barely there.</desc><text x="430" y="26" text-anchor="middle" font-size="17" font-weight="700" fill="var(--text-primary,#1f2937)">Edge texture (K=20) — break-rate, not magnitude, is what slides</text><text x="46" y="58" font-size="14" font-weight="700" fill="var(--text-primary,#1f2937)">target_gap ramp</text><text x="414" y="58" text-anchor="end" font-size="11.5" font-weight="700" fill="#d97706">soft · probabilistic</text><line x1="46" y1="240" x2="414" y2="240" stroke="var(--grid,#eef2f7)"/><text x="40" y="243" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">0%</text><line x1="46" y1="200.5" x2="414" y2="200.5" stroke="var(--grid,#eef2f7)"/><text x="40" y="203.5" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">25%</text><line x1="46" y1="161" x2="414" y2="161" stroke="var(--grid,#eef2f7)"/><text x="40" y="164" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">50%</text><line x1="46" y1="121.5" x2="414" y2="121.5" stroke="var(--grid,#eef2f7)"/><text x="40" y="124.5" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">75%</text><line x1="46" y1="82" x2="414" y2="82" stroke="var(--grid,#eef2f7)"/><text x="40" y="85" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">100%</text><rect x="35.77777777777778" y="202.07999999999998" width="20.444444444444443" height="37.92" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="81.77777777777777" y="205.24" width="20.444444444444443" height="34.76" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="127.77777777777777" y="208.4" width="20.444444444444443" height="31.6" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="173.77777777777777" y="217.88" width="20.444444444444443" height="22.12" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="219.77777777777777" y="228.94" width="20.444444444444443" height="11.06" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="265.77777777777777" y="230.52" width="20.444444444444443" height="9.48" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="311.77777777777777" y="240" width="20.444444444444443" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="357.77777777777777" y="240" width="20.444444444444443" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="403.77777777777777" y="240" width="20.444444444444443" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><path d="M46.0 82.0 L92.0 82.0 L138.0 82.0 L184.0 105.7 L230.0 129.4 L276.0 161.0 L322.0 224.2 L368.0 224.2 L414.0 216.3" fill="none" stroke="#d97706" stroke-width="2.5"/><circle cx="46" cy="82" r="3" fill="#d97706"/><circle cx="92" cy="82" r="3" fill="#d97706"/><circle cx="138" cy="82" r="3" fill="#d97706"/><circle cx="184" cy="105.7" r="3" fill="#d97706"/><circle cx="230" cy="129.4" r="3" fill="#d97706"/><circle cx="276" cy="161" r="3" fill="#d97706"/><circle cx="322" cy="224.20000000000002" r="3" fill="#d97706"/><circle cx="368" cy="224.20000000000002" r="3" fill="#d97706"/><circle cx="414" cy="216.29999999999998" r="3" fill="#d97706"/><text x="46" y="255" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">7</text><text x="138" y="255" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">8</text><text x="230" y="255" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">9</text><text x="322" y="255" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">10</text><text x="414" y="255" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">11</text><text x="230" y="271" text-anchor="middle" font-size="10.5" fill="var(--text-secondary,#6b7280)">target_gap →</text><text x="476" y="58" font-size="14" font-weight="700" fill="var(--text-primary,#1f2937)">W channel-close (A=100)</text><text x="844" y="58" text-anchor="end" font-size="11.5" font-weight="700" fill="#d97706">soft · steeper</text><line x1="476" y1="240" x2="844" y2="240" stroke="var(--grid,#eef2f7)"/><text x="470" y="243" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">0%</text><line x1="476" y1="200.5" x2="844" y2="200.5" stroke="var(--grid,#eef2f7)"/><text x="470" y="203.5" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">25%</text><line x1="476" y1="161" x2="844" y2="161" stroke="var(--grid,#eef2f7)"/><text x="470" y="164" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">50%</text><line x1="476" y1="121.5" x2="844" y2="121.5" stroke="var(--grid,#eef2f7)"/><text x="470" y="124.5" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">75%</text><line x1="476" y1="82" x2="844" y2="82" stroke="var(--grid,#eef2f7)"/><text x="470" y="85" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">100%</text><rect x="465.77777777777777" y="214.72" width="20.444444444444443" height="25.28" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="527.1111111111112" y="225.78" width="20.444444444444443" height="14.219999999999999" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="588.4444444444445" y="230.52" width="20.444444444444443" height="9.48" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="619.1111111111112" y="232.1" width="20.444444444444443" height="7.9" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="649.7777777777778" y="232.1" width="20.444444444444443" height="7.9" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="680.4444444444446" y="238.42" width="20.444444444444443" height="1.58" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="711.1111111111111" y="240" width="20.444444444444443" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="772.4444444444446" y="240" width="20.444444444444443" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="833.7777777777778" y="240" width="20.444444444444443" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><path d="M476.0 97.8 L537.3 97.8 L598.7 161.0 L629.3 184.7 L660.0 208.4 L690.7 208.4 L721.3 224.2 L782.7 240.0 L844.0 240.0" fill="none" stroke="#d97706" stroke-width="2.5"/><circle cx="476" cy="97.8" r="3" fill="#d97706"/><circle cx="537.3333333333334" cy="97.8" r="3" fill="#d97706"/><circle cx="598.6666666666666" cy="161" r="3" fill="#d97706"/><circle cx="629.3333333333334" cy="184.7" r="3" fill="#d97706"/><circle cx="660" cy="208.4" r="3" fill="#d97706"/><circle cx="690.6666666666667" cy="208.4" r="3" fill="#d97706"/><circle cx="721.3333333333333" cy="224.20000000000002" r="3" fill="#d97706"/><circle cx="782.6666666666667" cy="240" r="3" fill="#d97706"/><circle cx="844" cy="240" r="3" fill="#d97706"/><text x="476" y="255" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">6</text><text x="598.6666666666666" y="255" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">7</text><text x="660" y="255" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">7.5</text><text x="721.3333333333333" y="255" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">8</text><text x="844" y="255" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">9</text><text x="660" y="271" text-anchor="middle" font-size="10.5" fill="var(--text-secondary,#6b7280)">window W →</text><text x="46" y="308" font-size="14" font-weight="700" fill="var(--text-primary,#1f2937)">L_W low wall (γ→0)</text><text x="414" y="308" text-anchor="end" font-size="11.5" font-weight="700" fill="#dc2626">HARD · at γ=0</text><line x1="46" y1="490" x2="414" y2="490" stroke="var(--grid,#eef2f7)"/><text x="40" y="493" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">0%</text><line x1="46" y1="450.5" x2="414" y2="450.5" stroke="var(--grid,#eef2f7)"/><text x="40" y="453.5" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">25%</text><line x1="46" y1="411" x2="414" y2="411" stroke="var(--grid,#eef2f7)"/><text x="40" y="414" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">50%</text><line x1="46" y1="371.5" x2="414" y2="371.5" stroke="var(--grid,#eef2f7)"/><text x="40" y="374.5" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">75%</text><line x1="46" y1="332" x2="414" y2="332" stroke="var(--grid,#eef2f7)"/><text x="40" y="335" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">100%</text><rect x="36.8" y="490" width="18.4" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="67.46666666666665" y="490" width="18.4" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="87.91111111111111" y="490" width="18.4" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="108.35555555555557" y="490" width="18.4" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="128.8" y="490" width="18.4" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="159.46666666666667" y="490" width="18.4" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="190.13333333333335" y="490" width="18.4" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="231.02222222222224" y="490" width="18.4" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="312.80000000000007" y="490" width="18.4" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="404.8" y="490" width="18.4" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><path d="M46.0 490.0 L76.7 490.0 L97.1 490.0 L117.6 490.0 L138.0 490.0 L168.7 490.0 L199.3 490.0 L240.2 490.0 L322.0 490.0 L414.0 490.0" fill="none" stroke="#dc2626" stroke-width="2.5"/><circle cx="46" cy="490" r="3" fill="#dc2626"/><circle cx="76.66666666666666" cy="490" r="3" fill="#dc2626"/><circle cx="97.11111111111111" cy="490" r="3" fill="#dc2626"/><circle cx="117.55555555555557" cy="490" r="3" fill="#dc2626"/><circle cx="138" cy="490" r="3" fill="#dc2626"/><circle cx="168.66666666666666" cy="490" r="3" fill="#dc2626"/><circle cx="199.33333333333334" cy="490" r="3" fill="#dc2626"/><circle cx="240.22222222222223" cy="490" r="3" fill="#dc2626"/><circle cx="322.00000000000006" cy="490" r="3" fill="#dc2626"/><circle cx="414" cy="490" r="3" fill="#dc2626"/><text x="46" y="505" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">0</text><text x="97.11111111111111" y="505" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">0.05</text><text x="138" y="505" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">0.09</text><text x="199.33333333333334" y="505" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">0.15</text><text x="322.00000000000006" y="505" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">0.27</text><text x="230" y="521" text-anchor="middle" font-size="10.5" fill="var(--text-secondary,#6b7280)">γ →</text><text x="46" y="324" font-size="9.5" fill="var(--text-tertiary,#9ca3af)"><tspan x="46" dy="0">every point γ≥0 is clean — the wall is the sign flip at γ<0, a</tspan><tspan x="46" dy="11">deterministic discontinuity just off the left edge</tspan></text><text x="476" y="308" font-size="14" font-weight="700" fill="var(--text-primary,#1f2937)">L_W high wall (γ→2.4)</text><text x="844" y="308" text-anchor="end" font-size="11.5" font-weight="700" fill="#16a34a">barely a wall</text><line x1="476" y1="490" x2="844" y2="490" stroke="var(--grid,#eef2f7)"/><text x="470" y="493" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">0%</text><line x1="476" y1="450.5" x2="844" y2="450.5" stroke="var(--grid,#eef2f7)"/><text x="470" y="453.5" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">25%</text><line x1="476" y1="411" x2="844" y2="411" stroke="var(--grid,#eef2f7)"/><text x="470" y="414" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">50%</text><line x1="476" y1="371.5" x2="844" y2="371.5" stroke="var(--grid,#eef2f7)"/><text x="470" y="374.5" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">75%</text><line x1="476" y1="332" x2="844" y2="332" stroke="var(--grid,#eef2f7)"/><text x="470" y="335" text-anchor="end" font-size="9" fill="var(--text-tertiary,#9ca3af)">100%</text><rect x="460.6666666666667" y="490" width="30.666666666666668" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="523.7523809523809" y="490" width="30.666666666666668" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="597.3523809523812" y="490" width="30.666666666666668" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="691.9809523809525" y="490" width="30.666666666666668" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="755.0666666666668" y="490" width="30.666666666666668" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><rect x="828.6666666666666" y="490" width="30.666666666666668" height="0" fill="var(--text-tertiary,#9ca3af)" opacity="0.28" rx="1"/><path d="M476.0 490.0 L539.1 482.1 L612.7 482.1 L707.3 474.2 L770.4 474.2 L844.0 466.3" fill="none" stroke="#16a34a" stroke-width="2.5"/><circle cx="476" cy="490" r="3" fill="#16a34a"/><circle cx="539.0857142857143" cy="482.1" r="3" fill="#16a34a"/><circle cx="612.6857142857145" cy="482.1" r="3" fill="#16a34a"/><circle cx="707.3142857142859" cy="474.20000000000005" r="3" fill="#16a34a"/><circle cx="770.4000000000002" cy="474.20000000000005" r="3" fill="#16a34a"/><circle cx="844" cy="466.29999999999995" r="3" fill="#16a34a"/><text x="476" y="505" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">2.11</text><text x="539.0857142857143" y="505" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">2.17</text><text x="612.6857142857145" y="505" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">2.24</text><text x="707.3142857142859" y="505" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">2.33</text><text x="770.4000000000002" y="505" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">2.39</text><text x="844" y="505" text-anchor="middle" font-size="9" fill="var(--text-secondary,#6b7280)">2.46</text><text x="660" y="521" text-anchor="middle" font-size="10.5" fill="var(--text-secondary,#6b7280)">γ →</text><text x="476" y="324" font-size="9.5" fill="var(--text-tertiary,#9ca3af)"><tspan x="476" dy="0">only 3/20 break even at γ=2.46 — the coarse 'REJECT' was a</tspan><tspan x="476" dy="11">1-of-2-seed artifact</tspan></text><text x="46" y="530" font-size="10.5" fill="var(--text-tertiary,#9ca3af)">line = % of 20 seeds that broke · faint bars = mean junk% · the cliffs are statistical edges (some seeds wander into junk), not hard thresholds</text></svg>
|