18 KiB
PLAN: Front-End-Grouped Architecture Atlas Tracing Producer/Consumer Binaries & Artifacts (PLAN #67)
Document ID: PLAN-FRONT-END-GROUPED-ARCHITECTURE-ATLAS-AND-RELEASE-SYNC
Status: ACTIVE (docs/plans/active/)
Target Ecosystem Version: v2.18.0 (Baseline: v2.17.0)
Target Repositories: hyperstitionstudio-core, encyclopedia-knowledge-graph
Web Route: https://hyperstitionstud.io/graph/docs/architecture-atlas.html (/graph/docs/architecture-atlas.html)
Author: m00t & Hermes Agent
Date: 2026-12-01
1. Objective & Engineering Constraints
Build a lightweight, deterministic Architecture Atlas (hyperstitionstud_io.publishing.architecture_atlas, CLI hs-arch-atlas) that traces every binary/script, intermediate/published artifact, and front-end tool across the 6-repository hyperstitionstud.io ecosystem (hyperstitionstudio-core, ingglish-hyperdope-gematria, technocapital-singularity-zoology, encyclopedia-knowledge-graph, haiperdohp-jemaytreeah, hyperdope-ci-build), explicitly modeling producer -> artifact -> consumer lineage (for example: hs-quant-harvest & hs-macro-harvest -> real-market-history.json & real-macro-indicators-latest.json -> quant/timeseries.py -> quant-timeseries.json -> hs-daily-brief -> daily-brief-latest.json & daily-brief-data.js -> /quant/ Panel 6 & /api/v1/tools/hs_generate_daily_portfolio_brief).
Four Hard Design Invariants
- Front-End Tool Grouping Without Severing Interconnections: Group diagrams by the front-end tool / surface they serve (
8tool-centered groupsG01.QUANT..G08.MCP_DEPLOY+1shared backbone overview), while preserving 100% of cross-group producer/consumer dependencies via typed Boundary Port Pills ([IN <- G04.ZOOLOGY: <artifact>]and[OUT -> G08.MCP_DEPLOY: <consumer>]) backed by clickable same-page lowercase hyphenated DOM anchors (#g01-quant..#g08-mcp-deploy, avoiding CSS selector dot-collision on.) and matching canonical node/edge IDs (binary:*,artifact:*,frontend:*,service:*,port:*). - Lightweight on Disk (
<= 85 KBraw,<= 16 KBBrotli-11): Render as a single self-contained inline-SVG HTML document (/workspace/encyclopedia-knowledge-graph/docs/architecture-atlas.html) plus an optional compact JSON graph index (architecture-atlas.json,<= 25 KB), avoiding multi-hundred-KB raster PNGs (285 KBeach) and duplicate embedded-font PDFs in Git. - Lightweight on Recompilation / Rerendering (
< 5 msno-op,< 50 msdirty rebuild,0Pillow/ReportLab raster work): Compute a deterministicSHA-256content digest over the introspected topology +CURRENT_VERSION(vX.Y.Z). With--if-changed(default in hooks/tests), rewrite disk artifacts only when the topology or version actually changes, eliminating spurious dirty Git diffs duringtest_core_suite.pyruns. - Automatic Release Synchronization (
0extra manual steps): Integrate intohs-sync-version(version_sync.py),push-all-to-git-libre-audio.sh,deploy/sync-vps-repos.sh(.br/.gzpre-compression), andtests/test_core_suite.py(coverage gate asserting 100% ofpyproject.toml[project.scripts]binaries anddeploy/Caddyfileroutes appear in the atlas).
2. Format Selection & Disk / Render Footprint Budget
| Candidate Format | Disk Footprint (Uncompressed) | Brotli-11 VPS Size | Re-render Cost | Ctrl+F Searchable & Clickable Cross-Links | Decision |
|---|---|---|---|---|---|
Inline-SVG Self-Contained HTML (architecture-atlas.html) + architecture-atlas.json |
~55–80 KB total (1 HTML + 1 JSON) |
~10–15 KB |
< 5 ms (--if-changed no-op) / < 50 ms rebuild (0 Pillow/ReportLab) |
Yes (Ctrl+F across all binary/artifact labels + clickable #g01-quant..#g08-mcp-deploy port links) |
SELECTED |
Per-group PNG suite (8 × 285 KB) |
~2.3 MB binary assets in Git |
~2.3 MB (incompressible) |
~2.5 s Pillow rasterization + noisy binary diffs |
No (0 searchable text, 0 clickable links) |
REJECTED |
| Compiled ReportLab PDF atlas | ~120–250 KB per rebuild |
~120–250 KB |
~600 ms + non-deterministic stream diffs |
Partial (#page=, poor interactive navigation) |
REJECTED |
- Visual Styling: Reuses the offline Group 3 Stealth Basalt inline-SVG/CSS aesthetic (
#020617void +40pxgrid,#0f172adouble-rect masking behind arrows, DejaVu Sans Mono stack with zero external Google Fonts, semantic stroke colors: Cyan#22d3eeFront-End Tools, Emerald#34d399Binaries/CLIs, Violet#a78bfaStored Artifacts/DBs, Amber#fbbf24Timers/Sync/Forge, Rose#fb7185Isolation/Security/CI Gates).
3. Front-End Tool Grouping Topology (G01.QUANT .. G08.MCP_DEPLOY, Zero Severed Edges)
The atlas (architecture-atlas.html) renders Section 0 (Master Cross-Tool Backbone) followed by 8 Front-End Tool Sub-Diagrams (G01.QUANT .. G08.MCP_DEPLOY). Cross-group edges never break: whenever an artifact produced in one group is consumed in another, the producing group emits a right-gutter Output Port Pill ([OUT -> G03.GRAPH: taxonomy/*.json] linking to #g03-graph) and the consuming group renders a matching left-gutter Input Port Pill ([IN <- G04.ZOOLOGY: taxonomy/*.json] linking back to #g04-zoology), both referencing the same canonical artifact ID (artifact:*). Using id="g01-quant" .. id="g08-mcp-deploy" for DOM/CSS anchors while displaying G01.QUANT .. G08.MCP_DEPLOY in diagram labels prevents CSS selector dot-parsing collisions.
Section 0: Master Cross-Tool Backbone & Release/Deploy Spine
- Traces the top-level 6-repo flow at a glance:
- Producers: LAN Host
ingglish-exegesis.timer(ingglish-exegesis-push) + VPSsystemdtimers (run-vps-data-production.sh,run-vps-archive-rotation.sh) + Developerpush-all-to-git-libre-audio.sh(hs-sync-version,hs-readme-sync,hs-deploy-scripts-sync). - Hub & Hydrator:
git.libre.audio->deploy/sync-vps-repos.sh->/var/www/hyperstitionstud.io/repos(tmpfs,.br/.gz,deploy/Caddyfile+hyperstition-mcp.service :8095).
- Producers: LAN Host
G01.QUANT (#g01-quant): /quant/ — Quantitative Time-Series, Macro & Bayesian Brief Workbench
- Binaries & Modules:
hs-quant-harvest(quant/collector.py)hs-macro-harvest(quant/macro.py)python3 -m hyperstitionstud_io.quant.timeseries(quant/timeseries.py)hs-daily-brief(quant/daily_brief.py)hs-ticker-card(quant/cards.py)hs-quant-voice-build(publishing/quant_voice.py)hs-pdf-build(publishing/pdf_compiler.py)
- Explicit Producer -> Artifact -> Consumer Trace (
hs-daily-briefexemplar):hs-quant-harvest-> producesingglish-aq-archive/data/financial-aq-harvest-latest.json&site/quant/real-market-history.json.hs-macro-harvest-> producesingglish-aq-archive/data/real-macro-indicators-latest.json.quant/timeseries.py-> consumesreal-market-history.json+[IN <- G05.ARCHIVE: 25..NN-dossier-news-*.md]+[IN <- G04.ZOOLOGY: quantitative-economic-anchors.json]-> producessite/quant/quant-timeseries.json&quant-timeseries-data.js.hs-daily-brief-> consumesreal-macro-indicators-latest.json,quant-timeseries.json, and prioringglish-aq-archive/data/daily-brief-state.json(plusReadOnlyIsolationGuardover[IN <- G04.ZOOLOGY: glossary-registry.json, encyclopedia-manifest.json]) -> producesingglish-aq-archive/data/daily-brief-state.json,site/quant/daily-brief-latest.json, andsite/quant/daily-brief-data.js-> consumed by/quant/index.html(Panel 6) and[OUT -> G08.MCP_DEPLOY: hs_generate_daily_portfolio_brief].hs-ticker-card-> consumesquant-timeseries.json+[IN <- G04.ZOOLOGY: assemblage-builds-tier-list.json]-> produces*-stats-card.{png,json}->[OUT -> G08.MCP_DEPLOY: /api/v1/tools/hs_generate_ticker_stats_card].hs-quant-voice-build-> consumessite/quant/quant-tutorials.js-> produces deploy-timesite/quant/audio/ep0X-sY.wav(gitignored, hydrated on VPS).
G02.CALC_CI (#g02-calc-ci): /calc/ & /ci/ — Multi-Cipher Workbench (haiperdohp-jemaytreeah) & 4-Gate CI
- Binaries & Scripts:
ci_provision_ingglish.py,tools/normalize_caps.py,tools/classify_candidates.py,tools/generate_db_json.py,integrate-upstream-and-ui.sh(hyperdope-ci-build),run_exegesis_and_push_fedora41.sh. - Artifacts:
[IN <- G05.ARCHIVE: 01..NN-*.md & node_modules/ingglish]->ci_provision_ingglish.pyproduces/ci/(db_ingglish_entries.txt,ci-audit-report.json,pr-payload.json,ONBOARDING-INGGLISH-AQ.{md,pdf}) and patcheshaiperdohp-jemaytreeah/db.txt->generate_db_json.pycompilesdb_lite.json(16ciphers) +db.json(82ciphers) +config.js-> consumed by/calc/index.htmland[OUT -> G07.PORTAL_LEARN: /calc/ Closeups].
G03.GRAPH (#g03-graph): /graph/ — Interactive Knowledge Graph Workbench & Plan Archives
- Binaries & Scripts:
hs-kg-build(graph/cli.py),build_encyclopedia_knowledge_graph.py,hs-archive-rotate(publishing/archive_rotator.py),hs-pdf-build. - Artifacts:
[IN <- G04.ZOOLOGY: taxonomy/*.json, encyclopedia-manifest.json]->build_encyclopedia_knowledge_graph.pyproducesencyclopedia-graph.{json,graphml,gexf},graph-data.js,encyclopedia.canvas,atlas-mode{1,2,3}.png-> consumed by/graph/index.htmland[OUT -> G08.MCP_DEPLOY: hs_query_knowledge_graph & hs-db-build]. - Plan/Manual Lineage:
hs-archive-rotaterotatesdocs/archive/PLAN-*.md&docs/plans/inactive/->completed-plans-archive.tar.gz+archive-manifest.json&inactive-plans-archive.tar.gz+inactive-archive-manifest.json->[OUT -> G08.MCP_DEPLOY: hs_inspect_documentation_and_manuals].
G04.ZOOLOGY (#g04-zoology): /zoology/ & /encyclopedia/ — Taxonomy, Glossary, ETI Tier List & 22-Volume PDFs
- Binaries & Scripts:
classify_technocapital_singularity.py,sources.py,hs-citations(ci/citation_sources.py),generate_aq_tier_list.py,build_wire_report_pdf.py. - Artifacts:
[IN <- G05.ARCHIVE: node_modules/ingglish & 65..69-dossier-*.md]-> producestaxonomy/*.json(glossary-registry.json,singularity-zoology-matrix.json,memetic-superclass-registry.json,quantitative-economic-anchors.json,assemblage-builds-tier-list.json,citations-ledger-*.json),encyclopedia/00..08/*.pdf(22PDFs),tier-list-*.{md,pdf,png},comprehensive-glossary.{md,pdf},proposal-*.{md,pdf}->[OUT -> G01.QUANT, G03.GRAPH, G08.MCP_DEPLOY].
G05.ARCHIVE (#g05-archive): /archive/ — Current-Events & Thematic Ingglish AQ Corpus + Fedora 41 Worker
- Binaries & Scripts:
collect_news_aq.py,synthesize_news_dossier_openrouter.py,evaluate_aq.mjs,manage_lecture_artifacts.py,packaging/build-fedora41-rpm.sh,/usr/bin/ingglish-exegesis-push(run_exegesis_and_push_fedora41.sh). - Artifacts:
news-aq-harvest-*.json->25..73+-dossier-news-YYYY-MM-DD.md&00-index-and-methodology.md+01-ingglish-aq-lexicon.md+65..69-dossier-*.md+ingglish-isopsephic-exegesis-*.fc41.noarch.rpm->[OUT -> G01.QUANT, G02.CALC_CI, G04.ZOOLOGY].
G06.ENG_MATH (#g06-eng-math): /engineering/ & /math/ — Live-Introspected Explication Hubs & Polyglot REPL
- Binaries & Modules:
hs-eng-docs(publishing/engineering_docs.py),hs-math-docs(publishing/math_docs.py),publishing/polyglot_sandbox.py. - Artifacts: Introspects
[IN <- G08.MCP_DEPLOY: pyproject.toml, mcp/tools.py, schemas/v1/]+[IN <- G01.QUANT / G03.GRAPH / G04.ZOOLOGY: ciphers, phonetics, quant, lenses, ipld]-> producessite/engineering/{index.html,*/index.html,engineering-manifest.json,engineering-manifest-data.js},site/math/{index.html,*/index.html,math-manifest.json,math-manifest-data.js}, wired withsite/assets/hs-guile-scheme-repl.js->[OUT -> G08.MCP_DEPLOY: hs_inspect_engineering_and_math_docs & hs_evaluate_polyglot_sandbox].
G07.PORTAL_LEARN (#g07-portal-learn): / (Portal Home), /learn/ & /donate/ — Showcase, Interactive Track & Repo READMEs
- Binaries & Modules:
hs-closeups-sync(publishing/closeups_sync.py),hs-readme-sync(publishing/readme_sync.py),hs-highlights(publishing/highlights.py). - Artifacts: Introspects UI states across
[IN <- G01.QUANT, G02.CALC_CI, G03.GRAPH, G06.ENG_MATH]-> producessite/assets/closeups/{quadrant-*.png,ui-elements-manifest.json}consumed bysite/index.html;hs-readme-syncmaintains all6rootREADME.mdfiles +.git/hooks/{pre-commit,commit-msg};site/learn/{index.html,learn-app.js}&site/donate/index.htmlbindschemas/v1/learn-progress-state.schema.json.
G08.MCP_DEPLOY (#g08-mcp-deploy): /mcp, /api/v1/* & /schemas/ — Stateless MCP/REST Server, SQLite Catalog & Release/Deploy Pipeline
- Binaries & Modules:
hs-mcp(mcp/{server,tools,resources,rest}.py),hs-db-build(db/sqlite_meta.py),hs-doctor(ci/doctor.py),hs-public-smoke(ci/public_regression.py),hs-sync-version(version_sync.py),hs-deploy-scripts-sync(ci/deploy_scripts_sync.py),deploy/{run-vps-data-production.sh,run-vps-archive-rotation.sh,sync-vps-repos.sh},push-all-to-git-libre-audio.sh. - Artifacts:
hs-db-buildindexes[IN <- G03.GRAPH, G04.ZOOLOGY, G05.ARCHIVE, G06.ENG_MATH, G07.PORTAL_LEARN]into.cache/hyperstition-catalog.db&.cache/api-telemetry.db-> served alongside[IN <- G01.QUANT: daily-brief-latest.json, quant-timeseries.json]over/mcp(20tools,14resources) &/api/v1/*(withETag304);hs-doctor+hs-public-smokemaintain.cache/internal-test-baseline-latest.json.
4. Architecture & Implementation Modules
- Create
src/hyperstitionstud_io/publishing/architecture_atlas.py(hs-arch-atlas):- Defines typed node & edge dataclasses:
AtlasNode(id, group_id, kind, label, repo, path_or_route, module_or_entry)wherekind in {"binary", "artifact", "frontend", "service", "port"},group_id in {"G01.QUANT", "G02.CALC_CI", "G03.GRAPH", "G04.ZOOLOGY", "G05.ARCHIVE", "G06.ENG_MATH", "G07.PORTAL_LEARN", "G08.MCP_DEPLOY"}, andiduses typed prefixes (binary:*,artifact:*,frontend:*,service:*,port:in:*,port:out:*).AtlasEdge(src_id, dst_id, verb, label)whereverb in {"produces", "consumes", "serves", "verifies", "syncs"}.
- Live Introspection + Coverage Verification: Reads
pyproject.toml([project.scripts]),mcp/tools.py(MCP_TOOLS_SCHEMA), anddeploy/Caddyfile(handle_pathroutes) at build time. Computestopology_sha256(hashlib.sha256(canonical_json(atlas_payload) + CURRENT_VERSION)). - Zero-Churn
--if-changedMode: Before writingarchitecture-atlas.htmlorarchitecture-atlas.json, checks an embedded<!-- HS-ATLAS-DIGEST: <sha256> v<version> -->marker in the existing HTML (andtopology_sha256in JSON). If identical, returns{"ok": True, "changed": False, "skipped_write": True}in< 5 mswith 0 disk writes. - Pure-Python Inline SVG Layout Engine (
_render_group_svg): Automatically computes vertical lane columns inside each group (Binaries/Scripts|Produced Artifacts|Consumers / Front-End Tool), places[IN <- GXX.TAG: ...]pills on the left gutter and[OUT -> GYY.TAG: ...]pills on the right gutter (linking via lowercase#gXX-taganchors), applies#0f172adouble-rect masking behind orthogonal/cubic arrows so arrows never cross text, and verifies0bounding-box overlaps.
- Defines typed node & edge dataclasses:
- Register CLI & Release Pipeline Hooks:
pyproject.toml: Addhs-arch-atlas = "hyperstitionstud_io.publishing.architecture_atlas:main".version_sync.py: Callbuild_architecture_atlas(if_changed=True)at the end ofsync_versions()so everyhs-sync-version --set/--auto-bumprelease automatically refreshes the atlas with the new version and any added/changed binaries/routes.push-all-to-git-libre-audio.sh&deploy/sync-vps-repos.sh: Runhs-arch-atlas --if-changedpre-push (push-all-to-git-libre-audio.sh), and letsync-vps-repos.sh's existing*.htmlpre-compression pass serve/graph/docs/architecture-atlas.htmlas Brotli-11 (~12 KBover the wire).publishing/readme_sync.py&publishing/engineering_docs.py(Unit E0/E5): Document the atlas link (/graph/docs/architecture-atlas.html) and update17->21CLI entrypoints if needed (notingpyproject.tomlalready has20hs-*scripts today; addinghs-arch-atlasbrings it to21).tests/test_core_suite.py: Asserths-arch-atlas --checkpasses (100%ofpyproject.toml[project.scripts]binaries,hs-daily-brief, and activeCaddyfilefront-end routes represented,0broken#g01-quant..#g08-mcp-deployport targets,0container host paths,architecture-atlas.html <= 100 KB, and--if-changedsecond run performs0writes).
5. Verification Plan (Once Implemented)
- Run
hs-arch-atlasand confirmarchitecture-atlas.html(<= 100 KB) andarchitecture-atlas.json(<= 30 KB) are generated cleanly in< 100 ms. - Immediately re-run
hs-arch-atlas --if-changedand verifychanged == Falseandskipped_write == True(< 10 ms,git statusclean). - Run
hs-arch-atlas --checkand confirmmissing_cli_binaries == [],missing_caddy_routes == [],broken_port_links == [], andhs-daily-brieftracesreal-market-history.json+real-macro-indicators-latest.json+quant-timeseries.json+daily-brief-state.json->daily-brief-latest.json+daily-brief-data.js->/quant/&/mcp. - Run
PYTHONPATH=/workspace/hyperstitionstudio-core/src python3 /workspace/hyperstitionstudio-core/tests/test_core_suite.py(ALL 7 TEST SUITES PASSED) anddeploy/test-first-deployment.sh(HTTP 200on/graph/docs/architecture-atlas.htmlwithbrpre-compression).