Skip to content

feat(muix): implement probability-weibull - #12403

Merged
MarkusNeusinger merged 6 commits into
mainfrom
implementation/probability-weibull/muix
Oct 24, 2026
Merged

MarkusNeusinger merged 6 commits into
mainfrom
implementation/probability-weibull/muix

Conversation

@github-actions

Copy link
Copy Markdown
Contributor

Implementation: probability-weibull - javascript/muix

Implements the javascript/muix version of probability-weibull.

File: plots/probability-weibull/implementations/javascript/muix.tsx

Generation: adopted from 5b2bcb3e5e4dc5b3685a669c07cf3ab1b9918f69 (5b2bcb3) by gemini-4-argon; the model below runs repair

Model: opus

Parent Issue: #4668

Regeneration: previous quality 92 (forced: adopted from 5b2bcb3, fresh-generation review path)


🤖 impl-generate workflow

@github-actions github-actions Bot added the regen:forced Regeneration of an implementation that is live on main label Oct 24, 2026
@claude

claude Bot commented Oct 24, 2026

Copy link
Copy Markdown
Contributor

AI Review - Attempt 1/3

Image Description

Light render (plot-light.png): Warm off-white #FAF8F1 surface. Bold dark title "probability-weibull · javascript · muix · anyplot.ai" top-left, an inline legend top-right (dashed "Fit: β ≈ 2.09, η ≈ 453 kcycles", filled green "Failure", hollow green "Suspended (censored)"). Log x axis "Cycles to Failure (kcycles)" from ~65 to ~1150, linearized Weibull y axis "Cumulative Failure Probability (%)" with ticks 1% … 99% incl. 63.2%. 20 filled #009E73 failures and 4 hollow rings scatter around a black dashed fit line; a dotted 63.2% reference line carries a boxed callout "63.2% · η ≈ 453 kcycles" at the right, and the fit crosses it near 450. All text is readable; on the right of the x axis the labels "750 800 850 900" bunch closely.

Dark render (plot-dark.png): Warm near-black #1A1A17 surface. Title, legend text, axis titles and tick labels flip to light ink and read clearly; the grid is subtle grey, the fit line becomes light ink, the callout sits on an elevated dark box with light text. Data colours (filled and hollow #009E73) are identical to the light render. No dark-on-dark text.

Score: 85/100

Category Score Max
Visual Quality 29 30
Design Excellence 10 20
Spec Compliance 15 15
Data Quality 15 15
Code Quality 10 10
Library Mastery 6 10
Total 85 100

Visual Quality (29/30)

  • VQ-01: Text Legibility (8/8)
  • VQ-02: No Overlap (6/6)
  • VQ-03: Element Visibility (6/6)
  • VQ-04: Color Accessibility (2/2)
  • VQ-05: Layout & Canvas (3/4) - x tick labels bunch on the right of the log axis
  • VQ-06: Axis Labels & Title (2/2)
  • VQ-07: Palette Compliance (2/2)

Design Excellence (10/20)

  • DE-01: Aesthetic Sophistication (5/8) - custom header band with title left and compact legend right
  • DE-02: Visual Refinement (3/6) - distinct dash rhythms for fit vs reference line, page-colour marker outlines, elevated callout
  • DE-03: Data Storytelling (2/6) - data displayed, no hierarchy chosen beyond the Notes

Spec Compliance (15/15)

  • SC-01: Plot Type (5/5)
  • SC-02: Required Features (4/4)
  • SC-03: Data Mapping (3/3)
  • SC-04: Title & Legend (3/3)

Data Quality (15/15)

  • DQ-01: Feature Coverage (6/6)
  • DQ-02: Realistic Context (5/5)
  • DQ-03: Appropriate Scale (4/4) - checked: fit crosses 63.2% at ~450 kcycles, matching η ≈ 453

