{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "https://cdn.jsdelivr.net/npm/@pie-element/categorize@14.0.6/dist/schemas/session.schema.json",
  "type": "object",
  "properties": {
    "id": {
      "type": [
        "string",
        "number"
      ],
      "description": "Identifier of the session; the correct-response session carries the number 1"
    },
    "element": {
      "type": "string",
      "description": "The element the session belongs to"
    },
    "answers": {
      "type": "array",
      "items": {
        "$ref": "#/definitions/CategorizeAnswer"
      },
      "description": "The choices placed in each category"
    },
    "selector": {
      "type": "string",
      "description": "The input that made the last change; the delivery writes `Mouse`"
    },
    "audioStartTime": {
      "type": "number",
      "description": "When auto-played prompt audio started, in epoch milliseconds"
    },
    "audioEndTime": {
      "type": "number",
      "description": "When auto-played prompt audio ended, in epoch milliseconds"
    },
    "waitTime": {
      "type": "number",
      "description": "Milliseconds the learner waited for auto-played prompt audio to finish"
    },
    "shuffledValues": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Choice ids in the order they were shuffled for this learner, when choice order is not locked"
    }
  },
  "definitions": {
    "CategorizeAnswer": {
      "type": "object",
      "properties": {
        "category": {
          "type": "string",
          "description": "The identifier for the category"
        },
        "choices": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "Identifiers of the choices placed in the category"
        }
      },
      "required": [
        "category",
        "choices"
      ],
      "description": "The choices the learner placed in one category"
    }
  }
}
