The hybrid-systems-group tab for FRET, as a stand-alone Pluto notebook. Reads reachability/predicates.json and renders: - Plant-derived constants (T_c0, T_standby, etc.) - All operational deadbands with concretization - All safety limits as one-sided halfspaces with meanings - Mode invariants (inv1_holds, inv2_holds) as conjunctions - Per-mode entry/safe/exit/time tables - 2D projection of operating polytope (T_avg x n) - Reach-traceability table — what's covered, by which artifact - Edit-UX preview with sliders that don't actually write back Run with: cd app julia --project=. -e 'using Pkg; Pkg.instantiate()' # first time julia --project=. -e 'using Pluto; Pluto.run()' V2 will add write-back to predicates.json. V3 (the dream) is FRET-spec driven derivation of halfspaces from a structured vocabulary of physical bounds. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2.2 KiB
app — Predicate Explorer (Pluto.jl)
A local-server visual companion to reachability/predicates.json. Maps
the FRET-spec boolean predicates to their numerical halfspaces over the
10-state continuous vector, shows mode invariants as conjunctions of
named safety limits, and previews a UI for editing them.
v1: read-only. Sliders display in the edit panel but do not write back to the JSON. v2 will add live write-through. v3 (the dream) will derive halfspaces automatically from the FRET spec.
This is the FRET-adjacent piece — the "hybrid-systems group tab" we talked about. Stand-alone for now; integration into the upstream FRET UI is a later story.
Run
First time:
cd app
julia --project=. -e 'using Pkg; Pkg.instantiate()'
Subsequent:
julia --project=. -e 'using Pluto; Pluto.run()'
A browser window opens (default http://localhost:1234). Pick
predicate_explorer.jl from the file list. The notebook is reactive —
edit any cell, dependent cells re-run.
What you can do today (v1)
- Inspect every operational deadband, safety limit, mode invariant, and mode boundary.
- See the boolean ↔ continuous mapping for each predicate.
- View a 2D projection (T_avg × n) showing the operating polytope.
- Read the reach-status traceability table — which artifact has tried to discharge which obligation, with link.
- Move sliders to feel out the editing workflow.
What lands in v2
- Sliders write back to
predicates.jsonwith an "are you sure" gate. - Diff view: pending changes vs.\ the on-disk version.
- Re-run reach scripts in-place from the notebook.
What's the dream (v3)
- The FRET spec at
../fret-pipeline/pwr_hybrid_3.jsondeclares predicate names without numerical concretization. Could we use a structured ontology of physical bounds (fuel limits, trip setpoints, rate limits) plus the FRET text to derive the concretization? - Round-tripping changes back into the FRET model so the synthesis side stays consistent.
Caveats
- Pluto notebooks aren't great in version control — they're long files with cell UUIDs and order metadata. The notebook is committed because it's small and the cell order matters.
- Manifest.toml is gitignored; regenerate locally.