SVG Template Gallery

Explore all 49 SVG visualization templates covering fairness analysis, reporting, experimentation, and workflow integration in the vfairness rendering module. Click any template for a detailed preview with code examples.

SVG Rendering Module

The vfairness.rendering module provides polished, card-based SVG dashboards using Jinja2 templates. Zero dependencies beyond Python stdlib — auto-upgrades to Jinja2 when available.

SVG Rendering Demo: vfairness_0_svg_rendering_demo.ipynb — Interactive walkthrough of all 49 SVG templates with live rendering and synthetic data

Preprocessing & Feature Engineering

Bias detection and feature analysis visualizations

10 templates

Training-Time Interventions

Fairness-aware training analysis and method comparison

4 templates

Post-Processing Interventions

Threshold optimization and prediction reweighting

3 templates

Calibration Visualizations

Group-specific calibration analysis and reliability diagrams

5 templates

Evaluation & Metrics

Fairness metrics visualization and statistical analysis

10 templates

Monitoring & Operations

Real-time fairness monitoring, drift detection, and alert visualizations

4 templates

Reporting & Dashboards

Interactive dashboards, automated reports, and metrics storage for stakeholder communication

6 templates

Experimentation & A/B Testing

Fairness-aware A/B testing, power analysis, Pareto optimization, and causal decomposition

4 templates

Workflow Integration

MLOps, CI/CD gates, and PR report cards

Complete Template Reference

All 49 SVG templates in vfairness.rendering plus interactive components from vfairness.operations.reporting and vfairness.operations.experimentation:

Template Adapter Function Category Description
bias_audit.svgbias_audit_to_svg()PreprocessingBias detection dashboard
correlation_heatmap.svgcorrelation_heatmap_to_svg()PreprocessingFeature correlation matrix
correlation_matrix.svgcorrelation_matrix_to_svg()PreprocessingGeneral multi-method correlation matrix
proxy_risk.svgproxy_risk_to_svg()PreprocessingProxy variable detection
transformation_comparison.svgtransformation_comparison_to_svg()PreprocessingFeature transformation impact
intersectional_analysis.svgintersectional_analysis_to_svg()PreprocessingSubgroup analysis
fairness_report.svgfairness_report_to_svg()PreprocessingSummary dashboard
data_validation.svgdata_validation_to_svg()PreprocessingPre-training data validation
auto_discovery.svgauto_discovery_to_svg()PreprocessingProtected attribute scanner
training_report.svgtraining_report_to_svg()TrainingCompact training report
training_analysis_report.svgtraining_analysis_report_to_svg()TrainingFull training analysis
method_comparison.svgmethod_comparison_to_svg()TrainingMethod bar chart
tradeoff_analysis.svgtradeoff_analysis_to_svg()TrainingPareto scatter plot
threshold_optimization_report.svgthreshold_optimization_to_svg()Post-ProcessingThreshold dashboard
reweighting_comparison_report.svgreweighting_comparison_to_svg()Post-ProcessingReweighting methods
cicd_pipeline.svgcicd_pipeline_to_svg()Post-ProcessingDeployment gate
calibration_report.svgcalibration_report_to_svg()CalibrationCalibration dashboard
reliability_diagram.svgreliability_diagram_to_svg()CalibrationClassic reliability plot
group_calibration.svggroup_calibration_to_svg()CalibrationPer-group calibration
calibration_disparity.svgcalibration_disparity_to_svg()CalibrationCalibration gap
pareto_frontier.svgpareto_frontier_to_svg()CalibrationTrade-off frontier
fairness_detailed_report.svgfairness_detailed_report_to_svg()EvaluationExecutive report
radar_chart.svgradar_chart_to_svg()EvaluationMulti-metric radar
disparity_heatmap.svgdisparity_heatmap_to_svg()EvaluationPairwise disparities
metrics_bar_chart.svgmetrics_bar_chart_to_svg()EvaluationMetrics comparison
group_comparison.svggroup_comparison_to_svg()EvaluationGroup metrics
effect_sizes.svgeffect_sizes_to_svg()EvaluationEffect magnitudes
confidence_intervals.svgconfidence_intervals_to_svg()EvaluationStatistical CIs
robustness_testing.svgrobustness_testing_to_svg()EvaluationRobustness & sensitivity testing
ranking_fairness.svgranking_fairness_to_svg()EvaluationRanking fairness metrics
regression_fairness.svgregression_fairness_to_svg()EvaluationRegression equity report
monitoring_dashboard.svgmonitoring_dashboard_to_svg()MonitoringLive fairness dashboard
drift_report.svgdrift_report_to_svg()MonitoringMulti-scale drift report
alert_timeline.svgalert_timeline_to_svg()MonitoringAlert history timeline
temporal_analysis.svgtemporal_analysis_to_svg()MonitoringTrend & pattern analysis
experiment_results.svgexperiment_results_to_svg()ExperimentationA/B test results & forest plot
experiment_recommendation.svgexperiment_recommendation_to_svg()ExperimentationDeployment recommendation
power_analysis.svgpower_analysis_to_svg()ExperimentationStatistical power analysis
causal_decomposition.svgcausal_decomposition_to_svg()ExperimentationCausal mediation analysis
workflow_overview.svgworkflow_overview_to_svg()WorkflowDevelopment workflow pipeline
hierarchical_gate.svghierarchical_gate_to_svg()WorkflowHierarchical fairness gate
report_card.svgreport_card_to_svg()WorkflowPR fairness report card
reporting_dashboard_executive.svgreporting_dashboard_to_svg(tier="executive")ReportingExecutive tier — green, board-level
reporting_dashboard_operational.svgreporting_dashboard_to_svg(tier="operational")ReportingOperational tier — yellow, engineer view
reporting_dashboard_technical.svgreporting_dashboard_to_svg(tier="technical")ReportingTechnical tier — red, full audit
MetricsStoreMetricsStore()ReportingUnified metrics data layer
FairnessDashboardFairnessDashboard()ReportingInteractive Plotly dashboard
ReportGeneratorReportGenerator()ReportingAutomated multi-format reports
FairnessExperimentFairnessExperiment()ExperimentationFairness A/B testing
FairnessPowerAnalyzerFairnessPowerAnalyzer()ExperimentationPower analysis & SPRT
ExperimentAnalysisExperimentAnalysis()ExperimentationPareto & causal analysis

