Skip to content

feat(docs): architecture-diagram-3d, interactive 3D code-architecture diagrams - #3

Merged
NeuralEmpowerment merged 4 commits into
mainfrom
feat/docs-architecture-diagram-3d
Oct 14, 2026
Merged

NeuralEmpowerment merged 4 commits into
mainfrom
feat/docs-architecture-diagram-3d

Conversation

@NeuralEmpowerment

Copy link
Copy Markdown
Contributor

What

A new procedural skill, skills/docs/architecture-diagram-3d, that teaches how to build an interactive, orbitable 3D diagram of a codebase as one HTML page.

Live example it was distilled from (five views of a knowledge vertical): https://claude.ai/artifact/HnENkkWr7qKV23mYB3tnVU

Files

  • skills/docs/architecture-diagram-3d/SKILL.md: procedural chassis (when to use, input, workflow, output, outcomes, dated recommendations, references).
  • assets/template.html: the full engine (three.js r128 UMD from cdnjs, hand-written orbit with drag / shift-drag pan / wheel / pinch, auto-orbit toggle, reset view, per-frame projected HTML labels scaled by distance, raycast picking, ResizeObserver, prefers-reduced-motion, phone layout, THREE-load fallback) plus one small worked example view. Adding a view is data only.
  • references/visual-grammar.md: floors are layers, walls are boundaries, edge colour is the kind of flow, dashed is reference or planned, pulse shape tells bytes from facts, status strip, glass columns for slices, the room view, and the five-view set.
  • references/data-schema.md: every field of a DIAGRAMS entry, units, camera, sizing guidance.
  • references/build-checklist.md: ground it in the code, check every path with git cat-file -e origin/main:<path>, keep private content out, node --check the extracted script, publish under the host's artifact rules.
  • README.md: listed in the Docs collection.
  • skills/docs/system-infographic/SKILL.md: one added non-trigger so the static poster and the interactive 3D explorable route apart.

Checks

  • node --check on the extracted template script: pass.
  • scripts/verify-install.sh: install proof passed, docs module now 4 skills in both harnesses.
  • npx skills add ./skills/docs --list discovers the skill.
  • No em dashes, no home paths or hostnames (docs/PII-HYGIENE.md grep).

Do not merge yet; opened for review.

…tecture diagram skill

A procedural skill distilled from a published five-view page of a
knowledge vertical: floors are layers, blocks name code paths checked
against main, translucent walls mark security boundaries, edge colour is
the kind of flow, pulses show direction, and status (built, partial,
planned, gap) comes from the tracker or the code.

Ships the engine as assets/template.html (one generic builder over a
DIAGRAMS array, one worked example view), with references for the
visual grammar, the data schema and a build checklist. Adds a
non-trigger to system-infographic so the two docs skills route apart,
and lists the skill in the README docs collection.
…n, keyboard, wall tones

Left-drag orbits; right-, middle- and shift-drag translate in screen
space with the point under the cursor held still; two-finger drag
translates and pinch zooms; arrows/WASD, R/F, PageUp/Down, +/-, 0/Home
on a focusable canvas with a focus ring; only a left click picks.
Walls take tone, op and dash for package and isolation boundaries, and
toned labels take the tone colour. Hint line and the Controls section
match. Checklist notes the wrapper to prepend for local opening.
… tells the truth about the wall

From a Codex review of the PR:
- Read the code at origin/main's SHA, not the working checkout, so unmerged
  work is never drawn as built; check paths at that SHA.
- The template sets window.DIAGRAMS so the checklist's console export works;
  the path loop now takes any extension and directories.
- Worked example: payload crosses the wall twice (the PUT, and the reader
  resolving a reference); planned reader edges are dashed.
- Block labels are focusable buttons (Enter/Space); Q/E orbit; wheel and
  keyboard zoom switch auto-orbit off; the legend is built from EDGE_TEXT
  and STATUS_TEXT.
- A syntax error leaves an empty stage, not the fallback message.
@NeuralEmpowerment

Copy link
Copy Markdown
Contributor Author

Codex review (codex exec, read-only) + fixes in c2c16db

Codex found:

  • BLOCKER: the console path export failed because DIAGRAMS is scoped inside the IIFE. The grep fallback truncated .tsx to .ts and skipped other extensions.
  • BLOCKER: the workflow read the working checkout but checked only path existence on main, so unmerged behaviour could be drawn as built.
  • BLOCKER: in the worked example, "bytes cross only here" never crossed the wall, while handler to blobs did cross it carrying bytes.
  • NITs: planned-reader edges were solid; block labels weren't keyboard-reachable and there was no keyboard orbit; wheel and keyboard zoom left auto-orbit on; the legend hardcoded four edge kinds; "a syntax error shows the fallback" was wrong.

Fixed in c2c16db (all of the above):

  • Step 1 reads code at origin/main's SHA (worktree or git show) and records it in the eyebrow. Paths are checked at that SHA.
  • The template sets window.DIAGRAMS. The checklist exports resolved where entries from the console and checks them in a loop that takes any extension and directories.
  • Example text now says payload crosses twice, both through the blob store (the PUT, and the reader resolving a reference). Planned edges are dashed.
  • Labels are role=button with tabindex, opened with Enter/Space. Q/E orbit. Zoom turns auto-orbit off. The legend is built from EDGE_TEXT and STATUS_TEXT. Docs are updated to match.

Left: none.

Checks: node --check on the extracted script passes and scripts/verify-install.sh passes (every module, Claude Code + Codex). Not re-walked in a browser after the engine edits; worth one visual pass before merge. Not merged; the operator merges.

@NeuralEmpowerment
NeuralEmpowerment merged commit 5e8de1d into main Oct 14, 2026
2 checks passed
@NeuralEmpowerment
NeuralEmpowerment deleted the feat/docs-architecture-diagram-3d branch October 16, 2026 15:17
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