{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "urn:gdd:manifest:skills",
  "title": "manifest/skills.json",
  "type": "object",
  "required": [
    "schema_version",
    "skills"
  ],
  "additionalProperties": true,
  "properties": {
    "schema_version": {
      "type": "integer",
      "minimum": 1
    },
    "skills": {
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": true,
        "required": [
          "name"
        ],
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "description": "Skill id = scripts/skill-templates/<name>/ directory name."
          },
          "frontmatter_name": {
            "type": "string",
            "description": "Frontmatter name: value when it is not the default gdd-<name>."
          },
          "description": {
            "type": "string",
            "minLength": 20,
            "maxLength": 1024,
            "description": "Skill description (Phase 28.5 budget: 20..1024 chars)."
          },
          "argument_hint": {
            "type": "string"
          },
          "tools": {
            "type": "string",
            "description": "Comma-separated allow-list emitted as the frontmatter tools: line."
          },
          "user_invocable": {
            "type": "boolean"
          },
          "disable_model_invocation": {
            "type": "boolean"
          },
          "registered_in_phase": {
            "type": "string"
          },
          "aliases": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Reserved for pin shortcuts; honored by the pin metadata catalogue."
          },
          "composes_with": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Phase 50 (v3) optional: skill names this skill calls as sub-orchestration. Each becomes a directed composition edge validated by scripts/validate-composition-graph.cjs (must be a DAG, no dangling refs)."
          },
          "next_skills": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Phase 50 (v3) optional: pipeline hint listing skill names that naturally run after this one. Each becomes a directed edge in the composition graph (DAG, no dangling refs)."
          },
          "extra_frontmatter": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Non-managed frontmatter lines preserved verbatim (color, model, writes:, ...)."
          }
        }
      }
    }
  }
}
