{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://tsukiryuu.github.io/blinka-nest/relational-continuity-conformance-report.schema.json",
  "title": "Relational Continuity Conformance Declaration",
  "type": "object",
  "required": [
    "schema",
    "generated_at",
    "implementation",
    "relationship_to_spec_author",
    "inputs",
    "results",
    "summary",
    "claim_boundary"
  ],
  "properties": {
    "schema": {
      "const": "little-life-moths.rce-conformance-declaration.v1"
    },
    "generated_at": {
      "type": "string"
    },
    "implementation": {
      "type": "object",
      "required": ["id", "version", "language", "runtime"],
      "properties": {
        "id": {"type": "string", "minLength": 1},
        "version": {"type": "string", "minLength": 1},
        "language": {"type": "string", "minLength": 1},
        "runtime": {"type": "string", "minLength": 1},
        "source_url": {"type": ["string", "null"]}
      },
      "additionalProperties": true
    },
    "relationship_to_spec_author": {
      "enum": [
        "same_project_primary_implementation",
        "same_project_secondary_implementation",
        "external_independent_implementation",
        "external_collaborating_implementation",
        "unknown"
      ]
    },
    "inputs": {
      "type": "object",
      "required": ["event_schema_sha256", "taxonomy_sha256", "conformance_corpus_sha256"],
      "properties": {
        "event_schema_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"},
        "taxonomy_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"},
        "conformance_corpus_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}
      },
      "additionalProperties": false
    },
    "results": {
      "type": "array",
      "items": {
        "type": "object",
        "required": ["vector", "expected_valid", "actual_valid", "passed"],
        "properties": {
          "vector": {"type": "string"},
          "expected_valid": {"type": "boolean"},
          "actual_valid": {"type": "boolean"},
          "passed": {"type": "boolean"},
          "note": {"type": ["string", "null"]}
        },
        "additionalProperties": true
      }
    },
    "summary": {
      "type": "object",
      "required": ["vectors", "passed", "ok"],
      "properties": {
        "vectors": {"type": "integer", "minimum": 0},
        "passed": {"type": "integer", "minimum": 0},
        "ok": {"type": "boolean"}
      },
      "additionalProperties": false
    },
    "claim_boundary": {
      "type": "string"
    }
  },
  "additionalProperties": false
}
