Skip to content

Forensic engine console: archival-exhibit identity for the plain engine view#29

Merged
dsmcewan merged 2 commits into
mainfrom
engine-console
Jun 30, 2026
Merged

Forensic engine console: archival-exhibit identity for the plain engine view#29
dsmcewan merged 2 commits into
mainfrom
engine-console

Conversation

@dsmcewan

Copy link
Copy Markdown
Owner

Enhances the demo's plain generic view (engine.html) — the bare findings list from Phase 4 — into a polished, read-only forensic engine console, rendering live engine data in the archival-exhibit visual language. The curated Blanc lecture is untouched; no data/serialization changes (no drift).

  • engine.css (new, self-contained): archival-exhibit palette (paper #e6e8e1 / ink #18202c / pen #b0392b), mono transcript voice, scrolling body (decoupled from the lecture's full-screen style.css), responsive, :focus-visible, prefers-reduced-motion.
  • engine.html: masthead + corpus picker + case-stamp summary (message/finding/elevated/low counts) + findings + narration panel. Keeps the generic-view contract (no slideshow/Blanc/chat).
  • engine.js: each finding renders as an exhibit card — confidence badge, layer chips, seqs, per-signal evidence (layer · kind · detail · anchor · thread). Elevated findings get a data-driven convergence cue generated from the finding's real layers/signals (binds the ≥2 corroborating layers to the anchor). All corpus text escaped; reads only the generic core (never curated).
  • Contract test extended (test_engine_page_contract.py): kept all existing assertions, added engine.css-linked / badge / convergence-element checks.
  • Review: Spec ✅, quality approved; XSS escaping verified clean. One Important finding fixed — a per-card resize listener leak replaced with a single debounced module-level handler.

264 tests pass; ruff/mypy clean; demo-data-drift clean; lecture contract (test_web_ui_contract.py) still green.

🤖 Generated with Claude Code

dsmcewan and others added 2 commits June 30, 2026 11:51
Rewrites the plain engine view as a polished read-only console that
renders live corpus data in an archival-exhibit style (paper/ink/pen
palette, mono typeface, stamp badges, box-shadow cards). Elevated
findings get a data-driven convergence trace — a vertical spine with
layer nodes and an anchor diamond, generated from f.signals in real
time; no hardcoded content. Low-confidence findings render in muted
chip/badge style. Body scrolls (no overflow:hidden). engine.css is
fully self-contained; style.css is untouched.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01S6sBnLRAKeX1vEQXecJB7g
…er; drop escapeHtml on className

Fix 1: window resize listeners were registered once per elevated finding card
and never removed, so switching corpora accumulated detached-DOM listeners.
Replace with a single debounced (120 ms) module-level handler that queries
all .finding.elevated.tracing cards from the live DOM on each resize.

Fix 2: escapeHtml() was applied to f.confidence before assigning it to
li.className. The browser never HTML-parses a className, so this was a
cosmetic misuse. Assign the raw (controlled) value directly. All innerHTML
usages of f.confidence retain escapeHtml.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01S6sBnLRAKeX1vEQXecJB7g
@dsmcewan
dsmcewan merged commit 99aa91b into main Jun 30, 2026
6 checks passed
@dsmcewan
dsmcewan deleted the engine-console branch June 30, 2026 16:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant