Skip to content

UI/UX pass: routes, /about FFT, playground polish, dead-code cleanup#9

Open
shitijkarsolia wants to merge 6 commits into
mainfrom
ui/cleanup-and-fft-interactive
Open

UI/UX pass: routes, /about FFT, playground polish, dead-code cleanup#9
shitijkarsolia wants to merge 6 commits into
mainfrom
ui/cleanup-and-fft-interactive

Conversation

@shitijkarsolia
Copy link
Copy Markdown
Owner

Summary

End-to-end UI/UX pass on the website. No backend changes. Drives the project closer to the portfolio framing in PRODUCT.md: editorial system applied consistently across every page, the homepage demo actually demonstrates what its caption claims, /about earns its URL with a live FFT interactive, and the playground is honest about errors and unguarded actions.

Full audit and per-commit status lives in feedback.md at the repo root.

Changes

Routes & navigation

  • Removed /memories and /experiments (frontend pages only — backend API endpoints unchanged). Both were orphan routes nothing in the UI linked to. Sitemap, README route table, and docs/demo-script.md updated.
  • Skip-to-main link as the first child of <body>, id="main" on <main>. Tab once on any route to surface it.
  • Site footer with project name, dynamic copyright year, Source link to repo, author site link.

Editorial palette consistency

  • MemoryField recolored: memory nodes use --signal-amber, low-trust uses --muted-foreground, contradictions use --signal-red, edges and the new-node pulse ring use --signal-amber. Container background switched to the warm oklch(0.09 0.012 75) already used by the empty state.
  • SITE_AUTHOR.name → "Shitij Mathur" (real name). Cascades to the footer, the JSON-LD Person, OG/Twitter creator, and the <html> author tag.

/about rebuilt around an FFT interactive

  • Trimmed the redundant "What is HRR?" prose, the four operations cards, and the duplicate comparison table.
  • New centerpiece: components/explainer/fft-binding.tsx — a live interactive that runs the actual fft → complex multiply → ifft pipeline from lib/hrr/fft.ts on every keystroke. Two text inputs drive r and v in time domain, |R| and |V| magnitude spectra, |R ⊙ V| product, and bind(r, v) after the IFFT. Same code path the production engine uses for every memory in the playground.

Hero demo honesty (Tier 3 #23)

  • HeroDemo now encodes both clauses of the example sentence. Two triples sharing the Sarah subject decompose side-by-side; six bind strips render grouped by fact (the two r_s ⊛ Sarah strips are visually identical on purpose — same role + same value → same vector); the combined trace double-weights the subject hash to honor the math; probe recovers Sarah + login flow. Actually demonstrates the "many facts in one trace" claim.

Playground polish (Tier 2 batch: #7, #9, #10, #11, #12)

  • E (entity overlap) chip added to RecallChallenge result cards so the chip row matches the advertised hybrid formula 0.4·H + 0.3·K + 0.15·T + 0.15·E.
  • Status badges differentiated by semantic: outdated / stale / superseded--muted-foreground (passive); dubious / low trust--signal-red (concern). Two groups now scan as different categories at a glance.
  • Distortion lab Reset wrapped in a confirm Dialog naming the exact count of memories about to be wiped; trigger disables when the field is already empty.
  • Error UI added to RecallChallenge, RecallDuel, and all three DistortionLab mutations (noise, contradiction, reset). onError surfaces a dismissable inline block mirroring the homepage pattern; onMutate clears any previous error so the UI never stacks them.

Dead code & data hygiene (Tier 3 #18, #19)

  • Deleted three unused components: InteractiveExplainer (semantic duplicate of the homepage AlgebraSection), MetricCard, DemoScriptModal.
  • Moved 28 hardcoded EXTRA_SEED facts out of components/playground/hero-section.tsx into lib/demo-data.ts next to DEMO_FACTS.

Tested

  • npx tsc --noEmit — clean (after clearing the stale .next/dev/types/ validator artifacts that referenced the deleted route files).

  • npm run lint — 21 errors. All pre-existing, all in code this PR did not modify:

    • 20 in components/playground/memory-field.tsx's NodeTooltip (react-hooks/refs against the SVG-letterbox tooltip math, which intentionally reads containerRef.current during render).
    • 1 in lib/hrr/hrr.ts:94 (prefer-const on u2 in gaussianNoise).

    main was at 22 before this branch; deleting app/memories/page.tsx removed a setState-in-effect violation. Net: −1 lint error, 0 new errors introduced.

Out of scope

  • Backend code is untouched throughout.
  • Tier 2 fix: 22 audit findings (8 Critical, 4 High, 10 Medium) #8 (MemoryField as instrument — focusable nodes, click-to-pin tooltip) is parked at the author's request and won't be revisited in this PR or future recommendations.
  • Several small Tier 2 / Tier 3 polish items remain open and are listed in the "Next up" section of feedback.md. None are blockers.

Commits

Subject
0089488 drop unused routes, palette pass on field, footer, FFT interactive on /about
db9f44e docs(feedback): mark tier 1 items shipped, stale routes, add next-up batch
2c0d309 real-name author + prune stale feedback
e9e83fb ui(playground): polish batch — skip link, E chip, badge semantics, reset confirm, error UI
14b97c2 ui(hero): encode both clauses · delete InteractiveExplainer
44a1caa ui: cleanup pass — delete unused components, move EXTRA_SEED to demo-data

…e on /about

Apply accepted UI/UX feedback (full audit in feedback.md):

- Remove /memories and /experiments routes (not showcased, not needed).
  Drop them from the sitemap, README route table, and demo-script.
  Backend /memories/* API endpoints are unchanged — still consumed by
  TeachPanel, EncodeBlock, RecallBlock, TrustBlock, and the playground
  hero seed.
- Recolor MemoryField + legend to the editorial signal palette: memory
  nodes use --signal-amber, low-trust uses --muted-foreground,
  contradictions use --signal-red, edges and the new-node pulse ring use
  --signal-amber. Container background switched to the warm oklch already
  used by the empty state.
- Add SiteFooter (project name, dynamic copyright year, Source link to
  the repo, author-name link). Mounted after <main>.
- /about: drop redundant 'What is holographic memory?' prose, the four
  'HRR operations' cards, and the duplicate comparison table. Replace
  with FftBinding — a live interactive that runs fft → complex multiply
  → ifft from lib/hrr/fft.ts on every keystroke. Two text inputs drive
  r and v in the time domain, |R| and |V| magnitude spectra, |R⊙V|
  product, and bind(r,v) after the IFFT. Same code path the production
  engine uses for every memory.

Verification: tsc --noEmit clean. Lint: -1 versus main (deleting
app/memories/page.tsx removed a setState-in-effect violation); the
remaining 21 errors are pre-existing in memory-field's NodeTooltip and
lib/hrr/hrr.ts's gaussianNoise — neither modified on this branch.
…batch

Tier 1 #1#5 marked ✅ in place. Items made stale by the route deletion (Tier 2 #15, Tier 3 #20) marked ⊘. Tier 2 #16 re-targeted from /memories+/experiments to /playground.

Adds a Next-up section recommending a playground-polish batch (Tier 2 #7, #9, #10, #11, #12) totalling ~half a day, with #8 (MemoryField as instrument) as the single-feature alternative.
- lib/seo.ts: SITE_AUTHOR.name 'Shitij Karsolia' → 'Shitij Mathur'.
  Cascades to the footer, the JSON-LD Person, OG/Twitter creator and
  publisher fields, and the <html> author tag. URL stays the GitHub
  handle.
- feedback.md: drop the entries the route deletion made stale (Tier 2
  #15, Tier 3 #20), drop the now-redundant 'Suggested order of
  operations' section (the live forward plan lives in 'Next up'), and
  trim the 'Things to consider cutting' bullets that referred to the
  deleted /about table and /memories selects. Status summary table
  loses its 'Stale' column accordingly.
…set confirm, error UI

Tier 2 #7, #9, #10, #11, #12 from feedback.md.

- #7 (skip link): app/layout.tsx renders a sr-only focus:not-sr-only
  link as the first child of <body>; <main> carries id='main'.
- #9 (E chip): RecallChallenge result cards now show the entity-overlap
  component alongside H/K/T, matching the hybrid formula advertised
  above the picker.
- #10 (badge semantics): outdated/stale/superseded re-tinted to
  --muted-foreground (passive); dubious/low-trust re-tinted to
  --signal-red (concern). The two groups now scan as different
  categories.
- #11 (reset confirm): DistortionLab 'Clear All' wraps in the shadcn
  Dialog primitive. Confirm modal names the count being wiped; Cancel /
  'Clear all memories' in the footer. Trigger also disables when the
  field is already empty.
- #12 (error UI): RecallChallenge, RecallDuel, and all three
  DistortionLab mutations (noise, contradiction, reset) gained onError
  handlers with inline dismissable error blocks that mirror the homepage
  pattern. onMutate clears any previous error so the UI never stacks.

feedback.md: items marked done in place; Status summary moved them to
the Done column; Next-up section rewritten with Option A (#8 MemoryField
as instrument) and Option B (#18+#19+#23 cleanup) as the next moves.

Verification: tsc --noEmit clean. Lint count unchanged at 21 (same
pre-existing errors in memory-field's NodeTooltip and hrr.ts's
gaussianNoise); zero new errors from this batch.
Tier 3 #23 (full) and Tier 3 #18 (partial — InteractiveExplainer half)
from feedback.md.

- HeroDemo (#23): the example sentence has two clauses, but the figure
  only encoded the first. Now renders two triples sharing the 'Sarah'
  subject. Decompose section shows fact 1 / fact 2 blocks; bind section
  renders six strips grouped by fact (the two r_s ⊛ Sarah strips are
  visually identical on purpose — same role + same value → same vector,
  the determinism property). The combined trace double-weights the
  subject hash since bind(SUBJECT, Sarah) sums twice when both facts
  enter the same vector. Probe recovers Sarah + login flow, which
  actually demonstrates the 'many facts in one trace' claim the page
  keeps making.
- InteractiveExplainer (#18 partial): file deleted, import + render
  dropped from playground/page.tsx. The homepage AlgebraSection is now
  the single explainer for bind / superpose / unbind on the site.
  MetricCard and DemoScriptModal still ship unused; left for a later
  cleanup.

feedback.md: #23 marked done in place; #18 marked partial; Status
summary moved them; Option B in 'Next up' trimmed to the remaining
cleanup items.

Verification: tsc --noEmit clean. Lint count unchanged at 21 (same
pre-existing errors in memory-field's NodeTooltip and hrr.ts's
gaussianNoise); zero new errors from this commit.
…data

Tier 3 #18 (rest) and Tier 3 #19 from feedback.md.

- #18 (rest): delete components/metric-card.tsx and
  components/playground/demo-script-modal.tsx. Neither was imported
  anywhere; both shipped in the bundle for nothing. DemoScriptModal in
  particular pointed at a 'Seed Demo' button that had been renamed to
  'Seed the lab' long ago, so it was unreachable from the current UI.
- #19: move the 28 hardcoded EXTRA_SEED memory objects out of
  components/playground/hero-section.tsx and into lib/demo-data.ts next
  to DEMO_FACTS. Hero imports EXTRA_SEED rather than declaring it
  inline. Same data, same behavior; UI file is back to being about UI.

feedback.md: #18 marked fully done, #19 marked done; #16 updated to
note MetricCard was deleted; Status summary now has a 'Parked' column
with #8 (MemoryField as instrument) listed there at the author's
request. Next-up section rewritten as a flat list of small remaining
polish items, no longer recommends #8.

Verification: tsc --noEmit clean. Lint count unchanged at 21 (same
pre-existing errors in memory-field's NodeTooltip and hrr.ts's
gaussianNoise); zero new errors from this commit.
@vercel
Copy link
Copy Markdown

vercel Bot commented May 26, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
holomemory Ready Ready Preview, Comment May 26, 2026 9:30am

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