Code Quality (10/10)

  • CQ-01: KISS Structure (3/3)
  • CQ-02: Reproducibility (2/2)
  • CQ-03: Clean Imports (2/2)
  • CQ-04: Code Elegance (2/2)
  • CQ-05: Output & API (1/1)

Library Mastery (6/10)

  • LM-01: Idiomatic Usage (4/5)
  • LM-02: Distinctive Features (2/5) - custom overlay through useXScale/useYScale/useDrawingArea hooks

Score Caps Applied

  • None

Strengths

  • Correct Weibull paper: log x axis plus linearized ln(-ln(1-F)) y axis mapped back to percentage ticks via tickInterval/valueFormatter
  • Median ranks (i-0.3)/(n+0.4) with Johnson adjusted ranks for suspensions
  • Fit line visibly crosses the 63.2% ChartsReferenceLine at η ≈ 453; annotated β/η agree with the line
  • Hollow vs filled markers make censoring obvious in both themes
  • Composition API (ChartsContainer, LinePlot, ChartsReferenceLine, ChartsGrid) with scale hooks keeps marks at exact data values
  • Fully token-driven chrome; both themes legible

Weaknesses

  • VQ-05 (both): the log x axis uses 50-kcycle linear tick steps, so the labels bunch together on the right ("750 800 850 900" sit about 10–15 px apart and the 950/1050 ticks carry no label) while the left third has a single "100" label → log-friendly ticks (e.g. 100, 150, 200, 300, 500, 700, 1000) with roughly even spacing. Likely cause: no tickInterval set on the log x axis, so MUI's default linear-step ticks are used.
  • Suggestion: draw the failures and suspensions as two ScatterPlot series (hollow via slotProps/sx) so MUI's native ChartsLegend and tooltips cover them instead of the hand-built HTML legend.
  • Suggestion: anchor the 63.2% callout near the fit/reference-line crossing at eta instead of the far right edge.

@github-actions github-actions Bot added quality:85 Quality score 85/100 ai-rejected Quality not OK, triggers update labels Oct 24, 2026
@github-actions github-actions Bot added ai-attempt-1 First repair attempt and removed ai-rejected Quality not OK, triggers update labels Oct 24, 2026
Attempt 1/4 - fixes based on AI review

- VQ-05: log x axis now uses log-friendly ticks (1-1.5-2-3-5-7 per decade,
  derived from the axis range) instead of MUI's default linear steps

Declined:
- "Suggestion: draw failures and suspensions as two ScatterPlot series" — suggestion, not taken
- "Suggestion: anchor the 63.2% callout near the crossing at eta" — suggestion, not taken
@github-actions

Copy link
Copy Markdown
Contributor Author

🔧 Repair Attempt 1/4

Applied fixes based on AI review feedback.

Status: Repair completed, re-triggering review...


🤖 impl-repair

@claude

claude Bot commented Oct 24, 2026

Copy link
Copy Markdown
Contributor

AI Review - Attempt 2/3

Image Description

Light render (plot-light.png): Warm off-white #FAF8F1 page. The bold dark title "probability-weibull · javascript · muix · anyplot.ai" sits top-left, and a legend top-right shows a dashed "Fit: β ≈ 2.09, η ≈ 453 kcycles" line, a filled green "Failure" dot and a hollow green "Suspended (censored)" ring. The y axis "Cumulative Failure Probability (%)" is linearized Weibull with ticks at 1 %…99 % plus 63.2 %. The log x axis "Cycles to Failure (kcycles)" has ticks from 70 to 1000. The plot shows 20 filled #009E73 failures and 4 hollow rings along a dark dashed fit line, and a thin dotted 63.2 % reference line with a boxed callout "63.2% · η ≈ 453 kcycles" at the right. The fit crosses the reference line near 450 kcycles. All text is readable, and nothing is clipped or overlapping.

