Skip to content

Wiki: interactive architecture map across products - #118

Open
SylonZero wants to merge 3 commits into
masterfrom
cursor/wiki-architecture-map-cd88
Open

SylonZero wants to merge 3 commits into
masterfrom
cursor/wiki-architecture-map-cd88

Conversation

@SylonZero

Copy link
Copy Markdown
Owner

Summary

Adds an Architecture map to the Product Wiki (/wiki/<product>?view=map). It draws assets and their recorded dependencies for one product or for every product the reader can see. Selecting an asset opens a panel with its health, version, owners, and its current specs, plans, issues, and decisions. A trace control follows Direct, Upstream (what it relies on, transitively), or Downstream (what relies on it, with owners) connections.

  • Layout: layer columns. "All products" stacks one band per product over the same columns, so cross-product dependencies read clearly. "Layers only" drops the bands. Layout is deterministic, with no stored positions and the same "derived, not drawn" rule as the Asset Atlas.
  • Exploration: find (Enter selects), Health / Activity / Debt color lenses, fit-to-width zoom, hop badges on traced nodes, hover highlighting, and double-click to open the asset page.
  • Click-through: panel links go to wiki readers, the asset page, and the operational asset page. Assets in other products link to their own product's wiki.
  • Shareable state: focus, reach, scope, group, and lens live in the URL and survive Back and reload.
  • Entry points: wiki sidebar, the product overview's "Explore the architecture" heading, and "View on architecture map →" on each asset page.
  • Data: reuses getAssetInventory (same visibility rules). Only the wiki's own product contributes document titles and excerpts; bodies stay on the server.

Why not embed archify directly

archify is Apache-2.0 (with historical MIT grants), so it is license-compatible with this MIT project if its LICENSE and NOTICE are kept. Its bundled brand marks carry mixed licenses, including Vue's CC-BY-NC-SA, which matters only if the brand field is used. I tested it against real data before choosing:

  • It rendered the 15-asset demo workspace once component sizes were set explicitly.
  • Its layout gate fails closed at realistic sizes: 25 assets with 30 edges produced 26 clean-flow/edge-through-node errors, and 60 with 90 produced 337. Archify expects an agent to author layout and repair it in correction rounds, and its README lists general-purpose auto-layout as out of scope. A data-derived map would break whenever someone records a new dependency.
  • It is a CLI, not a library (private package, about 18 MB), and writes about 850 KB of self-contained HTML per render. Its IR has no per-node link field, so click-through would require injecting script into an iframe.

The map instead borrows archify's best interaction ideas (focus with upstream/downstream reach, a node finder, URL-kept views, a per-node detail panel) on top of a native, deterministic layout.

Archify render of the demo workspace (15 assets)

Screenshots

Single-product map fitted to width

All products: product bands with an upstream trace from Web Application

Cross-product upstream trace from Mobile BFF

Walkthrough (6× speed):

wiki-architecture-map-demo-6x.mp4

Testing

  • pnpm test: 643 passing, including the new tests/lib/wiki/map.test.ts. It covers reach depth through cycles, edge selection by direction, layout determinism and taxonomy order, non-overlapping product bands, cross-product data, no body leakage, and visibility.
  • pnpm typecheck and pnpm build pass. pnpm lint reports 0 errors.
  • Manual browser runs against the demo seed covered every control. They caught one bug, which is now fixed: Back from a document lost the selection, because initial state came from a cached server payload. It now reads from the live URL.

To show artifacts inline, enable in settings.

Open in Web Open in Cursor 

cursoragent and others added 3 commits October 29, 2026 05:20
Assets and dependency edges across every visible product, with reach tracing
(direct, upstream, downstream), find, color lenses, shareable URL state, and a
detail panel linking to each asset's wiki page and documents.

Co-authored-by: sai <sai@mindstaq.com>
…m, and restore state from the URL

Product grouping no longer stacks a product's internal edges as arcs on one
column, the map fits the reading width by default, and Back/reload restore the
selected asset, trace, and scope from the live URL rather than cached props.

Co-authored-by: sai <sai@mindstaq.com>

This branch has not been deployed

No deployments
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.

2 participants