{
  "$defs": {
    "ReviewPlanCase": {
      "description": "One test case in a plan or a case group, pinned to an exact version (and\nvariant). Coverage is counted against exactly this version; the matrix flags it\nwhen a newer version has since been ingested.",
      "properties": {
        "slug": {
          "description": "The test-case slug (e.g. `caldera`).",
          "type": "string"
        },
        "variant": {
          "description": "The variant to cover (e.g. `base`).",
          "type": "string"
        },
        "version": {
          "description": "The pinned, exact version (e.g. `v1.2.0`).",
          "type": "string"
        }
      },
      "required": ["slug", "version", "variant"],
      "type": "object"
    },
    "ReviewPlanCombo": {
      "description": "One harness+model combination in a plan or a combo group. The optional provider\nmirrors the new-run form's per-combination provider for provider-routed\nharnesses.",
      "properties": {
        "harness": {
          "$ref": "https://docs.testcabinet.ai/schema/core/run-record.schema.json#/$defs/HarnessSlug",
          "description": "The agent harness to drive."
        },
        "model": {
          "description": "The opaque model id passed to the harness.",
          "type": "string"
        },
        "provider": {
          "description": "The provider for a provider-routed harness, or null.",
          "type": ["string", "null"]
        }
      },
      "required": ["harness", "model"],
      "type": "object"
    }
  },
  "$id": "https://docs.testcabinet.ai/schema/coverage/coverage-plan.schema.json",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "description": "A reviewer's named coverage plan **as declared**: the groups it references, any\none-off members, and the target runs-per-cell. Persisted whole; one account may\nhold many.\n\nHow the plan is *fed* is [`CoverageSchedule`], stored beside this and never\nwritten by a declaration save. Handlers return the two flattened together as\n[`CoveragePlanOut`].",
  "properties": {
    "caseGroupIds": {
      "description": "The referenced case groups' ids.",
      "items": {
        "type": "string"
      },
      "type": "array"
    },
    "cases": {
      "description": "One-off cases pinned directly on the plan (unioned with the groups).",
      "items": {
        "$ref": "#/$defs/ReviewPlanCase"
      },
      "type": "array"
    },
    "comboGroupIds": {
      "description": "The referenced combination groups' ids.",
      "items": {
        "type": "string"
      },
      "type": "array"
    },
    "combos": {
      "description": "One-off combinations pinned directly on the plan (unioned with the groups).",
      "items": {
        "$ref": "#/$defs/ReviewPlanCombo"
      },
      "type": "array"
    },
    "id": {
      "description": "The plan's opaque id (minted on create).",
      "type": "string"
    },
    "name": {
      "description": "The reviewer-chosen display name.",
      "type": "string"
    },
    "runsPerCell": {
      "description": "The target number of runs desired for each `case × combination` cell.",
      "format": "uint32",
      "minimum": 0,
      "type": "integer"
    },
    "updatedAt": {
      "description": "RFC 3339 of when the plan was last saved.",
      "type": "string"
    }
  },
  "required": [
    "id",
    "name",
    "runsPerCell",
    "comboGroupIds",
    "caseGroupIds",
    "combos",
    "cases",
    "updatedAt"
  ],
  "title": "CoveragePlan",
  "type": "object"
}