Dark render (plot-dark.png): Warm near-black #1A1A17 page. The title, legend text, axis titles and ticks are all light ink and readable, and there is no dark-on-dark text. The grid stays subtle, and the callout box sits on the elevated dark surface. The data marks are the identical #009E73 filled dots and hollow rings. Only the fit line and the chrome flip to light ink.

Score: 87/100

Category Score Max
Visual Quality 30 30
Design Excellence 10 20
Spec Compliance 15 15
Data Quality 15 15
Code Quality 10 10
Library Mastery 7 10
Total 87 100

Visual Quality (30/30)

  • VQ-01: Text Legibility (8/8)
  • VQ-02: No Overlap (6/6)
  • VQ-03: Element Visibility (6/6)
  • VQ-04: Color Accessibility (2/2)
  • VQ-05: Layout & Canvas (4/4)
  • VQ-06: Axis Labels & Title (2/2)
  • VQ-07: Palette Compliance (2/2)

Design Excellence (10/20)

  • DE-01: Aesthetic Sophistication (5/8) - the header row combines the title with a legend that carries beta and eta; ink and green separate the model from the data
  • DE-02: Visual Refinement (3/6) - probability ticks at reliability-paper positions, log ticks at 1-1.5-2-3-5-7
  • DE-03: Data Storytelling (2/6) - shows the annotations the Notes ask for; no hierarchy chosen beyond the Notes

Spec Compliance (15/15)

  • SC-01: Plot Type (5/5)
  • SC-02: Required Features (4/4)
  • SC-03: Data Mapping (3/3)
  • SC-04: Title & Legend (3/3)

Data Quality (15/15)

  • DQ-01: Feature Coverage (6/6)
  • DQ-02: Realistic Context (5/5)
  • DQ-03: Appropriate Scale (4/4) - first failure at (1−0.3)/24.4 = 2.87 % matches the render; the fit crosses 63.2 % at about η = 453

Code Quality (10/10)

  • CQ-01: KISS Structure (3/3)
  • CQ-02: Reproducibility (2/2)
  • CQ-03: Clean Imports (2/2)
  • CQ-04: Code Elegance (2/2)
  • CQ-05: Output & API (1/1)

Library Mastery (7/10)

  • LM-01: Idiomatic Usage (4/5)
  • LM-02: Distinctive Features (3/5) - scale hooks for the custom SVG overlay, ChartsReferenceLine

Score Caps Applied

  • None

Strengths

  • Correct Weibull probability paper: a log time axis and a linearized ln(−ln(1−F)) axis with reliability-standard probability ticks (tickInterval + valueFormatter), so the fit is a straight line.
  • Median-rank plotting positions with Johnson's adjusted rank for suspensions; the annotated β/η (2.09 / 453 kcycles) agree with the line, which crosses the 63.2 % reference line at the characteristic life.
  • Censored units are hollow green rings and failures are filled dots, distinct in both themes.
  • Idiomatic v9 composition: ChartsContainer, LinePlot, ChartsReferenceLine and ChartsGrid, plus the useDrawingArea/useXScale/useYScale hooks for marks in data coordinates; skipAnimation is set.
  • A compact header row keeps the full height for the plot.

Weaknesses

  • Suggestion: anchor the η callout at the crossing of the fit line and the 63.2 % reference line (about 453 kcycles) instead of the right edge.
  • Suggestion: the fit line and the reference line are both dashed; a solid fit line would separate the model from the reference more clearly.

@github-actions github-actions Bot added quality:87 Quality score 87/100 ai-approved Quality OK, ready for merge and removed quality:85 Quality score 85/100 labels Oct 24, 2026
@MarkusNeusinger
MarkusNeusinger merged commit ada3aaa into main Oct 24, 2026
@MarkusNeusinger
MarkusNeusinger deleted the implementation/probability-weibull/muix branch October 24, 2026 12:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ai-approved Quality OK, ready for merge ai-attempt-1 First repair attempt quality:87 Quality score 87/100 regen:forced Regeneration of an implementation that is live on main

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant