{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://wouldliker.com/data/schemas/sound-behavior-profiles.schema.json",
  "title": "Wouldliker Sound Behavior Profiles",
  "type": "object",
  "required": ["site", "type", "updated_at", "profiles"],
  "properties": {
    "site": { "const": "wouldliker" },
    "type": { "const": "sound_behavior_profiles" },
    "updated_at": { "type": "string" },
    "description": { "type": "string" },
    "field_definitions": { "type": "object" },
    "role_definitions": { "type": "object" },
    "profiles": {
      "type": "array",
      "items": { "$ref": "#/$defs/sound_behavior_profile" }
    },
    "v1_boundary": { "type": "string" }
  },
  "$defs": {
    "sound_behavior_profile": {
      "type": "object",
      "required": [
        "sound_slug",
        "energy_shape",
        "density",
        "role",
        "voiceover_safe",
        "hook_starts_at_ms",
        "payoff_required",
        "loop_friendly",
        "recommended_lengths_s",
        "edit_guidance",
        "first_second_priority",
        "interference_risk"
      ],
      "properties": {
        "sound_slug": { "type": "string" },
        "name": { "type": "string" },
        "energy_shape": { "enum": ["steady", "rising", "punchy"] },
        "density": { "enum": ["low", "medium", "high"] },
        "role": {
          "enum": [
            "background_bed",
            "hook_pressure",
            "reveal_support",
            "voice_safe_motion"
          ]
        },
        "voiceover_safe": { "type": "boolean" },
        "hook_starts_at_ms": { "type": "integer", "minimum": 0 },
        "payoff_required": { "type": "boolean" },
        "loop_friendly": { "type": "boolean" },
        "recommended_lengths_s": {
          "type": "array",
          "items": { "type": "integer", "enum": [15, 30, 60, 90, 120] },
          "minItems": 1
        },
        "edit_guidance": { "type": "string" },
        "first_second_priority": {
          "enum": ["subject_in_frame", "hook_text", "motion", "face"]
        },
        "interference_risk": { "enum": ["low", "medium", "high"] }
      },
      "additionalProperties": false
    }
  }
}
