{
  "version": 1,
  "structures": [
    {
      "name": "moderation_triage_response",
      "description": "Initial moderation verdict on the submitted content",
      "example": {
        "verdict": "flag",
        "risk_category": "spam",
        "explanation": "Repeated promotional links with no original content."
      },
      "schema": {
        "type": "object",
        "properties": {
          "verdict": {
            "type": "string",
            "enum": [
              "approve",
              "flag",
              "block"
            ]
          },
          "risk_category": {
            "type": "string"
          },
          "explanation": {
            "type": "string"
          }
        },
        "required": [
          "verdict",
          "risk_category",
          "explanation"
        ],
        "additionalProperties": false
      }
    },
    {
      "name": "moderation_decision_response",
      "description": "Final decision and action taken",
      "example": {
        "final_decision": "flag",
        "action_taken": "hidden pending human review",
        "note": "Referred to a moderator for confirmation."
      },
      "schema": {
        "type": "object",
        "properties": {
          "final_decision": {
            "type": "string",
            "enum": [
              "approve",
              "flag",
              "block"
            ]
          },
          "action_taken": {
            "type": "string"
          },
          "note": {
            "type": "string"
          }
        },
        "required": [
          "final_decision",
          "action_taken",
          "note"
        ],
        "additionalProperties": false
      }
    }
  ],
  "workflows": [
    {
      "name": "content_moderation_workflow",
      "description": "Reviews content and starts the decision pipeline",
      "provider": "deepseek",
      "model": "deepseek-v4-flash",
      "backups": [
        {
          "provider": "anthropic",
          "model": "claude-haiku-4-5-20251001"
        }
      ],
      "request_type": "chat",
      "system_instructions": "Review the submitted content against a typical community policy: approve content that is safe and relevant, flag content that needs a human check, and block clear policy violations. Explain each verdict briefly.",
      "structure": "moderation_triage_response",
      "customer_fields": [
        "content_text",
        "content_type",
        "submitter_id"
      ],
      "test_mode": false,
      "cache_window_seconds": 300,
      "backend_pipeline": {
        "enabled": true,
        "events": [
          {
            "name": "content_submitted"
          },
          {
            "name": "apply_decision",
            "target_workflow": "moderation_decision_workflow"
          },
          {
            "name": "decision_recorded"
          }
        ]
      }
    },
    {
      "name": "moderation_decision_workflow",
      "description": "Records the final moderation action",
      "provider": "anthropic",
      "model": "claude-haiku-4-5-20251001",
      "backups": [
        {
          "provider": "deepseek",
          "model": "deepseek-v4-flash"
        }
      ],
      "request_type": "chat",
      "system_instructions": "Confirm the final moderation decision and describe the action taken, such as approving, hiding pending review, or blocking the content. Keep the note concise for moderators.",
      "structure": "moderation_decision_response",
      "customer_fields": [
        "content_text",
        "content_type",
        "submitter_id"
      ],
      "test_mode": false
    }
  ]
}
