{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/cueframe-ai/json-schema/cueframe-ai-critic-create-request-schema.json",
  "title": "CriticCreateRequest",
  "description": "Register a custom compose critic.",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/cueframe-ai-critics-api-openapi.yml#/components/schemas/CriticCreateRequest",
  "type": "object",
  "properties": {
    "criticId": {
      "type": "string",
      "minLength": 1,
      "description": "Stable client id; re-registering the same id UPSERTS."
    },
    "label": {
      "type": "string",
      "minLength": 1
    },
    "tier": {
      "type": "string",
      "enum": [
        "rules",
        "rubric",
        "evaluator"
      ]
    },
    "floor": {
      "description": "Score below this routes a refine like a built-in criterion. Defaults to 6.",
      "type": "number",
      "minimum": 0,
      "maximum": 10
    },
    "rules": {
      "description": "tier \"rules\": declarative ClientRule[] (data).",
      "type": "array",
      "items": {
        "type": "object",
        "propertyNames": {
          "type": "string"
        },
        "additionalProperties": {}
      }
    },
    "rubric": {
      "description": "tier \"rubric\": your criterion + description; scored as an extra column.",
      "type": "string"
    },
    "referenceMediaIds": {
      "description": "tier \"rubric\"/\"evaluator\": up to 6 org media ids whose thumbnails the judge sees as YOUR reference standard — \"looks like mine\" becomes a machine check. Each must be an org-owned media item with a visual thumbnail (422 names any that is not).",
      "maxItems": 6,
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "url": {
      "description": "tier \"evaluator\": your HTTPS webhook; CueFrame POSTs the artifact.",
      "type": "string",
      "format": "uri"
    }
  },
  "required": [
    "criticId",
    "label",
    "tier"
  ],
  "additionalProperties": false
}