From c41c1dc3598a3af669ece2de11dac213284a5286 Mon Sep 17 00:00:00 2001 From: Markus Neusinger <2921697+MarkusNeusinger@users.noreply.github.com> Date: Sat, 14 Feb 2026 15:43:40 +0100 Subject: [PATCH 1/6] =?UTF-8?q?update(pie-basic):=20highcharts=20=E2=80=94?= =?UTF-8?q?=20comprehensive=20quality=20review?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Comprehensive review improving code quality, data choice, visual design, spec compliance, and library feature usage. --- plots/pie-basic/implementations/highcharts.py | 92 +++++++++++-------- plots/pie-basic/metadata/highcharts.yaml | 10 +- plots/pie-basic/specification.md | 4 +- plots/pie-basic/specification.yaml | 1 + 4 files changed, 61 insertions(+), 46 deletions(-) diff --git a/plots/pie-basic/implementations/highcharts.py b/plots/pie-basic/implementations/highcharts.py index 496b8d2050..ba31d094c4 100644 --- a/plots/pie-basic/implementations/highcharts.py +++ b/plots/pie-basic/implementations/highcharts.py @@ -1,7 +1,7 @@ -""" pyplots.ai +"""pyplots.ai pie-basic: Basic Pie Chart -Library: highcharts unknown | Python 3.13.11 -Quality: 92/100 | Created: 2025-12-23 +Library: highcharts 1.10.3 | Python 3.14.0 +Quality: /100 | Updated: 2026-02-14 """ import tempfile @@ -17,40 +17,49 @@ from selenium.webdriver.chrome.options import Options -# Data - Market share distribution (5 categories, realistic business context) -categories = ["Product A", "Product B", "Product C", "Product D", "Product E"] -values = [35, 25, 20, 12, 8] +# Data — Cloud infrastructure market share (5 categories, realistic business context) +# No random data — fully deterministic +categories = ["AWS", "Azure", "Google Cloud", "Alibaba", "Others"] +values = [31, 25, 11, 4, 29] -# Colorblind-safe colors (Python Blue first, then complementary) -colors = ["#306998", "#FFD43B", "#9467BD", "#17BECF", "#8C564B"] +# Colorblind-safe palette (Python Blue first, then complementary) +colors = ["#306998", "#FFD43B", "#E07B54", "#17BECF", "#9467BD"] -# Create chart with container specified +# Chart chart = Chart(container="container") chart.options = HighchartsOptions() -# Chart configuration for 3600x3600 square (ideal for pie charts) chart.options.chart = { "type": "pie", "width": 3600, "height": 3600, "backgroundColor": "#ffffff", - "spacingTop": 80, - "spacingBottom": 80, - "spacingLeft": 80, - "spacingRight": 80, + "spacingTop": 60, + "spacingBottom": 40, + "spacingLeft": 100, + "spacingRight": 100, } # Title chart.options.title = { - "text": "pie-basic · highcharts · pyplots.ai", - "style": {"fontSize": "48px", "fontWeight": "bold"}, - "margin": 40, + "text": "Cloud Infrastructure Market Share · pie-basic · highcharts · pyplots.ai", + "style": {"fontSize": "52px", "fontWeight": "bold"}, + "margin": 20, +} + +# Subtitle +chart.options.subtitle = { + "text": "Global cloud spending by provider, 2024", + "style": {"fontSize": "36px", "color": "#666666"}, } # Colors chart.options.colors = colors -# Plot options for pie with percentage labels and legend +# Credits +chart.options.credits = {"enabled": False} + +# Plot options chart.options.plot_options = { "pie": { "allowPointSelect": True, @@ -58,33 +67,37 @@ "dataLabels": { "enabled": True, "format": "{point.name}: {point.percentage:.1f}%", - "style": {"fontSize": "32px", "textOutline": "none"}, - "distance": 40, - "connectorWidth": 2, + "style": {"fontSize": "38px", "textOutline": "none", "fontWeight": "normal"}, + "distance": 50, + "connectorWidth": 3, + "connectorColor": "#aaaaaa", + "softConnector": True, }, "showInLegend": True, - "slicedOffset": 25, + "slicedOffset": 35, "size": "70%", - "center": ["40%", "50%"], + "center": ["50%", "50%"], + "startAngle": -20, } } -# Legend on the right side +# Legend — bottom horizontal chart.options.legend = { "enabled": True, - "align": "right", - "verticalAlign": "middle", - "layout": "vertical", - "itemStyle": {"fontSize": "36px", "fontWeight": "normal"}, - "itemMarginTop": 20, - "itemMarginBottom": 20, + "align": "center", + "verticalAlign": "bottom", + "layout": "horizontal", + "itemStyle": {"fontSize": "38px", "fontWeight": "normal"}, "symbolRadius": 10, - "symbolHeight": 20, - "symbolWidth": 20, - "x": -80, + "symbolHeight": 22, + "symbolWidth": 22, + "margin": 20, } -# Create pie series with data - first slice (largest) is exploded for emphasis +# Tooltip +chart.options.tooltip = {"pointFormat": "{point.percentage:.1f}% market share", "style": {"fontSize": "28px"}} + +# Series — largest slice (AWS) exploded for emphasis series = PieSeries() series.name = "Market Share" series.data = [ @@ -113,16 +126,15 @@ """ -# Write temp HTML and take screenshot +# Write temp HTML and save interactive version with tempfile.NamedTemporaryFile(mode="w", suffix=".html", delete=False, encoding="utf-8") as f: f.write(html_content) temp_path = f.name -# Also save the HTML for interactive version with open("plot.html", "w", encoding="utf-8") as f: f.write(html_content) -# Setup Chrome for screenshot +# Screenshot via headless Chrome chrome_options = Options() chrome_options.add_argument("--headless") chrome_options.add_argument("--no-sandbox") @@ -132,14 +144,14 @@ driver = webdriver.Chrome(options=chrome_options) driver.get(f"file://{temp_path}") -time.sleep(5) # Wait for chart to render +time.sleep(5) driver.save_screenshot("plot_raw.png") driver.quit() -# Crop to exact 3600x3600 dimensions +# Crop to exact 3600x3600 img = Image.open("plot_raw.png") img_cropped = img.crop((0, 0, 3600, 3600)) img_cropped.save("plot.png") Path("plot_raw.png").unlink() -Path(temp_path).unlink() # Clean up temp file +Path(temp_path).unlink() diff --git a/plots/pie-basic/metadata/highcharts.yaml b/plots/pie-basic/metadata/highcharts.yaml index d0a3694015..046db0bce2 100644 --- a/plots/pie-basic/metadata/highcharts.yaml +++ b/plots/pie-basic/metadata/highcharts.yaml @@ -1,16 +1,16 @@ library: highcharts specification_id: pie-basic created: '2025-12-23T00:36:27Z' -updated: '2025-12-23T00:40:57Z' -generated_by: claude-opus-4-5-20251101 +updated: '2026-02-14T14:40:21+00:00' +generated_by: claude-opus-4-6 workflow_run: 20447778270 issue: 0 -python_version: 3.13.11 -library_version: unknown +python_version: '3.14.0' +library_version: 1.10.3 preview_url: https://storage.googleapis.com/pyplots-images/plots/pie-basic/highcharts/plot.png preview_thumb: https://storage.googleapis.com/pyplots-images/plots/pie-basic/highcharts/plot_thumb.png preview_html: https://storage.googleapis.com/pyplots-images/plots/pie-basic/highcharts/plot.html -quality_score: 92 +quality_score: null impl_tags: dependencies: - pillow diff --git a/plots/pie-basic/specification.md b/plots/pie-basic/specification.md index 0ae4d3484e..b335847897 100644 --- a/plots/pie-basic/specification.md +++ b/plots/pie-basic/specification.md @@ -16,10 +16,12 @@ A pie chart showing proportions of categorical data as slices of a circle. Each - `category` (string) - category labels - `value` (numeric) - values for each category - Size: 3-8 categories (too many becomes unreadable) +- Values must be positive and sum to a meaningful whole +- Example: Market share of 5-6 tech companies ## Notes - Include percentage labels on slices - Use distinct colors for each category - Add a legend for category identification -- Consider slight explosion for emphasis on key slice +- Slightly explode the largest or smallest slice for emphasis diff --git a/plots/pie-basic/specification.yaml b/plots/pie-basic/specification.yaml index 0e144ba892..9343ada0fe 100644 --- a/plots/pie-basic/specification.yaml +++ b/plots/pie-basic/specification.yaml @@ -23,3 +23,4 @@ tags: features: - basic - proportional + - comparison From 2249f1f4ddc98d4000926fed4a076e329f114cbc Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 14 Feb 2026 14:47:26 +0000 Subject: [PATCH 2/6] chore(highcharts): update quality score 86 and review feedback for pie-basic --- plots/pie-basic/implementations/highcharts.py | 4 +- plots/pie-basic/metadata/highcharts.yaml | 249 ++++++++++-------- 2 files changed, 139 insertions(+), 114 deletions(-) diff --git a/plots/pie-basic/implementations/highcharts.py b/plots/pie-basic/implementations/highcharts.py index ba31d094c4..1197f7a48b 100644 --- a/plots/pie-basic/implementations/highcharts.py +++ b/plots/pie-basic/implementations/highcharts.py @@ -1,7 +1,7 @@ -"""pyplots.ai +""" pyplots.ai pie-basic: Basic Pie Chart Library: highcharts 1.10.3 | Python 3.14.0 -Quality: /100 | Updated: 2026-02-14 +Quality: 86/100 | Created: 2025-12-23 """ import tempfile diff --git a/plots/pie-basic/metadata/highcharts.yaml b/plots/pie-basic/metadata/highcharts.yaml index 046db0bce2..d8ad2962dd 100644 --- a/plots/pie-basic/metadata/highcharts.yaml +++ b/plots/pie-basic/metadata/highcharts.yaml @@ -1,159 +1,178 @@ library: highcharts specification_id: pie-basic created: '2025-12-23T00:36:27Z' -updated: '2026-02-14T14:40:21+00:00' +updated: '2026-02-14T14:47:26Z' generated_by: claude-opus-4-6 workflow_run: 20447778270 issue: 0 -python_version: '3.14.0' +python_version: 3.14.0 library_version: 1.10.3 preview_url: https://storage.googleapis.com/pyplots-images/plots/pie-basic/highcharts/plot.png preview_thumb: https://storage.googleapis.com/pyplots-images/plots/pie-basic/highcharts/plot_thumb.png preview_html: https://storage.googleapis.com/pyplots-images/plots/pie-basic/highcharts/plot.html -quality_score: null +quality_score: 86 impl_tags: dependencies: - - pillow - selenium + - pillow techniques: - html-export - patterns: - - data-generation - - iteration-over-groups + patterns: [] dataprep: [] - styling: [] + styling: + - edge-highlighting review: strengths: - - Excellent use of Highcharts-specific pie chart features including slice explosion - and data label connectors - - Colorblind-safe palette with good color contrast between all 5 slices - - Clean implementation following library best practices with proper container specification - - 'All spec requirements met: percentage labels, legend, distinct colors, exploded - slice emphasis' - - Appropriate square format (3600x3600) chosen for pie chart visualization + - 'All spec requirements met: percentage labels, distinct colors, legend, exploded + slice' + - Excellent text legibility with explicitly set font sizes throughout + - Realistic, neutral dataset (cloud market share) with realistic proportions + - Clean, well-structured code with no unnecessary complexity + - Colorblind-safe palette with good visual contrast between slices + - Nice typography hierarchy with bold title, gray subtitle, and normal-weight labels weaknesses: - - Pie chart positioned at 40% horizontal center creates slight layout imbalance - with excess whitespace on right - - Data labels could benefit from slightly larger connector line distance for smaller - slices - image_description: 'The plot displays a pie chart with 5 slices representing market - share distribution. The title "pie-basic · highcharts · pyplots.ai" is shown at - the top. The pie is positioned slightly left of center with a vertical legend - on the right side. Colors used are: blue (#306998) for Product A (35.0%), yellow - (#FFD43B) for Product B (25.0%), purple (#9467BD) for Product C (20.0%), cyan - (#17BECF) for Product D (12.0%), and brown (#8C564B) for Product E (8.0%). Product - A (the largest slice) is exploded/offset from the pie for emphasis. Each slice - has a data label showing the category name and percentage with connector lines. - The layout uses a square 3600x3600 format appropriate for pie charts.' + - Empty space between the pie and the bottom legend wastes canvas area — consider + increasing pie size or reducing gap + - No data storytelling annotations — adding callouts like Top 3 providers control + 67% of market or highlighting the AWS dominance would elevate the chart + - Subtitle provides temporal context but the chart does not guide the viewer toward + any specific insight + - 'The exploded slice could be more visually dramatic (slicedOffset: 35 is modest + at this scale)' + image_description: 'The plot is a pie chart on a white background in square (3600x3600) + format. It displays "Cloud Infrastructure Market Share" with 5 slices: AWS (dark + blue, 31.0%), Azure (golden yellow, 25.0%), Google Cloud (terra cotta orange, + 11.0%), Alibaba (teal/cyan, 4.0%), and Others (medium purple, 29.0%). The AWS + slice is exploded (pulled outward) for emphasis. Data labels are positioned outside + each slice with thin gray connector lines, showing category name and percentage + in bold. The title reads "Cloud Infrastructure Market Share · pie-basic · highcharts + · pyplots.ai" in bold, with a gray subtitle "Global cloud spending by provider, + 2024" beneath it. A horizontal legend with colored circles sits at the bottom. + The pie occupies the center-upper portion of the canvas with notable whitespace + below the pie and above the legend.' criteria_checklist: visual_quality: - score: 36 - max: 40 + score: 28 + max: 30 items: - id: VQ-01 name: Text Legibility - score: 10 - max: 10 + score: 8 + max: 8 passed: true - comment: Title at 48px, data labels at 32px, legend at 36px - all perfectly - readable at 3600x3600 + comment: 'All font sizes explicitly set: title 52px, subtitle 36px, data labels + 38px, legend 38px. All clearly readable.' - id: VQ-02 name: No Overlap - score: 8 - max: 8 + score: 6 + max: 6 passed: true - comment: No overlapping text, data labels well-spaced with connector lines + comment: No overlapping text. Labels well-spaced with connector lines. - id: VQ-03 name: Element Visibility - score: 8 - max: 8 + score: 5 + max: 6 passed: true - comment: Pie slices clearly visible with good proportions, 70% size appropriate + comment: All slices visible. Alibaba (4%) is small but distinguishable. - id: VQ-04 name: Color Accessibility - score: 5 - max: 5 + score: 4 + max: 4 passed: true - comment: Colorblind-safe palette avoiding red-green conflicts + comment: Colorblind-safe palette with distinct hues (blue, yellow, orange, + teal, purple). - id: VQ-05 name: Layout Balance score: 3 - max: 5 + max: 4 passed: true - comment: Good overall but pie shifted left (40% center) creates some asymmetry - with large right-side whitespace - - id: VQ-07 - name: Grid & Legend + comment: Pie centered but noticeable empty space between pie bottom and legend. + - id: VQ-06 + name: Axis Labels & Title score: 2 max: 2 passed: true - comment: Legend well-positioned on right, clear formatting + comment: Descriptive title with context. Subtitle adds temporal dimension. + design_excellence: + score: 12 + max: 20 + items: + - id: DE-01 + name: Aesthetic Sophistication + score: 5 + max: 8 + passed: true + comment: Custom palette, intentional typography hierarchy, good color contrast. + Well-configured but not publication-exceptional. + - id: DE-02 + name: Visual Refinement + score: 4 + max: 6 + passed: true + comment: Credits disabled, custom connector styling, soft connectors, rounded + legend symbols, exploded slice. + - id: DE-03 + name: Data Storytelling + score: 3 + max: 6 + passed: true + comment: Exploded AWS slice draws attention to market leader. But no annotations + explaining insights. spec_compliance: - score: 25 - max: 25 + score: 15 + max: 15 items: - id: SC-01 name: Plot Type - score: 8 - max: 8 - passed: true - comment: Correct pie chart type - - id: SC-02 - name: Data Mapping score: 5 max: 5 passed: true - comment: Categories and values correctly mapped to slices - - id: SC-03 + comment: Correct pie chart. + - id: SC-02 name: Required Features - score: 5 - max: 5 + score: 4 + max: 4 passed: true - comment: Percentage labels ✓, distinct colors ✓, legend ✓, exploded slice - for emphasis - - id: SC-04 - name: Data Range + comment: Percentage labels, distinct colors, legend, exploded largest slice + — all present. + - id: SC-03 + name: Data Mapping score: 3 max: 3 passed: true - comment: All categories visible and proportional - - id: SC-05 - name: Legend Accuracy - score: 2 - max: 2 - passed: true - comment: Legend labels match data correctly - - id: SC-06 - name: Title Format - score: 2 - max: 2 + comment: Categories and values correctly mapped as pie slices. + - id: SC-04 + name: Title & Legend + score: 3 + max: 3 passed: true - comment: Uses correct format "pie-basic · highcharts · pyplots.ai" + comment: Correct title format, legend labels match data categories. data_quality: - score: 18 - max: 20 + score: 14 + max: 15 items: - id: DQ-01 name: Feature Coverage - score: 6 - max: 8 + score: 5 + max: 6 passed: true - comment: Shows 5 categories with varying proportions, exploded slice; could - show more variation in slice sizes + comment: Good range of slice sizes (4% to 31%), demonstrating pie chart with + both large and small proportions. - id: DQ-02 name: Realistic Context - score: 7 - max: 7 + score: 5 + max: 5 passed: true - comment: Market share distribution is a plausible real-world scenario + comment: Cloud infrastructure market share is a real, well-known, neutral + business scenario. - id: DQ-03 name: Appropriate Scale - score: 5 - max: 5 + score: 4 + max: 4 passed: true - comment: Values sum to 100%, realistic market share percentages + comment: Values are realistic approximations of actual cloud market shares. code_quality: - score: 8 + score: 10 max: 10 items: - id: CQ-01 @@ -161,41 +180,47 @@ review: score: 3 max: 3 passed: true - comment: 'Simple linear structure: imports → data → chart config → series - → export' + comment: 'Clean linear flow: Imports, Data, Chart, Series, Export.' - id: CQ-02 name: Reproducibility - score: 1 - max: 3 - passed: false - comment: Uses deterministic data (no random), but no seed comment; acceptable + score: 2 + max: 2 + passed: true + comment: Fully deterministic hardcoded data. - id: CQ-03 name: Clean Imports score: 2 max: 2 passed: true - comment: All imports used + comment: All imports are used. - id: CQ-04 - name: No Deprecated API - score: 1 - max: 1 + name: Code Elegance + score: 2 + max: 2 passed: true - comment: Uses current highcharts-core API + comment: Clean list comprehension for series data, appropriate complexity. - id: CQ-05 - name: Output Correct + name: Output & API score: 1 max: 1 passed: true - comment: Saves as plot.png correctly - library_features: - score: 5 - max: 5 + comment: Saves as plot.png, no deprecated functions. + library_mastery: + score: 7 + max: 10 items: - - id: LF-01 - name: Uses distinctive library features - score: 5 + - id: LM-01 + name: Idiomatic Usage + score: 4 + max: 5 + passed: true + comment: Proper Highcharts Python API usage with HighchartsOptions, PieSeries, + plot_options. + - id: LM-02 + name: Distinctive Features + score: 3 max: 5 passed: true - comment: 'Uses Highcharts-specific features: allowPointSelect, slicedOffset - for explosion, showInLegend, connector lines, point selection' - verdict: APPROVED + comment: 'Uses Highcharts-specific: allowPointSelect, sliced/selected, softConnector, + startAngle, slicedOffset.' + verdict: REJECTED From 049d45cd715b5e2e31d514e2014ed5dea25db4a2 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 14 Feb 2026 14:55:03 +0000 Subject: [PATCH 3/6] fix(highcharts): address review feedback for pie-basic Attempt 1/3 - fixes based on AI review --- plots/pie-basic/implementations/highcharts.py | 116 +++++++++++++----- 1 file changed, 84 insertions(+), 32 deletions(-) diff --git a/plots/pie-basic/implementations/highcharts.py b/plots/pie-basic/implementations/highcharts.py index 1197f7a48b..e0d55dbc98 100644 --- a/plots/pie-basic/implementations/highcharts.py +++ b/plots/pie-basic/implementations/highcharts.py @@ -1,4 +1,4 @@ -""" pyplots.ai +"""pyplots.ai pie-basic: Basic Pie Chart Library: highcharts 1.10.3 | Python 3.14.0 Quality: 86/100 | Created: 2025-12-23 @@ -21,10 +21,14 @@ # No random data — fully deterministic categories = ["AWS", "Azure", "Google Cloud", "Alibaba", "Others"] values = [31, 25, 11, 4, 29] +total = sum(values) # Colorblind-safe palette (Python Blue first, then complementary) colors = ["#306998", "#FFD43B", "#E07B54", "#17BECF", "#9467BD"] +# Compute top-3 share for annotation +top3_share = sum(values[:3]) + # Chart chart = Chart(container="container") chart.options = HighchartsOptions() @@ -34,23 +38,24 @@ "width": 3600, "height": 3600, "backgroundColor": "#ffffff", - "spacingTop": 60, - "spacingBottom": 40, - "spacingLeft": 100, - "spacingRight": 100, + "spacingTop": 50, + "spacingBottom": 30, + "spacingLeft": 80, + "spacingRight": 80, + "style": {"fontFamily": "'Segoe UI', Tahoma, Geneva, Verdana, sans-serif"}, } # Title chart.options.title = { "text": "Cloud Infrastructure Market Share · pie-basic · highcharts · pyplots.ai", - "style": {"fontSize": "52px", "fontWeight": "bold"}, - "margin": 20, + "style": {"fontSize": "50px", "fontWeight": "bold", "color": "#1a1a2e"}, + "margin": 10, } -# Subtitle +# Subtitle with storytelling context chart.options.subtitle = { - "text": "Global cloud spending by provider, 2024", - "style": {"fontSize": "36px", "color": "#666666"}, + "text": (f"Global cloud spending by provider, 2024 — Top 3 providers control {top3_share}% of the market"), + "style": {"fontSize": "34px", "color": "#555555", "fontWeight": "normal"}, } # Colors @@ -59,59 +64,105 @@ # Credits chart.options.credits = {"enabled": False} -# Plot options +# Plot options with enhanced visual refinement chart.options.plot_options = { "pie": { "allowPointSelect": True, "cursor": "pointer", + "borderWidth": 2, + "borderColor": "#ffffff", + "shadow": {"color": "rgba(0,0,0,0.12)", "offsetX": 3, "offsetY": 3, "width": 8}, "dataLabels": { "enabled": True, - "format": "{point.name}: {point.percentage:.1f}%", - "style": {"fontSize": "38px", "textOutline": "none", "fontWeight": "normal"}, - "distance": 50, - "connectorWidth": 3, - "connectorColor": "#aaaaaa", + "format": "{point.name}
{point.percentage:.1f}%", + "style": {"fontSize": "38px", "textOutline": "none", "fontWeight": "normal", "color": "#333333"}, + "distance": 55, + "connectorWidth": 2, + "connectorColor": "#999999", "softConnector": True, + "connectorShape": "crookedLine", }, "showInLegend": True, - "slicedOffset": 35, - "size": "70%", - "center": ["50%", "50%"], + "slicedOffset": 45, + "size": "75%", + "center": ["50%", "46%"], "startAngle": -20, + "innerSize": "0%", + "states": {"hover": {"halo": {"size": 15, "opacity": 0.25}}, "inactive": {"opacity": 0.5}}, } } -# Legend — bottom horizontal +# Legend — bottom horizontal, refined styling chart.options.legend = { "enabled": True, "align": "center", "verticalAlign": "bottom", "layout": "horizontal", - "itemStyle": {"fontSize": "38px", "fontWeight": "normal"}, - "symbolRadius": 10, - "symbolHeight": 22, - "symbolWidth": 22, - "margin": 20, + "itemStyle": {"fontSize": "36px", "fontWeight": "normal", "color": "#444444"}, + "itemHoverStyle": {"color": "#1a1a2e"}, + "symbolRadius": 8, + "symbolHeight": 20, + "symbolWidth": 20, + "margin": 15, + "padding": 12, } # Tooltip -chart.options.tooltip = {"pointFormat": "{point.percentage:.1f}% market share", "style": {"fontSize": "28px"}} +chart.options.tooltip = { + "pointFormat": "{point.percentage:.1f}% market share", + "style": {"fontSize": "28px"}, + "backgroundColor": "rgba(255,255,255,0.95)", + "borderColor": "#cccccc", + "borderRadius": 8, + "shadow": {"color": "rgba(0,0,0,0.08)", "offsetX": 1, "offsetY": 1, "width": 3}, +} # Series — largest slice (AWS) exploded for emphasis +# Use point-level custom styling for the leader slice series = PieSeries() series.name = "Market Share" -series.data = [ - {"name": cat, "y": val, "sliced": i == 0, "selected": i == 0} - for i, (cat, val) in enumerate(zip(categories, values, strict=True)) -] +series_data = [] +for i, (cat, val) in enumerate(zip(categories, values, strict=True)): + point = {"name": cat, "y": val, "sliced": i == 0, "selected": i == 0} + if i == 0: + # Highlight leader with slightly brighter variant and thicker border + point["borderWidth"] = 3 + point["borderColor"] = "#1e4060" + series_data.append(point) + +series.data = series_data chart.add_series(series) -# Download Highcharts JS for inline embedding (required for headless Chrome) +# Download Highcharts JS for inline embedding highcharts_url = "https://code.highcharts.com/highcharts.js" with urllib.request.urlopen(highcharts_url, timeout=30) as response: highcharts_js = response.read().decode("utf-8") +# Callout annotation as an overlay (positioned with CSS for precise control) +callout_html = """ +
+ AWS leads with nearly ⅓ of global cloud revenue +
+""" + # Generate HTML with inline scripts html_str = chart.to_js_literal() html_content = f""" @@ -120,8 +171,9 @@ - +
+ {callout_html} """ From 94e50db395a5f4b19e2df16d86db48fcd9f789a9 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 14 Feb 2026 14:59:12 +0000 Subject: [PATCH 4/6] chore(highcharts): update quality score 88 and review feedback for pie-basic --- plots/pie-basic/implementations/highcharts.py | 4 +- plots/pie-basic/metadata/highcharts.yaml | 173 ++++++++++-------- 2 files changed, 95 insertions(+), 82 deletions(-) diff --git a/plots/pie-basic/implementations/highcharts.py b/plots/pie-basic/implementations/highcharts.py index e0d55dbc98..95ab92dcf5 100644 --- a/plots/pie-basic/implementations/highcharts.py +++ b/plots/pie-basic/implementations/highcharts.py @@ -1,7 +1,7 @@ -"""pyplots.ai +""" pyplots.ai pie-basic: Basic Pie Chart Library: highcharts 1.10.3 | Python 3.14.0 -Quality: 86/100 | Created: 2025-12-23 +Quality: 88/100 | Created: 2025-12-23 """ import tempfile diff --git a/plots/pie-basic/metadata/highcharts.yaml b/plots/pie-basic/metadata/highcharts.yaml index d8ad2962dd..8289e076a2 100644 --- a/plots/pie-basic/metadata/highcharts.yaml +++ b/plots/pie-basic/metadata/highcharts.yaml @@ -1,7 +1,7 @@ library: highcharts specification_id: pie-basic created: '2025-12-23T00:36:27Z' -updated: '2026-02-14T14:47:26Z' +updated: '2026-02-14T14:59:12Z' generated_by: claude-opus-4-6 workflow_run: 20447778270 issue: 0 @@ -10,49 +10,55 @@ library_version: 1.10.3 preview_url: https://storage.googleapis.com/pyplots-images/plots/pie-basic/highcharts/plot.png preview_thumb: https://storage.googleapis.com/pyplots-images/plots/pie-basic/highcharts/plot_thumb.png preview_html: https://storage.googleapis.com/pyplots-images/plots/pie-basic/highcharts/plot.html -quality_score: 86 +quality_score: 88 impl_tags: dependencies: - selenium - pillow techniques: + - annotations - html-export - patterns: [] + patterns: + - iteration-over-groups dataprep: [] styling: - edge-highlighting review: strengths: - - 'All spec requirements met: percentage labels, distinct colors, legend, exploded - slice' - - Excellent text legibility with explicitly set font sizes throughout - - Realistic, neutral dataset (cloud market share) with realistic proportions - - Clean, well-structured code with no unnecessary complexity - - Colorblind-safe palette with good visual contrast between slices - - Nice typography hierarchy with bold title, gray subtitle, and normal-weight labels + - Excellent data storytelling with subtitle context (Top 3 providers control 67%) + and callout annotation highlighting AWS leadership + - 'Strong visual polish: custom shadows, border styling, crooked connectors, exploded + leader slice with distinct border' + - 'Perfect spec compliance: all requirements from specification met (percentage + labels, distinct colors, legend, exploded slice)' + - Idiomatic Highcharts usage with point-level customization and interactive state + configuration + - Realistic, neutral data context (cloud infrastructure market share) weaknesses: - - Empty space between the pie and the bottom legend wastes canvas area — consider - increasing pie size or reducing gap - - No data storytelling annotations — adding callouts like Top 3 providers control - 67% of market or highlighting the AWS dominance would elevate the chart - - Subtitle provides temporal context but the chart does not guide the viewer toward - any specific insight - - 'The exploded slice could be more visually dramatic (slicedOffset: 35 is modest - at this scale)' - image_description: 'The plot is a pie chart on a white background in square (3600x3600) - format. It displays "Cloud Infrastructure Market Share" with 5 slices: AWS (dark - blue, 31.0%), Azure (golden yellow, 25.0%), Google Cloud (terra cotta orange, - 11.0%), Alibaba (teal/cyan, 4.0%), and Others (medium purple, 29.0%). The AWS - slice is exploded (pulled outward) for emphasis. Data labels are positioned outside - each slice with thin gray connector lines, showing category name and percentage - in bold. The title reads "Cloud Infrastructure Market Share · pie-basic · highcharts - · pyplots.ai" in bold, with a gray subtitle "Global cloud spending by provider, - 2024" beneath it. A horizontal legend with colored circles sits at the bottom. - The pie occupies the center-upper portion of the canvas with notable whitespace - below the pie and above the legend.' + - 'Layout balance: significant vertical gap between pie chart and callout/legend + area wastes canvas space — consider moving callout closer or using Highcharts + native annotations' + - The callout annotation uses a CSS overlay div rather than Highcharts built-in + annotation API, which would be more idiomatic and easier to position relative + to the chart + - Minor label crowding between Alibaba 4.0% and Google Cloud 11.0% — adjusting startAngle + or label distance could improve spacing + - PIL/Pillow imported solely for a crop operation — could potentially adjust window-size + and chart height to avoid the extra dependency + image_description: 'The plot displays a pie chart titled "Cloud Infrastructure Market + Share · pie-basic · highcharts · pyplots.ai" on a white background in 3600×3600 + square format. Five slices represent cloud providers: AWS (31.0%, dark teal-blue, + exploded outward), Azure (25.0%, golden yellow), Google Cloud (11.0%, burnt orange), + Alibaba (4.0%, cyan), and Others (29.0%, purple). Each slice has bold data labels + showing the provider name and percentage, connected by gray connector lines. The + subtitle reads "Global cloud spending by provider, 2024 — Top 3 providers control + 67% of the market." A dark gradient callout box near the bottom states "AWS leads + with nearly ⅓ of global cloud revenue" with a blue left border accent. A horizontal + legend at the very bottom shows colored circles for each category. The color palette + is colorblind-safe with good contrast between all slices.' criteria_checklist: visual_quality: - score: 28 + score: 26 max: 30 items: - id: VQ-01 @@ -60,64 +66,68 @@ review: score: 8 max: 8 passed: true - comment: 'All font sizes explicitly set: title 52px, subtitle 36px, data labels - 38px, legend 38px. All clearly readable.' + comment: 'All font sizes explicitly set: title 50px, subtitle 34px, data labels + 38px, legend 36px. All clearly readable.' - id: VQ-02 name: No Overlap - score: 6 + score: 5 max: 6 passed: true - comment: No overlapping text. Labels well-spaced with connector lines. + comment: Mostly clean spacing. Alibaba and Google Cloud labels slightly crowded + but readable. - id: VQ-03 name: Element Visibility - score: 5 + score: 6 max: 6 passed: true - comment: All slices visible. Alibaba (4%) is small but distinguishable. + comment: All slices clearly visible including small Alibaba slice. Exploded + AWS slice provides effective emphasis. - id: VQ-04 name: Color Accessibility score: 4 max: 4 passed: true - comment: Colorblind-safe palette with distinct hues (blue, yellow, orange, - teal, purple). + comment: 'Colorblind-safe palette: blue, yellow, orange, cyan, purple. No + red-green reliance.' - id: VQ-05 name: Layout Balance - score: 3 + score: 2 max: 4 - passed: true - comment: Pie centered but noticeable empty space between pie bottom and legend. + passed: false + comment: Significant gap between pie and callout/legend. Callout floats disconnected + from chart. - id: VQ-06 name: Axis Labels & Title - score: 2 + score: 1 max: 2 passed: true - comment: Descriptive title with context. Subtitle adds temporal dimension. + comment: N/A for pie charts but title and subtitle provide strong descriptive + context. design_excellence: - score: 12 + score: 16 max: 20 items: - id: DE-01 name: Aesthetic Sophistication - score: 5 + score: 7 max: 8 passed: true - comment: Custom palette, intentional typography hierarchy, good color contrast. - Well-configured but not publication-exceptional. + comment: Custom palette, shadows, refined borders, dark gradient callout. + Above defaults but cyan is slightly jarring. - id: DE-02 name: Visual Refinement - score: 4 + score: 5 max: 6 passed: true - comment: Credits disabled, custom connector styling, soft connectors, rounded - legend symbols, exploded slice. + comment: Credits disabled, custom legend symbols, subtle shadows, soft connectors. + Gap between pie and callout breaks visual flow. - id: DE-03 name: Data Storytelling - score: 3 + score: 4 max: 6 passed: true - comment: Exploded AWS slice draws attention to market leader. But no annotations - explaining insights. + comment: Subtitle contextualizes top-3 dominance, callout highlights AWS, + exploded slice draws attention. Callout could be better integrated. spec_compliance: score: 15 max: 15 @@ -127,26 +137,28 @@ review: score: 5 max: 5 passed: true - comment: Correct pie chart. + comment: 'Correct chart type: basic pie chart.' - id: SC-02 name: Required Features score: 4 max: 4 passed: true - comment: Percentage labels, distinct colors, legend, exploded largest slice - — all present. + comment: 'All spec requirements met: percentage labels, distinct colors, legend, + exploded largest slice.' - id: SC-03 name: Data Mapping score: 3 max: 3 passed: true - comment: Categories and values correctly mapped as pie slices. + comment: Categories correctly mapped to slices, values correctly determine + proportions. - id: SC-04 name: Title & Legend score: 3 max: 3 passed: true - comment: Correct title format, legend labels match data categories. + comment: Title follows spec-id · library · pyplots.ai format. Legend labels + match categories. data_quality: score: 14 max: 15 @@ -156,23 +168,23 @@ review: score: 5 max: 6 passed: true - comment: Good range of slice sizes (4% to 31%), demonstrating pie chart with - both large and small proportions. + comment: Good variety in slice sizes (31%, 25%, 29%, 11%, 4%). Demonstrates + range well. - id: DQ-02 name: Realistic Context score: 5 max: 5 passed: true - comment: Cloud infrastructure market share is a real, well-known, neutral + comment: Cloud infrastructure market share is real, neutral, comprehensible business scenario. - id: DQ-03 name: Appropriate Scale score: 4 max: 4 passed: true - comment: Values are realistic approximations of actual cloud market shares. + comment: Values sum to 100%, realistic for 2024 cloud market. code_quality: - score: 10 + score: 8 max: 10 items: - id: CQ-01 @@ -180,47 +192,48 @@ review: score: 3 max: 3 passed: true - comment: 'Clean linear flow: Imports, Data, Chart, Series, Export.' + comment: 'Flat structure: imports, data, chart config, series, HTML, screenshot.' - id: CQ-02 name: Reproducibility score: 2 max: 2 passed: true - comment: Fully deterministic hardcoded data. + comment: Fully deterministic data, no randomness. - id: CQ-03 name: Clean Imports - score: 2 + score: 1 max: 2 - passed: true - comment: All imports are used. + passed: false + comment: PIL/Pillow imported just for crop operation, adds unnecessary dependency. - id: CQ-04 name: Code Elegance - score: 2 + score: 1 max: 2 - passed: true - comment: Clean list comprehension for series data, appropriate complexity. + passed: false + comment: CSS-based callout overlay is functional but verbose. Heavy HTML/CSS + for a single annotation. - id: CQ-05 name: Output & API score: 1 max: 1 passed: true - comment: Saves as plot.png, no deprecated functions. - library_mastery: - score: 7 + comment: Saves as plot.png, uses current Highcharts API. + library_features: + score: 9 max: 10 items: - id: LM-01 name: Idiomatic Usage - score: 4 + score: 5 max: 5 passed: true - comment: Proper Highcharts Python API usage with HighchartsOptions, PieSeries, - plot_options. + comment: 'Expert Highcharts usage: Chart/HighchartsOptions/PieSeries, point-level + properties, plot_options config.' - id: LM-02 name: Distinctive Features - score: 3 + score: 4 max: 5 passed: true - comment: 'Uses Highcharts-specific: allowPointSelect, sliced/selected, softConnector, - startAngle, slicedOffset.' + comment: Leverages hover halo, inactive opacity, point selection, shadow config, + crookedLine connectors. CSS overlay instead of native annotations. verdict: REJECTED From 821cebaf70955dad7ac3907c34ebee7aefa551f6 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 14 Feb 2026 15:09:00 +0000 Subject: [PATCH 5/6] fix(highcharts): address review feedback for pie-basic Attempt 2/3 - fixes based on AI review --- plots/pie-basic/implementations/highcharts.py | 92 +++++++------------ 1 file changed, 34 insertions(+), 58 deletions(-) diff --git a/plots/pie-basic/implementations/highcharts.py b/plots/pie-basic/implementations/highcharts.py index 95ab92dcf5..967e146994 100644 --- a/plots/pie-basic/implementations/highcharts.py +++ b/plots/pie-basic/implementations/highcharts.py @@ -1,4 +1,4 @@ -""" pyplots.ai +"""pyplots.ai pie-basic: Basic Pie Chart Library: highcharts 1.10.3 | Python 3.14.0 Quality: 88/100 | Created: 2025-12-23 @@ -12,21 +12,19 @@ from highcharts_core.chart import Chart from highcharts_core.options import HighchartsOptions from highcharts_core.options.series.pie import PieSeries -from PIL import Image from selenium import webdriver from selenium.webdriver.chrome.options import Options # Data — Cloud infrastructure market share (5 categories, realistic business context) -# No random data — fully deterministic categories = ["AWS", "Azure", "Google Cloud", "Alibaba", "Others"] values = [31, 25, 11, 4, 29] -total = sum(values) # Colorblind-safe palette (Python Blue first, then complementary) -colors = ["#306998", "#FFD43B", "#E07B54", "#17BECF", "#9467BD"] +# Replaced cyan (#17BECF) with softer teal (#2CA089) for better palette harmony +colors = ["#306998", "#FFD43B", "#E07B54", "#2CA089", "#9467BD"] -# Compute top-3 share for annotation +# Compute top-3 share for subtitle storytelling top3_share = sum(values[:3]) # Chart @@ -35,13 +33,13 @@ chart.options.chart = { "type": "pie", - "width": 3600, - "height": 3600, + "width": 4800, + "height": 2700, "backgroundColor": "#ffffff", - "spacingTop": 50, - "spacingBottom": 30, - "spacingLeft": 80, - "spacingRight": 80, + "spacingTop": 30, + "spacingBottom": 25, + "spacingLeft": 60, + "spacingRight": 60, "style": {"fontFamily": "'Segoe UI', Tahoma, Geneva, Verdana, sans-serif"}, } @@ -52,10 +50,15 @@ "margin": 10, } -# Subtitle with storytelling context +# Subtitle with storytelling context and insight callout chart.options.subtitle = { - "text": (f"Global cloud spending by provider, 2024 — Top 3 providers control {top3_share}% of the market"), - "style": {"fontSize": "34px", "color": "#555555", "fontWeight": "normal"}, + "text": ( + f"Global cloud spending by provider, 2024 \u2014 Top 3 providers control {top3_share}% of the market" + '
' + "AWS leads with nearly \u2153 of global cloud revenue" + ), + "useHTML": True, + "style": {"fontSize": "34px", "color": "#555555", "fontWeight": "normal", "textAlign": "center"}, } # Colors @@ -83,16 +86,16 @@ "connectorShape": "crookedLine", }, "showInLegend": True, - "slicedOffset": 45, + "slicedOffset": 40, "size": "75%", - "center": ["50%", "46%"], - "startAngle": -20, + "center": ["50%", "55%"], + "startAngle": -45, "innerSize": "0%", "states": {"hover": {"halo": {"size": 15, "opacity": 0.25}}, "inactive": {"opacity": 0.5}}, } } -# Legend — bottom horizontal, refined styling +# Legend — bottom horizontal chart.options.legend = { "enabled": True, "align": "center", @@ -103,8 +106,8 @@ "symbolRadius": 8, "symbolHeight": 20, "symbolWidth": 20, - "margin": 15, - "padding": 12, + "margin": 8, + "padding": 8, } # Tooltip @@ -118,7 +121,6 @@ } # Series — largest slice (AWS) exploded for emphasis -# Use point-level custom styling for the leader slice series = PieSeries() series.name = "Market Share" @@ -126,7 +128,6 @@ for i, (cat, val) in enumerate(zip(categories, values, strict=True)): point = {"name": cat, "y": val, "sliced": i == 0, "selected": i == 0} if i == 0: - # Highlight leader with slightly brighter variant and thicker border point["borderWidth"] = 3 point["borderColor"] = "#1e4060" series_data.append(point) @@ -139,30 +140,6 @@ with urllib.request.urlopen(highcharts_url, timeout=30) as response: highcharts_js = response.read().decode("utf-8") -# Callout annotation as an overlay (positioned with CSS for precise control) -callout_html = """ -
- AWS leads with nearly ⅓ of global cloud revenue -
-""" - # Generate HTML with inline scripts html_str = chart.to_js_literal() html_content = f""" @@ -171,9 +148,8 @@ - -
- {callout_html} + +
""" @@ -192,18 +168,18 @@ chrome_options.add_argument("--no-sandbox") chrome_options.add_argument("--disable-dev-shm-usage") chrome_options.add_argument("--disable-gpu") -chrome_options.add_argument("--window-size=3600,3800") +chrome_options.add_argument("--window-size=4800,2700") driver = webdriver.Chrome(options=chrome_options) + +# Adjust window to get exact 4800x2700 viewport (compensate for browser chrome) +inner_h = driver.execute_script("return window.innerHeight") +outer_h = driver.get_window_size()["height"] +driver.set_window_size(4800, 2700 + (outer_h - inner_h)) + driver.get(f"file://{temp_path}") time.sleep(5) -driver.save_screenshot("plot_raw.png") +driver.save_screenshot("plot.png") driver.quit() -# Crop to exact 3600x3600 -img = Image.open("plot_raw.png") -img_cropped = img.crop((0, 0, 3600, 3600)) -img_cropped.save("plot.png") -Path("plot_raw.png").unlink() - Path(temp_path).unlink() From 2f6813250f1398fabaaf9e90476db73473760537 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 14 Feb 2026 15:12:52 +0000 Subject: [PATCH 6/6] chore(highcharts): update quality score 90 and review feedback for pie-basic --- plots/pie-basic/implementations/highcharts.py | 4 +- plots/pie-basic/metadata/highcharts.yaml | 176 +++++++++--------- 2 files changed, 85 insertions(+), 95 deletions(-) diff --git a/plots/pie-basic/implementations/highcharts.py b/plots/pie-basic/implementations/highcharts.py index 967e146994..05534e5166 100644 --- a/plots/pie-basic/implementations/highcharts.py +++ b/plots/pie-basic/implementations/highcharts.py @@ -1,7 +1,7 @@ -"""pyplots.ai +""" pyplots.ai pie-basic: Basic Pie Chart Library: highcharts 1.10.3 | Python 3.14.0 -Quality: 88/100 | Created: 2025-12-23 +Quality: 90/100 | Created: 2025-12-23 """ import tempfile diff --git a/plots/pie-basic/metadata/highcharts.yaml b/plots/pie-basic/metadata/highcharts.yaml index 8289e076a2..d297f1914a 100644 --- a/plots/pie-basic/metadata/highcharts.yaml +++ b/plots/pie-basic/metadata/highcharts.yaml @@ -1,7 +1,7 @@ library: highcharts specification_id: pie-basic created: '2025-12-23T00:36:27Z' -updated: '2026-02-14T14:59:12Z' +updated: '2026-02-14T15:12:52Z' generated_by: claude-opus-4-6 workflow_run: 20447778270 issue: 0 @@ -10,124 +10,114 @@ library_version: 1.10.3 preview_url: https://storage.googleapis.com/pyplots-images/plots/pie-basic/highcharts/plot.png preview_thumb: https://storage.googleapis.com/pyplots-images/plots/pie-basic/highcharts/plot_thumb.png preview_html: https://storage.googleapis.com/pyplots-images/plots/pie-basic/highcharts/plot.html -quality_score: 88 +quality_score: 90 impl_tags: dependencies: - selenium - - pillow techniques: - - annotations - html-export - patterns: - - iteration-over-groups + patterns: [] dataprep: [] styling: - edge-highlighting review: strengths: - - Excellent data storytelling with subtitle context (Top 3 providers control 67%) - and callout annotation highlighting AWS leadership - - 'Strong visual polish: custom shadows, border styling, crooked connectors, exploded - leader slice with distinct border' - - 'Perfect spec compliance: all requirements from specification met (percentage - labels, distinct colors, legend, exploded slice)' - - Idiomatic Highcharts usage with point-level customization and interactive state - configuration - - Realistic, neutral data context (cloud infrastructure market share) + - Excellent data storytelling with computed subtitle insight (Top 3 control 67%) + and italic callout for AWS dominance + - Visually polished with shadow effects, white slice borders, and crookedLine connectors + - All spec requirements met perfectly (percentages, legend, distinct colors, exploded + slice) + - Realistic and neutral data context with appropriate values + - Good use of Highcharts-specific features (states, softConnector, slicedOffset, + useHTML) + - Dual output (interactive HTML + static PNG) demonstrates library capability weaknesses: - - 'Layout balance: significant vertical gap between pie chart and callout/legend - area wastes canvas space — consider moving callout closer or using Highcharts - native annotations' - - The callout annotation uses a CSS overlay div rather than Highcharts built-in - annotation API, which would be more idiomatic and easier to position relative - to the chart - - Minor label crowding between Alibaba 4.0% and Google Cloud 11.0% — adjusting startAngle - or label distance could improve spacing - - PIL/Pillow imported solely for a crop operation — could potentially adjust window-size - and chart height to avoid the extra dependency + - Minor whitespace gap between subtitle and pie chart top could be tightened + - Alibaba slice at 4% is quite thin — could benefit from slightly more visual emphasis + - Legend symbols (circles) at the bottom are relatively small compared to the label + text size image_description: 'The plot displays a pie chart titled "Cloud Infrastructure Market - Share · pie-basic · highcharts · pyplots.ai" on a white background in 3600×3600 - square format. Five slices represent cloud providers: AWS (31.0%, dark teal-blue, - exploded outward), Azure (25.0%, golden yellow), Google Cloud (11.0%, burnt orange), - Alibaba (4.0%, cyan), and Others (29.0%, purple). Each slice has bold data labels - showing the provider name and percentage, connected by gray connector lines. The - subtitle reads "Global cloud spending by provider, 2024 — Top 3 providers control - 67% of the market." A dark gradient callout box near the bottom states "AWS leads - with nearly ⅓ of global cloud revenue" with a blue left border accent. A horizontal - legend at the very bottom shows colored circles for each category. The color palette - is colorblind-safe with good contrast between all slices.' + Share · pie-basic · highcharts · pyplots.ai" at 4800x2700 px on a white background. + Five slices represent cloud providers: AWS (31.0%, dark blue #306998) is the largest + and exploded outward for emphasis; Azure (25.0%, yellow #FFD43B) is the second + largest; Others (29.0%, purple #9467BD) is a large aggregated slice; Google Cloud + (11.0%, salmon/orange #E07B54) is mid-sized; and Alibaba (4.0%, teal #2CA089) + is the smallest. Data labels outside each slice show the provider name in bold + and percentage, connected by subtle crookedLine connectors. A subtitle reads "Global + cloud spending by provider, 2024 — Top 3 providers control 67% of the market" + with an italicized insight line "AWS leads with nearly 1/3 of global cloud revenue." + A horizontal legend at the bottom lists all five categories with colored circle + symbols. White borders separate slices, and subtle shadows add depth.' criteria_checklist: visual_quality: - score: 26 + score: 27 max: 30 items: - id: VQ-01 name: Text Legibility - score: 8 + score: 7 max: 8 passed: true - comment: 'All font sizes explicitly set: title 50px, subtitle 34px, data labels - 38px, legend 36px. All clearly readable.' + comment: All font sizes explicitly set (title 50px, subtitle 34px, labels + 38px, legend 36px); all readable; title/subtitle could be slightly larger + at full resolution - id: VQ-02 name: No Overlap - score: 5 + score: 6 max: 6 passed: true - comment: Mostly clean spacing. Alibaba and Google Cloud labels slightly crowded - but readable. + comment: No overlapping text; data labels well-spaced with crookedLine connectors - id: VQ-03 name: Element Visibility - score: 6 + score: 5 max: 6 passed: true - comment: All slices clearly visible including small Alibaba slice. Exploded - AWS slice provides effective emphasis. + comment: All slices clearly visible; Alibaba at 4% is small but distinguishable - id: VQ-04 name: Color Accessibility score: 4 max: 4 passed: true - comment: 'Colorblind-safe palette: blue, yellow, orange, cyan, purple. No - red-green reliance.' + comment: Colorblind-safe palette (blue, yellow, orange, teal, purple); no + red-green ambiguity - id: VQ-05 name: Layout Balance - score: 2 + score: 3 max: 4 - passed: false - comment: Significant gap between pie and callout/legend. Callout floats disconnected - from chart. + passed: true + comment: Pie occupies good portion of canvas (75% size); some excess whitespace + between subtitle and pie top - id: VQ-06 name: Axis Labels & Title - score: 1 + score: 2 max: 2 passed: true - comment: N/A for pie charts but title and subtitle provide strong descriptive - context. + comment: Descriptive title with context; N/A for pie chart axes design_excellence: score: 16 max: 20 items: - id: DE-01 name: Aesthetic Sophistication - score: 7 + score: 6 max: 8 passed: true - comment: Custom palette, shadows, refined borders, dark gradient callout. - Above defaults but cyan is slightly jarring. + comment: Custom palette, intentional font hierarchy, shadow effects, white + slice borders, crookedLine connectors — clearly above defaults - id: DE-02 name: Visual Refinement score: 5 max: 6 passed: true - comment: Credits disabled, custom legend symbols, subtle shadows, soft connectors. - Gap between pie and callout breaks visual flow. + comment: Credits disabled, soft connectors, subtle shadows, white border separation, + generous spacing, hover/inactive states - id: DE-03 name: Data Storytelling - score: 4 + score: 5 max: 6 passed: true - comment: Subtitle contextualizes top-3 dominance, callout highlights AWS, - exploded slice draws attention. Callout could be better integrated. + comment: Computed subtitle insight (Top 3 control 67%), italic callout for + AWS dominance, exploded slice draws attention spec_compliance: score: 15 max: 15 @@ -137,28 +127,27 @@ review: score: 5 max: 5 passed: true - comment: 'Correct chart type: basic pie chart.' + comment: Correct pie chart type - id: SC-02 name: Required Features score: 4 max: 4 passed: true - comment: 'All spec requirements met: percentage labels, distinct colors, legend, - exploded largest slice.' + comment: Percentage labels, distinct colors, legend, exploded largest slice + — all present - id: SC-03 name: Data Mapping score: 3 max: 3 passed: true - comment: Categories correctly mapped to slices, values correctly determine - proportions. + comment: Categories and values correctly mapped to slices - id: SC-04 name: Title & Legend score: 3 max: 3 passed: true - comment: Title follows spec-id · library · pyplots.ai format. Legend labels - match categories. + comment: Title format correct with spec-id · library · pyplots.ai; legend + labels match data data_quality: score: 14 max: 15 @@ -168,23 +157,23 @@ review: score: 5 max: 6 passed: true - comment: Good variety in slice sizes (31%, 25%, 29%, 11%, 4%). Demonstrates - range well. + comment: 5 categories with good size variation (4%-31%); dominant, mid-size, + small, and aggregated Others slice - id: DQ-02 name: Realistic Context score: 5 max: 5 passed: true - comment: Cloud infrastructure market share is real, neutral, comprehensible - business scenario. + comment: Cloud infrastructure market share — real, neutral business scenario + with recognizable companies - id: DQ-03 name: Appropriate Scale score: 4 max: 4 passed: true - comment: Values sum to 100%, realistic for 2024 cloud market. + comment: Values (31%, 25%, 11%, 4%, 29%) realistic for 2024 cloud market code_quality: - score: 8 + score: 10 max: 10 items: - id: CQ-01 @@ -192,48 +181,49 @@ review: score: 3 max: 3 passed: true - comment: 'Flat structure: imports, data, chart config, series, HTML, screenshot.' + comment: 'Linear flow: imports, data, chart config, series, export' - id: CQ-02 name: Reproducibility score: 2 max: 2 passed: true - comment: Fully deterministic data, no randomness. + comment: Deterministic hardcoded data, no randomness - id: CQ-03 name: Clean Imports - score: 1 + score: 2 max: 2 - passed: false - comment: PIL/Pillow imported just for crop operation, adds unnecessary dependency. + passed: true + comment: All imports used - id: CQ-04 name: Code Elegance - score: 1 + score: 2 max: 2 - passed: false - comment: CSS-based callout overlay is functional but verbose. Heavy HTML/CSS - for a single annotation. + passed: true + comment: Clean iteration for series data, computed subtitle insight, appropriate + complexity - id: CQ-05 name: Output & API score: 1 max: 1 passed: true - comment: Saves as plot.png, uses current Highcharts API. - library_features: - score: 9 + comment: Saves plot.png and plot.html; no deprecated functions + library_mastery: + score: 8 max: 10 items: - id: LM-01 name: Idiomatic Usage - score: 5 + score: 4 max: 5 passed: true - comment: 'Expert Highcharts usage: Chart/HighchartsOptions/PieSeries, point-level - properties, plot_options config.' + comment: Proper use of HighchartsOptions, PieSeries, options API, add_series(), + to_js_literal() - id: LM-02 name: Distinctive Features score: 4 max: 5 passed: true - comment: Leverages hover halo, inactive opacity, point selection, shadow config, - crookedLine connectors. CSS overlay instead of native annotations. - verdict: REJECTED + comment: Leverages allowPointSelect, slicedOffset, hover halo states, inactive + opacity, softConnector with crookedLine, shadow config, useHTML subtitle, + interactive HTML export + verdict: APPROVED