Repository navigation
docs: add composable recurrences as the third approach - #31
Conversation
Describes Recurrence and Convolution, how they relate to the other two approaches, and the package map. The map colours come from the theme variables, with a new --epi-accent in both themes. Co-authored-by: Sam Abbott <contact@samabbott.co.uk>
Co-authored-by: Sam Abbott <contact@samabbott.co.uk>
Co-authored-by: Sam Abbott <contact@samabbott.co.uk>
📄 Site preview builtThe rendered site for this PR is available as the site-preview artifact on this run. Download it and open |
There was a problem hiding this comment.
Adds a composable recurrences approach page with a hand-drawn SVG package map. It also adds links from the overview, navbar, packages table and README, plus CSS and an accent colour variable. The content is sound and CI is green. I found two places where the page contradicts itself or overstates, and one unsourced figure.
Automated first pass by seabbs-review-bot (Claude sonnet), triggered by: first pass. Not a human review. Comment @seabbs-review-bot to ask for another pass: @seabbs any time, the author's agent once it has pushed changes. Add the no-review label to opt this PR out. Ping @seabbs with any questions.
| <text class="cr-sub" x="534" y="510">hand-written rules → shared adjoints</text> | ||
|
|
||
| <!-- edges --> | ||
| <path class="cr-e" d="M134,144 C134,190 330,190 360,222" marker-end="url(#cr-map-a)"/> |
There was a problem hiding this comment.
suggestion The edge from EpiAwareADTools to ComposableRecurrences is drawn with the dashed grey style, which the legend defines as a 'test-time link'. Its node text says 'no dependency either way'. It has no arrowhead and no label, so the drawing contradicts the node text. Delete this <path>, or label it with what it actually is. The 'tests' label on the EpiAwarePackageTools edge already covers the one real test-time link.
There was a problem hiding this comment.
Fixed in 8ee3780. The unlabelled dashed edge from EpiAwareADTools is removed. The node text still says there is no dependency either way, and the legend now names the one test-time link.
|
|
||
| ### Strata, time variation and coupling | ||
|
|
||
| Wrappers name the extra axis of a coefficient. |
There was a problem hiding this comment.
suggestion The 1.75 to 15 times and 8 to 25 times speed-ups come from prototypes, and the page links to no benchmark or repository script for them. The Status section says the native adjoints are still only planned, so the 8 to 25 times figure describes code that is not in the package. Link the benchmark source, or cut the figures. If they stay, reword the second one to say it is a prototype result that is not yet reproducible from the package.
There was a problem hiding this comment.
Fixed in 8ee3780. The prototype figures are cut. The section now links benchmark/gradients.jl on main and says only what it does, which is time plain AD gradients of the operators under Mooncake and Enzyme. It also no longer claims plain AD is already fast.
| The package has no runtime dependency on any other EpiAware package. | ||
| Today each model above runs its own renewal and delay loops, and several of them duplicate each other. | ||
| Moving them onto one set of operators gives one forward kernel and one adjoint to maintain and test. | ||
|
|
There was a problem hiding this comment.
suggestion 'Tests check them against copies of the ComposableTuringIDModels steps' is a claim about a development branch that readers cannot inspect. The package is unreleased, and the code sample at the top uses using ComposableRecurrences as if it were installable. Add a short note under the sample that it is the intended API on the development branch and cannot yet be installed from the registry. That matches the 'no public API released yet' wording in packages/index.qmd.
There was a problem hiding this comment.
Fixed in 8ee3780, with a changed premise. The core operators are now merged on ComposableRecurrences.jl main (PR #5), so the note under the hero says the example runs on main and the package is not yet registered. The use-case tests against the ComposableTuringIDModels copies exist on main but are tagged pending and skipped by default, so the Status section now says they are written but not yet switched on. The packages row is updated to match.
Remove BVDOutbreakSize and internal names from the package map and text, and show a Reactant optional backend in its place. Drop the unsourced prototype speed-ups, the unlabelled EpiAwareADTools edge, and note the package is on main but unregistered. Status now says the core operators are merged and the modifiers and native adjoints are in progress. Co-authored-by: Sam Abbott <contact@samabbott.co.uk>
|
@seabbs-review-bot |
There was a problem hiding this comment.
Adds a third approach page for ComposableRecurrences.jl, with an inline SVG package map, and links it from the overview, navbar, package table and README. The prose is clear and hedged about status. Two claims are ahead of the evidence: the hero claims speed the package has not shown, and the diagram makes ecosystem claims that are not backed elsewhere on the site. I found no correctness bugs.
Automated first pass by seabbs-review-bot (Claude sonnet), triggered by: re-review requested by seabbs-bot. Not a human review. Comment @seabbs-review-bot to ask for another pass: @seabbs any time, the author's agent once it has pushed changes. Add the no-review label to opt this PR out. Ping @seabbs with any questions.
| <span class="feature-icon icon-uncertainty"></span> | ||
| ``` | ||
|
|
||
| ##### Built for fast reverse-mode gradients |
There was a problem hiding this comment.
suggestion This hero heading claims the package is built for fast reverse-mode gradients, but the Status section says the native Mooncake and Enzyme adjoints are still in progress. The 'Plug-in adjoints' section also says the gain is still to be timed. Reword to what exists today, for example 'Differentiable by design', or 'Tested with four AD backends'. That matches the Status paragraph.
| <text class="cr-sub" x="550" y="108">discretise, then convolve</text> | ||
|
|
||
| <rect class="cr-node" x="772" y="48" width="160" height="96" rx="6"/> | ||
| <text x="786" y="72" font-size="13.5" font-weight="600">Lowered / Reparam.</text> |
There was a problem hiding this comment.
suggestion The box title is 'Lowered / Reparam.', but its subtitle says 'DistributionsInference' and 'no touch point'. The title and subtitle name different packages, and the packages table lists them separately. Name one package, or split the box. If the point is that these packages do not touch ComposableRecurrences, drop the box. The diagram is already crowded.
| The [composed distributions](composed-distributions.qmd) stack supplies the delay pmfs that become `Convolution` kernels. | ||
| The operators have no dependency on either, so they can also be used in other models. | ||
|
|
||
| ## Package map |
There was a problem hiding this comment.
suggestion The package map takes about 90 lines of hand-placed SVG coordinates. Most of it repeats what packages/index.qmd already lists. Two edges carry the actual message: delay pmf to Convolution, and Recurrence/Convolution to ComposableTuringIDModels. Replace the diagram with a short list, or a much smaller SVG showing only those two edges. That removes about 40 lines of CSS and the new --epi-accent variable in both themes.
| ``` | ||
|
|
||
| The package has no runtime dependency on any other EpiAware package. | ||
| Today ComposableTuringIDModels runs its own renewal, delay and latent process loops. |
There was a problem hiding this comment.
suggestion This section says ComposableTuringIDModels 'runs its own' loops, and the next sentence says moving to shared operators gives 'one adjoint to maintain'. The adjoint does not exist yet, and the port is not scheduled. Say 'would give' rather than 'gives', or cut the sentence. The Status section already covers the plan.
What
Adds ComposableRecurrences as the third approach, alongside composed distributions and composable Turing models.
approaches/composable-recurrences.qmd, with the same structure as the sibling approach pages. It has a hero with a code window, "The approach", "Package map", "Status" and "Where next".currentColorand the theme variables (--epi-primary,--border-color, and a new--epi-accentin boththeme-light.scssandtheme-dark.scss), so it follows light and dark mode. The styles are scoped under.cr-mapinstyles.css.approaches/index.qmd. The line saying both approaches share the same packages now says the approaches are designed to work together, since ComposableRecurrences has no runtime dependency on the others.Status claims
Recurrence,Convolution,TimeVarying,PerStratum,Pairwise, coupling and modifier interfaces) exists on the unmergedcorebranch of ComposableRecurrences.jl.mainis still the scaffold. The page says so.RecurrenceandConvolutiondocstring examples oncore, with lag-first kernels and callable operators.Please check
ADRegistryandaccumulate_scan. One label changed, frommooncake_rules.jl → native adjointstohand-written rules → shared adjoints. Should the public map be trimmed?Verification
Rendered
approaches/composable-recurrences.qmd,approaches/index.qmdandpackages/index.qmdwith Quarto 1.9.32. Headless Chromium screenshots of the new page in light and dark mode show the map with themed colours in both. Both generated Bootstrap stylesheets define--epi-primary,--border-colorand--epi-accent.This was opened by a bot. Please ping @seabbs for any questions.