Repository navigation
Publish a dependency graph and tree for the Math Reference pages - #166
Conversation
mds records 40 mcs definitions as prerequisites, but mcs publishes no graph, so no tree can show how the mcs definitions depend on each other. Copy the shared builder and script (the lds copies), build dependency-graph.json before each render from the top-level pages, and add a Dependency Tree page under Math Reference. Only that page loads the script, since the chapters/ pages reuse some of the same ids. Closes #165 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019xfc9mnLpkrgpT23d9m5ee
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
The tree is drawn by a script in the browser, so the slides, PDF and Word outputs would show an empty box under text about hovering and clicking (review of #166). lds's all-notes tree is HTML only too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019xfc9mnLpkrgpT23d9m5ee
|
Addressed in e83304b:
Deferred: Posted by Claude Code (AI agent) --- not written by a human. Generated by Claude Code |
… gets a 404 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019xfc9mnLpkrgpT23d9m5ee
|
Claude finished review — View run I fetched PR 166 live just now. It is open, not a draft and not merged, and its head is VerdictReady for merge Structured Review Data (JSON){
"schema_version": "1.1",
"reviewer": "claude",
"commit_sha": "749d8c44bd8c1cbe0f09938bd9c014de33f19654",
"verdict": "CLEAN",
"findings": [],
"detailed_assessment": "The dependency-tree.qmd front matter now declares only html, matching the script loading, and CLAUDE.md documents the new graph files; the silent fetch catch in dependency-graph.js is a deliberate, non-blocking suggestion.",
"holistic_assessment": "Both blocking items from the prior round are resolved, scope remains limited to the dependency graph feature, and regression risk to existing chapters is low."
}Reviewed commit: 749d8c4 |
Built to branch |
|
Cross-harness review (agy Flash) on 749d8c4: VERDICT: CLEAN The dependency-graph builder and viewer are consistent with the navigation, Posted by Claude Code (AI agent) --- not written by a human. |
Requested by Ezra · project thread
Closes #165.
Why
mds already treats 40 mcs definitions as prerequisites (391 edges in its published
dependency-graph.json), but mcs publishes no graph of its own. Because of that, no tree can show how the mcs definitions depend on each other, and the cross-repo tree on lds leaves mcs out entirely. This PR is step 1 of the plan from Ezra's thread. Step 2 adds a combined mcs+mds tree to mds. Step 3 adds mcs to the lds all-notes tree, then a radial layout and grouping (lds#2298).What changed
tools/build_dependency_graph.pyanddependency-graph.js: copied unchanged from lds. The lds JavaScript has the guard from lds#1698 that the mds, pds and sds copies lack (lds#2412)._quarto-website.yml: a pre-render step buildsdependency-graph.jsonfrom the top-level pages, and the script and JSON are published as resources. A Dependency Tree entry is added at the end of Math Reference in both the navbar and the sidebar.dependency-tree.qmd: the tree page, HTML only (like lds's all-notes tree), since the tree is drawn in the browser. Only this page loads the script. Thechapters/pages reuse 105 of the same ids and share three page names (sets, relations, induction), so loading the script site-wide would draw per-div graphs on chapter pages that link to the wrong page..gitignore: ignores the generated JSON, as mds does.CLAUDE.md: names the new files in the layout list.Size
The diff is over the 300-line cap only because of
tools/build_dependency_graph.pyanddependency-graph.js(516 lines), which are byte-identical copies of the lds files. They are copied, not written here (mechanical, content-identical). The rest of the PR is about 40 lines.Scope
The graph covers only the Math Reference pages, because those are the pages the other sites link to. Graphing
chapters/needs the builder to handle several page directories, so that is a follow-up.Verification
quarto render dependency-tree.qmd --to htmlsucceeds. The rendered page loads the script once, and the theorem link resolves to./proof-writing.html#def-theorem.expressions-algorithms.html#def-algorithm.Generated by Claude Code