{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "f250-government-control-surface-census-v1",
  "title": "Freedom 250 Government Control Surface Census",
  "type": "object",
  "required": [
    "schema_version",
    "research_id",
    "window",
    "denominator_state",
    "records"
  ],
  "properties": {
    "schema_version": {
      "const": "f250.control-surface-census/v1"
    },
    "research_id": {
      "const": "government-hidden-control-surfaces-2026"
    },
    "window": {
      "type": "object",
      "required": ["start", "end"],
      "properties": {
        "start": {"const": "2025-01-01"},
        "end": {"const": "2026-09-28T23:59:59-04:00"}
      },
      "additionalProperties": false
    },
    "denominator_state": {
      "enum": ["provisional", "frozen", "reconciled"]
    },
    "records": {
      "type": "array",
      "items": {"$ref": "#/$defs/record"}
    }
  },
  "$defs": {
    "record": {
      "type": "object",
      "required": [
        "surface_id",
        "name",
        "cohort",
        "surface_class",
        "federal_status",
        "anchor_actor",
        "lifecycle_state",
        "chart_disposition",
        "depth_tier",
        "wave",
        "sweep_state",
        "window_start",
        "window_end",
        "official_roots",
        "source_state",
        "last_verified"
      ],
      "properties": {
        "surface_id": {
          "type": "string",
          "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
        },
        "name": {"type": "string", "minLength": 1},
        "cohort": {
          "enum": [
            "financial_markets",
            "government_management",
            "cloud_cyber_infrastructure",
            "retirement_tax_delivery",
            "trade_industry_infrastructure",
            "defense_science_research",
            "faca_other",
            "external_research_interface"
          ]
        },
        "surface_class": {
          "enum": [
            "federal_entity",
            "federal_component",
            "faca_advisory_body",
            "statutory_advisory_body",
            "non_faca_advisory_body",
            "interagency_council",
            "management_council",
            "program_board",
            "sunshine_board",
            "stakeholder_contact_ledger",
            "implementation_dashboard",
            "ffrdc",
            "ffrdc_administrator",
            "federally_chartered_private_body",
            "private_research_body",
            "cohort_denominator"
          ]
        },
        "federal_status": {
          "enum": [
            "inside_federal_group",
            "coordination_overlay",
            "program_or_route_only",
            "federally_sponsored_outside_group",
            "chartered_outside_group",
            "private_external",
            "to_verify"
          ]
        },
        "anchor_actor": {"type": ["string", "null"]},
        "legal_basis": {"type": ["string", "null"]},
        "lifecycle_state": {
          "enum": [
            "active_verified",
            "active_unverified_current",
            "inactive",
            "terminated",
            "expired",
            "archived",
            "proposed",
            "unknown"
          ]
        },
        "chart_disposition": {
          "enum": [
            "existing_node",
            "candidate_node",
            "coordination_overlay",
            "relationship_only",
            "adjacent_private",
            "exclude_from_chart",
            "pending_review"
          ]
        },
        "canonical_chart_match": {"type": ["string", "null"]},
        "depth_tier": {"enum": ["A", "B", "C", "D", "pending"]},
        "wave": {"type": "integer", "minimum": 0, "maximum": 10},
        "sweep_state": {
          "enum": [
            "not_started",
            "preflighted",
            "in_progress",
            "complete",
            "held",
            "excluded"
          ]
        },
        "window_start": {"const": "2025-01-01"},
        "window_end": {"const": "2026-09-28T23:59:59-04:00"},
        "official_roots": {
          "type": "array",
          "items": {"type": "string", "format": "uri"}
        },
        "source_state": {
          "enum": [
            "official_verified",
            "official_partial",
            "official_route_only",
            "access_limited",
            "not_recovered"
          ]
        },
        "last_verified": {"type": ["string", "null"], "format": "date"},
        "inclusion_basis": {"type": ["string", "null"]},
        "exclusion_reason": {"type": ["string", "null"]},
        "notes": {"type": ["string", "null"]}
      },
      "additionalProperties": false
    }
  },
  "additionalProperties": false
}
