{
  "defaultPreset": "hypermedia-threads",
  "order": [
    "hypermedia-threads",
    "protocol-stack",
    "research-branching"
  ],
  "graphs": {
    "hypermedia-threads": {
      "id": "hypermedia-threads",
      "label": "Hypermedia Threads",
      "description": "URL-addressed spatial notebook graph showing hypermedia documents, offscreen Worker rendering, and cross-origin iframe embedding.",
      "camera": {
        "x": 0,
        "y": 10,
        "zoom": 0.86
      },
      "nodes": [
        {
          "id": "ht-root",
          "title": "URL-Addressed Canvas",
          "kind": "hypermedia",
          "x": -130,
          "y": -215,
          "w": 260,
          "h": 126,
          "summary": "Encodes camera coordinates and graph deltas into #cam=x,y,z&g=... with zero server-side state."
        },
        {
          "id": "ht-affordance",
          "title": "Hypermedia Controls",
          "kind": "specification",
          "x": -440,
          "y": -25,
          "w": 250,
          "h": 126,
          "summary": "Documents carry inline links, controls, and state transitions instead of out-of-band SDK contracts."
        },
        {
          "id": "ht-spatial",
          "title": "2D Spatial Indexing",
          "kind": "surface",
          "x": -130,
          "y": -25,
          "w": 260,
          "h": 126,
          "summary": "World-space coordinates preserve parallel reading branches instead of flattening threads into scroll history."
        },
        {
          "id": "ht-offscreen",
          "title": "OffscreenCanvas Worker",
          "kind": "runtime",
          "x": 185,
          "y": -25,
          "w": 260,
          "h": 126,
          "summary": "Transfers canvas presentation off the main thread via transferControlToOffscreen() and postMessage."
        },
        {
          "id": "ht-snapshot",
          "title": "Deterministic Snapshots",
          "kind": "protocol",
          "x": -440,
          "y": 165,
          "w": 250,
          "h": 126,
          "summary": "Canonical JSON and Base64URL serialization ensure identical hashes reconstruct identical layouts."
        },
        {
          "id": "ht-embed",
          "title": "Cross-Origin Frame Embed",
          "kind": "surface",
          "x": -130,
          "y": 165,
          "w": 260,
          "h": 126,
          "summary": "frame-ancestors CSP allows aifoc.us embedding while omitting COEP require-corp headers."
        },
        {
          "id": "ht-frustum",
          "title": "Viewport Frustum Culling",
          "kind": "runtime",
          "x": 185,
          "y": 165,
          "w": 260,
          "h": 126,
          "summary": "Tests node bounding boxes against world-space viewport extents before submitting 2D draw calls."
        }
      ],
      "edges": [
        {
          "from": "ht-root",
          "to": "ht-affordance",
          "relation": "links-via"
        },
        {
          "from": "ht-root",
          "to": "ht-spatial",
          "relation": "addresses"
        },
        {
          "from": "ht-root",
          "to": "ht-offscreen",
          "relation": "renders-with"
        },
        {
          "from": "ht-affordance",
          "to": "ht-snapshot",
          "relation": "serializes-to"
        },
        {
          "from": "ht-spatial",
          "to": "ht-embed",
          "relation": "embeds-in"
        },
        {
          "from": "ht-offscreen",
          "to": "ht-frustum",
          "relation": "culls-using"
        }
      ]
    },
    "protocol-stack": {
      "id": "protocol-stack",
      "label": "Protocol Stack Graph",
      "description": "Execution pipeline from Cloudflare Edge Worker headers through Pointer Events capture into OffscreenCanvas rasterization.",
      "camera": {
        "x": 0,
        "y": 0,
        "zoom": 0.86
      },
      "nodes": [
        {
          "id": "ps-edge",
          "title": "Cloudflare Edge Worker",
          "kind": "runtime",
          "x": -135,
          "y": -230,
          "w": 270,
          "h": 122,
          "summary": "Intercepts / and /api/* via run_worker_first and attaches explicit frame-ancestors CSP directives."
        },
        {
          "id": "ps-csp",
          "title": "Iframe Security Boundary",
          "kind": "protocol",
          "x": -445,
          "y": -55,
          "w": 255,
          "h": 122,
          "summary": "Permits https://aifoc.us frame ancestors without COEP require-corp so embedded documents load cleanly."
        },
        {
          "id": "ps-pointer",
          "title": "Pointer Events Capture",
          "kind": "specification",
          "x": -135,
          "y": -55,
          "w": 270,
          "h": 122,
          "summary": "Normalizes mouse, pen, and touch input via setPointerCapture() and CSS touch-action: none."
        },
        {
          "id": "ps-codec",
          "title": "Base64URL Hash Codec",
          "kind": "hypermedia",
          "x": 190,
          "y": -55,
          "w": 255,
          "h": 122,
          "summary": "Synchronizes camera and node coordinates into location.hash using history.replaceState()."
        },
        {
          "id": "ps-worker",
          "title": "Module Render Worker",
          "kind": "runtime",
          "x": -135,
          "y": 125,
          "w": 270,
          "h": 122,
          "summary": "Coalesces scene states across requestAnimationFrame ticks inside public/canvas-renderer.js."
        },
        {
          "id": "ps-raster",
          "title": "Offscreen / 2D Fallback",
          "kind": "surface",
          "x": 190,
          "y": 125,
          "w": 255,
          "h": 122,
          "summary": "Executes shared 2D vector drawing commands on OffscreenCanvas or main-thread 2D Canvas."
        }
      ],
      "edges": [
        {
          "from": "ps-edge",
          "to": "ps-csp",
          "relation": "enforces"
        },
        {
          "from": "ps-edge",
          "to": "ps-pointer",
          "relation": "serves"
        },
        {
          "from": "ps-pointer",
          "to": "ps-codec",
          "relation": "writes"
        },
        {
          "from": "ps-pointer",
          "to": "ps-worker",
          "relation": "dispatches"
        },
        {
          "from": "ps-worker",
          "to": "ps-raster",
          "relation": "composites"
        },
        {
          "from": "ps-codec",
          "to": "ps-raster",
          "relation": "hydrates"
        }
      ]
    },
    "research-branching": {
      "id": "research-branching",
      "label": "Research Branching Tree",
      "description": "Comparison between monolithic super-app containers and URL-forkable, origin-isolated hypermedia surfaces.",
      "camera": {
        "x": 0,
        "y": 25,
        "zoom": 0.82
      },
      "nodes": [
        {
          "id": "rb-origin",
          "title": "Monolithic Super App",
          "kind": "surface",
          "x": -130,
          "y": -255,
          "w": 260,
          "h": 122,
          "summary": "Bundles vertical utilities inside a single closed container with proprietary deep links."
        },
        {
          "id": "rb-split",
          "title": "Composable Web Surfaces",
          "kind": "hypermedia",
          "x": -130,
          "y": -80,
          "w": 260,
          "h": 122,
          "summary": "Separates capabilities into independent web origins composed via standard URLs and iframes."
        },
        {
          "id": "rb-branch-a",
          "title": "Branch A: URL State",
          "kind": "branch",
          "x": -435,
          "y": 105,
          "w": 250,
          "h": 122,
          "summary": "Encodes viewport and node edits inside #cam= hashes so every snapshot URL is immediately forkable."
        },
        {
          "id": "rb-branch-b",
          "title": "Branch B: Scoped Origins",
          "kind": "branch",
          "x": -130,
          "y": 105,
          "w": 260,
          "h": 122,
          "summary": "Browsers enforce origin isolation, permissions, and storage boundaries without host container trust."
        },
        {
          "id": "rb-branch-c",
          "title": "Branch C: Edge Manifests",
          "kind": "branch",
          "x": 185,
          "y": 105,
          "w": 255,
          "h": 122,
          "summary": "Stateless Workers publish hypermedia presets (/api/seed-graphs) with zero persistent session coupling."
        },
        {
          "id": "rb-leaf",
          "title": "Forkable Research Graph",
          "kind": "protocol",
          "x": -285,
          "y": 285,
          "w": 265,
          "h": 122,
          "summary": "Any reader can drag nodes, add a branch card, and copy the hash URL to pass state directly."
        }
      ],
      "edges": [
        {
          "from": "rb-origin",
          "to": "rb-split",
          "relation": "decomposes-into"
        },
        {
          "from": "rb-split",
          "to": "rb-branch-a",
          "relation": "branches-to"
        },
        {
          "from": "rb-split",
          "to": "rb-branch-b",
          "relation": "branches-to"
        },
        {
          "from": "rb-split",
          "to": "rb-branch-c",
          "relation": "branches-to"
        },
        {
          "from": "rb-branch-a",
          "to": "rb-leaf",
          "relation": "enables"
        },
        {
          "from": "rb-branch-b",
          "to": "rb-leaf",
          "relation": "isolates"
        }
      ]
    }
  },
  "presets": [
    {
      "id": "hypermedia-threads",
      "label": "Hypermedia Threads",
      "description": "URL-addressed spatial notebook graph showing hypermedia documents, offscreen Worker rendering, and cross-origin iframe embedding.",
      "camera": {
        "x": 0,
        "y": 10,
        "zoom": 0.86
      },
      "nodes": [
        {
          "id": "ht-root",
          "title": "URL-Addressed Canvas",
          "kind": "hypermedia",
          "x": -130,
          "y": -215,
          "w": 260,
          "h": 126,
          "summary": "Encodes camera coordinates and graph deltas into #cam=x,y,z&g=... with zero server-side state."
        },
        {
          "id": "ht-affordance",
          "title": "Hypermedia Controls",
          "kind": "specification",
          "x": -440,
          "y": -25,
          "w": 250,
          "h": 126,
          "summary": "Documents carry inline links, controls, and state transitions instead of out-of-band SDK contracts."
        },
        {
          "id": "ht-spatial",
          "title": "2D Spatial Indexing",
          "kind": "surface",
          "x": -130,
          "y": -25,
          "w": 260,
          "h": 126,
          "summary": "World-space coordinates preserve parallel reading branches instead of flattening threads into scroll history."
        },
        {
          "id": "ht-offscreen",
          "title": "OffscreenCanvas Worker",
          "kind": "runtime",
          "x": 185,
          "y": -25,
          "w": 260,
          "h": 126,
          "summary": "Transfers canvas presentation off the main thread via transferControlToOffscreen() and postMessage."
        },
        {
          "id": "ht-snapshot",
          "title": "Deterministic Snapshots",
          "kind": "protocol",
          "x": -440,
          "y": 165,
          "w": 250,
          "h": 126,
          "summary": "Canonical JSON and Base64URL serialization ensure identical hashes reconstruct identical layouts."
        },
        {
          "id": "ht-embed",
          "title": "Cross-Origin Frame Embed",
          "kind": "surface",
          "x": -130,
          "y": 165,
          "w": 260,
          "h": 126,
          "summary": "frame-ancestors CSP allows aifoc.us embedding while omitting COEP require-corp headers."
        },
        {
          "id": "ht-frustum",
          "title": "Viewport Frustum Culling",
          "kind": "runtime",
          "x": 185,
          "y": 165,
          "w": 260,
          "h": 126,
          "summary": "Tests node bounding boxes against world-space viewport extents before submitting 2D draw calls."
        }
      ],
      "edges": [
        {
          "from": "ht-root",
          "to": "ht-affordance",
          "relation": "links-via"
        },
        {
          "from": "ht-root",
          "to": "ht-spatial",
          "relation": "addresses"
        },
        {
          "from": "ht-root",
          "to": "ht-offscreen",
          "relation": "renders-with"
        },
        {
          "from": "ht-affordance",
          "to": "ht-snapshot",
          "relation": "serializes-to"
        },
        {
          "from": "ht-spatial",
          "to": "ht-embed",
          "relation": "embeds-in"
        },
        {
          "from": "ht-offscreen",
          "to": "ht-frustum",
          "relation": "culls-using"
        }
      ]
    },
    {
      "id": "protocol-stack",
      "label": "Protocol Stack Graph",
      "description": "Execution pipeline from Cloudflare Edge Worker headers through Pointer Events capture into OffscreenCanvas rasterization.",
      "camera": {
        "x": 0,
        "y": 0,
        "zoom": 0.86
      },
      "nodes": [
        {
          "id": "ps-edge",
          "title": "Cloudflare Edge Worker",
          "kind": "runtime",
          "x": -135,
          "y": -230,
          "w": 270,
          "h": 122,
          "summary": "Intercepts / and /api/* via run_worker_first and attaches explicit frame-ancestors CSP directives."
        },
        {
          "id": "ps-csp",
          "title": "Iframe Security Boundary",
          "kind": "protocol",
          "x": -445,
          "y": -55,
          "w": 255,
          "h": 122,
          "summary": "Permits https://aifoc.us frame ancestors without COEP require-corp so embedded documents load cleanly."
        },
        {
          "id": "ps-pointer",
          "title": "Pointer Events Capture",
          "kind": "specification",
          "x": -135,
          "y": -55,
          "w": 270,
          "h": 122,
          "summary": "Normalizes mouse, pen, and touch input via setPointerCapture() and CSS touch-action: none."
        },
        {
          "id": "ps-codec",
          "title": "Base64URL Hash Codec",
          "kind": "hypermedia",
          "x": 190,
          "y": -55,
          "w": 255,
          "h": 122,
          "summary": "Synchronizes camera and node coordinates into location.hash using history.replaceState()."
        },
        {
          "id": "ps-worker",
          "title": "Module Render Worker",
          "kind": "runtime",
          "x": -135,
          "y": 125,
          "w": 270,
          "h": 122,
          "summary": "Coalesces scene states across requestAnimationFrame ticks inside public/canvas-renderer.js."
        },
        {
          "id": "ps-raster",
          "title": "Offscreen / 2D Fallback",
          "kind": "surface",
          "x": 190,
          "y": 125,
          "w": 255,
          "h": 122,
          "summary": "Executes shared 2D vector drawing commands on OffscreenCanvas or main-thread 2D Canvas."
        }
      ],
      "edges": [
        {
          "from": "ps-edge",
          "to": "ps-csp",
          "relation": "enforces"
        },
        {
          "from": "ps-edge",
          "to": "ps-pointer",
          "relation": "serves"
        },
        {
          "from": "ps-pointer",
          "to": "ps-codec",
          "relation": "writes"
        },
        {
          "from": "ps-pointer",
          "to": "ps-worker",
          "relation": "dispatches"
        },
        {
          "from": "ps-worker",
          "to": "ps-raster",
          "relation": "composites"
        },
        {
          "from": "ps-codec",
          "to": "ps-raster",
          "relation": "hydrates"
        }
      ]
    },
    {
      "id": "research-branching",
      "label": "Research Branching Tree",
      "description": "Comparison between monolithic super-app containers and URL-forkable, origin-isolated hypermedia surfaces.",
      "camera": {
        "x": 0,
        "y": 25,
        "zoom": 0.82
      },
      "nodes": [
        {
          "id": "rb-origin",
          "title": "Monolithic Super App",
          "kind": "surface",
          "x": -130,
          "y": -255,
          "w": 260,
          "h": 122,
          "summary": "Bundles vertical utilities inside a single closed container with proprietary deep links."
        },
        {
          "id": "rb-split",
          "title": "Composable Web Surfaces",
          "kind": "hypermedia",
          "x": -130,
          "y": -80,
          "w": 260,
          "h": 122,
          "summary": "Separates capabilities into independent web origins composed via standard URLs and iframes."
        },
        {
          "id": "rb-branch-a",
          "title": "Branch A: URL State",
          "kind": "branch",
          "x": -435,
          "y": 105,
          "w": 250,
          "h": 122,
          "summary": "Encodes viewport and node edits inside #cam= hashes so every snapshot URL is immediately forkable."
        },
        {
          "id": "rb-branch-b",
          "title": "Branch B: Scoped Origins",
          "kind": "branch",
          "x": -130,
          "y": 105,
          "w": 260,
          "h": 122,
          "summary": "Browsers enforce origin isolation, permissions, and storage boundaries without host container trust."
        },
        {
          "id": "rb-branch-c",
          "title": "Branch C: Edge Manifests",
          "kind": "branch",
          "x": 185,
          "y": 105,
          "w": 255,
          "h": 122,
          "summary": "Stateless Workers publish hypermedia presets (/api/seed-graphs) with zero persistent session coupling."
        },
        {
          "id": "rb-leaf",
          "title": "Forkable Research Graph",
          "kind": "protocol",
          "x": -285,
          "y": 285,
          "w": 265,
          "h": 122,
          "summary": "Any reader can drag nodes, add a branch card, and copy the hash URL to pass state directly."
        }
      ],
      "edges": [
        {
          "from": "rb-origin",
          "to": "rb-split",
          "relation": "decomposes-into"
        },
        {
          "from": "rb-split",
          "to": "rb-branch-a",
          "relation": "branches-to"
        },
        {
          "from": "rb-split",
          "to": "rb-branch-b",
          "relation": "branches-to"
        },
        {
          "from": "rb-split",
          "to": "rb-branch-c",
          "relation": "branches-to"
        },
        {
          "from": "rb-branch-a",
          "to": "rb-leaf",
          "relation": "enables"
        },
        {
          "from": "rb-branch-b",
          "to": "rb-leaf",
          "relation": "isolates"
        }
      ]
    }
  ]
}