{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "title": "Customer Survey Response Output",
    "type": "object",
    "additionalProperties": false,
    "properties": {
        "customerId": {
            "type": "string",
            "description": "Unique identifier for the customer"
        },
        "totalScore": {
            "type": "integer",
            "description": "Sum of survey ratings (range 3-15)"
        },
        "sentiment": {
            "type": "string",
            "enum": [
                "Positive",
                "Neutral",
                "Negative"
            ],
            "description": "AI classification of feedback sentiment"
        },
        "status": {
            "type": "string",
            "enum": [
                "Good",
                "Neutral",
                "Bad"
            ],
            "description": "Overall classification based on score and sentiment"
        },
        "alertTriggered": {
            "type": "boolean",
            "description": "True if score is below threshold or sentiment is negative"
        }
    },
    "required": [
        "customerId",
        "totalScore",
        "sentiment",
        "status",
        "alertTriggered"
    ]
}