"""
    schemas: Autonomy Engine control related data with Autonomy 
    Engine metadata, configurations and default instructions
"""

autonomy_engine_control_schema = {
    "type": "object",
    "properties": {
        "message_type": {
            "type": "string",
            "description": "Type of message",
            "example": "autonomy_engine_control",
            "enum": ["autonomy_engine_control"],
        },
        "state": {
            "type": "string",
            "enum": ["start", "pause", "stop"],
            "description": "Autonomy engine instruction to start or stop model",
            "example": "stop",
        },
    },
    "oneOf": [
        {
            "properties": {
                "planning_config_ID": {
                    "type": "string",
                    "format": "uuid",
                    "pattern": "[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}",
                    "description": "Unique identifier (uuid) for this specification version generated",
                },
            },
        },
        {
            "properties": {
                "planning_config_ID": {
                    "type": "integer",
                    "description": "Unique identifier (uuid) for this specification version generated",
                    "example": 2,
                },
            },
        },
    ],
    "required": ["message_type", "planning_config_ID"],
}