{
  "$defs": {
    "Fixed": {
      "description": "An integer geometry value in 1/1000th layout-pixel units.",
      "format": "int64",
      "type": "integer"
    },
    "MessageDeliveryV1": {
      "enum": [
        "call",
        "return",
        "async"
      ],
      "type": "string"
    },
    "QuantizedPointV1": {
      "properties": {
        "x": {
          "$ref": "#/$defs/Fixed"
        },
        "y": {
          "$ref": "#/$defs/Fixed"
        }
      },
      "required": [
        "x",
        "y"
      ],
      "type": "object"
    },
    "QuantizedRectV1": {
      "properties": {
        "height": {
          "$ref": "#/$defs/Fixed"
        },
        "width": {
          "$ref": "#/$defs/Fixed"
        },
        "x": {
          "$ref": "#/$defs/Fixed"
        },
        "y": {
          "$ref": "#/$defs/Fixed"
        }
      },
      "required": [
        "x",
        "y",
        "width",
        "height"
      ],
      "type": "object"
    },
    "SceneEdgeObservationV1": {
      "properties": {
        "delivery": {
          "anyOf": [
            {
              "$ref": "#/$defs/MessageDeliveryV1"
            },
            {
              "type": "null"
            }
          ]
        },
        "id": {
          "type": "string"
        },
        "kind": {
          "type": "string"
        },
        "label": {
          "type": "string"
        },
        "label_position": {
          "$ref": "#/$defs/QuantizedPointV1"
        },
        "render_path": {
          "description": "An opaque renderer path. All comparable coordinates live in the\nquantized fields; the path is retained for visual troubleshooting.",
          "type": "string"
        },
        "route_points": {
          "items": {
            "$ref": "#/$defs/QuantizedPointV1"
          },
          "type": "array"
        },
        "source": {
          "type": "string"
        },
        "source_port": {
          "$ref": "#/$defs/ScenePortObservationV1"
        },
        "target": {
          "type": "string"
        },
        "target_port": {
          "$ref": "#/$defs/ScenePortObservationV1"
        },
        "text_bounds": {
          "$ref": "#/$defs/QuantizedRectV1"
        }
      },
      "required": [
        "id",
        "source",
        "target",
        "label",
        "kind",
        "render_path",
        "route_points",
        "source_port",
        "target_port",
        "label_position",
        "text_bounds"
      ],
      "type": "object"
    },
    "SceneGroupObservationV1": {
      "properties": {
        "bounds": {
          "$ref": "#/$defs/QuantizedRectV1"
        },
        "id": {
          "type": "string"
        },
        "label": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "label",
        "bounds"
      ],
      "type": "object"
    },
    "SceneGuideObservationV1": {
      "properties": {
        "id": {
          "type": "string"
        },
        "kind": {
          "type": "string"
        },
        "label": {
          "type": [
            "string",
            "null"
          ]
        },
        "render_path": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "kind",
        "render_path"
      ],
      "type": "object"
    },
    "SceneMarkObservationV1": {
      "properties": {
        "accessibility_label": {
          "type": "string"
        },
        "bounds": {
          "$ref": "#/$defs/QuantizedRectV1"
        },
        "id": {
          "type": "string"
        },
        "kind": {
          "type": "string"
        },
        "label": {
          "type": "string"
        },
        "label_position": {
          "$ref": "#/$defs/QuantizedPointV1"
        },
        "render_path": {
          "type": "string"
        },
        "style_index": {
          "format": "uint",
          "minimum": 0,
          "type": "integer"
        },
        "value_millis": {
          "anyOf": [
            {
              "$ref": "#/$defs/Fixed"
            },
            {
              "type": "null"
            }
          ]
        }
      },
      "required": [
        "id",
        "label",
        "kind",
        "render_path",
        "bounds",
        "label_position",
        "style_index",
        "accessibility_label"
      ],
      "type": "object"
    },
    "SceneNodeObservationV1": {
      "properties": {
        "accessibility_label": {
          "type": "string"
        },
        "bounds": {
          "$ref": "#/$defs/QuantizedRectV1"
        },
        "details": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "id": {
          "type": "string"
        },
        "kind": {
          "type": "string"
        },
        "label": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "label",
        "kind",
        "bounds",
        "accessibility_label"
      ],
      "type": "object"
    },
    "ScenePortObservationV1": {
      "properties": {
        "point": {
          "$ref": "#/$defs/QuantizedPointV1"
        },
        "side": {
          "type": "string"
        }
      },
      "required": [
        "side",
        "point"
      ],
      "type": "object"
    }
  },
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "description": "A fixed-geometry observation of the renderer's scene graph.",
  "properties": {
    "edges": {
      "items": {
        "$ref": "#/$defs/SceneEdgeObservationV1"
      },
      "type": "array"
    },
    "geometry_scale": {
      "format": "int64",
      "type": "integer"
    },
    "groups": {
      "items": {
        "$ref": "#/$defs/SceneGroupObservationV1"
      },
      "type": "array"
    },
    "guides": {
      "items": {
        "$ref": "#/$defs/SceneGuideObservationV1"
      },
      "type": "array"
    },
    "marks": {
      "items": {
        "$ref": "#/$defs/SceneMarkObservationV1"
      },
      "type": "array"
    },
    "nodes": {
      "items": {
        "$ref": "#/$defs/SceneNodeObservationV1"
      },
      "type": "array"
    },
    "profile": {
      "type": "string"
    },
    "schema_version": {
      "type": "string"
    },
    "variant": {
      "type": [
        "string",
        "null"
      ]
    },
    "viewport": {
      "$ref": "#/$defs/QuantizedRectV1"
    }
  },
  "required": [
    "schema_version",
    "geometry_scale",
    "profile",
    "viewport",
    "nodes",
    "groups",
    "edges",
    "guides"
  ],
  "title": "SceneObservationV1",
  "type": "object"
}
