{
  "manifest_version": "0.1",
  "work_slug": "climate-policy-primap-prioritization-divergence",
  "protocol": "protocol:secondary-analysis 0.1",
  "module": "agent/tools.py",
  "analysis_unit": "analysis.py",
  "published_results": "results.json",
  "source_dataset_doi": "10.5281/zenodo.5175154",
  "environment": {
    "language": "python",
    "tested_version": "3.13",
    "requirements": "requirements-reproduction.txt",
    "network": "deny-except-pinned-inputs"
  },
  "execution": {
    "boundary": "docs/72-reproduction-contract.md",
    "live_invocation": "not connected; the sandboxed runner gates execution over MCP",
    "cost_note": "each source variant is a large CSV fetched per run (main 44MB, no_extrap 42MB, no_extrap_no_rounding 92MB, no_rounding 98MB); the acceptance calls stay within the main variant except the two that reproduce claim 4, which is computed from no_rounding, so a check costs two downloads (44MB and 98MB)"
  },
  "tools": [
    {
      "name": "divergence_test",
      "summary": "Annex I vs non-Annex I divergence between the two prioritization rules.",
      "unit": "analysis.primary_test over analysis.national_totals (with analysis.cliffs_delta and analysis.bootstrap_delta_ci)",
      "parameters": [
        {
          "name": "entity",
          "type": "string",
          "default": "KYOTOGHG (AR4GWP100)",
          "range": "any entity in the series: CO2, CH4, N2O, NF3, SF6, the HFCS/PFCS/FGASES baskets, and KYOTOGHG under AR4 or SAR GWP-100",
          "published_values": ["KYOTOGHG (AR4GWP100)", "CO2", "CH4"],
          "notes": "The published gas robustness covers CO2 and CH4 only; N2O and the fluorinated baskets are equally available."
        },
        {
          "name": "year",
          "type": "string",
          "default": "2019",
          "range": "any year column from 1750 to 2019",
          "published_values": ["2019", "1990", "2000", "2010"],
          "notes": "The published temporal robustness samples four years from a 270-year series."
        },
        {
          "name": "variant",
          "type": "string",
          "default": "main",
          "range": "main | no_extrap | no_rounding | no_extrap_no_rounding",
          "published_values": ["main", "no_rounding"]
        },
        {
          "name": "seed",
          "type": "number",
          "default": 42,
          "range": "any integer seed for the Cliff's delta bootstrap",
          "published_values": [42]
        },
        {
          "name": "n_boot",
          "type": "number",
          "default": 10000,
          "range": ">= 1 bootstrap resamples",
          "published_values": [10000],
          "notes": "Exposed so a caller can check the delta CI is not an artefact of 10,000 resamples."
        }
      ],
      "returns": "group sizes, both median absolute relative differences, Mann-Whitney U, p_value, cliffs_delta and its bootstrap CI",
      "supports_claims": [1, 3, 4, 5],
      "deterministic": true
    },
    {
      "name": "exact_agreement_test",
      "summary": "Fisher's exact on Annex I membership against exact scenario agreement.",
      "unit": "analysis.secondary_test over analysis.national_totals",
      "parameters": [
        {"name": "entity", "type": "string", "default": "KYOTOGHG (AR4GWP100)", "range": "any entity in the series", "published_values": ["KYOTOGHG (AR4GWP100)"]},
        {"name": "year", "type": "string", "default": "2019", "range": "any year column from 1750 to 2019", "published_values": ["2019"]},
        {"name": "variant", "type": "string", "default": "main", "range": "main | no_extrap | no_rounding | no_extrap_no_rounding", "published_values": ["main"]}
      ],
      "returns": "the 2x2 contingency, both equal-fractions, odds_ratio and p_value",
      "supports_claims": [2],
      "deterministic": true
    },
    {
      "name": "exact_agreement_count",
      "summary": "How many countries have the two scenarios exactly equal.",
      "unit": "the exact_equal column built in analysis.national_totals",
      "parameters": [
        {"name": "entity", "type": "string", "default": "KYOTOGHG (AR4GWP100)", "range": "any entity in the series", "published_values": ["KYOTOGHG (AR4GWP100)"]},
        {"name": "year", "type": "string", "default": "2019", "range": "any year column from 1750 to 2019", "published_values": ["2019"]},
        {"name": "variant", "type": "string", "default": "main", "range": "main | no_extrap | no_rounding | no_extrap_no_rounding", "published_values": ["main", "no_rounding"]}
      ],
      "returns": "variant, n_countries, n_exact_equal_total",
      "supports_claims": [2, 4],
      "deterministic": true
    }
  ]
}
