{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://intelligence.metatron.marketing/entities/statement.schema.json",
  "title": "Metatron Intelligence source-qualified entity statement",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "statement_id",
    "subject_id",
    "predicate",
    "value_or_object_id",
    "valid_from",
    "valid_to",
    "observed_at",
    "source_id",
    "source_locator",
    "confidence",
    "status"
  ],
  "properties": {
    "statement_id": {
      "type": "string",
      "pattern": "^STM-[A-F0-9]{32}$"
    },
    "subject_id": {
      "type": "string",
      "pattern": "^ENT-[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
    },
    "predicate": {
      "enum": [
        "name",
        "version",
        "publisher",
        "publication_date",
        "scope",
        "boundary",
        "consolidation_date",
        "provider_identifier",
        "family_identifier",
        "version_identifier",
        "release_date",
        "modality",
        "access_mode",
        "license",
        "organization_identifier",
        "legal_name",
        "team_identifier",
        "service_identifier",
        "alias_identifier",
        "benchmark_identifier",
        "task_scope",
        "metric_contract",
        "evaluation_conditions",
        "comparability_boundary",
        "contamination_boundary"
      ]
    },
    "value_or_object_id": {
      "type": [
        "string",
        "null"
      ]
    },
    "valid_from": {
      "type": [
        "string",
        "null"
      ],
      "format": "date"
    },
    "valid_to": {
      "type": [
        "string",
        "null"
      ],
      "format": "date"
    },
    "observed_at": {
      "type": "string",
      "format": "date"
    },
    "source_id": {
      "type": "string",
      "minLength": 1
    },
    "source_locator": {
      "type": "string",
      "minLength": 1
    },
    "confidence": {
      "enum": [
        "source_reported",
        "editorial_synthesis"
      ]
    },
    "status": {
      "const": "observed"
    }
  }
}
