{
  "$id": "https://commandlayer.org/schemas/v1.1.0/commons/classify/classify.receipt.schema.json",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "classify.receipt",
  "description": "Receipt for a classify request, including assigned labels and optional scores or taxonomy.",
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "verb": {
      "type": "string",
      "const": "classify"
    },
    "schema_version": {
      "type": "string",
      "const": "1.1.0"
    },
    "status": {
      "description": "Outcome status for this verb invocation.",
      "type": "string",
      "enum": [
        "success",
        "error",
        "delegated"
      ]
    },
    "labels": {
      "description": "Labels assigned to the input.",
      "type": "array",
      "items": {
        "type": "string",
        "minLength": 1,
        "maxLength": 128
      },
      "minItems": 1,
      "maxItems": 128
    },
    "scores": {
      "description": "Optional per-label scores between 0 and 1.",
      "type": "array",
      "items": {
        "type": "number",
        "minimum": 0,
        "maximum": 1
      },
      "maxItems": 128
    },
    "taxonomy": {
      "description": "Optional taxonomy or hierarchy path used for classification.",
      "type": "array",
      "items": {
        "type": "string",
        "minLength": 1,
        "maxLength": 256
      },
      "maxItems": 128
    }
  },
  "required": [
    "verb",
    "schema_version",
    "status",
    "labels"
  ]
}
