{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook-use-case/1.0.0/data.schema.json",
  "title": "Codeops Playbook Use Case",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "$schema",
    "meta",
    "content",
    "assets",
    "references",
    "annotations"
  ],
  "cuddler": {
    "specVersion": "1.0.0-draft.7",
    "documentTypeId": "codeops-playbook-use-case",
    "schemaVersion": "1.0.0",
    "output": {
      "primaryContentType": "application/json",
      "supportedContentTypes": [
        "application/json"
      ]
    },
    "profile": {
      "id": "codeops-playbook",
      "version": "1.0.0",
      "for-ai": [
        {
          "instruction": "Explain what this Cuddler schema profile governs so AI consumers understand when to use this schema family.",
          "input": "",
          "output": "Codeops Playbook parent-and-child schema family layered on the Cuddler d7 core data specification."
        }
      ]
    },
    "schemaLinks": [
      {
        "rel": "parent-artifact-definition",
        "targetSchema": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook/1.0.0/data.schema.json",
        "targetDocumentTypeId": "codeops-playbook",
        "for-ai": [
          {
            "instruction": "Explain why codeops-playbook is linked here and when an AI consumer should follow that related schema.",
            "input": "",
            "output": "This child schema belongs to the parent Codeops Playbook Artifact Definition."
          }
        ]
      },
      {
        "rel": "related",
        "targetSchema": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook-acceptance-metrics/1.0.0/data.schema.json",
        "targetDocumentTypeId": "codeops-playbook-acceptance-metrics",
        "for-ai": [
          {
            "instruction": "Explain why codeops-playbook-acceptance-metrics is linked here and when an AI consumer should follow that related schema.",
            "input": "",
            "output": "Related Playbook document schema for Acceptance Metrics."
          }
        ]
      },
      {
        "rel": "related",
        "targetSchema": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook-amendment/1.0.0/data.schema.json",
        "targetDocumentTypeId": "codeops-playbook-amendment",
        "for-ai": [
          {
            "instruction": "Explain why codeops-playbook-amendment is linked here and when an AI consumer should follow that related schema.",
            "input": "",
            "output": "Related Playbook document schema for Amendment."
          }
        ]
      },
      {
        "rel": "related",
        "targetSchema": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook-api-integration-and-sync-engine/1.0.0/data.schema.json",
        "targetDocumentTypeId": "codeops-playbook-api-integration-and-sync-engine",
        "for-ai": [
          {
            "instruction": "Explain why codeops-playbook-api-integration-and-sync-engine is linked here and when an AI consumer should follow that related schema.",
            "input": "",
            "output": "Related Playbook document schema for Api Integration And Sync Engine."
          }
        ]
      },
      {
        "rel": "related",
        "targetSchema": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook-local-storage-and-evidence-model/1.0.0/data.schema.json",
        "targetDocumentTypeId": "codeops-playbook-local-storage-and-evidence-model",
        "for-ai": [
          {
            "instruction": "Explain why codeops-playbook-local-storage-and-evidence-model is linked here and when an AI consumer should follow that related schema.",
            "input": "",
            "output": "Related Playbook document schema for Local Storage And Evidence Model."
          }
        ]
      },
      {
        "rel": "related",
        "targetSchema": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook-project-structure-and-boundaries/1.0.0/data.schema.json",
        "targetDocumentTypeId": "codeops-playbook-project-structure-and-boundaries",
        "for-ai": [
          {
            "instruction": "Explain why codeops-playbook-project-structure-and-boundaries is linked here and when an AI consumer should follow that related schema.",
            "input": "",
            "output": "Related Playbook document schema for Project Structure And Boundaries."
          }
        ]
      },
      {
        "rel": "related",
        "targetSchema": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook-route-api-use-case-matrix/1.0.0/data.schema.json",
        "targetDocumentTypeId": "codeops-playbook-route-api-use-case-matrix",
        "for-ai": [
          {
            "instruction": "Explain why codeops-playbook-route-api-use-case-matrix is linked here and when an AI consumer should follow that related schema.",
            "input": "",
            "output": "Related Playbook document schema for Route Api Use Case Matrix."
          }
        ]
      },
      {
        "rel": "related",
        "targetSchema": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook-target-architecture/1.0.0/data.schema.json",
        "targetDocumentTypeId": "codeops-playbook-target-architecture",
        "for-ai": [
          {
            "instruction": "Explain why codeops-playbook-target-architecture is linked here and when an AI consumer should follow that related schema.",
            "input": "",
            "output": "Related Playbook document schema for Target Architecture."
          }
        ]
      },
      {
        "rel": "related",
        "targetSchema": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook-testing-strategy/1.0.0/data.schema.json",
        "targetDocumentTypeId": "codeops-playbook-testing-strategy",
        "for-ai": [
          {
            "instruction": "Explain why codeops-playbook-testing-strategy is linked here and when an AI consumer should follow that related schema.",
            "input": "",
            "output": "Related Playbook document schema for Testing Strategy."
          }
        ]
      },
      {
        "rel": "related",
        "targetSchema": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook-ui-and-routing/1.0.0/data.schema.json",
        "targetDocumentTypeId": "codeops-playbook-ui-and-routing",
        "for-ai": [
          {
            "instruction": "Explain why codeops-playbook-ui-and-routing is linked here and when an AI consumer should follow that related schema.",
            "input": "",
            "output": "Related Playbook document schema for Ui And Routing."
          }
        ]
      },
      {
        "rel": "related",
        "targetSchema": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook-use-case-driven-development/1.0.0/data.schema.json",
        "targetDocumentTypeId": "codeops-playbook-use-case-driven-development",
        "for-ai": [
          {
            "instruction": "Explain why codeops-playbook-use-case-driven-development is linked here and when an AI consumer should follow that related schema.",
            "input": "",
            "output": "Related Playbook document schema for Use Case Driven Development."
          }
        ]
      }
    ]
  },
  "properties": {
    "$schema": {
      "type": "string",
      "format": "uri",
      "const": "https://www.cuddler.dev/standards/artifact-definitions/codeops-playbook-use-case/1.0.0/data.schema.json",
      "for-ai": [
        {
          "instruction": "Use this guidance when preparing a valid value for this schema node.",
          "input": "",
          "output": "Absolute URI for this immutable schema."
        }
      ]
    },
    "meta": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "documentId",
        "documentTypeId",
        "schemaVersion",
        "title",
        "createdAt",
        "updatedAt",
        "authors"
      ],
      "properties": {
        "documentId": {
          "type": "string",
          "format": "uuid",
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Document UUID."
            }
          ]
        },
        "documentTypeId": {
          "type": "string",
          "const": "codeops-playbook-use-case",
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Stable document type identifier."
            }
          ]
        },
        "schemaVersion": {
          "type": "string",
          "const": "1.0.0",
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Document schema version."
            }
          ]
        },
        "title": {
          "type": "string",
          "pattern": "^UC-[A-Z][A-Z-]*-\\d{3}-.+$",
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Human-readable document title."
            }
          ]
        },
        "createdAt": {
          "type": "string",
          "format": "date-time",
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Creation timestamp."
            }
          ]
        },
        "updatedAt": {
          "type": "string",
          "format": "date-time",
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Last update timestamp."
            }
          ]
        },
        "authors": {
          "type": "array",
          "minItems": 1,
          "items": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "id",
              "name"
            ],
            "properties": {
              "id": {
                "type": "string",
                "format": "uuid",
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Author UUID."
                  }
                ]
              },
              "name": {
                "type": "string",
                "minLength": 1,
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Author display name."
                  }
                ]
              },
              "email": {
                "type": "string",
                "format": "email",
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Optional author email address."
                  }
                ]
              }
            },
            "for-ai": [
              {
                "instruction": "Use this guidance when preparing a valid value for this schema node.",
                "input": "",
                "output": "Author identity record."
              }
            ]
          },
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Ordered list of document authors."
            }
          ]
        },
        "summary": {
          "type": "string",
          "minLength": 1,
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Short document summary."
            }
          ]
        }
      },
      "for-ai": [
        {
          "instruction": "Use this guidance when preparing a valid value for this schema node.",
          "input": "",
          "output": "Document identity and authorship metadata."
        }
      ]
    },
    "content": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "sections",
        "documentModel"
      ],
      "properties": {
        "sections": {
          "type": "array",
          "minItems": 7,
          "items": {
            "oneOf": [
              {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "key",
                  "heading",
                  "blocks"
                ],
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "summary",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Stable section key."
                      }
                    ]
                  },
                  "heading": {
                    "type": "string",
                    "const": "Summary",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Rendered section heading."
                      }
                    ]
                  },
                  "blocks": {
                    "type": "array",
                    "minItems": 1,
                    "items": {
                      "type": "object",
                      "additionalProperties": false,
                      "required": [
                        "kind",
                        "blockId",
                        "text"
                      ],
                      "properties": {
                        "kind": {
                          "type": "string",
                          "const": "text",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Block kind discriminator."
                            }
                          ]
                        },
                        "blockId": {
                          "type": "string",
                          "format": "uuid",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Unique block UUID."
                            }
                          ]
                        },
                        "text": {
                          "type": "string",
                          "minLength": 1,
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Markdown body text."
                            }
                          ]
                        },
                        "format": {
                          "type": "string",
                          "enum": [
                            "markdown"
                          ],
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Text serialization format."
                            }
                          ]
                        }
                      },
                      "for-ai": [
                        {
                          "instruction": "Use this guidance when preparing a valid value for this schema node.",
                          "input": "",
                          "output": "Markdown text block."
                        }
                      ]
                    },
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Markdown content blocks for the section."
                      }
                    ]
                  },
                  "subsections": {
                    "type": "array",
                    "items": false,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Nested subsections for the section."
                      }
                    ]
                  }
                },
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Summary section."
                  }
                ]
              },
              {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "key",
                  "heading",
                  "blocks"
                ],
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "preconditions",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Stable section key."
                      }
                    ]
                  },
                  "heading": {
                    "type": "string",
                    "const": "Preconditions",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Rendered section heading."
                      }
                    ]
                  },
                  "blocks": {
                    "type": "array",
                    "minItems": 1,
                    "items": {
                      "type": "object",
                      "additionalProperties": false,
                      "required": [
                        "kind",
                        "blockId",
                        "text"
                      ],
                      "properties": {
                        "kind": {
                          "type": "string",
                          "const": "text",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Block kind discriminator."
                            }
                          ]
                        },
                        "blockId": {
                          "type": "string",
                          "format": "uuid",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Unique block UUID."
                            }
                          ]
                        },
                        "text": {
                          "type": "string",
                          "minLength": 1,
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Markdown body text."
                            }
                          ]
                        },
                        "format": {
                          "type": "string",
                          "enum": [
                            "markdown"
                          ],
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Text serialization format."
                            }
                          ]
                        }
                      },
                      "for-ai": [
                        {
                          "instruction": "Use this guidance when preparing a valid value for this schema node.",
                          "input": "",
                          "output": "Markdown text block."
                        }
                      ]
                    },
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Markdown content blocks for the section."
                      }
                    ]
                  },
                  "subsections": {
                    "type": "array",
                    "items": false,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Nested subsections for the section."
                      }
                    ]
                  }
                },
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Preconditions section."
                  }
                ]
              },
              {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "key",
                  "heading",
                  "blocks"
                ],
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "trigger",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Stable section key."
                      }
                    ]
                  },
                  "heading": {
                    "type": "string",
                    "const": "Trigger",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Rendered section heading."
                      }
                    ]
                  },
                  "blocks": {
                    "type": "array",
                    "minItems": 1,
                    "items": {
                      "type": "object",
                      "additionalProperties": false,
                      "required": [
                        "kind",
                        "blockId",
                        "text"
                      ],
                      "properties": {
                        "kind": {
                          "type": "string",
                          "const": "text",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Block kind discriminator."
                            }
                          ]
                        },
                        "blockId": {
                          "type": "string",
                          "format": "uuid",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Unique block UUID."
                            }
                          ]
                        },
                        "text": {
                          "type": "string",
                          "minLength": 1,
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Markdown body text."
                            }
                          ]
                        },
                        "format": {
                          "type": "string",
                          "enum": [
                            "markdown"
                          ],
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Text serialization format."
                            }
                          ]
                        }
                      },
                      "for-ai": [
                        {
                          "instruction": "Use this guidance when preparing a valid value for this schema node.",
                          "input": "",
                          "output": "Markdown text block."
                        }
                      ]
                    },
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Markdown content blocks for the section."
                      }
                    ]
                  },
                  "subsections": {
                    "type": "array",
                    "items": false,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Nested subsections for the section."
                      }
                    ]
                  }
                },
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Trigger section."
                  }
                ]
              },
              {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "key",
                  "heading",
                  "blocks"
                ],
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "primary-flow",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Stable section key."
                      }
                    ]
                  },
                  "heading": {
                    "type": "string",
                    "const": "Primary flow",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Rendered section heading."
                      }
                    ]
                  },
                  "blocks": {
                    "type": "array",
                    "minItems": 1,
                    "items": {
                      "type": "object",
                      "additionalProperties": false,
                      "required": [
                        "kind",
                        "blockId",
                        "text"
                      ],
                      "properties": {
                        "kind": {
                          "type": "string",
                          "const": "text",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Block kind discriminator."
                            }
                          ]
                        },
                        "blockId": {
                          "type": "string",
                          "format": "uuid",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Unique block UUID."
                            }
                          ]
                        },
                        "text": {
                          "type": "string",
                          "minLength": 1,
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Markdown body text."
                            }
                          ]
                        },
                        "format": {
                          "type": "string",
                          "enum": [
                            "markdown"
                          ],
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Text serialization format."
                            }
                          ]
                        }
                      },
                      "for-ai": [
                        {
                          "instruction": "Use this guidance when preparing a valid value for this schema node.",
                          "input": "",
                          "output": "Markdown text block."
                        }
                      ]
                    },
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Markdown content blocks for the section."
                      }
                    ]
                  },
                  "subsections": {
                    "type": "array",
                    "items": false,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Nested subsections for the section."
                      }
                    ]
                  }
                },
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Primary flow section."
                  }
                ]
              },
              {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "key",
                  "heading",
                  "blocks"
                ],
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "alternate-or-failure-flow",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Stable section key."
                      }
                    ]
                  },
                  "heading": {
                    "type": "string",
                    "const": "Alternate or failure flow",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Rendered section heading."
                      }
                    ]
                  },
                  "blocks": {
                    "type": "array",
                    "minItems": 1,
                    "items": {
                      "type": "object",
                      "additionalProperties": false,
                      "required": [
                        "kind",
                        "blockId",
                        "text"
                      ],
                      "properties": {
                        "kind": {
                          "type": "string",
                          "const": "text",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Block kind discriminator."
                            }
                          ]
                        },
                        "blockId": {
                          "type": "string",
                          "format": "uuid",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Unique block UUID."
                            }
                          ]
                        },
                        "text": {
                          "type": "string",
                          "minLength": 1,
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Markdown body text."
                            }
                          ]
                        },
                        "format": {
                          "type": "string",
                          "enum": [
                            "markdown"
                          ],
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Text serialization format."
                            }
                          ]
                        }
                      },
                      "for-ai": [
                        {
                          "instruction": "Use this guidance when preparing a valid value for this schema node.",
                          "input": "",
                          "output": "Markdown text block."
                        }
                      ]
                    },
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Markdown content blocks for the section."
                      }
                    ]
                  },
                  "subsections": {
                    "type": "array",
                    "items": false,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Nested subsections for the section."
                      }
                    ]
                  }
                },
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Alternate or failure flow section."
                  }
                ]
              },
              {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "key",
                  "heading",
                  "blocks"
                ],
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "contracts",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Stable section key."
                      }
                    ]
                  },
                  "heading": {
                    "type": "string",
                    "const": "Contracts",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Rendered section heading."
                      }
                    ]
                  },
                  "blocks": {
                    "type": "array",
                    "minItems": 1,
                    "items": {
                      "type": "object",
                      "additionalProperties": false,
                      "required": [
                        "kind",
                        "blockId",
                        "text"
                      ],
                      "properties": {
                        "kind": {
                          "type": "string",
                          "const": "text",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Block kind discriminator."
                            }
                          ]
                        },
                        "blockId": {
                          "type": "string",
                          "format": "uuid",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Unique block UUID."
                            }
                          ]
                        },
                        "text": {
                          "type": "string",
                          "minLength": 1,
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Markdown body text."
                            }
                          ]
                        },
                        "format": {
                          "type": "string",
                          "enum": [
                            "markdown"
                          ],
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Text serialization format."
                            }
                          ]
                        }
                      },
                      "for-ai": [
                        {
                          "instruction": "Use this guidance when preparing a valid value for this schema node.",
                          "input": "",
                          "output": "Markdown text block."
                        }
                      ]
                    },
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Markdown content blocks for the section."
                      }
                    ]
                  },
                  "subsections": {
                    "type": "array",
                    "items": false,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Nested subsections for the section."
                      }
                    ]
                  }
                },
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Contracts section."
                  }
                ]
              },
              {
                "type": "object",
                "additionalProperties": false,
                "required": [
                  "key",
                  "heading",
                  "blocks"
                ],
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "automated-coverage",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Stable section key."
                      }
                    ]
                  },
                  "heading": {
                    "type": "string",
                    "const": "Automated coverage",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Rendered section heading."
                      }
                    ]
                  },
                  "blocks": {
                    "type": "array",
                    "minItems": 1,
                    "items": {
                      "type": "object",
                      "additionalProperties": false,
                      "required": [
                        "kind",
                        "blockId",
                        "text"
                      ],
                      "properties": {
                        "kind": {
                          "type": "string",
                          "const": "text",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Block kind discriminator."
                            }
                          ]
                        },
                        "blockId": {
                          "type": "string",
                          "format": "uuid",
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Unique block UUID."
                            }
                          ]
                        },
                        "text": {
                          "type": "string",
                          "minLength": 1,
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Markdown body text."
                            }
                          ]
                        },
                        "format": {
                          "type": "string",
                          "enum": [
                            "markdown"
                          ],
                          "for-ai": [
                            {
                              "instruction": "Use this guidance when preparing a valid value for this schema node.",
                              "input": "",
                              "output": "Text serialization format."
                            }
                          ]
                        }
                      },
                      "for-ai": [
                        {
                          "instruction": "Use this guidance when preparing a valid value for this schema node.",
                          "input": "",
                          "output": "Markdown text block."
                        }
                      ]
                    },
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Markdown content blocks for the section."
                      }
                    ]
                  },
                  "subsections": {
                    "type": "array",
                    "items": false,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Nested subsections for the section."
                      }
                    ]
                  }
                },
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Automated coverage section."
                  }
                ]
              }
            ]
          },
          "allOf": [
            {
              "contains": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "summary",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Required section key."
                      }
                    ]
                  }
                },
                "required": [
                  "key"
                ],
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Required section selector for summary."
                  }
                ]
              },
              "minContains": 1
            },
            {
              "contains": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "preconditions",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Required section key."
                      }
                    ]
                  }
                },
                "required": [
                  "key"
                ],
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Required section selector for preconditions."
                  }
                ]
              },
              "minContains": 1
            },
            {
              "contains": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "trigger",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Required section key."
                      }
                    ]
                  }
                },
                "required": [
                  "key"
                ],
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Required section selector for trigger."
                  }
                ]
              },
              "minContains": 1
            },
            {
              "contains": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "primary-flow",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Required section key."
                      }
                    ]
                  }
                },
                "required": [
                  "key"
                ],
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Required section selector for primary-flow."
                  }
                ]
              },
              "minContains": 1
            },
            {
              "contains": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "alternate-or-failure-flow",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Required section key."
                      }
                    ]
                  }
                },
                "required": [
                  "key"
                ],
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Required section selector for alternate-or-failure-flow."
                  }
                ]
              },
              "minContains": 1
            },
            {
              "contains": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "contracts",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Required section key."
                      }
                    ]
                  }
                },
                "required": [
                  "key"
                ],
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Required section selector for contracts."
                  }
                ]
              },
              "minContains": 1
            },
            {
              "contains": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "const": "automated-coverage",
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Required section key."
                      }
                    ]
                  }
                },
                "required": [
                  "key"
                ],
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Required section selector for automated-coverage."
                  }
                ]
              },
              "minContains": 1
            }
          ],
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Top-level sections for the document."
            }
          ]
        },
        "documentModel": {
          "type": "object",
          "additionalProperties": false,
          "required": [
            "catalogEntry"
          ],
          "properties": {
            "catalogEntry": {
              "type": "object",
              "additionalProperties": false,
              "required": [
                "key",
                "path",
                "title",
                "kind",
                "scope",
                "priority",
                "canonicalOwnerPath",
                "whenToLoad",
                "appliesToPaths",
                "relatedTopics",
                "routeScope",
                "relatedDocumentPaths",
                "triggerConditions",
                "lastReviewed",
                "legacyMarkdownPath"
              ],
              "properties": {
                "key": {
                  "type": "string",
                  "pattern": "^[a-z][a-z0-9-]{2,62}$",
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Stable catalog entry key."
                    }
                  ]
                },
                "path": {
                  "type": "string",
                  "pattern": "^Playbook/docs/use-cases/.+\\.json$",
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Catalog entry path."
                    }
                  ]
                },
                "title": {
                  "type": "string",
                  "pattern": "^UC-[A-Z][A-Z-]*-\\d{3}-.+$",
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Catalog entry title."
                    }
                  ]
                },
                "kind": {
                  "type": "string",
                  "enum": [
                    "playbook-doc",
                    "use-case"
                  ],
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Catalog entry kind."
                    }
                  ]
                },
                "scope": {
                  "type": "string",
                  "minLength": 1,
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Catalog entry scope."
                    }
                  ]
                },
                "priority": {
                  "type": "string",
                  "enum": [
                    "always",
                    "targeted",
                    "fallback",
                    "override"
                  ],
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Catalog entry loading priority."
                    }
                  ]
                },
                "canonicalOwnerPath": {
                  "type": "string",
                  "pattern": "^Playbook/docs/use-cases/.+\\.json$",
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Owning canonical path for the document."
                    }
                  ]
                },
                "whenToLoad": {
                  "type": "array",
                  "minItems": 1,
                  "items": {
                    "type": "string",
                    "minLength": 1,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Load guidance item."
                      }
                    ]
                  },
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Guidance for when to load this document."
                    }
                  ]
                },
                "appliesToPaths": {
                  "type": "array",
                  "minItems": 1,
                  "items": {
                    "type": "string",
                    "minLength": 1,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Affected path glob."
                      }
                    ]
                  },
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Affected repository paths."
                    }
                  ]
                },
                "relatedTopics": {
                  "type": "array",
                  "minItems": 1,
                  "items": {
                    "type": "string",
                    "minLength": 1,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Related topic."
                      }
                    ]
                  },
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Related retrieval topics."
                    }
                  ]
                },
                "routeScope": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "minLength": 1,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Route scope item."
                      }
                    ]
                  },
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Covered routes or route-like surfaces."
                    }
                  ]
                },
                "relatedDocumentPaths": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "minLength": 1,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Related catalog path."
                      }
                    ]
                  },
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Related catalog entry paths."
                    }
                  ]
                },
                "baseDocumentPath": {
                  "type": "string",
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Optional base document path."
                    }
                  ]
                },
                "triggerConditions": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "minLength": 1,
                    "for-ai": [
                      {
                        "instruction": "Use this guidance when preparing a valid value for this schema node.",
                        "input": "",
                        "output": "Trigger condition."
                      }
                    ]
                  },
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Additional trigger guidance."
                    }
                  ]
                },
                "lastReviewed": {
                  "type": "string",
                  "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Last reviewed date."
                    }
                  ]
                },
                "legacyMarkdownPath": {
                  "type": "string",
                  "pattern": "^Playbook/docs/use-cases/.+\\.md$",
                  "for-ai": [
                    {
                      "instruction": "Use this guidance when preparing a valid value for this schema node.",
                      "input": "",
                      "output": "Legacy markdown path replaced by this JSON document."
                    }
                  ]
                }
              },
              "for-ai": [
                {
                  "instruction": "Use this guidance when preparing a valid value for this schema node.",
                  "input": "",
                  "output": "Catalog metadata for this document."
                }
              ]
            }
          },
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Catalog metadata mirrored from the Playbook index."
            }
          ]
        }
      },
      "for-ai": [
        {
          "instruction": "Use this guidance when preparing a valid value for this schema node.",
          "input": "",
          "output": "Human-readable section content plus catalog metadata."
        }
      ]
    },
    "assets": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "library"
      ],
      "properties": {
        "library": {
          "type": "array",
          "items": {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "id",
              "kind",
              "title",
              "altText",
              "locator"
            ],
            "properties": {
              "id": {
                "type": "string",
                "format": "uuid",
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Asset UUID."
                  }
                ]
              },
              "kind": {
                "type": "string",
                "enum": [
                  "file",
                  "link"
                ],
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Asset type discriminator."
                  }
                ]
              },
              "title": {
                "type": "string",
                "minLength": 1,
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Asset title."
                  }
                ]
              },
              "altText": {
                "type": "string",
                "minLength": 1,
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Accessible asset description."
                  }
                ]
              },
              "contentType": {
                "type": "string",
                "minLength": 1,
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Optional MIME type."
                  }
                ]
              },
              "locator": {
                "type": "string",
                "minLength": 1,
                "for-ai": [
                  {
                    "instruction": "Use this guidance when preparing a valid value for this schema node.",
                    "input": "",
                    "output": "Asset locator or repository path."
                  }
                ]
              }
            },
            "for-ai": [
              {
                "instruction": "Use this guidance when preparing a valid value for this schema node.",
                "input": "",
                "output": "Asset descriptor."
              }
            ]
          },
          "for-ai": [
            {
              "instruction": "Use this guidance when preparing a valid value for this schema node.",
              "input": "",
              "output": "Asset library entries."
            }
          ]
        }
      },
      "for-ai": [
        {
          "instruction": "Use this guidance when preparing a valid value for this schema node.",
          "input": "",
          "output": "Strict asset container."
        }
      ]
    },
    "references": {
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "id",
          "title",
          "locator"
        ],
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid",
            "for-ai": [
              {
                "instruction": "Use this guidance when preparing a valid value for this schema node.",
                "input": "",
                "output": "Reference UUID."
              }
            ]
          },
          "title": {
            "type": "string",
            "minLength": 1,
            "for-ai": [
              {
                "instruction": "Use this guidance when preparing a valid value for this schema node.",
                "input": "",
                "output": "Reference title."
              }
            ]
          },
          "locator": {
            "type": "string",
            "minLength": 1,
            "for-ai": [
              {
                "instruction": "Use this guidance when preparing a valid value for this schema node.",
                "input": "",
                "output": "Reference locator."
              }
            ]
          },
          "kind": {
            "type": "string",
            "minLength": 1,
            "for-ai": [
              {
                "instruction": "Use this guidance when preparing a valid value for this schema node.",
                "input": "",
                "output": "Optional reference kind."
              }
            ]
          },
          "notes": {
            "type": "string",
            "minLength": 1,
            "for-ai": [
              {
                "instruction": "Use this guidance when preparing a valid value for this schema node.",
                "input": "",
                "output": "Optional explanation of the reference."
              }
            ]
          }
        },
        "for-ai": [
          {
            "instruction": "Use this guidance when preparing a valid value for this schema node.",
            "input": "",
            "output": "External reference record."
          }
        ]
      },
      "for-ai": [
        {
          "instruction": "Use this guidance when preparing a valid value for this schema node.",
          "input": "",
          "output": "External references used by the document."
        }
      ]
    },
    "annotations": {
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "key",
          "value"
        ],
        "properties": {
          "key": {
            "type": "string",
            "pattern": "^[a-z0-9][a-z0-9.-]*:[a-z0-9][a-z0-9-]*$",
            "for-ai": [
              {
                "instruction": "Use this guidance when preparing a valid value for this schema node.",
                "input": "",
                "output": "Namespaced annotation key."
              }
            ]
          },
          "value": {
            "type": [
              "string",
              "number",
              "boolean",
              "null"
            ],
            "for-ai": [
              {
                "instruction": "Use this guidance when preparing a valid value for this schema node.",
                "input": "",
                "output": "Scalar annotation value."
              }
            ]
          }
        },
        "for-ai": [
          {
            "instruction": "Use this guidance when preparing a valid value for this schema node.",
            "input": "",
            "output": "Scalar annotation record."
          }
        ]
      },
      "for-ai": [
        {
          "instruction": "Use this guidance when preparing a valid value for this schema node.",
          "input": "",
          "output": "Scalar annotations for non-canonical helper metadata."
        }
      ]
    }
  },
  "for-ai": [
    {
      "instruction": "Use this guidance when preparing a valid value for this schema node.",
      "input": "",
      "output": "Cuddler-compliant child schema for Codeops Playbook use-case documents."
    }
  ]
}
