{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://oometa.ai/knowledge/handoff.schema.json",
  "title": "OOMeta reviewable task handoff",
  "description": "Structural contract only. Does not authorize execution or verify evidence. Acceptance checks are review instructions, never auto-executed commands.",
  "type": "object",
  "additionalProperties": false,
  "required": ["schema_version", "task_id", "previous_conclusion", "evidence", "acceptance_criteria", "owner", "due_at", "escalation"],
  "properties": {
    "schema_version": {"const": 1},
    "task_id": {"type": "string", "minLength": 1},
    "previous_conclusion": {"type": "string", "minLength": 1},
    "evidence": {
      "type": "array", "minItems": 1,
      "items": {
        "type": "object", "additionalProperties": false,
        "required": ["id", "reference", "observed_at", "verification"],
        "properties": {
          "id": {"type": "string", "minLength": 1},
          "reference": {"type": "string", "minLength": 1},
          "observed_at": {"type": "string", "format": "date-time"},
          "verification": {"enum": ["not-verified", "internally-reviewed", "independently-verified"]}
        }
      }
    },
    "acceptance_criteria": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}},
    "owner": {"type": "string", "minLength": 1},
    "due_at": {"type": "string", "format": "date-time"},
    "escalation": {
      "type": "object", "additionalProperties": false,
      "required": ["owner", "condition"],
      "properties": {"owner": {"type": "string", "minLength": 1}, "condition": {"type": "string", "minLength": 1}}
    }
  }
}
