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

autonomy_schema = {
    "type": "object",
    "properties": {
        "message_type": {
            "type": "string",
            "description": "Type of message",
            "example": "autonomy",
            "enum": ["autonomy"],
        },
        "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,
                    },
                },
            },
        ],
        "state": {
            "type": "string",
            "enum": ["start", "stop"],
            "description": "Autonomy engine instruction to start or stop model",
            "example": "stop",
        },
    },
    "required": ["message_type", "planning_config_ID"],
}