Worked Examples
Apply baseline construction — Global Impact Catalyst
Scientifically and technically construct sustainability baselines in Global Impact Catalyst using source-reviewed indicator registry models, versioned methods, data-quality controls, and reproducible calculations. This guide provides GitHub implementation references, synthetic tests, engineering validation criteria, and governance safeguards that distinguish observed change from scientifically defensible impact claims.
Application: Global Impact Catalyst
Component: Indicator Registry / Baseline Models / Program Measurement
Article type: Operational and engineering guide
Source-reviewed code: GitHub commit e75808a0aa27…
Installed version: Not verified
Editorial status: Ready for WordPress review; staging acceptance pending
Reading time: Approximately 17–22 minutes
1. Goal and scope
Construct a traceable baseline for a sustainability indicator within an authorized Global Impact Catalyst workspace. A baseline is the reference value or historical distribution for an indicator; it is not automatically a valid counterfactual or causal estimate.
Outcome: A unit-consistent, version-pinned, reproducible baseline calculation supported by original observations, a defined reference period, quality decisions, and explicit review status. For external impact claims, require a separately justified comparison design and evidence chain.
2. Requirements and permissions
- Identify the workspace, initiative, indicator, actor, data owner and reporting purpose; confirm current authorization.
- Select the indicator-definition version, unit definition, measurement boundary, reference dates and data sources.
- Collect historical observations with source IDs, timestamps, revision status, access classifications and provenance.
- Define missing-data rules before calculation and retain original records for audit.
- Separate internal drafting from review, approval, export and publication permissions.
The WordPress workspace documentation describes authenticated editor interfaces and REST nonce checks; do not assume a particular live role configuration without verifying the deployed installation. See WordPress workspace.
3. Source-reviewed architecture and version contract
| Component | Source-reviewed role | Evidence |
|---|---|---|
| Registry v1.4.0 | Unit and indicator definitions, baseline models, immutable versions, initiative bindings | Registry implementation |
| Baseline methods | Point, period average, rolling average, benchmark, modelled expression | Baseline methodology |
| SQLite persistence | Baseline model and version tables, references and revision metadata | SQL migration |
| Registry export | Workspace-scoped models, versions, bindings and integrity summary | Registry schema |
| Measurement v1.5.0 | Time-indexed complete, missing, late, partial and revised observations | Measurement documentation |
| WordPress surface | Authenticated indicator-registry interface described as managing baseline models | WordPress workspace |
Source pin: Repository main tree reviewed at commit e75808a0aa272656b1fdbacd2491c30fd6b987dc. Registry contract 1.4.0; measurement documentation 1.5.0. These are repository-level findings, not verification of the installed WordPress plugin or production database.
4. Baseline model definitions and data contract
The registry implementation declares the internal method values point_first, point_latest, period_average, rolling_average, benchmark, and modelled. The public methodology document uses the broader labels point, average, rolling, benchmark and modelled. Use the implementation values for code-level work; do not substitute editorial labels into an API contract.
| Field | Meaning / validation |
|---|---|
baseline_model_id |
Stable identifier; must not silently identify a different workspace’s record |
workspace_id |
Authorized project context; enforce workspace-scoped read and write checks |
method_type |
One permitted baseline method |
unit_id |
Registered compatible unit |
period_start / period_end |
Inclusive study window where applicable, with documented date semantics |
minimum_observations |
Threshold for usable observations; model schema requires at least one |
confidence |
Declared low, medium, high or not_assessed; not a statistical confidence interval |
parameters / formula_expression |
Method-specific settings; expressions use the restricted formula language |
current_version / revision |
Immutable model version versus record revision/concurrency marker |
The registry export schema enumerates baseline fields and immutable version records. The SQL migration additionally defines the period, benchmark, expression and governance fields. See Registry schema and SQL migration.
5. Baseline construction procedure
- Specify the question. Define indicator, population, organization boundary, geography, reference period, unit and intended decision.
- Fix the definition version. Locate the indicator definition, its unit and applicable measurement method. Preserve the exact bound version.
- Choose method. Use first/latest only for justified points; a period average for comparable observations; rolling average for a declared window; benchmark for an external reference; and modelled only with reviewed inputs and formula.
- Prepare observations. Reject unapproved sources and unparseable/non-finite values. Record missing, partial, late and revised states without silently equating them to zero. Resolve duplicated and superseded records.
- Verify comparability. Standardize units, sampling frequency and population boundary. Consider seasons, changes in operations and historical revisions.
- Compute and capture. Record input observation IDs, count used, method, value, unit and the model-version ID. The Python
compute_baselinefunction returns these core result fields; it is not in itself a complete provenance package. - Review. Reproduce independently and document exclusions, uncertainty, the counterfactual decision, and permission to report.
- Preserve. Retain the version-pinned calculation, evidence manifest and decision history. Saving does not confer approval.
Relevant source: Registry implementation, including register_baseline_model, get_baseline_model, compute_baseline and bind_indicator_registry.
6. Synthetic calculation and aggregation semantics
Suppose a fictional factory reports annual emissions of 12,000, 11,500 and 11,000 tCO₂e and constant output of 100,000 units each year in 2022–2024. Total emissions are 34,500 tCO₂e; total output is 300,000 units; pooled emissions intensity is 0.115 tCO₂e/unit.
pooled_intensity = sum(emissions) / sum(output) = 34500 / 300000 = 0.115
This pooled intensity is a derived ratio and is not necessarily equal to an arithmetic mean of per-facility ratios in datasets with different denominators. Do not assume that period_average calculates a weighted ratio: inspect the current implementation and model the indicator’s aggregation explicitly.
After intervention, a fictional value of 0.100 tCO₂e/unit gives (0.100 / 0.115 - 1) × 100 = -13.04%. This is an observed change, not an attributable reduction absent a defensible counterfactual.
7. Computation, formula and failure behavior
The code exposes a narrow arithmetic expression language, gic-expression-1.0. It allows numeric literals, permitted names and arithmetic while rejecting function calls, imports, attribute access, indexing, and other executable syntax. A non-finite result or division by zero raises a validation error. See Registry implementation.
| Input | Expected engineering behavior |
|---|---|
| No usable observations | Do not return a fabricated zero baseline; fail or mark incomplete according to the verified method contract |
| Too few observations | Fail the minimum-observation criterion; preserve source evidence |
| Incompatible dimensions | Reject comparison or conversion |
| Zero rate denominator | Reject calculation; avoid Infinity and NaN |
| Formula with arbitrary Python call | Reject expression |
| Stale model revision | Reject conflicting write; do not overwrite an intervening version |
| Superseded observation | Explicitly apply effective-record selection, preserving revision lineage |
| Unauthorized workspace | Deny read, write and export; verify at every service boundary |
8. Reproducible developer example
The following fixture and validation pseudocode are independent educational examples, not a verified request body for a production route:
{
"workspace_id": "ws-synthetic",
"indicator": "emissions_intensity",
"unit": "tCO2e/unit",
"period": ["2022", "2023", "2024"],
"emissions_tco2e": [12000, 11500, 11000],
"production_units": [100000, 100000, 100000],
"expected_pooled_intensity": 0.115,
"review_status": "draft"
}
require_authorized_workspace(actor, workspace)
assert_compatible_units(inputs)
assert_nonzero(sum(output_units))
result = sum(emissions_tco2e) / sum(output_units)
assert_finite(result)
persist_provenance_and_version_pin(result)
require_separate_review_before_publication()
Do not send this JSON directly to WordPress or Python service endpoints without deriving the actual accepted payload from the pinned code and contract tests.
9. Testing and engineering acceptance
| Case | Acceptance criterion |
|---|---|
| Determinism | Identical data, model version and method reproduce identical value |
| Ordering and window | Point/rolling methods select correct dated observations |
| Version pinning | New model version does not silently rewrite prior results |
| Zero and missing values | Zero permitted only when measured; missing never coerced to zero |
| Units | Recognized compatible conversion succeeds; incompatible dimension fails |
| Security | Cross-workspace reads/writes, exports and public discovery are denied |
| Revision collision | Stale edit fails with recoverable conflict |
| Privacy | Restricted observations never appear in public logs, search or exports |
| Claim governance | Computed or saved draft cannot become published claim implicitly |
Existing source tests: Registry tests. The accompanying local fixture tester in this package validates synthetic calculations and negative cases; it does not exercise Global Impact Catalyst’s installed application.
10. Troubleshooting and recovery
Mismatch between baseline and subsequent values
Check denominator, units, indicator-version references, effective observation revisions and scope changes. Re-run with a pinned fixture. Record the discrepancy before attempting correction.
Baseline model is visible but result cannot be reproduced
Verify whether source observations, method configuration, reference date range and exact model version were preserved. The registry result fields alone are not full evidence lineage.
Stale version or unauthorized update
Retain conflict evidence and recover the latest authorized revision; never bypass revision controls or rewrite immutable version rows. Escalate cross-workspace authorization defects before any deployment.
Public report implies causality
Downgrade the language to observed change and require a separately reviewed causal design. A historical benchmark is not a counterfactual by default.
11. Review, scientific validity and publication boundary
Registry integrity checks and successful computation support technical consistency but do not establish indicator construct validity, representativeness, statistical confidence, additionality, or causal impact. Reviewer checks must cover period choice, measurement assumptions, uncertainty, omitted observations, benchmark relevance, external drivers, and any potential conflict of interest.
Separate the evidence classes: source-reviewed denotes code and documentation inspected at a pinned commit; offline-tested denotes synthetic local checks; staging-verified denotes controlled instance evidence; scientifically reviewed denotes independent methodological acceptance; and production-verified requires deployed behavior evidence. None follows automatically from another.
12. GitHub references and technical reading
- Registry implementation —
python/global_impact_registry.py - Baseline methodology —
docs/baselines-targets-methods.md - Registry schema —
schemas/global_impact_indicator_registry.schema.json - SQL migration —
migrations/005_indicator_registry_units_baselines_targets_methods.sql - Registry tests —
tests/test_indicator_registry.py - Measurement repository —
python/global_impact_measurement.py - Measurement documentation —
docs/program-measurement.md - WordPress plugin —
wordpress/global-impact-catalyst-demo/global-impact-catalyst-demo.php - WordPress workspace —
docs/wordpress-workspace.md - Indicator registry —
docs/indicator-registry.md
References are pinned to the reviewed repository commit to prevent links from silently changing after future code revisions.
13. Quality-check summary
- Do the baseline and indicator reference the correct workspace and exact immutable definitions?
- Does the reference period precede the intervention and reflect an appropriate population?
- Are units, denominators, source revisions, missingness and exclusions explicit?
- Can the exact result be independently reproduced from preserved evidence?
- Are the source and deployed implementation versions distinguished?
- Are causal claims, publication authorization and scientific approval governed separately?
Completion standard: A complete, documented baseline suitable for authorized review—not an automatically approved sustainability claim.
