Repository navigation
T2 · Migrate SPC charts #182
Copy link
Copy link
Open
Labels
phase:F-webappWeb platform migration (P1-P5)Web platform migration (P1-P5)priority:P1release-critical — the version can't ship without itrelease-critical — the version can't ship without itsize:Mmedium — a day-ish, a few filesmedium — a day-ish, a few filestool:spcSPC appSPC apptool:webweb/ Next.js surfaceweb/ Next.js surfacetype:refactorrestructure, no behavior changerestructure, no behavior change
Milestone
Description
Summary
Migrate the SPC control charts (X̄-R, I-MR, c-chart with Western Electric / Nelson overlays, plus the Week-10 EWMA/CUSUM depth) from Streamlit to the Next.js app, consuming the API delivered in P3.
Mostly stateless compute→render. The rule-overlay rendering is the interesting part; the disturbance simulator needs a client-side state model.
Part of P4 · Tool migration. Needs P2 (web foundation) and P3 (API). Strangler fig: Streamlit keeps serving every tool not yet migrated.
Scope
- React view(s) under
web/app/app/, calling the P3 endpoints. - Client-side state only — session state lives in React, there is no server-side session.
- Plotly figures render via the existing framework-agnostic figure builders (
react-plotly.js); the chart layer is a host swap, not a rewrite. - Loading and error states for every API call — this is where API cold start becomes a UX concern rather than an availability one.
- Delete the corresponding Streamlit page in this same issue, once parity is verified.
Constraints
- Session-state sites to re-implement: 2 (
docs/research/frontend-migration.md§3.3). - Exact endpoint names bind at execution time against the API actually delivered in P3 — do not assume names from the plan doc.
- Do not touch
quality_coreor engine logic. Presentation + transport only. - Parity is measured on numbers, not layout: same input must produce identical results to the Streamlit page it replaces.
Definition of Done
- View live in the web app, wired to the P3 endpoints
- Parity verified against the Streamlit page on the same input — outputs identical
- Loading + error states implemented
- Streamlit page for this tool deleted; nav updated; remaining Streamlit tools still work
-
web-gateandgateboth green; zero diff to engines - SME verification
- Definition of Done (📌 Definition of Done — the contract (read before every issue) #43) honored
Refs: epic #107, docs/research/web-platform-migration.md §5.2, docs/research/frontend-migration.md §3.3
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
phase:F-webappWeb platform migration (P1-P5)Web platform migration (P1-P5)priority:P1release-critical — the version can't ship without itrelease-critical — the version can't ship without itsize:Mmedium — a day-ish, a few filesmedium — a day-ish, a few filestool:spcSPC appSPC apptool:webweb/ Next.js surfaceweb/ Next.js surfacetype:refactorrestructure, no behavior changerestructure, no behavior change
Activity