{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "impression_contact_sheet.schema.json",
  "title": "impression_contact_sheet input",
  "description": "Tile candidate impression pictures into one labelled grid (panel 1..N) so a single vision_analyze call can check element counts panel by panel. See docs/rendering.md - a zero exit code proves nothing about a picture; this only makes the looking cheaper.",
  "type": "object",
  "required": ["images", "out"],
  "additionalProperties": false,
  "properties": {
    "images": {
      "type": "array",
      "minItems": 1,
      "maxItems": 24,
      "description": "Paths to the pictures, in the order they should appear (panel 1 first).",
      "items": {"type": "string", "minLength": 1}
    },
    "out": {
      "type": "string",
      "minLength": 1,
      "description": "Where to write the contact sheet PNG. Parent directories are created."
    },
    "columns": {
      "type": "integer",
      "minimum": 1,
      "maximum": 8,
      "default": 3,
      "description": "Grid width in cells."
    },
    "cell_px": {
      "type": "integer",
      "minimum": 96,
      "maximum": 2048,
      "default": 640,
      "description": "Longest side of one cell, in px, before tiling."
    },
    "labels": {
      "type": "array",
      "description": "One caption per image. Shorter than images is padded with the panel number; longer is ignored.",
      "items": {"type": "string"}
    },
    "title": {
      "type": "string",
      "default": "",
      "description": "Heading printed across the top of the sheet."
    }
  }
}
