{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://recit.dev/schema/v1/chart.json",
  "x-recit-stability": "preview",
  "oneOf": [
    {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "line"
        },
        "$schema": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "subtitle": {
          "type": "string"
        },
        "source": {
          "type": "string"
        },
        "alt": {
          "type": "string"
        },
        "unit": {
          "type": "string"
        },
        "axis": {
          "type": "object",
          "properties": {
            "kind": {
              "type": "string",
              "enum": [
                "month-of-year",
                "month",
                "day",
                "year",
                "labels",
                "categories",
                "xy",
                "map"
              ]
            },
            "key": {
              "type": "string",
              "minLength": 1
            }
          },
          "required": [
            "kind"
          ],
          "additionalProperties": false
        },
        "x": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "series": {
          "minItems": 1,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string",
                "minLength": 1
              },
              "values": {
                "type": "array",
                "items": {
                  "type": [
                    "number",
                    "null"
                  ]
                }
              }
            },
            "required": [
              "name",
              "values"
            ],
            "additionalProperties": false
          }
        },
        "xLabel": {
          "type": "string"
        },
        "yLabel": {
          "type": "string"
        },
        "zero": {
          "type": "boolean"
        },
        "marks": {
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "x": {
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 1
                      },
                      {
                        "type": "number"
                      }
                    ]
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "x"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "y": {
                    "type": "number"
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "y"
                ],
                "additionalProperties": false
              }
            ]
          }
        },
        "roles": {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "type": "string",
            "enum": [
              "1",
              "2",
              "3",
              "4",
              "5",
              "6",
              "7",
              "8",
              "alert",
              "solution",
              "reference",
              "context"
            ]
          }
        },
        "facet": {
          "type": "string",
          "enum": [
            "series"
          ]
        },
        "columns": {
          "type": "integer",
          "minimum": 1,
          "maximum": 4
        },
        "context": {
          "type": "boolean"
        },
        "area": {
          "type": "boolean"
        }
      },
      "required": [
        "type",
        "x",
        "series"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "area"
        },
        "$schema": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "subtitle": {
          "type": "string"
        },
        "source": {
          "type": "string"
        },
        "alt": {
          "type": "string"
        },
        "unit": {
          "type": "string"
        },
        "axis": {
          "type": "object",
          "properties": {
            "kind": {
              "type": "string",
              "enum": [
                "month-of-year",
                "month",
                "day",
                "year",
                "labels",
                "categories",
                "xy",
                "map"
              ]
            },
            "key": {
              "type": "string",
              "minLength": 1
            }
          },
          "required": [
            "kind"
          ],
          "additionalProperties": false
        },
        "x": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "series": {
          "minItems": 1,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string",
                "minLength": 1
              },
              "values": {
                "type": "array",
                "items": {
                  "type": [
                    "number",
                    "null"
                  ]
                }
              }
            },
            "required": [
              "name",
              "values"
            ],
            "additionalProperties": false
          }
        },
        "xLabel": {
          "type": "string"
        },
        "yLabel": {
          "type": "string"
        },
        "zero": {
          "type": "boolean"
        },
        "marks": {
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "x": {
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 1
                      },
                      {
                        "type": "number"
                      }
                    ]
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "x"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "y": {
                    "type": "number"
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "y"
                ],
                "additionalProperties": false
              }
            ]
          }
        },
        "roles": {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "type": "string",
            "enum": [
              "1",
              "2",
              "3",
              "4",
              "5",
              "6",
              "7",
              "8",
              "alert",
              "solution",
              "reference",
              "context"
            ]
          }
        },
        "facet": {
          "type": "string",
          "enum": [
            "series"
          ]
        },
        "columns": {
          "type": "integer",
          "minimum": 1,
          "maximum": 4
        },
        "context": {
          "type": "boolean"
        },
        "stack": {
          "type": "boolean"
        }
      },
      "required": [
        "type",
        "x",
        "series"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "dot"
        },
        "$schema": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "subtitle": {
          "type": "string"
        },
        "source": {
          "type": "string"
        },
        "alt": {
          "type": "string"
        },
        "unit": {
          "type": "string"
        },
        "axis": {
          "type": "object",
          "properties": {
            "kind": {
              "type": "string",
              "enum": [
                "month-of-year",
                "month",
                "day",
                "year",
                "labels",
                "categories",
                "xy",
                "map"
              ]
            },
            "key": {
              "type": "string",
              "minLength": 1
            }
          },
          "required": [
            "kind"
          ],
          "additionalProperties": false
        },
        "x": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "series": {
          "minItems": 1,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string",
                "minLength": 1
              },
              "values": {
                "type": "array",
                "items": {
                  "type": [
                    "number",
                    "null"
                  ]
                }
              }
            },
            "required": [
              "name",
              "values"
            ],
            "additionalProperties": false
          }
        },
        "xLabel": {
          "type": "string"
        },
        "yLabel": {
          "type": "string"
        },
        "zero": {
          "type": "boolean"
        },
        "marks": {
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "x": {
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 1
                      },
                      {
                        "type": "number"
                      }
                    ]
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "x"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "y": {
                    "type": "number"
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "y"
                ],
                "additionalProperties": false
              }
            ]
          }
        },
        "roles": {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "type": "string",
            "enum": [
              "1",
              "2",
              "3",
              "4",
              "5",
              "6",
              "7",
              "8",
              "alert",
              "solution",
              "reference",
              "context"
            ]
          }
        },
        "facet": {
          "type": "string",
          "enum": [
            "series"
          ]
        },
        "columns": {
          "type": "integer",
          "minimum": 1,
          "maximum": 4
        },
        "context": {
          "type": "boolean"
        }
      },
      "required": [
        "type",
        "x",
        "series"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "bar"
        },
        "$schema": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "subtitle": {
          "type": "string"
        },
        "source": {
          "type": "string"
        },
        "alt": {
          "type": "string"
        },
        "unit": {
          "type": "string"
        },
        "axis": {
          "type": "object",
          "properties": {
            "kind": {
              "type": "string",
              "enum": [
                "month-of-year",
                "month",
                "day",
                "year",
                "labels",
                "categories",
                "xy",
                "map"
              ]
            },
            "key": {
              "type": "string",
              "minLength": 1
            }
          },
          "required": [
            "kind"
          ],
          "additionalProperties": false
        },
        "x": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "series": {
          "minItems": 1,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string",
                "minLength": 1
              },
              "values": {
                "type": "array",
                "items": {
                  "type": [
                    "number",
                    "null"
                  ]
                }
              }
            },
            "required": [
              "name",
              "values"
            ],
            "additionalProperties": false
          }
        },
        "xLabel": {
          "type": "string"
        },
        "yLabel": {
          "type": "string"
        },
        "zero": {
          "type": "boolean"
        },
        "marks": {
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "x": {
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 1
                      },
                      {
                        "type": "number"
                      }
                    ]
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "x"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "y": {
                    "type": "number"
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "y"
                ],
                "additionalProperties": false
              }
            ]
          }
        },
        "roles": {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "type": "string",
            "enum": [
              "1",
              "2",
              "3",
              "4",
              "5",
              "6",
              "7",
              "8",
              "alert",
              "solution",
              "reference",
              "context"
            ]
          }
        },
        "facet": {
          "type": "string",
          "enum": [
            "series"
          ]
        },
        "columns": {
          "type": "integer",
          "minimum": 1,
          "maximum": 4
        },
        "context": {
          "type": "boolean"
        },
        "orientation": {
          "type": "string",
          "enum": [
            "vertical",
            "horizontal"
          ]
        },
        "stack": {
          "type": "boolean"
        }
      },
      "required": [
        "type",
        "x",
        "series"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "heatmap"
        },
        "$schema": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "subtitle": {
          "type": "string"
        },
        "source": {
          "type": "string"
        },
        "alt": {
          "type": "string"
        },
        "unit": {
          "type": "string"
        },
        "axis": {
          "type": "object",
          "properties": {
            "kind": {
              "type": "string",
              "enum": [
                "month-of-year",
                "month",
                "day",
                "year",
                "labels",
                "categories",
                "xy",
                "map"
              ]
            },
            "key": {
              "type": "string",
              "minLength": 1
            }
          },
          "required": [
            "kind"
          ],
          "additionalProperties": false
        },
        "rows": {
          "minItems": 1,
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "cols": {
          "minItems": 1,
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "values": {
          "type": "array",
          "items": {
            "type": "array",
            "items": {
              "type": [
                "number",
                "null"
              ]
            }
          }
        },
        "scale": {
          "type": "string",
          "enum": [
            "sequential",
            "diverging"
          ]
        },
        "midpoint": {
          "type": "number"
        },
        "breaks": {
          "type": "array",
          "items": {
            "type": "number"
          }
        },
        "rowGroups": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "legendTitle": {
          "type": "string"
        }
      },
      "required": [
        "type",
        "rows",
        "cols",
        "values"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "scatter"
        },
        "$schema": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "subtitle": {
          "type": "string"
        },
        "source": {
          "type": "string"
        },
        "alt": {
          "type": "string"
        },
        "unit": {
          "type": "string"
        },
        "axis": {
          "type": "object",
          "properties": {
            "kind": {
              "type": "string",
              "enum": [
                "month-of-year",
                "month",
                "day",
                "year",
                "labels",
                "categories",
                "xy",
                "map"
              ]
            },
            "key": {
              "type": "string",
              "minLength": 1
            }
          },
          "required": [
            "kind"
          ],
          "additionalProperties": false
        },
        "points": {
          "minItems": 1,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "x": {
                "type": "number"
              },
              "y": {
                "type": "number"
              },
              "label": {
                "type": "string"
              },
              "group": {
                "type": "string"
              },
              "size": {
                "type": "number",
                "minimum": 0
              },
              "z": {
                "type": "number"
              }
            },
            "required": [
              "x",
              "y"
            ],
            "additionalProperties": false
          }
        },
        "xLabel": {
          "type": "string"
        },
        "yLabel": {
          "type": "string"
        },
        "xUnit": {
          "type": "string"
        },
        "yUnit": {
          "type": "string"
        },
        "xScale": {
          "type": "string",
          "enum": [
            "linear",
            "log"
          ]
        },
        "yScale": {
          "type": "string",
          "enum": [
            "linear",
            "log"
          ]
        },
        "sizeLabel": {
          "type": "string"
        },
        "annotate": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "highlight": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "roles": {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "type": "string",
            "enum": [
              "1",
              "2",
              "3",
              "4",
              "5",
              "6",
              "7",
              "8",
              "alert",
              "solution",
              "reference",
              "context"
            ]
          }
        },
        "marks": {
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "x": {
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 1
                      },
                      {
                        "type": "number"
                      }
                    ]
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "x"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "y": {
                    "type": "number"
                  },
                  "label": {
                    "type": "string"
                  }
                },
                "required": [
                  "y"
                ],
                "additionalProperties": false
              }
            ]
          }
        }
      },
      "required": [
        "type",
        "points"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "kpi"
        },
        "$schema": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "subtitle": {
          "type": "string"
        },
        "source": {
          "type": "string"
        },
        "alt": {
          "type": "string"
        },
        "unit": {
          "type": "string"
        },
        "axis": {
          "type": "object",
          "properties": {
            "kind": {
              "type": "string",
              "enum": [
                "month-of-year",
                "month",
                "day",
                "year",
                "labels",
                "categories",
                "xy",
                "map"
              ]
            },
            "key": {
              "type": "string",
              "minLength": 1
            }
          },
          "required": [
            "kind"
          ],
          "additionalProperties": false
        },
        "items": {
          "minItems": 1,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "label": {
                "type": "string",
                "minLength": 1
              },
              "value": {
                "type": [
                  "string",
                  "number"
                ]
              },
              "note": {
                "type": "string"
              }
            },
            "required": [
              "label",
              "value"
            ],
            "additionalProperties": false
          }
        }
      },
      "required": [
        "type",
        "items"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "choropleth"
        },
        "$schema": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "subtitle": {
          "type": "string"
        },
        "source": {
          "type": "string"
        },
        "alt": {
          "type": "string"
        },
        "unit": {
          "type": "string"
        },
        "axis": {
          "type": "object",
          "properties": {
            "kind": {
              "type": "string",
              "enum": [
                "month-of-year",
                "month",
                "day",
                "year",
                "labels",
                "categories",
                "xy",
                "map"
              ]
            },
            "key": {
              "type": "string",
              "minLength": 1
            }
          },
          "required": [
            "kind"
          ],
          "additionalProperties": false
        },
        "base": {
          "type": "string",
          "minLength": 1
        },
        "key": {
          "type": "string",
          "minLength": 1
        },
        "nameKey": {
          "type": "string",
          "minLength": 1
        },
        "values": {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "type": [
              "number",
              "null"
            ]
          }
        },
        "scale": {
          "type": "string",
          "enum": [
            "sequential",
            "diverging"
          ]
        },
        "midpoint": {
          "type": "number"
        },
        "breaks": {
          "type": "array",
          "items": {
            "type": "number"
          }
        },
        "legendTitle": {
          "type": "string"
        },
        "highlight": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      },
      "required": [
        "type",
        "values"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "points"
        },
        "$schema": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "subtitle": {
          "type": "string"
        },
        "source": {
          "type": "string"
        },
        "alt": {
          "type": "string"
        },
        "unit": {
          "type": "string"
        },
        "axis": {
          "type": "object",
          "properties": {
            "kind": {
              "type": "string",
              "enum": [
                "month-of-year",
                "month",
                "day",
                "year",
                "labels",
                "categories",
                "xy",
                "map"
              ]
            },
            "key": {
              "type": "string",
              "minLength": 1
            }
          },
          "required": [
            "kind"
          ],
          "additionalProperties": false
        },
        "base": {
          "type": "string",
          "minLength": 1
        },
        "points": {
          "minItems": 1,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "lon": {
                "type": "number"
              },
              "lat": {
                "type": "number"
              },
              "label": {
                "type": "string",
                "minLength": 1
              },
              "group": {
                "type": "string"
              },
              "size": {
                "type": "number",
                "minimum": 0
              },
              "href": {
                "type": "string",
                "minLength": 1
              },
              "z": {
                "type": "number"
              }
            },
            "required": [
              "lon",
              "lat",
              "label"
            ],
            "additionalProperties": false
          }
        },
        "lines": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "from": {
                "anyOf": [
                  {
                    "type": "string",
                    "minLength": 1
                  },
                  {
                    "type": "array",
                    "prefixItems": [
                      {
                        "type": "number"
                      },
                      {
                        "type": "number"
                      }
                    ],
                    "items": false,
                    "minItems": 2,
                    "maxItems": 2
                  }
                ]
              },
              "to": {
                "anyOf": [
                  {
                    "type": "string",
                    "minLength": 1
                  },
                  {
                    "type": "array",
                    "prefixItems": [
                      {
                        "type": "number"
                      },
                      {
                        "type": "number"
                      }
                    ],
                    "items": false,
                    "minItems": 2,
                    "maxItems": 2
                  }
                ]
              },
              "label": {
                "type": "string"
              }
            },
            "required": [
              "from",
              "to"
            ],
            "additionalProperties": false
          }
        },
        "sizeLabel": {
          "type": "string"
        },
        "highlight": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "roles": {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "type": "string",
            "enum": [
              "1",
              "2",
              "3",
              "4",
              "5",
              "6",
              "7",
              "8",
              "alert",
              "solution",
              "reference",
              "context"
            ]
          }
        }
      },
      "required": [
        "type",
        "points"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "const": "overlay"
        },
        "$schema": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "scale": {
          "type": "string",
          "enum": [
            "none",
            "index",
            "max"
          ]
        },
        "layers": {
          "minItems": 2,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string",
                "minLength": 1
              },
              "chart": {
                "oneOf": [
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "type": "string",
                        "const": "line"
                      },
                      "$schema": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "subtitle": {
                        "type": "string"
                      },
                      "source": {
                        "type": "string"
                      },
                      "alt": {
                        "type": "string"
                      },
                      "unit": {
                        "type": "string"
                      },
                      "axis": {
                        "type": "object",
                        "properties": {
                          "kind": {
                            "type": "string",
                            "enum": [
                              "month-of-year",
                              "month",
                              "day",
                              "year",
                              "labels",
                              "categories",
                              "xy",
                              "map"
                            ]
                          },
                          "key": {
                            "type": "string",
                            "minLength": 1
                          }
                        },
                        "required": [
                          "kind"
                        ],
                        "additionalProperties": false
                      },
                      "x": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      "series": {
                        "minItems": 1,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "name": {
                              "type": "string",
                              "minLength": 1
                            },
                            "values": {
                              "type": "array",
                              "items": {
                                "type": [
                                  "number",
                                  "null"
                                ]
                              }
                            }
                          },
                          "required": [
                            "name",
                            "values"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "xLabel": {
                        "type": "string"
                      },
                      "yLabel": {
                        "type": "string"
                      },
                      "zero": {
                        "type": "boolean"
                      },
                      "marks": {
                        "type": "array",
                        "items": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "x": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "minLength": 1
                                    },
                                    {
                                      "type": "number"
                                    }
                                  ]
                                },
                                "label": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "x"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "object",
                              "properties": {
                                "y": {
                                  "type": "number"
                                },
                                "label": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "y"
                              ],
                              "additionalProperties": false
                            }
                          ]
                        }
                      },
                      "roles": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "type": "string",
                          "enum": [
                            "1",
                            "2",
                            "3",
                            "4",
                            "5",
                            "6",
                            "7",
                            "8",
                            "alert",
                            "solution",
                            "reference",
                            "context"
                          ]
                        }
                      },
                      "facet": {
                        "type": "string",
                        "enum": [
                          "series"
                        ]
                      },
                      "columns": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 4
                      },
                      "context": {
                        "type": "boolean"
                      },
                      "area": {
                        "type": "boolean"
                      }
                    },
                    "required": [
                      "type",
                      "x",
                      "series"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "type": "string",
                        "const": "area"
                      },
                      "$schema": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "subtitle": {
                        "type": "string"
                      },
                      "source": {
                        "type": "string"
                      },
                      "alt": {
                        "type": "string"
                      },
                      "unit": {
                        "type": "string"
                      },
                      "axis": {
                        "type": "object",
                        "properties": {
                          "kind": {
                            "type": "string",
                            "enum": [
                              "month-of-year",
                              "month",
                              "day",
                              "year",
                              "labels",
                              "categories",
                              "xy",
                              "map"
                            ]
                          },
                          "key": {
                            "type": "string",
                            "minLength": 1
                          }
                        },
                        "required": [
                          "kind"
                        ],
                        "additionalProperties": false
                      },
                      "x": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      "series": {
                        "minItems": 1,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "name": {
                              "type": "string",
                              "minLength": 1
                            },
                            "values": {
                              "type": "array",
                              "items": {
                                "type": [
                                  "number",
                                  "null"
                                ]
                              }
                            }
                          },
                          "required": [
                            "name",
                            "values"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "xLabel": {
                        "type": "string"
                      },
                      "yLabel": {
                        "type": "string"
                      },
                      "zero": {
                        "type": "boolean"
                      },
                      "marks": {
                        "type": "array",
                        "items": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "x": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "minLength": 1
                                    },
                                    {
                                      "type": "number"
                                    }
                                  ]
                                },
                                "label": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "x"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "object",
                              "properties": {
                                "y": {
                                  "type": "number"
                                },
                                "label": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "y"
                              ],
                              "additionalProperties": false
                            }
                          ]
                        }
                      },
                      "roles": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "type": "string",
                          "enum": [
                            "1",
                            "2",
                            "3",
                            "4",
                            "5",
                            "6",
                            "7",
                            "8",
                            "alert",
                            "solution",
                            "reference",
                            "context"
                          ]
                        }
                      },
                      "facet": {
                        "type": "string",
                        "enum": [
                          "series"
                        ]
                      },
                      "columns": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 4
                      },
                      "context": {
                        "type": "boolean"
                      },
                      "stack": {
                        "type": "boolean"
                      }
                    },
                    "required": [
                      "type",
                      "x",
                      "series"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "type": "string",
                        "const": "dot"
                      },
                      "$schema": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "subtitle": {
                        "type": "string"
                      },
                      "source": {
                        "type": "string"
                      },
                      "alt": {
                        "type": "string"
                      },
                      "unit": {
                        "type": "string"
                      },
                      "axis": {
                        "type": "object",
                        "properties": {
                          "kind": {
                            "type": "string",
                            "enum": [
                              "month-of-year",
                              "month",
                              "day",
                              "year",
                              "labels",
                              "categories",
                              "xy",
                              "map"
                            ]
                          },
                          "key": {
                            "type": "string",
                            "minLength": 1
                          }
                        },
                        "required": [
                          "kind"
                        ],
                        "additionalProperties": false
                      },
                      "x": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      "series": {
                        "minItems": 1,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "name": {
                              "type": "string",
                              "minLength": 1
                            },
                            "values": {
                              "type": "array",
                              "items": {
                                "type": [
                                  "number",
                                  "null"
                                ]
                              }
                            }
                          },
                          "required": [
                            "name",
                            "values"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "xLabel": {
                        "type": "string"
                      },
                      "yLabel": {
                        "type": "string"
                      },
                      "zero": {
                        "type": "boolean"
                      },
                      "marks": {
                        "type": "array",
                        "items": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "x": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "minLength": 1
                                    },
                                    {
                                      "type": "number"
                                    }
                                  ]
                                },
                                "label": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "x"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "object",
                              "properties": {
                                "y": {
                                  "type": "number"
                                },
                                "label": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "y"
                              ],
                              "additionalProperties": false
                            }
                          ]
                        }
                      },
                      "roles": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "type": "string",
                          "enum": [
                            "1",
                            "2",
                            "3",
                            "4",
                            "5",
                            "6",
                            "7",
                            "8",
                            "alert",
                            "solution",
                            "reference",
                            "context"
                          ]
                        }
                      },
                      "facet": {
                        "type": "string",
                        "enum": [
                          "series"
                        ]
                      },
                      "columns": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 4
                      },
                      "context": {
                        "type": "boolean"
                      }
                    },
                    "required": [
                      "type",
                      "x",
                      "series"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "type": "string",
                        "const": "bar"
                      },
                      "$schema": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "subtitle": {
                        "type": "string"
                      },
                      "source": {
                        "type": "string"
                      },
                      "alt": {
                        "type": "string"
                      },
                      "unit": {
                        "type": "string"
                      },
                      "axis": {
                        "type": "object",
                        "properties": {
                          "kind": {
                            "type": "string",
                            "enum": [
                              "month-of-year",
                              "month",
                              "day",
                              "year",
                              "labels",
                              "categories",
                              "xy",
                              "map"
                            ]
                          },
                          "key": {
                            "type": "string",
                            "minLength": 1
                          }
                        },
                        "required": [
                          "kind"
                        ],
                        "additionalProperties": false
                      },
                      "x": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      "series": {
                        "minItems": 1,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "name": {
                              "type": "string",
                              "minLength": 1
                            },
                            "values": {
                              "type": "array",
                              "items": {
                                "type": [
                                  "number",
                                  "null"
                                ]
                              }
                            }
                          },
                          "required": [
                            "name",
                            "values"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "xLabel": {
                        "type": "string"
                      },
                      "yLabel": {
                        "type": "string"
                      },
                      "zero": {
                        "type": "boolean"
                      },
                      "marks": {
                        "type": "array",
                        "items": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "x": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "minLength": 1
                                    },
                                    {
                                      "type": "number"
                                    }
                                  ]
                                },
                                "label": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "x"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "object",
                              "properties": {
                                "y": {
                                  "type": "number"
                                },
                                "label": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "y"
                              ],
                              "additionalProperties": false
                            }
                          ]
                        }
                      },
                      "roles": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "type": "string",
                          "enum": [
                            "1",
                            "2",
                            "3",
                            "4",
                            "5",
                            "6",
                            "7",
                            "8",
                            "alert",
                            "solution",
                            "reference",
                            "context"
                          ]
                        }
                      },
                      "facet": {
                        "type": "string",
                        "enum": [
                          "series"
                        ]
                      },
                      "columns": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 4
                      },
                      "context": {
                        "type": "boolean"
                      },
                      "orientation": {
                        "type": "string",
                        "enum": [
                          "vertical",
                          "horizontal"
                        ]
                      },
                      "stack": {
                        "type": "boolean"
                      }
                    },
                    "required": [
                      "type",
                      "x",
                      "series"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "type": "string",
                        "const": "heatmap"
                      },
                      "$schema": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "subtitle": {
                        "type": "string"
                      },
                      "source": {
                        "type": "string"
                      },
                      "alt": {
                        "type": "string"
                      },
                      "unit": {
                        "type": "string"
                      },
                      "axis": {
                        "type": "object",
                        "properties": {
                          "kind": {
                            "type": "string",
                            "enum": [
                              "month-of-year",
                              "month",
                              "day",
                              "year",
                              "labels",
                              "categories",
                              "xy",
                              "map"
                            ]
                          },
                          "key": {
                            "type": "string",
                            "minLength": 1
                          }
                        },
                        "required": [
                          "kind"
                        ],
                        "additionalProperties": false
                      },
                      "rows": {
                        "minItems": 1,
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      "cols": {
                        "minItems": 1,
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      "values": {
                        "type": "array",
                        "items": {
                          "type": "array",
                          "items": {
                            "type": [
                              "number",
                              "null"
                            ]
                          }
                        }
                      },
                      "scale": {
                        "type": "string",
                        "enum": [
                          "sequential",
                          "diverging"
                        ]
                      },
                      "midpoint": {
                        "type": "number"
                      },
                      "breaks": {
                        "type": "array",
                        "items": {
                          "type": "number"
                        }
                      },
                      "rowGroups": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      "legendTitle": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "type",
                      "rows",
                      "cols",
                      "values"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "type": "string",
                        "const": "scatter"
                      },
                      "$schema": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "subtitle": {
                        "type": "string"
                      },
                      "source": {
                        "type": "string"
                      },
                      "alt": {
                        "type": "string"
                      },
                      "unit": {
                        "type": "string"
                      },
                      "axis": {
                        "type": "object",
                        "properties": {
                          "kind": {
                            "type": "string",
                            "enum": [
                              "month-of-year",
                              "month",
                              "day",
                              "year",
                              "labels",
                              "categories",
                              "xy",
                              "map"
                            ]
                          },
                          "key": {
                            "type": "string",
                            "minLength": 1
                          }
                        },
                        "required": [
                          "kind"
                        ],
                        "additionalProperties": false
                      },
                      "points": {
                        "minItems": 1,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "x": {
                              "type": "number"
                            },
                            "y": {
                              "type": "number"
                            },
                            "label": {
                              "type": "string"
                            },
                            "group": {
                              "type": "string"
                            },
                            "size": {
                              "type": "number",
                              "minimum": 0
                            },
                            "z": {
                              "type": "number"
                            }
                          },
                          "required": [
                            "x",
                            "y"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "xLabel": {
                        "type": "string"
                      },
                      "yLabel": {
                        "type": "string"
                      },
                      "xUnit": {
                        "type": "string"
                      },
                      "yUnit": {
                        "type": "string"
                      },
                      "xScale": {
                        "type": "string",
                        "enum": [
                          "linear",
                          "log"
                        ]
                      },
                      "yScale": {
                        "type": "string",
                        "enum": [
                          "linear",
                          "log"
                        ]
                      },
                      "sizeLabel": {
                        "type": "string"
                      },
                      "annotate": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      "highlight": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      "roles": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "type": "string",
                          "enum": [
                            "1",
                            "2",
                            "3",
                            "4",
                            "5",
                            "6",
                            "7",
                            "8",
                            "alert",
                            "solution",
                            "reference",
                            "context"
                          ]
                        }
                      },
                      "marks": {
                        "type": "array",
                        "items": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "x": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "minLength": 1
                                    },
                                    {
                                      "type": "number"
                                    }
                                  ]
                                },
                                "label": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "x"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "object",
                              "properties": {
                                "y": {
                                  "type": "number"
                                },
                                "label": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "y"
                              ],
                              "additionalProperties": false
                            }
                          ]
                        }
                      }
                    },
                    "required": [
                      "type",
                      "points"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "type": "string",
                        "const": "kpi"
                      },
                      "$schema": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "subtitle": {
                        "type": "string"
                      },
                      "source": {
                        "type": "string"
                      },
                      "alt": {
                        "type": "string"
                      },
                      "unit": {
                        "type": "string"
                      },
                      "axis": {
                        "type": "object",
                        "properties": {
                          "kind": {
                            "type": "string",
                            "enum": [
                              "month-of-year",
                              "month",
                              "day",
                              "year",
                              "labels",
                              "categories",
                              "xy",
                              "map"
                            ]
                          },
                          "key": {
                            "type": "string",
                            "minLength": 1
                          }
                        },
                        "required": [
                          "kind"
                        ],
                        "additionalProperties": false
                      },
                      "items": {
                        "minItems": 1,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string",
                              "minLength": 1
                            },
                            "value": {
                              "type": [
                                "string",
                                "number"
                              ]
                            },
                            "note": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      }
                    },
                    "required": [
                      "type",
                      "items"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "type": "string",
                        "const": "choropleth"
                      },
                      "$schema": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "subtitle": {
                        "type": "string"
                      },
                      "source": {
                        "type": "string"
                      },
                      "alt": {
                        "type": "string"
                      },
                      "unit": {
                        "type": "string"
                      },
                      "axis": {
                        "type": "object",
                        "properties": {
                          "kind": {
                            "type": "string",
                            "enum": [
                              "month-of-year",
                              "month",
                              "day",
                              "year",
                              "labels",
                              "categories",
                              "xy",
                              "map"
                            ]
                          },
                          "key": {
                            "type": "string",
                            "minLength": 1
                          }
                        },
                        "required": [
                          "kind"
                        ],
                        "additionalProperties": false
                      },
                      "base": {
                        "type": "string",
                        "minLength": 1
                      },
                      "key": {
                        "type": "string",
                        "minLength": 1
                      },
                      "nameKey": {
                        "type": "string",
                        "minLength": 1
                      },
                      "values": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "type": [
                            "number",
                            "null"
                          ]
                        }
                      },
                      "scale": {
                        "type": "string",
                        "enum": [
                          "sequential",
                          "diverging"
                        ]
                      },
                      "midpoint": {
                        "type": "number"
                      },
                      "breaks": {
                        "type": "array",
                        "items": {
                          "type": "number"
                        }
                      },
                      "legendTitle": {
                        "type": "string"
                      },
                      "highlight": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      }
                    },
                    "required": [
                      "type",
                      "values"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "type": {
                        "type": "string",
                        "const": "points"
                      },
                      "$schema": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "subtitle": {
                        "type": "string"
                      },
                      "source": {
                        "type": "string"
                      },
                      "alt": {
                        "type": "string"
                      },
                      "unit": {
                        "type": "string"
                      },
                      "axis": {
                        "type": "object",
                        "properties": {
                          "kind": {
                            "type": "string",
                            "enum": [
                              "month-of-year",
                              "month",
                              "day",
                              "year",
                              "labels",
                              "categories",
                              "xy",
                              "map"
                            ]
                          },
                          "key": {
                            "type": "string",
                            "minLength": 1
                          }
                        },
                        "required": [
                          "kind"
                        ],
                        "additionalProperties": false
                      },
                      "base": {
                        "type": "string",
                        "minLength": 1
                      },
                      "points": {
                        "minItems": 1,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "lon": {
                              "type": "number"
                            },
                            "lat": {
                              "type": "number"
                            },
                            "label": {
                              "type": "string",
                              "minLength": 1
                            },
                            "group": {
                              "type": "string"
                            },
                            "size": {
                              "type": "number",
                              "minimum": 0
                            },
                            "href": {
                              "type": "string",
                              "minLength": 1
                            },
                            "z": {
                              "type": "number"
                            }
                          },
                          "required": [
                            "lon",
                            "lat",
                            "label"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "lines": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "from": {
                              "anyOf": [
                                {
                                  "type": "string",
                                  "minLength": 1
                                },
                                {
                                  "type": "array",
                                  "prefixItems": [
                                    {
                                      "type": "number"
                                    },
                                    {
                                      "type": "number"
                                    }
                                  ],
                                  "items": false,
                                  "minItems": 2,
                                  "maxItems": 2
                                }
                              ]
                            },
                            "to": {
                              "anyOf": [
                                {
                                  "type": "string",
                                  "minLength": 1
                                },
                                {
                                  "type": "array",
                                  "prefixItems": [
                                    {
                                      "type": "number"
                                    },
                                    {
                                      "type": "number"
                                    }
                                  ],
                                  "items": false,
                                  "minItems": 2,
                                  "maxItems": 2
                                }
                              ]
                            },
                            "label": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "from",
                            "to"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "sizeLabel": {
                        "type": "string"
                      },
                      "highlight": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      "roles": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {
                          "type": "string",
                          "enum": [
                            "1",
                            "2",
                            "3",
                            "4",
                            "5",
                            "6",
                            "7",
                            "8",
                            "alert",
                            "solution",
                            "reference",
                            "context"
                          ]
                        }
                      }
                    },
                    "required": [
                      "type",
                      "points"
                    ],
                    "additionalProperties": false
                  }
                ]
              },
              "series": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "required": [
              "name",
              "chart"
            ],
            "additionalProperties": false
          }
        }
      },
      "required": [
        "type",
        "layers"
      ],
      "additionalProperties": false
    }
  ]
}
