safety.viz v1.5.0
safety.viz v1.5.0
Two renderers join the gallery and one of them is not a chart. The hepatic tooling grows a third view and a companion module for trials that enrol participants who already have abnormal liver tests, the eDISH scatter gets back the direct manipulation and marginal detail deferred from the v1.3 port, and every lab renderer gains a shared participant drill-down — click a point in one chart and read that person's whole lab course underneath it.
See it move: the annotated v1.5.0 demo walks each new feature with short clips and try-it-yourself steps against the live gallery.
What's new
-
Participant Profile — a new chart-agnostic module (obot.roadmap#45, #98/#99, PR #105). Until now, drilling into a participant meant whatever detail panel a given renderer happened to have. This is one module they all share: a demographics header with R Ratio and a templated record link-out, a labs-over-time spaghetti with reference cut-lines, and a per-measure summary table whose sparklines expand into an inset chart — stepping worst-first through a multi-participant cohort. It mounts standalone against any chart that dispatches
participantsSelected, or opens in a right-hand rail beside the chart with an expand state (v2, PR #112, obot.roadmap#75). v2 also adds a second data domain: an adverse-event summary block and an AE timeline drawn on the labs chart's own study-day axis, so one panel reads a participant's labs and AEs against the same clock. Six renderers adopted it in this release: hep-explorer, shift-plot, outlier-explorer, delta-delta, histogram and qt-explorer. Try it live. -
Hepatic ALT Waterfall — a new renderer for the population eDISH cannot serve (obot.roadmap#43, #93, PR #97). In trials that enrol participants with elevated baseline ALT but normal baseline bilirubin — chronic liver disease, NASH, hepatitis — the ×ULN quadrants fill with people who were already there on day one. Figure 5 of Amirzadegan et al., Drug Safety 2025;48:443–453 answers that with a floating bar per participant, from their own baseline ALT to their maximum on-treatment ALT in absolute U/L, ranked by baseline so the two arms' highest baselines meet at the seam: blue for placebo, bronze for active drug, green for new-onset jaundice, flanked by a box-and-whisker summary per arm. Marked a prototype pending the open clinical judgement calls in design #43. Try it live.
-
Migration Sankey — a third view on the Hepatic Safety Explorer (
view: 'migration', same requirement, same PR). Figure 3 of the same paper: a Sankey mirrored about a pinned centre column of baseline eDISH quadrants, placebo flowing left and active drug right, Hy's Law at the top, ribbon thickness proportional to participant count on one shared scale so the arms compare directly. Ribbon colour comes from a fixed concern matrix rather than the direction of travel, so the geometry and the clinical reading can never disagree. The point of it is the hand-off: click a ribbon, take "Review these N in the composite plot", and the composite view opens with exactly those participants carried across and highlighted — the paper's Sankey→composite workflow, executable. Try it live. -
The eDISH scatter gets its hands back (obot.roadmap#88, PR #110). Four sets of features deferred from the v1.3 coordinated-core port land together. Drag the Hy's-Law cut-lines — quadrant percentages, corner labels and the summary table all move during the drag, and the value lands in the matching Reference Line box; a selected participant survives it. Marginal box plots and axis rugs follow the filtered view, not the whole cohort. The chart now says what it means: each quadrant carries its clinical reading in the summary table, legends carry each arm's n and percent, point-size encoding explains itself, and the standing "not validated for clinical use" caution sits under every view. Data handling is traceable: dropped records download as a CSV naming, per row, which mapped column failed, and below-LLOQ results are imputed by the original renderer's documented rules and reported.
-
Axis-limit inputs load pre-filled (#85, PR #108) with the data-driven defaults the chart is already using, instead of sitting empty until you type into them — so you can see the current limits, and nudge one without having to supply both.
Also in this release
hep-core: the 2,149-linehep-explorer.jssplits into an orchestrator plus per-view components over a shared hepatic domain layer (#91) — one per-participant reduction now feeds Figures 3, 4 and 5 alike. One deliberate behaviour change came out of it: the peak computation excluded the baseline record by study day rather than by identity, so the 24 of 318 demo participants with no day-0 record had their own baseline counted as on-treatment and could never show a below-baseline peak — the exact signal the waterfall is built on. Now excluded by identity.TRTAjoins the arm-column auto-detect candidates.- Requirement matrices now live in this repo (obot.roadmap#64, PR #111) rather than in
obot.agent, so a renderer's spec, tests and evidence sit in one checkout and move in one PR. (Assumes #111 merged.) - Closed-PR preview sites now redirect to the dev tier instead of 404-ing (#107).
dist/safety.viz-1.4.1/is restored to the bytes v1.4.1 actually shipped, and the e2e fixtures no longer pin a bundle version that the next bump strands (#109).
The gallery
Eleven renderers are now available, up from nine:
| Renderer | Factory | What it shows |
|---|---|---|
| Safety Histogram | histogram |
Distribution of a lab or vital-sign measure, with a normal-range overlay and a linked listing |
| Safety Outlier Explorer | outlierExplorer |
One line per participant over time against a population normal-range band |
| Safety Results Over Time | resultsOverTime |
Population distribution of a measure at each visit |
| Safety Shift Plot | shiftPlot |
Baseline versus comparison-visit values on a scatter with an identity line |
| Safety Delta-Delta | deltaDelta |
Paired change-from-baseline comparison of two measures |
| Hepatic Safety Explorer | hepExplorer |
eDISH / mDISH scatter with Hy's-Law quadrants, plus the composite (×Baseline) and migration views |
| Hepatic ALT Waterfall | hepWaterfall |
Baseline → maximum on-treatment ALT in absolute U/L, for abnormal-baseline trials |
| Participant Profile | participantProfile |
One participant's whole lab course — header, spaghetti, measure table — for any chart |
| Adverse Event Explorer | aeExplorer |
Hierarchical AE incidence by System Organ Class and preferred term |
| Adverse Event Timelines | aeTimelines |
Participant-level AE timelines by severity and onset |
| QT Safety Explorer | qtExplorer |
ECG QT/QTc central tendency, outlier scatter and categorical thresholds |
Vendor the new bundle at dist/safety.viz-1.5.0/ (IIFE + ESM, as before):
<script src="dist/safety.viz-1.5.0/safety.viz.js"></script>
<script>
SafetyViz.hepWaterfall(document.querySelector('#chart'), { data, settings });
SafetyViz.participantProfile(document.querySelector('#profile'), { data, settings });
</script>Two new factories join the library. Every existing renderer API is unchanged: hepExplorer gains the migration view through its documented view setting, and the six renderers that adopted the participant profile surface it in the v2 right-hand rail (expand for full width) — nothing existing was removed or renamed.
Known direction
Participant profile v2 landed inside this same release (#112): the rail is the shipped surfacing. If you are wiring the profile into your own chart, wire the participantsSelected event - that contract is unchanged and stable. The remaining #75 tail (narrow-rail layout, cohort-stepper refinements) follows in a minor.
Trust
As with every release, the new work traces to requirement-keyed tests with published evidence reports regenerated on the canonical Linux runner, plus reviewed requirement matrices and a JSDoc-complete API reference. This release is 981 unit and 219 browser tests green — hep-waterfall alone contributes 245 evidence records across 85 requirement rows, and the participant profile 288 across 55.
Requirements delivered: obot.roadmap#43 (abnormal-baseline DILI tools — migration Sankey + ALT waterfall), obot.roadmap#45 (participant profile — shared drill-down module), obot.roadmap#75 (participant profile v2 — rail + AE domain), obot.roadmap#88 (hepExplorer follow-up enhancements, partial — #54/#55 stay open), obot.roadmap#64 (requirement-matrix relocation).
This release was drafted by Claude Code using Opus 5 and reviewed by @jwildfire