{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "anu_v3_1_go_ready_packet.schema.json",
  "title": "ANU v3.1 GO-Ready Packet",
  "description": "Emitted by micro refinement loop when Codex verdict converges to PASS or PASS_WITH_RECOMMENDATIONS and all 8 safety gates pass. Source: ANU v3 master spec section 5.7. ANCHOR-5: must contain chair_command.",
  "type": "object",
  "required": [
    "schema",
    "task_id",
    "ready_for",
    "codex_verdict",
    "critical_7",
    "permission_expansion",
    "forbidden_action",
    "required_chair_decision",
    "chair_command"
  ],
  "properties": {
    "schema": {"type": "string", "const": "anu_v3.go_ready_packet.v1"},
    "task_id": {"type": "string", "pattern": "^task-[0-9A-Za-z_+.-]+$"},
    "ready_for": {
      "type": "string",
      "enum": ["DISPATCH", "EXISTING_AUTOMATION", "EVIDENCE_WRITE", "NEXT_TASK_PLAN"]
    },
    "codex_verdict": {
      "type": "string",
      "enum": ["PASS", "PASS_WITH_RECOMMENDATIONS"]
    },
    "critical_7": {"type": "boolean", "const": false},
    "permission_expansion": {"type": "boolean", "const": false},
    "forbidden_action": {"type": "boolean", "const": false},
    "required_chair_decision": {
      "type": "string",
      "enum": ["FINAL_GO_ONLY"]
    },
    "chair_command": {
      "type": "string",
      "minLength": 1,
      "description": "Verbatim command line the chair copy-pastes to grant final GO."
    },
    "rounds": {"type": "integer", "minimum": 0},
    "changed_files": {"type": "array", "items": {"type": "string"}},
    "evidence_paths": {"type": "array", "items": {"type": "string"}},
    "generated_at": {"type": "string"}
  },
  "additionalProperties": false
}
