{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://unpkg.com/plotagents/schema.json",
  "title": "plotagents spec",
  "description": "Declarative chart spec. Data as rows (tidy) plus the field name for each role. Everything else has well-designed defaults. `data` is required except for kpi (`items`), flowchart (`nodes` + `edges`), chord (`matrix`) and wordcloud with raw `text`.",
  "type": "object",
  "properties": {
    "type": {
      "type": "string",
      "enum": [
        "auto",
        "bar",
        "column",
        "count",
        "line",
        "area",
        "scatter",
        "bubble",
        "treemap",
        "sunburst",
        "donut",
        "pie",
        "heatmap",
        "sankey",
        "kpi",
        "hist",
        "kde",
        "ecdf",
        "regplot",
        "residplot",
        "jointplot",
        "box",
        "violin",
        "strip",
        "swarm",
        "point",
        "radar",
        "network",
        "chord",
        "pyramid",
        "flowchart",
        "gantt",
        "wordcloud",
        "choropleth",
        "symbolmap",
        "pointmap",
        "table",
        "corr",
        "pairplot",
        "spark",
        "bump",
        "waffle",
        "dendrogram",
        "dotplot",
        "rail",
        "barplot",
        "countplot",
        "columns",
        "lineplot",
        "areaplot",
        "scatterplot",
        "histplot",
        "histogram",
        "kdeplot",
        "density",
        "ecdfplot",
        "lmplot",
        "reg",
        "regression",
        "joint",
        "boxplot",
        "violinplot",
        "stripplot",
        "swarmplot",
        "beeswarm",
        "pointplot",
        "spider",
        "doughnut",
        "dotmap",
        "dot-map",
        "tilemap",
        "basemap",
        "mapa-puntos",
        "mapa-de-puntos",
        "latlon",
        "graph",
        "force",
        "red",
        "chord-diagram",
        "cuerdas",
        "populationpyramid",
        "population",
        "piramide",
        "pirámide",
        "diagram",
        "process",
        "diagrama",
        "map",
        "mapa",
        "choroplethmap",
        "symbol",
        "bubblemap",
        "mapa-simbolos",
        "words",
        "word-cloud",
        "wordclouds",
        "tagcloud",
        "tag-cloud",
        "nube",
        "nube-de-palabras",
        "cloud",
        "timeline",
        "roadmap",
        "schedule",
        "cronograma",
        "carta-gantt",
        "ganttchart",
        "gantt-chart",
        "planning",
        "tabla",
        "tables",
        "datatable",
        "data-table",
        "grid",
        "tableau",
        "tabelle",
        "tabela",
        "spreadsheet",
        "planilla",
        "correlation",
        "correlations",
        "corrplot",
        "corrmatrix",
        "corr-matrix",
        "correlation-matrix",
        "correlogram",
        "correlograma",
        "correlacion",
        "correlación",
        "matriz-correlacion",
        "matriz-de-correlacion",
        "matriz-de-correlación",
        "clustermap",
        "cluster-map",
        "pairs",
        "pairgrid",
        "splom",
        "scattermatrix",
        "scatter-matrix",
        "scatterplot-matrix",
        "matriz-de-dispersion",
        "matriz-de-dispersión",
        "sparkline",
        "sparklines",
        "microchart",
        "bumpchart",
        "bump-chart",
        "rank",
        "ranking",
        "slope",
        "slopegraph",
        "slope-chart",
        "waffle-chart",
        "squares",
        "unitchart",
        "unit-chart",
        "cuadros",
        "dendrograma",
        "linkage",
        "hclust",
        "cluster-tree",
        "riel",
        "range-rail",
        "field-rail",
        "dot-plot",
        "wilkinson",
        "dot-histogram",
        "puntos-apilados",
        "tree",
        "stat",
        "stats",
        "number",
        "heat",
        "flow"
      ],
      "description": "Compare: bar, count. Time: line, area. Schedules: gantt. Relationships: scatter, bubble, regplot, residplot, jointplot, radar, corr (correlation matrix; clustermap), pairplot (scatter-plot matrix). Distributions (seaborn): hist, kde, ecdf, box, violin, strip, swarm, point. Part-to-whole: treemap, sunburst, donut, pie. Other: heatmap, sankey, kpi, spark (a sparkline for a table cell), rail (one row of a distribution for a table cell: min–max, a band, the median, the value and reference ticks), network, chord, pyramid, flowchart, wordcloud. Maps: choropleth, symbolmap, pointmap (lat/lon dots over a tile basemap). seaborn names are accepted (barplot, countplot, histplot, kdeplot, boxplot, violinplot, lmplot…). \"auto\" (default) picks from the data."
    },
    "data": {
      "description": "The table. Rows [{ \"region\": \"Biobío\", \"sales\": 1240 }], or, shorter for many rows (field names once): header + rows [[\"region\", \"sales\"], [\"Biobío\", 1240], [\"Ñuble\", 830]], columns { \"region\": [\"Biobío\", \"Ñuble\"], \"sales\": [1240, 830] }, or CSV/TSV text \"region,sales\\nBiobío,1240\". For kpi it can be omitted in favor of `items`.",
      "anyOf": [
        {
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "object"
              },
              {
                "type": "array"
              }
            ]
          }
        },
        {
          "type": "object"
        },
        {
          "type": "string"
        }
      ]
    },
    "title": {
      "type": "string",
      "description": "Optional. When set, the finding as a full sentence, ideally with the key number, e.g. \"Biobío accounts for 32% of sales\". Leave it out when the page around the chart already titles it."
    },
    "subtitle": {
      "type": "string",
      "description": "Optional. How to read the chart: measure, unit and period, e.g. \"Sales by region, CLP millions, 2025\"."
    },
    "source": {
      "type": "string",
      "description": "Optional. Data source, shown at the bottom right."
    },
    "locale": {
      "type": "string",
      "enum": [
        "es",
        "en",
        "pt",
        "fr",
        "de",
        "auto"
      ],
      "description": "Language and number format. Default \"es\" (1.234,5); \"en\" for 1,234.5; also \"pt\", \"fr\", \"de\". \"auto\" recognizes the language from the title, subtitle, column names and categories (tables do this when `locale` is omitted)."
    },
    "x": {
      "type": "string",
      "description": "x-axis or category field (bar, line, area, scatter, heatmap, box, violin…)."
    },
    "y": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ],
      "description": "Value field. For line/bar a list of fields (wide table) turns each one into a series."
    },
    "series": {
      "type": "string",
      "description": "Field that splits the data into colored series. Alias: hue."
    },
    "color": {
      "type": "string",
      "description": "Alias of series when it names a field (a \"#hex\" value is a fixed color instead)."
    },
    "hue": {
      "type": "string",
      "description": "Alias of series (seaborn naming)."
    },
    "value": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        }
      ],
      "description": "Value field for treemap, sunburst, donut, heatmap, sankey and radar. rail: the row value drawn as the dot (a field of the row, or a number)."
    },
    "label": {
      "type": "string",
      "description": "Name field (treemap, donut, point labels in scatter/regplot)."
    },
    "group": {
      "type": "string",
      "description": "Level-1 group field for a two-level treemap (shortcut for path). gantt: phase/workstream field (one colored section per phase). table: rows grouped under a header per value."
    },
    "path": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Hierarchy for treemap/sunburst, any depth: [level1, level2, …]."
    },
    "size": {
      "type": "string",
      "description": "Bubble size field (area-proportional). network: field of `nodes` with each node's weight. dendrogram (rows input): each leaf's weight, drawn as a bar with its figure beside the name (horizontal); joins add up their leaves."
    },
    "sub": {
      "type": "string",
      "description": "dendrogram (rows input): a second line under each leaf name (horizontal); rows grow to fit it."
    },
    "from": {
      "type": "string",
      "description": "Sankey source field."
    },
    "to": {
      "type": "string",
      "description": "Sankey target field."
    },
    "axis": {
      "type": "string",
      "description": "radar: field with the axis names (long format)."
    },
    "axes": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "radar: fields to use as axes (wide format, one row per series)."
    },
    "items": {
      "type": "array",
      "description": "kpi: the indicators to show.",
      "items": {
        "type": "object",
        "required": [
          "label",
          "value"
        ],
        "properties": {
          "label": {
            "type": "string"
          },
          "value": {
            "type": "number"
          },
          "delta": {
            "type": "number",
            "description": "Relative change as a fraction (0.12 = +12%)."
          },
          "previous": {
            "type": "number",
            "description": "Previous value; when given, the change is computed."
          },
          "period": {
            "type": "string",
            "description": "What it is compared against, e.g. \"vs 2025\"."
          },
          "good": {
            "type": "string",
            "enum": [
              "up",
              "down"
            ],
            "description": "Whether going up is good (up) or bad (down, e.g. costs)."
          },
          "trend": {
            "type": "array",
            "items": {
              "type": "number"
            },
            "description": "Short series for the sparkline."
          },
          "target": {
            "type": "number",
            "description": "Target: draws a progress meter."
          },
          "format": {
            "type": "string"
          }
        }
      }
    },
    "text": {
      "description": "wordcloud: field with the words, OR the raw text to count (a string or a list of strings, e.g. open survey answers). Raw text drops Spanish/English stopwords.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ]
    },
    "textField": {
      "type": "string",
      "description": "wordcloud: field holding free text in each row; words are counted across rows."
    },
    "stopwords": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "wordcloud: extra words to ignore when counting raw text."
    },
    "minFont": {
      "type": "number",
      "description": "wordcloud: smallest font size (default 11)."
    },
    "maxFont": {
      "type": "number",
      "description": "wordcloud: largest font size (default from the panel size)."
    },
    "task": {
      "type": "string",
      "description": "gantt: task name field (one row per task)."
    },
    "start": {
      "type": "string",
      "description": "gantt: start date field (\"2026-03-02\", \"2026-03\") or a number (e.g. week)."
    },
    "end": {
      "type": "string",
      "description": "gantt: end date field. Day dates are inclusive. Missing end, or end equal to start, makes a milestone."
    },
    "duration": {
      "type": "string",
      "description": "gantt: duration field (days, or units of a numeric axis) instead of `end`."
    },
    "progress": {
      "type": "string",
      "description": "gantt: completion field, 0–1 or 0–100. The filled part of each bar is the progress."
    },
    "dependsOn": {
      "type": "string",
      "description": "gantt: field with the name(s) of the predecessor task(s) (\"A\" or \"A, B\"): draws arrows."
    },
    "milestone": {
      "type": "string",
      "description": "gantt: boolean field that marks milestones (drawn as diamonds)."
    },
    "today": {
      "description": "gantt: date of the \"today\" line (\"2026-03-12\"), or true for the current date.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "boolean"
        },
        {
          "type": "number"
        }
      ]
    },
    "groupHeaders": {
      "description": "gantt: false draws phases as a color legend instead of section headers.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string",
          "enum": [
            "compact"
          ]
        }
      ]
    },
    "rowHeight": {
      "type": "number",
      "description": "gantt: row height in px."
    },
    "collapsed": {
      "description": "gantt: phases (values of `group`) drawn collapsed into one summary row; true collapses all. In the browser a click on a phase header toggles it.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ]
    },
    "collapsible": {
      "type": "boolean",
      "description": "gantt: false disables click-to-collapse of phases in the browser."
    },
    "critical": {
      "type": "boolean",
      "description": "gantt: highlight the critical path, the zero-slack chain along `dependsOn`."
    },
    "criticalColor": {
      "type": "string",
      "description": "gantt: color of the critical path."
    },
    "weekends": {
      "type": "boolean",
      "description": "gantt: shade weekends on day plans of up to 120 days (default true)."
    },
    "todayColor": {
      "type": "string",
      "description": "gantt: color of the \"today\" line."
    },
    "sort": {
      "type": "string",
      "enum": [
        "desc",
        "asc",
        "none",
        "alpha",
        "start"
      ],
      "description": "bar: category order (desc by default unless the categories are time). gantt: \"start\" orders tasks by start date. donut/chord: \"none\" keeps the data order."
    },
    "geo": {
      "description": "choropleth/symbolmap: \"chile\" (16 regions, default), \"usa\" (50 states + DC, Albers with Alaska/Hawaii insets; Puerto Rico when it has data), \"world\" (countries; matched by ISO-2, ISO-3 or name), a name registered with registerGeo(), or YOUR OWN geometry: a GeoJSON FeatureCollection, Feature, list of Features or bare geometry, a TopoJSON Topology, or geometry already projected at build time: { paths: { id: \"M…Z\" | { d, at: [x, y] } }, points?: { id: [x, y] }, names?: { id: name } } (SVG path strings in pixels, y down; no projection is applied, `orientation`/`rotate` still turn it). Polygons are filled, LineStrings stroked and Points drawn as dots. In the browser, render() also accepts a URL to a .geojson/.topojson file.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "object"
        },
        {
          "type": "array",
          "items": {
            "type": "object"
          }
        }
      ]
    },
    "geoObject": {
      "type": "string",
      "description": "TopoJSON: name of the object inside `objects` to draw (default: the first one)."
    },
    "key": {
      "type": "string",
      "description": "choropleth/symbolmap: data field with the region, state or country name/code to match (US: \"TX\", \"Texas\", \"06\")."
    },
    "projection": {
      "description": "Map projection (picked automatically): \"mercator\", \"equalEarth\", \"albersUsa\", \"equirectangular\", \"conic\" (or { type: \"conic\", parallels: [-30, -45], rotate: 72 }), \"identity\" (coordinates already in pixels, y down) or \"planar\" (projected coordinates such as UTM metres, y up; chosen automatically when coordinates are outside lon/lat range).",
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "mercator",
            "equalEarth",
            "albersUsa",
            "equirectangular",
            "conic",
            "identity",
            "planar"
          ]
        },
        {
          "type": "object",
          "properties": {
            "type": {
              "type": "string"
            },
            "parallels": {
              "type": "array",
              "items": {
                "type": "number"
              }
            },
            "rotate": {
              "type": "number"
            },
            "center": {
              "type": "array",
              "items": {
                "type": "number"
              }
            }
          }
        }
      ]
    },
    "values": {
      "type": "boolean",
      "description": "choropleth with state codes (usa): false shows only the codes, without values."
    },
    "featureKey": {
      "type": "string",
      "description": "choropleth: feature property to match `key` against. Default tries code, id, ISO-3, name and aliases, then any property whose values match the data (e.g. \"CUT_REG\", \"GEOID\")."
    },
    "nameKey": {
      "type": "string",
      "description": "choropleth: feature property with the display name (default: name, NOMBRE, NAME_1, ADMIN…)."
    },
    "fitTo": {
      "description": "Map framing: zoom to some regions (names or codes), a bounding box [lonMin, latMin, lonMax, latMax] (in the geometry's own coordinates), \"markers\", or \"mainland\" (leave out far islands and claims found by the sea gap that separates them: Rapa Nui, Juan Fernández, Antarctica). The rest of the map stays as context, clipped.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "number"
              }
            ]
          }
        }
      ]
    },
    "links": {
      "description": "choropleth/symbolmap: lines between places, drawn above the regions. [{ from, to, value }] or { data, from, to, value, color, curveness (0.2), width: [min, max] px (0.75–6), opacity, label }. Ends are region keys (same matching as `key`) or [lon, lat]. A line is a relation, not a route: curved, one color, no arrowheads, width proportional to value; each line is a hoverable mark with data-key \"from→to\".",
      "anyOf": [
        {
          "type": "array",
          "items": {
            "type": "object"
          }
        },
        {
          "type": "object"
        }
      ]
    },
    "rotate": {
      "type": "number",
      "enum": [
        90,
        -90,
        180,
        270
      ],
      "description": "Maps: turn the projected map a quarter (or half) turn clockwise, after projection and fitting; labels stay upright and hit areas follow. -90 puts north on the left."
    },
    "orientation": {
      "type": "string",
      "enum": [
        "horizontal",
        "vertical"
      ],
      "description": "dendrogram: \"horizontal\" (root left, leaves right, default) or \"vertical\" (root on top)."
    },
    "markers": {
      "description": "Map: points on top, from [{ lon, lat, label, value?, color? }] or { data, lon, lat, label, size, color, legend, maxRadius, labels }. With a size field, circles are area-proportional.",
      "anyOf": [
        {
          "type": "array",
          "items": {
            "type": "object"
          }
        },
        {
          "type": "object"
        }
      ]
    },
    "layers": {
      "type": "array",
      "description": "Map: extra GeoJSON drawn over (or `below: true` under) the regions: rivers, roads, routes, borders, points. Each { geo, label?, stroke?, width?, fill?, dash?, opacity?, below? }; a `label` adds a legend key.",
      "items": {
        "type": "object"
      }
    },
    "borderColor": {
      "type": "string",
      "description": "Map: color of the borders between regions."
    },
    "borderWidth": {
      "type": "number",
      "description": "Map: width of the borders between regions."
    },
    "pointRadius": {
      "type": "number",
      "description": "Map: radius of Point features in your own GeoJSON (default 5)."
    },
    "missing": {
      "type": "string",
      "enum": [
        "hatch",
        "plain",
        "context",
        "tint",
        "gap"
      ],
      "description": "Cells/regions without data. choropleth: \"hatch\" (default), \"plain\" (flat tint) or \"context\" (flat tint, no tooltip and no \"no data\" key: regions drawn only as surroundings). heatmap: \"tint\" (default), \"plain\" (outline only), \"hatch\" or \"gap\" (nothing drawn)."
    },
    "views": {
      "type": "array",
      "description": "choropleth: several readings (indicators, years) of ONE geometry in one SVG. Each view is a patch of the spec: { id (lowercase, digits, - or _), label?, value?, data?, format?, colorScale?, scale?, classes?, thresholds?, midpoint?, colors?, legendTitle?, tooltip?, highlight? (outlined in that view only), links? (that view's lines) }. The first view is drawn as usual; every other view is baked as one class per region and a <style> keyed by the root's data-view attribute, with its legend, labels, lines and tooltips (data-vtip-<id>). Switching views is setting data-view (plotagents/views: setView). Views cannot change the shapes, framing or frame (geo, key, fitTo, orientation, width, title…).",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "label": {
            "type": "string"
          },
          "value": {
            "type": "string"
          },
          "data": {
            "type": "array",
            "items": {
              "type": "object"
            }
          }
        }
      }
    },
    "pathPrecision": {
      "type": "integer",
      "minimum": 0,
      "maximum": 3,
      "description": "sankey: decimals of the link paths (default 2). Maps: decimals of the drawn path coordinates, in pixels. Setting it (or `simplify`) writes compact paths: relative commands, rounded to this grid (default 1). About half the bytes of the default paths."
    },
    "simplify": {
      "type": "number",
      "minimum": 0,
      "description": "Maps: simplify each outline on screen (Douglas–Peucker) with this tolerance in pixels (0.3–1 is invisible on a page and cuts a detailed map to a third). Implies compact paths (`pathPrecision`)."
    },
    "sprite": {
      "type": "string",
      "description": "choropleth: path of an outlines file written once with mapSprite(spec) (e.g. \"/maps/chile.svg\"). Each region becomes a <use href=\"file#id\"> through one transform that frames and turns it, so one cached file serves every page, width and framing; colors, classes, tooltips and links stay on the <use>. Points are still drawn inline. Paths and http(s) only, no #."
    },
    "microstates": {
      "description": "Maps with ISO countries (geo: \"world\"): draw as a dot the states and territories too small to have an outline at this scale (Singapore, Malta, Bahrain, Hong Kong… 74 of them, matched by ISO-2, ISO-3 or name). true: only those with data; \"all\": every one. Dot radius: `pointRadius` (default 2.5).",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string",
          "enum": [
            "all"
          ]
        }
      ]
    },
    "thresholds": {
      "type": "array",
      "items": {
        "type": "number"
      },
      "description": "choropleth: class breaks (same as a list in `scale`)."
    },
    "lat": {
      "type": "string",
      "description": "pointmap: latitude field (auto-detected: lat, latitude, latitud)."
    },
    "lon": {
      "type": "string",
      "description": "pointmap: longitude field (auto-detected: lon, lng, longitude, longitud)."
    },
    "tiles": {
      "description": "pointmap: basemap. \"osm\" (default), \"esri-gray\", \"esri-dark\", \"carto-light\", \"carto-dark\", \"mapbox-light\", \"mapbox-dark\" (needs `tilesKey`), your own { url, attribution, subdomains, maxZoom, retina } with {z}/{x}/{y}, or false for none (vector world outline).",
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "osm",
            "esri-gray",
            "esri-dark",
            "carto-light",
            "carto-dark",
            "mapbox-light",
            "mapbox-dark"
          ]
        },
        {
          "type": "boolean",
          "enum": [
            false
          ]
        },
        {
          "type": "object",
          "properties": {
            "url": {
              "type": "string"
            },
            "attribution": {
              "type": "string"
            },
            "subdomains": {
              "type": "string"
            },
            "maxZoom": {
              "type": "number"
            },
            "retina": {
              "type": "boolean"
            }
          },
          "required": [
            "url"
          ]
        }
      ]
    },
    "tilesKey": {
      "type": "string",
      "description": "pointmap: API key or PUBLIC token for the tile provider (Mapbox \"pk.…\"; a secret \"sk.\" token is rejected because it would be visible in the SVG)."
    },
    "tileStyle": {
      "type": "string",
      "enum": [
        "muted",
        "original"
      ],
      "description": "pointmap: \"muted\" (default) desaturates the basemap so the data stands out; \"original\" keeps its colors."
    },
    "tileOpacity": {
      "type": "number",
      "minimum": 0,
      "maximum": 1,
      "description": "pointmap: basemap opacity."
    },
    "zoom": {
      "type": "number",
      "description": "pointmap: tile zoom level (automatic from the points by default)."
    },
    "center": {
      "type": "array",
      "items": {
        "type": "number"
      },
      "minItems": 2,
      "maxItems": 2,
      "description": "pointmap: map center [lon, lat] (default: fitted to the points)."
    },
    "tall": {
      "type": "boolean",
      "description": "Map: false prevents the tall layout (map on the left, ranked label column on the right) for elongated territories."
    },
    "midpoint": {
      "type": "number",
      "description": "choropleth/heatmap: diverging color scale around this value (e.g. 0 for changes)."
    },
    "classes": {
      "type": "integer",
      "description": "choropleth: number of color classes (default 5)."
    },
    "scale": {
      "description": "choropleth: \"quantile\" (default), \"equal\", \"continuous\", \"categorical\" (text values get one color each; automatic when `value` holds text) or a list of thresholds.",
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "quantile",
            "equal",
            "continuous",
            "categorical"
          ]
        },
        {
          "type": "array",
          "items": {
            "type": "number"
          }
        }
      ]
    },
    "nodes": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "network: node rows (id, group, size). flowchart: steps (id, label, type: start|end|process|decision|data|note, lane). sankey: { id, label, sub, color, column, tip }: an id apart from its label (the same place in two stages stays two nodes), a second line, a fixed column."
    },
    "edges": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "flowchart: connections (from, to, label). Same as `data`."
    },
    "layout": {
      "type": "string",
      "enum": [
        "force",
        "circular",
        "radial",
        "concentric",
        "clusters",
        "tree",
        "grid",
        "circle",
        "preset"
      ],
      "description": "network layout: \"force\" (default) deterministic force-directed; \"circular\" around a circle by group with names rotated outward (\"circle\" = circular); \"radial\" tree rings from `focus` or the most connected node; \"concentric\" rings by weight; \"clusters\" one cluster per group; \"tree\" the radial tree laid flat; \"grid\" ordered by group; \"preset\" nodes bring their own x, y (MDS, UMAP, Gephi…), fitted with one scale for both axes; edges are then optional."
    },
    "nodeX": {
      "type": "string",
      "description": "network layout \"preset\": field of `nodes` with the x position (default \"x\")."
    },
    "nodeY": {
      "type": "string",
      "description": "network layout \"preset\": field of `nodes` with the y position (default \"y\"); y grows downward unless `flipY`."
    },
    "flipY": {
      "type": "boolean",
      "description": "network layout \"preset\" and maps with projection \"identity\": y grows upward (math orientation) instead of downward."
    },
    "curveness": {
      "type": "number",
      "minimum": 0,
      "description": "network: edge bend as a share of its length (default 0.3; 0 = straight)."
    },
    "maxRadius": {
      "type": "number",
      "description": "network/symbolmap/pointmap/bubble: largest node or circle radius in px."
    },
    "minRadius": {
      "type": "number",
      "exclusiveMinimum": 0,
      "description": "network: smallest node radius in px (default 2.5), so the lightest nodes stay visible."
    },
    "stretch": {
      "type": "boolean",
      "description": "network layout \"preset\": scale x and y separately so the positions fill the area (for coordinates already normalized per axis, like 0–1 MDS output). Default false keeps one scale for both axes."
    },
    "edgeColor": {
      "type": "string",
      "description": "network: \"source\" (default) draws each edge in its source node's color; \"neutral\" draws every edge in the theme's muted ink; any color (or \"var(--x, #hex)\") sets one ink for all. `colors[\"a→b\"]` still pins one edge (either direction), drawn on top."
    },
    "edgeOpacity": {
      "description": "network: edge opacity, a number for all, or [min, max] scaled by value (linear). Default 0.5 (0.3 above 150 edges).",
      "anyOf": [
        {
          "type": "number",
          "minimum": 0,
          "maximum": 1
        },
        {
          "type": "array",
          "items": {
            "type": "number"
          },
          "minItems": 2,
          "maxItems": 2
        }
      ]
    },
    "edgeWidth": {
      "description": "network: edge width in px, a number for all, or [min, max] scaled by the square root of value. Default 0.6–3 with a value field, 1 without.",
      "anyOf": [
        {
          "type": "number",
          "exclusiveMinimum": 0
        },
        {
          "type": "array",
          "items": {
            "type": "number"
          },
          "minItems": 2,
          "maxItems": 2
        }
      ]
    },
    "iterations": {
      "type": "integer",
      "description": "network: force-layout iterations (automatic by size)."
    },
    "nodeId": {
      "type": "string",
      "description": "network: id field in `nodes` (default id/name)."
    },
    "nodeLabel": {
      "type": "string",
      "description": "network: label field in `nodes` (default label, else the id)."
    },
    "labelOrientation": {
      "type": "string",
      "enum": [
        "horizontal",
        "radial"
      ],
      "description": "chord: label orientation (radial by default above 10 groups)."
    },
    "ribbonColor": {
      "type": "string",
      "enum": [
        "source",
        "smaller",
        "larger"
      ],
      "description": "chord: ribbon color: \"source\" (default when directed), \"smaller\" group (default) or \"larger\" flow."
    },
    "matrix": {
      "type": "array",
      "items": {
        "type": "array",
        "items": {
          "type": "number"
        }
      },
      "description": "chord: square flow matrix (with `names`)."
    },
    "names": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "chord: group names for `matrix`."
    },
    "directed": {
      "type": "boolean",
      "description": "chord: treat flows as directed (default false)."
    },
    "direction": {
      "type": "string",
      "enum": [
        "TB",
        "LR"
      ],
      "description": "flowchart: top-to-bottom or left-to-right (automatic by default)."
    },
    "age": {
      "type": "string",
      "description": "pyramid: age-group field."
    },
    "sex": {
      "type": "string",
      "description": "pyramid: field with exactly two sides (e.g. sex)."
    },
    "percent": {
      "type": "boolean",
      "description": "pyramid: show shares of the total population."
    },
    "facet": {
      "type": "string",
      "description": "One panel per value of this field (small multiples, seaborn col). Shared scales and colors."
    },
    "col": {
      "type": "string",
      "description": "Alias of facet (seaborn naming)."
    },
    "facetOrder": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "facet: panel order (values of the facet field; the rest follow)."
    },
    "columns": {
      "description": "table: the columns, in order: field names or objects { field, label, type, format, align, width, good, target, colorScale, total, lines }. Column types: text, number, bar (data bar), heat (cell color), delta (▲/▼ change, colored by `good`), sparkline (field holds a list of numbers), progress (meter vs `target` field/number, or 0–1 / 0–100), badge (status pill; status words in es/en/pt/fr/de get good/warning/critical colors), check (booleans as ✓), date, link, rank, range (a rail: the row value as a dot on min–max, with a band [lo, hi], a median notch and reference ticks (`ref` or `refs: [{ field | value, label }]`); `scale: \"row\"` gives each row its own scale; `clip: true` cuts the scale to min–max and `domain: [from, to]` (numbers or fields) to any span, drawing what falls past an end as a chevron; a row without min/max in a column that has them prints only its number). link: a URL (opens in a new tab) or a site path such as \"/es/x\" (same tab). Omit to infer everything. facet: panels per row (an integer, seaborn col_wrap). kpi: tiles per row. waffle: squares per row.",
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "object",
                "properties": {
                  "field": {
                    "type": "string"
                  },
                  "label": {
                    "type": "string"
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "text",
                      "number",
                      "bar",
                      "heat",
                      "delta",
                      "sparkline",
                      "progress",
                      "badge",
                      "check",
                      "date",
                      "link",
                      "rank",
                      "range"
                    ]
                  },
                  "format": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "object"
                      }
                    ]
                  },
                  "align": {
                    "type": "string",
                    "enum": [
                      "left",
                      "right",
                      "center"
                    ]
                  },
                  "width": {
                    "type": "number"
                  },
                  "good": {
                    "type": "string",
                    "enum": [
                      "up",
                      "down"
                    ]
                  },
                  "target": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "number"
                      }
                    ]
                  },
                  "colorScale": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      {
                        "type": "object"
                      }
                    ]
                  },
                  "min": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "number"
                      }
                    ],
                    "description": "range: field (or fixed number) with the low end of the rail."
                  },
                  "max": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "number"
                      }
                    ],
                    "description": "range: high end of the rail."
                  },
                  "band": {
                    "type": "array",
                    "items": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "number"
                        }
                      ]
                    },
                    "minItems": 2,
                    "maxItems": 2,
                    "description": "range: [lo, hi] fields of the shaded band (e.g. quartiles)."
                  },
                  "bandLabel": {
                    "type": "string"
                  },
                  "median": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "number"
                      }
                    ],
                    "description": "range: notch."
                  },
                  "ref": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "number"
                      }
                    ],
                    "description": "range: reference tick (e.g. the national figure)."
                  },
                  "refLabel": {
                    "type": "string"
                  },
                  "refs": {
                    "type": "array",
                    "items": {
                      "anyOf": [
                        {
                          "type": "number"
                        },
                        {
                          "type": "string"
                        },
                        {
                          "type": "object",
                          "properties": {
                            "value": {
                              "type": "number"
                            },
                            "field": {
                              "type": "string"
                            },
                            "label": {
                              "type": "string"
                            },
                            "color": {
                              "type": "string"
                            }
                          }
                        }
                      ]
                    },
                    "description": "range: several reference ticks, each with its label in the tooltip."
                  },
                  "clip": {
                    "type": "boolean",
                    "description": "range: the scale is min–max (the column's, or the row's with scale: \"row\"); what falls past an end is a chevron."
                  },
                  "domain": {
                    "type": "array",
                    "minItems": 2,
                    "maxItems": 2,
                    "items": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "number"
                        }
                      ]
                    },
                    "description": "range: each row's scale, [from, to] as numbers or fields (e.g. p5–p95); past an end, a chevron."
                  },
                  "minLabel": {
                    "type": "string"
                  },
                  "maxLabel": {
                    "type": "string"
                  },
                  "medianLabel": {
                    "type": "string"
                  },
                  "domainLabel": {
                    "type": "string"
                  },
                  "scale": {
                    "type": "string",
                    "enum": [
                      "shared",
                      "row"
                    ],
                    "description": "range: one scale for the column (default) or one per row (indicators in different units)."
                  },
                  "formatBy": {
                    "type": "string",
                    "description": "number/bar/heat/delta/range: one format per row (indicators in different units). A field whose value is a format (\"percent\", { suffix: \" yrs\" }); from JS also a function (value, row) => text. Range rails go per row; no total."
                  },
                  "total": {
                    "anyOf": [
                      {
                        "type": "boolean"
                      },
                      {
                        "type": "string",
                        "enum": [
                          "sum",
                          "mean",
                          "min",
                          "max",
                          "count"
                        ]
                      }
                    ]
                  },
                  "lines": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 6
                  },
                  "text": {
                    "type": "string",
                    "description": "link: field with the text to show instead of the URL."
                  },
                  "sortable": {
                    "type": "boolean"
                  }
                }
              }
            ]
          }
        }
      ]
    },
    "sortBy": {
      "type": "string",
      "description": "table: column to sort by (field or label). Numbers sort high→low by default, text A→Z. In the browser a click on a header sorts."
    },
    "sortOrder": {
      "type": "string",
      "enum": [
        "asc",
        "desc"
      ],
      "description": "table: sort direction (same as `sort: \"asc\" | \"desc\"`)."
    },
    "pageSize": {
      "anyOf": [
        {
          "type": "integer",
          "minimum": 1
        },
        {
          "type": "boolean",
          "enum": [
            false
          ]
        }
      ],
      "description": "table: rows per page. Default: all rows up to 15, then pages of 10. false shows every row."
    },
    "page": {
      "type": "integer",
      "minimum": 1,
      "description": "table: page to show (1-based). In the browser the pager changes it."
    },
    "query": {
      "type": "string",
      "description": "table: show only rows that contain these words (accent- and case-insensitive)."
    },
    "search": {
      "type": "boolean",
      "description": "table: search box in the browser (default: on above 20 rows)."
    },
    "total": {
      "description": "table: totals row. true sums numbers (and averages percents and progress); \"mean\"/\"sum\"; or { field: \"sum\" | \"mean\" | false, label }.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string",
          "enum": [
            "sum",
            "mean",
            "min",
            "max"
          ]
        },
        {
          "type": "object"
        }
      ]
    },
    "totalLabel": {
      "type": "string",
      "description": "table: label of the totals row (default \"Total\"/\"Gesamt\")."
    },
    "rank": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string"
        }
      ],
      "description": "table: true adds a \"#\" column with the position under the current sort. bump: a field that already holds the rank (1 = first), instead of ranking `y`."
    },
    "ends": {
      "type": "string",
      "enum": [
        "all",
        "first-last"
      ],
      "description": "bump: \"first-last\" draws only the first and last period (a slope chart; the `slope` alias sets it)."
    },
    "linkage": {
      "type": "array",
      "items": {
        "type": "array",
        "items": {
          "type": "number"
        }
      },
      "description": "dendrogram: a scipy-style linkage matrix (n − 1 rows [a, b, height, count]); indices < n are leaves. Pair it with `labels` (one per observation)."
    },
    "clusters": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "dendrogram: names for the groups that `cut` makes, in leaf order."
    },
    "parent": {
      "type": "string",
      "description": "dendrogram: field with the parent id of each row (empty for the root)."
    },
    "heightField": {
      "type": "string",
      "description": "dendrogram: field with the height at which a node joins its children (default \"height\"). With rows input, `series` colors each leaf by a field (a swatch at its end, no `cut` needed; legend unless `legend: false`), `size` weighs it, `sub` adds a second line and `xLabel` titles the height axis."
    },
    "bin": {
      "type": "number",
      "description": "dotplot: bin width in units of `x` (or `bins` for a count)."
    },
    "ticks": {
      "type": "array",
      "description": "dotplot: your own axis ticks, [[value, label], …] (e.g. income brackets), instead of the automatic ones.",
      "items": {
        "anyOf": [
          {
            "type": "number"
          },
          {
            "type": "array"
          }
        ]
      }
    },
    "dotSize": {
      "type": "number",
      "description": "dotplot: largest dot diameter in px (default 14)."
    },
    "min": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        }
      ],
      "description": "rail: low end of the rail (a field of the row, or a number)."
    },
    "max": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        }
      ],
      "description": "rail: high end of the rail."
    },
    "median": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        }
      ],
      "description": "rail: the median notch."
    },
    "ref": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        }
      ],
      "description": "rail: one reference tick (same as a one-entry `refs`), named by `refLabel`."
    },
    "refs": {
      "type": "array",
      "description": "rail and table `range` columns: reference ticks, each with its own label in the tooltip: [{ field: \"region\", label: \"Biobío\" }, { value: 12, label: \"Target\", color }]. `label` may name a field of the row. A ref outside a clipped scale is an open chevron at that end.",
      "items": {
        "anyOf": [
          {
            "type": "number"
          },
          {
            "type": "string"
          },
          {
            "type": "object",
            "properties": {
              "value": {
                "type": "number"
              },
              "field": {
                "type": "string"
              },
              "label": {
                "type": "string"
              },
              "color": {
                "type": "string"
              }
            }
          }
        ]
      }
    },
    "refLabel": {
      "type": "string",
      "description": "rail: name of `ref` in the tooltip (default \"Reference\")."
    },
    "bandLabel": {
      "type": "string",
      "description": "rail: name of the band in the tooltip (default \"Middle half\")."
    },
    "medianLabel": {
      "type": "string",
      "description": "rail: name of the median in the tooltip (default \"Median\")."
    },
    "minLabel": {
      "type": "string",
      "description": "rail: name of the low end in the tooltip, or a field of the row holding it (e.g. the lowest place). With minLabel/maxLabel the tooltip lists both ends instead of \"Range: a–b\"."
    },
    "maxLabel": {
      "type": "string",
      "description": "rail: name of the high end in the tooltip, or a field of the row holding it."
    },
    "valueLabel": {
      "type": "string",
      "description": "rail: name of the dot in the tooltip (default: the value field), or a field of the row holding it."
    },
    "domainLabel": {
      "type": "string",
      "description": "rail: with `domain`, a tooltip line naming the scale (e.g. \"Middle 90% of communes\")."
    },
    "domain": {
      "type": "array",
      "minItems": 2,
      "maxItems": 2,
      "items": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "number"
          }
        ]
      },
      "description": "rail: the scale, [from, to] as numbers or fields (e.g. [\"p5\", \"p95\"]). Anything past an end is drawn as a chevron at that end instead of stretching the scale; without min/max the rail spans the whole domain."
    },
    "clip": {
      "type": "boolean",
      "description": "rail: the scale is [min, max]; a value or reference past an end is a chevron at that end (it does not stretch the scale)."
    },
    "fallback": {
      "type": "string",
      "enum": [
        "value",
        "none"
      ],
      "description": "rail: what a row without min/max (and no `domain`) shows: the figure alone (default) or nothing. Never a lone dot."
    },
    "dot": {
      "type": "boolean",
      "description": "spark: false hides the end dot."
    },
    "dotRadius": {
      "type": "number",
      "description": "spark: end dot radius in px. rail: the dot radius (default 4.5 at 18 px tall). dotplot: dot radius in px, not capped by the pixel width of a bin (a fine bin in a narrow box keeps readable dots; neighbours may touch). With an explicit `height` it still shrinks so the tallest stack fits."
    },
    "unit": {
      "type": "number",
      "description": "waffle: what one square is worth (default 1, or a round number when the total passes `maxSquares`)."
    },
    "maxSquares": {
      "type": "integer",
      "description": "waffle: most squares before each square is worth a round `unit` (default 400)."
    },
    "perSquare": {
      "type": "boolean",
      "description": "waffle: each square is its own mark (a <rect>, with `rx` when rounded) with its own row's tooltip (one check, one person), in data order within each series. Only while one square is one unit."
    },
    "cellRadius": {
      "type": "number",
      "minimum": 0,
      "description": "waffle: corner radius of each square in px (0 = square corners). Default: the theme's bar radius, at most a quarter of the square."
    },
    "cards": {
      "description": "table: one card per row. \"auto\" (default) switches when the columns do not fit (phones); true always; false never (columns shrink and truncate).",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string",
          "enum": [
            "auto"
          ]
        }
      ]
    },
    "density": {
      "type": "string",
      "enum": [
        "compact",
        "normal",
        "comfortable"
      ],
      "description": "table: row height."
    },
    "striped": {
      "type": "boolean",
      "description": "table: tint every other row (helps on very wide tables)."
    },
    "bars": {
      "type": "boolean",
      "description": "table: false turns off the automatic data bar on the main numeric column."
    },
    "sortable": {
      "type": "boolean",
      "description": "table: false disables click-to-sort on headers in the browser."
    },
    "sharex": {
      "type": "boolean",
      "description": "facet: same x scale in every panel (default true)."
    },
    "panelHeight": {
      "type": "number",
      "description": "facet: height of each panel in px (a `panelNote` adds its own lines on top)."
    },
    "sharey": {
      "description": "facet: same y scale in every panel (default true). \"span\": the same span in every panel, each with its own floor, and the same plot size in pixels, so a slope means the same change everywhere.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string",
          "enum": [
            "span"
          ]
        }
      ]
    },
    "panelNote": {
      "type": "string",
      "description": "facet: a field whose value is written under each panel name (e.g. the latest value and its change). Space is reserved for it in every panel, so panels never overlap and keep the same plot height."
    },
    "panelColor": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          }
        }
      ],
      "description": "facet: write each panel name in a colour: true takes the panel's series colour (facet and series on the same field, or one series per panel); an object { panel: color }; from JS a function (panel, rows) => color. Hex colours are darkened as needed to stay readable."
    },
    "time": {
      "type": "string",
      "description": "Time field (d3plus-style): shows one period at a time (the latest by default, or `timeValue`). Add `slider: true` only when the person asks to move through periods."
    },
    "timeValue": {
      "description": "Period to show when `time` is set."
    },
    "slider": {
      "description": "Browser time controls, OFF by default; set them only when the person asks. true: period buttons when there are few periods (≤ 8), a minimal slider otherwise; line/area get a range slider. \"buttons\" or \"slider\" force one.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string",
          "enum": [
            "buttons",
            "slider"
          ]
        }
      ]
    },
    "play": {
      "type": "boolean",
      "description": "Browser: false keeps the time controls but hides the play button."
    },
    "playInterval": {
      "type": "number",
      "description": "Browser: milliseconds per period while playing."
    },
    "legend": {
      "description": "Legend: true/false, or its position \"top\" (default), \"bottom\", \"left\", \"right\" (left/right fall back to bottom under 520px wide), or { position }.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string",
          "enum": [
            "top",
            "bottom",
            "left",
            "right"
          ]
        },
        {
          "type": "object",
          "properties": {
            "position": {
              "type": "string",
              "enum": [
                "top",
                "bottom",
                "left",
                "right"
              ]
            }
          }
        }
      ]
    },
    "legendTitle": {
      "type": "string",
      "description": "Title of a color-ramp or size legend (heatmap, maps)."
    },
    "exclude": {
      "description": "Drop legend entries (series, first hierarchy level, group or donut slice) and recompute axes and shares with the rest. Colors stay fixed; excluded entries remain in the legend, faded, so a click re-adds them. In the browser shift+click on a legend key toggles it.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ]
    },
    "compare": {
      "description": "With `time`: period to compute changes against: \"previous\" (default), \"first\", a specific period, or false.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        },
        {
          "type": "boolean"
        }
      ]
    },
    "colorBy": {
      "type": "string",
      "enum": [
        "group",
        "change",
        "label"
      ],
      "description": "treemap: \"change\" colors tiles by % change vs the comparison period (diverging, growth cool / decline warm); \"label\" colors a single-level treemap by item."
    },
    "shade": {
      "type": "boolean",
      "description": "treemap/sunburst: subtle lightness steps inside each category (default false: one solid color per category)."
    },
    "xRange": {
      "type": "array",
      "description": "line/area: visible x range [from, to] (what the range slider sets with `slider: true`)."
    },
    "showValues": {
      "type": "boolean",
      "description": "treemap: show each tile value next to its label."
    },
    "hole": {
      "type": "number",
      "minimum": 0,
      "maximum": 0.9,
      "description": "sunburst: size of the center hole as a fraction of the radius (default 0.3)."
    },
    "focus": {
      "description": "treemap/sunburst: path to drill into, e.g. [\"Mining\"] (in the browser a click on a tile or legend key zooms to it). network: a node id to center and highlight with its neighbors.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ]
    },
    "depth": {
      "type": "integer",
      "description": "treemap/sunburst: how many levels to show."
    },
    "xScale": {
      "type": "string",
      "enum": [
        "linear",
        "log"
      ]
    },
    "yScale": {
      "type": "string",
      "enum": [
        "linear",
        "log"
      ]
    },
    "xDomain": {
      "type": "array",
      "items": {
        "type": "number"
      },
      "description": "Fixed x domain [min, max]."
    },
    "yDomain": {
      "type": "array",
      "items": {
        "type": "number"
      },
      "description": "Fixed value-axis domain [min, max]."
    },
    "valueDomain": {
      "type": "array",
      "items": {
        "type": "number"
      },
      "minItems": 2,
      "maxItems": 2,
      "description": "box/violin/strip/swarm/point/radar: fixed value-axis domain [min, max] whatever the orientation."
    },
    "orient": {
      "type": "string",
      "enum": [
        "v",
        "h"
      ],
      "description": "box/violin/strip/swarm/point: \"v\" vertical or \"h\" horizontal (same as `horizontal`)."
    },
    "zero": {
      "type": "boolean",
      "description": "line: force (or prevent) a y axis starting at zero."
    },
    "xLabel": {
      "type": "string",
      "description": "x-axis title."
    },
    "yLabel": {
      "type": "string",
      "description": "y-axis title (drawn horizontally above the axis)."
    },
    "format": {
      "description": "Value format: \"number\" | \"compact\" | \"percent\" | \"currency\" | \"integer\", or { type, prefix, suffix, decimals (0–20), currency }.",
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "number",
            "compact",
            "percent",
            "currency",
            "integer"
          ]
        },
        {
          "type": "object",
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "number",
                "compact",
                "percent",
                "currency",
                "integer"
              ]
            },
            "prefix": {
              "type": "string"
            },
            "suffix": {
              "type": "string"
            },
            "decimals": {
              "type": "integer",
              "minimum": 0,
              "maximum": 20
            },
            "currency": {
              "type": "string"
            },
            "scale": {
              "type": "number"
            }
          }
        }
      ]
    },
    "xFormat": {
      "description": "Format of x values when x is a measure (scatter, regplot, hist).",
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "number",
            "compact",
            "percent",
            "currency",
            "integer"
          ]
        },
        {
          "type": "object",
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "number",
                "compact",
                "percent",
                "currency",
                "integer"
              ]
            },
            "prefix": {
              "type": "string"
            },
            "suffix": {
              "type": "string"
            },
            "decimals": {
              "type": "integer",
              "minimum": 0,
              "maximum": 20
            },
            "currency": {
              "type": "string"
            },
            "scale": {
              "type": "number"
            }
          }
        }
      ]
    },
    "yFormat": {
      "description": "Format of the y-axis ticks (line, area, bar: the value axis), apart from `format`, which writes labels and tooltips. Default: `format`.",
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "number",
            "compact",
            "percent",
            "currency",
            "integer"
          ]
        },
        {
          "type": "object",
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "number",
                "compact",
                "percent",
                "currency",
                "integer"
              ]
            },
            "prefix": {
              "type": "string"
            },
            "suffix": {
              "type": "string"
            },
            "decimals": {
              "type": "integer",
              "minimum": 0,
              "maximum": 20
            },
            "currency": {
              "type": "string"
            },
            "scale": {
              "type": "number"
            }
          }
        }
      ]
    },
    "highlight": {
      "description": "Emphasize one or more categories/series and mute the rest. table: the rows whose label matches.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ]
    },
    "dashed": {
      "description": "Draw some shapes dashed (hatched fill + dashed outline; dashed stroke for lines) to mark estimates, projections or provisional figures. A category/series/region name or a list of them, a data field whose truthy rows are dashed, { field, equals }, or true for all.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "boolean"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        {
          "type": "object",
          "properties": {
            "field": {
              "type": "string"
            },
            "equals": {}
          }
        }
      ]
    },
    "dashedFrom": {
      "description": "line/area/bar on a time axis: x value from which marks are dashed (a projection). Lines turn dashed from the last firm point, over a soft labeled band.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        }
      ]
    },
    "dashedLabel": {
      "description": "What the dashed shapes mean (\"Projection\", \"Preliminary\"): legend entry, band label and tooltip line. false hides the band label.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "boolean"
        }
      ]
    },
    "labels": {
      "description": "Value labels: true, false or \"auto\". In scatter/regplot: a number of points or a list of names to label. network: true labels every node. dendrogram: leaf labels true/false/\"auto\" (every k-th when they do not fit), or with `linkage`, the list of leaf names.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string"
        },
        {
          "type": "number"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ]
    },
    "refLines": {
      "type": "array",
      "description": "Reference lines (targets, averages). dotplot: vertical lines at `x` (a number, or a field whose rows all hold the same value), label on top; `showValue: false` writes the label without the value, on the line and in its tooltip; `dash: true` (3 3) or an SVG dash pattern (\"4 2\") dashes it.",
      "items": {
        "type": "object",
        "properties": {
          "y": {
            "type": "number"
          },
          "x": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "string"
              }
            ]
          },
          "value": {
            "type": "number"
          },
          "label": {
            "type": "string"
          },
          "color": {
            "type": "string"
          },
          "showValue": {
            "type": "boolean"
          },
          "dash": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "string"
              }
            ]
          }
        }
      }
    },
    "annotations": {
      "type": "array",
      "description": "line/area: events on the x axis.",
      "items": {
        "type": "object",
        "properties": {
          "x": {},
          "label": {
            "type": "string"
          }
        }
      }
    },
    "stack": {
      "description": "bar/area: true stacks; \"percent\" stacks to 100%.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string",
          "enum": [
            "percent"
          ]
        }
      ]
    },
    "horizontal": {
      "type": "boolean",
      "description": "Force horizontal orientation (otherwise chosen from label length and count)."
    },
    "top": {
      "type": "integer",
      "description": "bar: keep the N largest and fold the rest into \"Other\". table: keep the first N rows after sorting. bump: keep series in the top N at some period (default 12); a rank below N is drawn on a \"below N\" row."
    },
    "endLabels": {
      "type": "boolean",
      "description": "line/regplot: false removes the series names at the end of each line (a legend is drawn instead)."
    },
    "labelsFor": {
      "type": "object",
      "additionalProperties": {
        "type": "string"
      },
      "description": "Wide table (y as a list): display names per column, e.g. { \"rev\": \"Revenue\" }."
    },
    "index": {
      "type": "boolean",
      "description": "line: rebase each series to 100 at its first value (compare growth without a dual axis)."
    },
    "curve": {
      "type": "string",
      "enum": [
        "linear",
        "smooth",
        "step"
      ]
    },
    "aggregate": {
      "type": "string",
      "enum": [
        "sum",
        "mean",
        "max",
        "min",
        "count",
        "last",
        "first"
      ],
      "description": "How to combine repeated rows. Default sum."
    },
    "ci": {
      "description": "line/bar/regplot: confidence interval (true = 95, or a number). In line/bar it switches the estimator to the mean.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "number"
        }
      ]
    },
    "errorbar": {
      "type": "string",
      "enum": [
        "ci",
        "sd",
        "se",
        "pi",
        "none"
      ],
      "description": "Error bar or band type."
    },
    "estimator": {
      "type": "string",
      "enum": [
        "mean",
        "median",
        "sum",
        "count"
      ],
      "description": "How to summarize several observations per category."
    },
    "bins": {
      "type": "integer",
      "description": "hist: number of bins."
    },
    "binWidth": {
      "type": "number",
      "description": "hist: bin width."
    },
    "stat": {
      "type": "string",
      "enum": [
        "count",
        "percent",
        "density",
        "probability"
      ],
      "description": "hist: what the y axis measures."
    },
    "kde": {
      "type": "boolean",
      "description": "hist: overlay a density curve."
    },
    "multiple": {
      "type": "string",
      "enum": [
        "layer",
        "stack",
        "dodge",
        "fill"
      ],
      "description": "hist/kde with hue: how groups are combined."
    },
    "fill": {
      "type": "boolean",
      "description": "kde: fill the area. line: false removes the gradient under a single line."
    },
    "order": {
      "description": "regplot: polynomial degree (number). box/violin/strip/swarm/point: category order (list). corr: variable order (list). sankey: \"given\" keeps the order of `nodes` in every column. waffle: series order (default: largest first).",
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        {
          "type": "string",
          "enum": [
            "given"
          ]
        }
      ]
    },
    "stages": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "sankey: a heading over each column (\"Region\", \"Customs office\", \"Country\")."
    },
    "relax": {
      "description": "sankey: separate the node labels of each column so none overprints its neighbor. true keeps 31 px between label centers (name plus second line); a number sets that distance (below 28 px each label is one line). Labels move as little as possible, every node is named, and a moved label gets a leader line to its node. Without `height` the chart grows until the labels fit.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "number",
          "exclusiveMinimum": 0
        }
      ]
    },
    "linkColor": {
      "description": "sankey: flows take the color of their \"source\" or their \"target\"; a list sets it per stage ([\"source\", \"target\"]). `colors[\"from→to\"]` pins one flow.",
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "source",
            "target"
          ]
        },
        {
          "type": "array",
          "items": {
            "type": "string",
            "enum": [
              "source",
              "target"
            ]
          }
        }
      ]
    },
    "tooltip": {
      "description": "What each mark says on hover, beyond its value. true keeps the default lines (on a dendrogram it also gives every join a card: height, leaves, weight, and the fields of its own row). A list of fields (\"Field: value\" lines from the mark's rows), or { title: field, fields: [field | { field, label, format }], text: field (pre-written text, may hold line breaks), replace: true (drop the default lines) }, or false. From JavaScript, also a function (d) => text | { title, lines }. A mark made of several rows shows a field only when they agree.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "object"
              }
            ]
          }
        },
        {
          "type": "object",
          "properties": {
            "title": {
              "type": "string"
            },
            "fields": {
              "type": "array"
            },
            "text": {
              "type": "string"
            },
            "replace": {
              "type": "boolean"
            }
          }
        }
      ]
    },
    "crosshair": {
      "type": "boolean",
      "description": "line/area: false writes one tooltip column per x (with `data-tip`) instead of the browser crosshair: for pages that bring their own tooltip layer. Implied by `tooltip`."
    },
    "band": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "lower": {
              "type": "string"
            },
            "upper": {
              "type": "string"
            },
            "label": {
              "type": "string"
            }
          },
          "required": [
            "lower",
            "upper"
          ]
        },
        {
          "type": "array",
          "items": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "number"
              }
            ]
          },
          "minItems": 2,
          "maxItems": 2
        }
      ],
      "description": "line/area: an interval that comes already computed (a model's 80% interval, a published range), drawn as is with no estimator. `label` names it in the legend. Combines with `dashedFrom`. rail: [lo, hi] fields (or numbers) of the shaded band, e.g. the quartiles."
    },
    "missingLabel": {
      "type": "string",
      "description": "bar: what the tooltip says for a value that is missing (default \"sin dato\" / \"no data\"). A missing value is never drawn as 0. heatmap: what the tooltip of a cell without a value says (default \"—\"). table: what a cell (and its tooltip) prints for a missing value (default \"—\")."
    },
    "missingMark": {
      "type": "string",
      "description": "bar: text written at the base where a bar is missing (\"n/a\")."
    },
    "xBands": {
      "description": "bar (columns) and line/area: shaded ranges of the x axis behind the marks: [{ from, to, label, color }].",
      "anyOf": [
        {
          "type": "object"
        },
        {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "from": {},
              "to": {},
              "label": {
                "type": "string"
              },
              "color": {
                "type": "string"
              }
            }
          }
        }
      ]
    },
    "href": {
      "type": "string",
      "description": "treemap tiles, horizontal bar names, scatter dots, choropleth regions and network nodes (a field of `nodes`) link to the URL in this field (paths and http(s) only)."
    },
    "hollow": {
      "description": "scatter/bubble: rows where this field is truthy are drawn as hollow dots (same color as the outline). network: a field of `nodes`, or a list of node ids, drawn hollow: a second encoding without a second color (hollow nodes are named after the filled ones, in a muted ink).",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ]
    },
    "filled": {
      "description": "scatter/bubble: the opposite of `hollow`: rows where this field is falsy are hollow. network: a field of `nodes` or a list of node ids that stay filled; every other node is hollow (e.g. the activities one place specializes in, lit on the same map).",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ]
    },
    "lowess": {
      "type": "boolean",
      "description": "regplot: local regression instead of a straight line."
    },
    "logx": {
      "type": "boolean",
      "description": "regplot: fit y ~ log(x) with a log x axis."
    },
    "trend": {
      "type": "boolean",
      "description": "scatter: add a least-squares line and R²."
    },
    "annotate": {
      "type": "boolean",
      "description": "regplot: show R² and n."
    },
    "kind": {
      "type": "string",
      "enum": [
        "scatter",
        "reg"
      ],
      "description": "jointplot: center plot. pairplot: \"reg\" adds a least-squares line to every scatter panel."
    },
    "marginal": {
      "type": "string",
      "enum": [
        "hist",
        "kde"
      ],
      "description": "jointplot: marginal plots."
    },
    "inner": {
      "type": "string",
      "enum": [
        "box",
        "quartiles",
        "points",
        "stick",
        "none"
      ],
      "description": "violin: what goes inside."
    },
    "bandwidth": {
      "type": "number",
      "description": "violin: KDE bandwidth (default Scott's rule)."
    },
    "bwAdjust": {
      "type": "number",
      "description": "kde/violin/hist kde: multiply the bandwidth (seaborn bw_adjust)."
    },
    "cut": {
      "type": "number",
      "description": "kde/violin: how far the density extends past the data, in bandwidths. dendrogram: the height to cut at; each subtree below it is a colored, named group."
    },
    "jitter": {
      "description": "strip: spread of the points across the category (fraction of the band, default 0.6; 0 or false = none).",
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "boolean"
        }
      ]
    },
    "dodge": {
      "type": "boolean",
      "description": "strip/swarm/point with hue: place groups side by side."
    },
    "hueOrder": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "Order of the hue groups."
    },
    "showMeans": {
      "type": "boolean",
      "description": "box/strip: mark the mean."
    },
    "cumulative": {
      "type": "boolean",
      "description": "hist/kde: cumulative distribution."
    },
    "rug": {
      "type": "boolean",
      "description": "kde: tick marks for each observation."
    },
    "complementary": {
      "type": "boolean",
      "description": "ecdf: show 1 − F(x) (share above each value)."
    },
    "radius": {
      "type": "number",
      "description": "Point radius in px (scatter, regplot, strip, swarm)."
    },
    "split": {
      "type": "boolean",
      "description": "violin: with two hue levels, one half each."
    },
    "points": {
      "description": "box: overlay the observations. line: markers on every point; a list of series names (or { series: true }) puts them only on those series.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        {
          "type": "object",
          "additionalProperties": {
            "type": "boolean"
          }
        }
      ]
    },
    "lineWidths": {
      "type": "object",
      "additionalProperties": {
        "type": "number"
      },
      "description": "line: stroke width per series in px, e.g. { \"1991–2020 mean\": 3.5 }. Series not named keep the default; legend and end labels are unchanged."
    },
    "tileLabels": {
      "type": "string",
      "enum": [
        "auto",
        "wrap"
      ],
      "description": "treemap: \"auto\" (default) writes a name only when it fits whole with its share; \"wrap\" also writes it on two or three lines without the share, and as a last resort truncated with \"…\"."
    },
    "shareOf": {
      "type": "string",
      "enum": [
        "group",
        "total",
        "both"
      ],
      "description": "treemap with `focus`: what share each tile prints: of the group (default), of the whole, or both (\"53% · 11% of total\")."
    },
    "normalize": {
      "type": "boolean",
      "description": "radar: scale each axis 0–1 by its own maximum."
    },
    "half": {
      "type": "boolean",
      "description": "donut: semicircle."
    },
    "thickness": {
      "type": "number",
      "minimum": 0,
      "maximum": 1,
      "description": "donut: ring thickness as a fraction of the radius (1 = pie)."
    },
    "maxSlices": {
      "type": "integer",
      "minimum": 2,
      "description": "donut/pie: slices before the rest fold into \"Other\" (default 6)."
    },
    "centerValue": {
      "type": "string",
      "description": "donut/sunburst: text in the center (default: the total)."
    },
    "centerLabel": {
      "type": "string",
      "description": "donut/sunburst: caption under the center value."
    },
    "cellHeight": {
      "type": "number",
      "description": "heatmap: maximum cell height in px."
    },
    "floor": {
      "type": "number",
      "description": "heatmap: values below are drawn as plain empty cells (not \"no data\"; the tooltip keeps the value) and do not count for the color scale."
    },
    "ceiling": {
      "type": "number",
      "description": "heatmap: values above are drawn as plain empty cells and do not count for the color scale."
    },
    "midClass": {
      "description": "heatmap with binned `colorScale.breaks` around 0: \"neutral\" draws the class that contains 0 in the theme's neutral tint, so near-zero cells are not painted; { color } gives that class this color instead (a skin patch can set it without replacing the theme).",
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "neutral"
          ]
        },
        {
          "type": "object",
          "properties": {
            "color": {
              "type": "string"
            }
          }
        }
      ]
    },
    "cornerLabel": {
      "type": "string",
      "description": "heatmap: a title in the empty corner where the row labels meet the column labels, e.g. \"born in ↓ / lives in →\". \"\\n\" breaks it into lines; the row-label column widens to fit (same cap). What does not fit is truncated, with the full text in its tooltip."
    },
    "groupColors": {
      "type": "object",
      "additionalProperties": {
        "type": "string"
      },
      "description": "heatmap with `xGroup` / `yGroup`: a color per group name. Each colored group gets a 3 px stripe of its color on the edge of its band that faces the grid, instead of the alternate tint."
    },
    "emptyRow": {
      "type": "string",
      "description": "heatmap: a row with no values at all is written across with this text (e.g. \"no data\") instead of empty cells."
    },
    "rowTip": {
      "type": "string",
      "description": "heatmap: tooltip of each row label, from this field (first row of that label that has it): what belongs to the whole row and need not repeat in every cell. From JS, also a function (label) => text."
    },
    "rowHref": {
      "type": "string",
      "description": "heatmap: row labels link to the URL in this field (first row of that label that has one; paths and http(s) only). From JS, also a function (label) => url."
    },
    "colHref": {
      "type": "string",
      "description": "heatmap: column labels link to the URL in this field. From JS, also a function (label) => url."
    },
    "xLabelAngle": {
      "type": "number",
      "minimum": -90,
      "maximum": 90,
      "description": "heatmap: rotate the column labels (-90 upright, -45 slanted). The label strip grows to fit (long labels are cut, full name in the tooltip); labels are thinned only when they would touch."
    },
    "xLabelPosition": {
      "type": "string",
      "enum": [
        "top",
        "bottom"
      ],
      "description": "heatmap: column labels under the grid (default) or over it."
    },
    "yLabelPosition": {
      "type": "string",
      "enum": [
        "left",
        "above"
      ],
      "description": "Horizontal box/violin/strip/swarm/point: row names to the left of the axis (default) or \"above\" each row, so the value axis keeps the full width (a phone)."
    },
    "clamp": {
      "type": "boolean",
      "description": "strip/swarm/box/violin/point with a value domain (`xDomain` horizontal, `yDomain` vertical): values outside are drawn on its edge, and the edge tick says so (\"≤ 0,01%\", \"≥ 100%\") when some value lies beyond. On a log axis it also lets 0 sit on the low edge."
    },
    "labelWidth": {
      "type": "number",
      "description": "network: widest node label in px before it is truncated (default 150). dendrogram: widest names column in px (default 30% of the width horizontal, 120 px vertical)."
    },
    "treeWidth": {
      "type": "number",
      "description": "dendrogram (horizontal): width of the tree in px; the names column takes the rest (e.g. 250 of 1236)."
    },
    "edgeTip": {
      "type": "boolean",
      "description": "network: false writes no tooltip on edges (also with `tooltip: false`). Hundreds of edges each with its own text weigh more than the drawing."
    },
    "cellGap": {
      "description": "heatmap: space between cells in px (default 2). 0 joins them (square corners); [x, y] per axis.",
      "anyOf": [
        {
          "type": "number",
          "minimum": 0
        },
        {
          "type": "array",
          "items": {
            "type": "number",
            "minimum": 0
          },
          "minItems": 2,
          "maxItems": 2
        }
      ]
    },
    "diagonal": {
      "description": "heatmap: cells where x equals y (e.g. \"stayed in the same region\") are drawn apart: their own color, outside the color scale, with a legend entry and a tooltip line. true, a label, or { label, color, opacity }. A missing value stays \"no data\".",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string"
        },
        {
          "type": "object",
          "properties": {
            "label": {
              "type": "string"
            },
            "color": {
              "type": "string"
            },
            "opacity": {
              "type": "number",
              "minimum": 0,
              "maximum": 1
            }
          }
        }
      ]
    },
    "cellColor": {
      "type": "string",
      "description": "heatmap: a field whose value names the class of a cell (\"Revised\", \"Estimate\"); those cells are drawn in `colors[class]`, outside the color scale, with a legend entry and a tooltip line. A value written as a color (#hex, rgb(), var()) is used as is, without a legend entry."
    },
    "labelFormat": {
      "description": "heatmap: format of the number written inside each cell, apart from the tooltip and legend (same forms as `format`). From JS a function; returning \"\" leaves that cell without a numeral.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "object"
        }
      ]
    },
    "xGroup": {
      "type": "string",
      "description": "bar/heatmap/strip/box…: group consecutive categories of the horizontal axis (bar: of the category axis, either orientation). A tinted band with the group name runs along the axis; nothing is reordered."
    },
    "yGroup": {
      "type": "string",
      "description": "heatmap: group consecutive rows; bar/strip: same as xGroup on a horizontal chart."
    },
    "xTicks": {
      "type": "object",
      "properties": {
        "every": {
          "type": "integer",
          "minimum": 1
        }
      },
      "description": "heatmap/bar/strip: label every Nth category of the horizontal axis ({ every: 5 }); labels are still thinned further if they collide."
    },
    "yTicks": {
      "type": "object",
      "properties": {
        "every": {
          "type": "integer",
          "minimum": 1
        }
      },
      "description": "heatmap: label every Nth row; bar/strip horizontal: every Nth category."
    },
    "vars": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "corr/pairplot: the numeric fields to relate, in order (seaborn `vars`). Default: every numeric field (pairplot: the first 6). `y: [...]` works too."
    },
    "method": {
      "type": "string",
      "enum": [
        "pearson",
        "spearman"
      ],
      "description": "corr: correlation coefficient. \"pearson\" (default, linear) or \"spearman\" (ranks: monotonic relations, robust to outliers)."
    },
    "triangle": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "lower",
            "full"
          ]
        },
        {
          "type": "boolean"
        }
      ],
      "description": "corr: \"lower\" (default) shows each pair once, below the diagonal; \"full\" shows the whole symmetric matrix (default with `cluster`)."
    },
    "cluster": {
      "type": "boolean",
      "description": "corr: reorder variables by hierarchical clustering (average linkage on 1 − r) and draw the dendrogram on top, like sns.clustermap. `type: \"clustermap\"` sets it."
    },
    "dendrogram": {
      "type": "boolean",
      "description": "corr with `cluster`: false hides the dendrogram but keeps the clustered order."
    },
    "alpha": {
      "type": "number",
      "exclusiveMinimum": 0,
      "exclusiveMaximum": 1,
      "description": "corr: significance level (e.g. 0.05). Cells with p ≥ alpha are greyed out and a legend key explains it. p-values use Fisher's z."
    },
    "cellSize": {
      "type": "number",
      "description": "corr: maximum cell size in px (cells are square)."
    },
    "diag": {
      "type": "string",
      "enum": [
        "hist",
        "kde"
      ],
      "description": "pairplot: what goes on the diagonal. Default \"hist\", or \"kde\" when `hue` is set."
    },
    "upper": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "corr",
            "scatter"
          ]
        },
        {
          "type": "boolean",
          "enum": [
            false
          ]
        }
      ],
      "description": "pairplot: above the diagonal, \"corr\" (default: Pearson r, tinted by strength, per `hue` group when there is room), \"scatter\" (mirror), or false (empty)."
    },
    "corner": {
      "type": "boolean",
      "description": "pairplot: draw only the lower triangle and the diagonal (seaborn corner=True)."
    },
    "panelSize": {
      "type": "number",
      "description": "pairplot: maximum panel size in px."
    },
    "diverging": {
      "type": "boolean",
      "description": "heatmap/choropleth: diverging color scale around 0 (or `midpoint`)."
    },
    "colors": {
      "type": "object",
      "additionalProperties": {
        "type": "string"
      },
      "description": "Pin colors to entities: { \"Biobío\": \"#3A47B8\" }. Any color may be a CSS variable with a fallback, \"var(--accent, #3A47B8)\": the page decides it, the fallback is used for contrast and tints."
    },
    "skins": {
      "type": "array",
      "description": "Several color sets in one SVG; page CSS picks which one shows. Each item patches the colors of the spec (theme, palette, ramp, colorScale, colors). The first is the default (written in the attributes); every other one needs `when`, the CSS selector of an ancestor under which it applies (e.g. \"html.dark\"). Geometry and text must not change between skins.",
      "items": {
        "type": "object",
        "properties": {
          "when": {
            "type": "string"
          },
          "theme": {},
          "palette": {},
          "ramp": {},
          "colorScale": {},
          "colors": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          }
        }
      }
    },
    "palettes": {
      "description": "Alternative palettes baked into one SVG: a list of names (e.g. [\"cdia\", \"arcilla\", \"nordico\", \"tinta\"]) or true for every family. The first (or `palette`) is the default; the page switches with data-palette=\"nordico\" on any ancestor (toHTML adds buttons). Geometry is identical, only colors change.",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ]
    },
    "palette": {
      "description": "Categorical colors: a palette family that also brings matching ramps and a dark-mode variant (\"cdia\" default with 8 colors; minimal 5-color families \"arcilla\", \"nordico\", \"tinta\"), a name (\"okabe-ito\", \"tableau10\", \"udec\"), a matplotlib qualitative palette (\"tab10\", \"tab20\", \"Set1\", \"Set2\", \"Set3\", \"Pastel1\", \"Pastel2\", \"Paired\", \"Accent\", \"Dark2\"), any colormap name (sampled, e.g. \"viridis\"), or a list of colors in fixed order.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ]
    },
    "ramp": {
      "description": "Sequential ramp: a name (\"indigo\", \"magenta\", \"teal\", \"amber\"), any colormap name, or a list of colors from light to dark.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      ]
    },
    "colorScale": {
      "description": "Continuous color scale (heatmap, choropleth, treemap change, pointmap values): any matplotlib colormap name, case-insensitive, `_r` reverses (\"viridis\", \"plasma\", \"inferno\", \"magma\", \"cividis\", \"Blues\", \"Greens\", \"YlOrRd\", \"RdBu\", \"coolwarm\", \"Spectral\", \"turbo\", \"twilight\"…); diverging names imply a diverging scale. Or a list of hex colors, or { name | colors, reverse, mid }. Aliases: cmap, colormap. Qualitative palettes (tab10…) go in `palette`; avoid rainbow maps (jet, hsv).",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          },
          "minItems": 2
        },
        {
          "type": "object",
          "properties": {
            "name": {
              "type": "string"
            },
            "colors": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "reverse": {
              "type": "boolean"
            },
            "mid": {
              "type": "number",
              "description": "Center of a diverging scale."
            },
            "breaks": {
              "type": "array",
              "items": {
                "type": "number"
              },
              "description": "Class breaks, ascending: discrete classes instead of a gradient (heatmap, choropleth, treemap change). `colors` needs breaks.length + 1 entries (or give `name` and it is sampled). The legend becomes a stepped key. Repeated breaks (quantiles of tied data) are merged, with the color of the empty class between them dropped."
            },
            "closed": {
              "type": "string",
              "enum": [
                "left",
                "right"
              ],
              "description": "With `breaks`: which end of a class includes its break. \"left\" (default): breaks[i−1] ≤ v < breaks[i], a value equal to a break goes to the class above; \"right\": breaks[i−1] < v ≤ breaks[i], to the class below."
            }
          }
        }
      ]
    },
    "cmap": {
      "description": "Alias of colorScale (matplotlib naming).",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          },
          "minItems": 2
        },
        {
          "type": "object",
          "properties": {
            "name": {
              "type": "string"
            },
            "colors": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "reverse": {
              "type": "boolean"
            },
            "mid": {
              "type": "number",
              "description": "Center of a diverging scale."
            },
            "breaks": {
              "type": "array",
              "items": {
                "type": "number"
              },
              "description": "Class breaks, ascending: discrete classes instead of a gradient (heatmap, choropleth, treemap change). `colors` needs breaks.length + 1 entries (or give `name` and it is sampled). The legend becomes a stepped key. Repeated breaks (quantiles of tied data) are merged, with the color of the empty class between them dropped."
            },
            "closed": {
              "type": "string",
              "enum": [
                "left",
                "right"
              ],
              "description": "With `breaks`: which end of a class includes its break. \"left\" (default): breaks[i−1] ≤ v < breaks[i], a value equal to a break goes to the class above; \"right\": breaks[i−1] < v ≤ breaks[i], to the class below."
            }
          }
        }
      ]
    },
    "colormap": {
      "description": "Alias of colorScale.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          },
          "minItems": 2
        },
        {
          "type": "object",
          "properties": {
            "name": {
              "type": "string"
            },
            "colors": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "reverse": {
              "type": "boolean"
            },
            "mid": {
              "type": "number",
              "description": "Center of a diverging scale."
            },
            "breaks": {
              "type": "array",
              "items": {
                "type": "number"
              },
              "description": "Class breaks, ascending: discrete classes instead of a gradient (heatmap, choropleth, treemap change). `colors` needs breaks.length + 1 entries (or give `name` and it is sampled). The legend becomes a stepped key. Repeated breaks (quantiles of tied data) are merged, with the color of the empty class between them dropped."
            },
            "closed": {
              "type": "string",
              "enum": [
                "left",
                "right"
              ],
              "description": "With `breaks`: which end of a class includes its break. \"left\" (default): breaks[i−1] ≤ v < breaks[i], a value equal to a break goes to the class above; \"right\": breaks[i−1] < v ≤ breaks[i], to the class below."
            }
          }
        }
      ]
    },
    "theme": {
      "description": "Theme: \"papel\" (light, default), \"noche\" (dark), a name registered with registerTheme(), or a JSON object deep-merged over `extends`. Simple tokens: background (alias of surface), text (alias of ink), accent (first series color), grid (a color or { color, dash, width }), axis, tooltip { bg, ink }, radius / barRadius (corner radius), font. Full keys: surface, ink, lede, muted, tint, dim, other, categorical (list, palette or colormap name), sequential, diverging, status {good, warning, critical}, font {family, mono, import}, type {title, subtitle, label, axis, legend, source, titleWeight}, marks {barRadius, barMax, lineWidth, pointRadius, gap, ring, areaOpacity, bandOpacity, dotOpacity}, axes {inside, grid}, layout {padding}. configure({ theme }) applies it to every chart.",
      "anyOf": [
        {
          "type": "string",
          "description": "\"papel\", \"noche\", \"light\", \"dark\" or a registered theme name."
        },
        {
          "type": "object",
          "properties": {
            "extends": {
              "type": "string"
            },
            "mode": {
              "type": "string",
              "enum": [
                "light",
                "dark"
              ]
            },
            "background": {
              "type": "string"
            },
            "surface": {
              "type": "string"
            },
            "text": {
              "type": "string"
            },
            "ink": {
              "type": "string"
            },
            "lede": {
              "type": "string"
            },
            "muted": {
              "type": "string"
            },
            "accent": {
              "type": "string"
            },
            "grid": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "object",
                  "properties": {
                    "color": {
                      "type": "string"
                    },
                    "dash": {
                      "type": "string"
                    },
                    "width": {
                      "type": "number"
                    }
                  }
                }
              ]
            },
            "axis": {
              "type": "string"
            },
            "tooltip": {
              "type": "object",
              "properties": {
                "bg": {
                  "type": "string"
                },
                "ink": {
                  "type": "string"
                }
              }
            },
            "radius": {
              "type": "number"
            },
            "barRadius": {
              "type": "number"
            },
            "categorical": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              ]
            },
            "sequential": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              ]
            },
            "diverging": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              ]
            },
            "font": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "object"
                }
              ]
            },
            "status": {
              "type": "object"
            },
            "type": {
              "type": "object"
            },
            "marks": {
              "type": "object"
            },
            "axes": {
              "type": "object"
            },
            "layout": {
              "type": "object"
            }
          }
        }
      ]
    },
    "font": {
      "description": "Typeface for the whole chart: a Google Fonts name (\"Poppins\"), a CSS stack (\"'Inter', sans-serif\") or { family, import }. configure({ font }) sets it for every chart.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "object"
        }
      ]
    },
    "textScale": {
      "type": "number",
      "description": "Multiplies every text size (1.5, 2…); the layout is recomputed so nothing overlaps. Aliases: fontScale, labelScale. configure({ textScale }) sets it for every chart."
    },
    "width": {
      "type": "number",
      "description": "Width in px (default 720; render() uses the container width)."
    },
    "height": {
      "type": "number",
      "description": "Height in px. Automatic for horizontal bars, heatmaps, KPI tiles, and narrow treemaps, sunbursts and radars."
    },
    "padding": {
      "description": "Margin around the chart in px. Default: 8 top and bottom, 0 at the sides (the chart reaches the edges of its container). A number for every side, [vertical, horizontal], [top, right, bottom, left] or { top, right, bottom, left }.",
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "array",
          "items": {
            "type": "number"
          },
          "minItems": 2,
          "maxItems": 4
        },
        {
          "type": "object",
          "properties": {
            "top": {
              "type": "number"
            },
            "right": {
              "type": "number"
            },
            "bottom": {
              "type": "number"
            },
            "left": {
              "type": "number"
            }
          }
        }
      ]
    }
  }
}