Quick Usage

python
from vfairness.rendering import (
    render_svg, list_templates,
    # Report dashboards
    bias_audit_to_svg, calibration_report_to_svg, fairness_report_to_svg,
    # Feature engineering
    correlation_matrix_to_svg,
    # Training
    training_report_to_svg, training_analysis_report_to_svg,
    # Post-processing
    threshold_optimization_to_svg, reweighting_comparison_to_svg,
    # Evaluation
    fairness_detailed_report_to_svg, radar_chart_to_svg,
    # Monitoring
    monitoring_dashboard_to_svg, drift_report_to_svg,
    alert_timeline_to_svg, temporal_analysis_to_svg,
    # Reporting
    reporting_dashboard_to_svg,
    # Experimentation
    experiment_results_to_svg, experiment_recommendation_to_svg,
    power_analysis_to_svg,
    # Workflow integration
    workflow_overview_to_svg,
    hierarchical_gate_to_svg,
    report_card_to_svg,
)

# List all available templates
print(list_templates())

# Render using adapter functions
svg = training_analysis_report_to_svg(report, save_path='report.svg')

# Or use render_svg directly
svg = render_svg('radar_chart', {'metrics': [...], 'groups': [...]})

# ── Reporting ──────────────────────────────────────────────
from vfairness.operations.reporting import (
    MetricsStore, FairnessDashboard, ReportGenerator, InteractiveDashboard
)

store = MetricsStore()
store.ingest_from_monitor(monitor)          # Feed from monitoring
dashboard = FairnessDashboard(store)
fig = dashboard.create_executive_view()     # Plotly figure

gen = ReportGenerator(store, dashboard)
report = gen.generate_executive_report()    # HTML / PDF / JSON

# ── Experimentation ────────────────────────────────────────
from vfairness.operations.experimentation import (
    FairnessExperiment, FairnessPowerAnalyzer, ExperimentAnalysis
)

exp = FairnessExperiment(
    control_data=df_ctrl, treatment_data=df_treat,
    protected_attributes=['gender', 'race'], outcome_column='approved',
)
result = exp.run_full_analysis()
analysis = ExperimentAnalysis(result, experiment=exp)
rec = analysis.decision_recommendation()   # Deploy / hold / revert