{
  "format": "tensorviz.graph",
  "version": 3,
  "exportedAt": "2026-09-17T05:53:58.907442+00:00",
  "status": "static",
  "warningCount": 0,
  "document": {
    "schemaVersion": 2,
    "semantic": {
      "graph_id": "snapshot",
      "name": "RotaryAttention",
      "revision": 0,
      "nodes": [
        {
          "node_id": "input",
          "kind": "input",
          "op": "Input",
          "params": {
            "shape": "1,6,8"
          },
          "in_ports": [],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "input",
              "name": "Input",
              "displayName": "Input",
              "description": "Model input node",
              "icon": "ArrowRight",
              "category": "io",
              "parameters": [
                {
                  "name": "shape",
                  "type": "string",
                  "defaultValue": "1,3,224,224",
                  "required": true,
                  "description": "Input tensor shape (comma-separated, e.g., 1,3,224,224)"
                },
                {
                  "name": "name",
                  "type": "string",
                  "defaultValue": "input",
                  "required": false,
                  "description": "Name for this input"
                }
              ]
            }
          }
        },
        {
          "node_id": "query",
          "kind": "layer",
          "op": "Linear",
          "params": {
            "in_features": 8,
            "out_features": 8
          },
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "linear",
              "name": "Linear",
              "displayName": "Linear",
              "description": "Fully Connected Layer",
              "icon": "Minus",
              "category": "linear",
              "parameters": [
                {
                  "name": "in_features",
                  "type": "number",
                  "defaultValue": 512,
                  "required": true,
                  "description": "Size of input features",
                  "min": 1
                },
                {
                  "name": "out_features",
                  "type": "number",
                  "defaultValue": 256,
                  "required": true,
                  "description": "Size of output features",
                  "min": 1
                },
                {
                  "name": "bias",
                  "type": "boolean",
                  "defaultValue": true,
                  "required": false,
                  "description": "If set to False, the layer will not learn an additive bias"
                }
              ]
            }
          }
        },
        {
          "node_id": "key",
          "kind": "layer",
          "op": "Linear",
          "params": {
            "in_features": 8,
            "out_features": 8
          },
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "linear",
              "name": "Linear",
              "displayName": "Linear",
              "description": "Fully Connected Layer",
              "icon": "Minus",
              "category": "linear",
              "parameters": [
                {
                  "name": "in_features",
                  "type": "number",
                  "defaultValue": 512,
                  "required": true,
                  "description": "Size of input features",
                  "min": 1
                },
                {
                  "name": "out_features",
                  "type": "number",
                  "defaultValue": 256,
                  "required": true,
                  "description": "Size of output features",
                  "min": 1
                },
                {
                  "name": "bias",
                  "type": "boolean",
                  "defaultValue": true,
                  "required": false,
                  "description": "If set to False, the layer will not learn an additive bias"
                }
              ]
            }
          }
        },
        {
          "node_id": "value",
          "kind": "layer",
          "op": "Linear",
          "params": {
            "in_features": 8,
            "out_features": 8
          },
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "linear",
              "name": "Linear",
              "displayName": "Linear",
              "description": "Fully Connected Layer",
              "icon": "Minus",
              "category": "linear",
              "parameters": [
                {
                  "name": "in_features",
                  "type": "number",
                  "defaultValue": 512,
                  "required": true,
                  "description": "Size of input features",
                  "min": 1
                },
                {
                  "name": "out_features",
                  "type": "number",
                  "defaultValue": 256,
                  "required": true,
                  "description": "Size of output features",
                  "min": 1
                },
                {
                  "name": "bias",
                  "type": "boolean",
                  "defaultValue": true,
                  "required": false,
                  "description": "If set to False, the layer will not learn an additive bias"
                }
              ]
            }
          }
        },
        {
          "node_id": "query_rope",
          "kind": "module",
          "op": "Module",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "module",
              "name": "Module",
              "displayName": "Module",
              "description": "Custom module group (nn.Module)",
              "icon": "Package",
              "category": "module",
              "parameters": [
                {
                  "name": "name",
                  "type": "string",
                  "defaultValue": "CustomModule",
                  "required": true,
                  "description": "Module class name"
                },
                {
                  "name": "description",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Module description"
                }
              ]
            },
            "moduleInstanceId": "query_rope",
            "moduleTemplateId": "model::RotaryPositions",
            "isGroup": true,
            "moduleMembers": [
              "python@query_rope#1",
              "python@query_rope#0",
              "mul@query_rope#0",
              "mul@query_rope#3",
              "mul@query_rope#4",
              "add@query_rope#0",
              "mul@query_rope#1",
              "mul@query_rope#2",
              "sub@query_rope#0",
              "stack@query_rope#0",
              "flatten@query_rope#0"
            ],
            "moduleLayerCount": 11
          }
        },
        {
          "node_id": "key_rope",
          "kind": "module",
          "op": "Module",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "module",
              "name": "Module",
              "displayName": "Module",
              "description": "Custom module group (nn.Module)",
              "icon": "Package",
              "category": "module",
              "parameters": [
                {
                  "name": "name",
                  "type": "string",
                  "defaultValue": "CustomModule",
                  "required": true,
                  "description": "Module class name"
                },
                {
                  "name": "description",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Module description"
                }
              ]
            },
            "moduleInstanceId": "key_rope",
            "moduleTemplateId": "model::RotaryPositions",
            "isGroup": true,
            "moduleMembers": [
              "python@key_rope#1",
              "python@key_rope#0",
              "mul@key_rope#0",
              "mul@key_rope#3",
              "mul@key_rope#4",
              "add@key_rope#0",
              "mul@key_rope#1",
              "mul@key_rope#2",
              "sub@key_rope#0",
              "stack@key_rope#0",
              "flatten@key_rope#0"
            ],
            "moduleLayerCount": 11
          }
        },
        {
          "node_id": "div@RotaryAttention#0",
          "kind": "layer",
          "op": "torch.div",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "div",
              "name": "torch.div",
              "displayName": "torch.div",
              "description": "PyTorch div operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            }
          }
        },
        {
          "node_id": "softmax",
          "kind": "layer",
          "op": "Softmax",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "softmax",
              "name": "Softmax",
              "displayName": "Softmax",
              "description": "Softmax over a dimension",
              "icon": "TrendingUp",
              "category": "activation",
              "parameters": [
                {
                  "name": "dim",
                  "type": "number",
                  "defaultValue": 1,
                  "required": true,
                  "description": "Dimension along which Softmax is computed"
                }
              ]
            }
          }
        },
        {
          "node_id": "python@RotaryAttention#0",
          "kind": "layer",
          "op": "Python",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "python",
              "name": "Python",
              "displayName": "Python",
              "description": "A statement from the source file that has no graph equivalent. Its code is kept verbatim and its shape is unknown until the model is traced.",
              "icon": "Hash",
              "category": "misc",
              "parameters": []
            }
          }
        },
        {
          "node_id": "project",
          "kind": "layer",
          "op": "Linear",
          "params": {
            "in_features": 8,
            "out_features": 8
          },
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "linear",
              "name": "Linear",
              "displayName": "Linear",
              "description": "Fully Connected Layer",
              "icon": "Minus",
              "category": "linear",
              "parameters": [
                {
                  "name": "in_features",
                  "type": "number",
                  "defaultValue": 512,
                  "required": true,
                  "description": "Size of input features",
                  "min": 1
                },
                {
                  "name": "out_features",
                  "type": "number",
                  "defaultValue": 256,
                  "required": true,
                  "description": "Size of output features",
                  "min": 1
                },
                {
                  "name": "bias",
                  "type": "boolean",
                  "defaultValue": true,
                  "required": false,
                  "description": "If set to False, the layer will not learn an additive bias"
                }
              ]
            }
          }
        },
        {
          "node_id": "output",
          "kind": "output",
          "op": "Output",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [],
          "metadata": {
            "layerType": {
              "id": "output",
              "name": "Output",
              "displayName": "Output",
              "description": "Model output node",
              "icon": "ArrowLeft",
              "category": "io",
              "parameters": [
                {
                  "name": "name",
                  "type": "string",
                  "defaultValue": "output",
                  "required": false,
                  "description": "Name for this output"
                }
              ]
            }
          }
        },
        {
          "node_id": "python@query_rope#1",
          "kind": "layer",
          "op": "Python",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "python",
              "name": "Python",
              "displayName": "Python",
              "description": "A statement from the source file that has no graph equivalent. Its code is kept verbatim and its shape is unknown until the model is traced.",
              "icon": "Hash",
              "category": "misc",
              "parameters": []
            },
            "parentId": "query_rope"
          }
        },
        {
          "node_id": "python@query_rope#0",
          "kind": "layer",
          "op": "Python",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "python",
              "name": "Python",
              "displayName": "Python",
              "description": "A statement from the source file that has no graph equivalent. Its code is kept verbatim and its shape is unknown until the model is traced.",
              "icon": "Hash",
              "category": "misc",
              "parameters": []
            },
            "parentId": "query_rope"
          }
        },
        {
          "node_id": "mul@query_rope#0",
          "kind": "layer",
          "op": "torch.mul",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "mul",
              "name": "torch.mul",
              "displayName": "torch.mul",
              "description": "PyTorch mul operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "query_rope"
          }
        },
        {
          "node_id": "mul@query_rope#3",
          "kind": "layer",
          "op": "torch.mul",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "mul",
              "name": "torch.mul",
              "displayName": "torch.mul",
              "description": "PyTorch mul operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "query_rope"
          }
        },
        {
          "node_id": "mul@query_rope#4",
          "kind": "layer",
          "op": "torch.mul",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "mul",
              "name": "torch.mul",
              "displayName": "torch.mul",
              "description": "PyTorch mul operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "query_rope"
          }
        },
        {
          "node_id": "add@query_rope#0",
          "kind": "layer",
          "op": "torch.add",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "add",
              "name": "torch.add",
              "displayName": "torch.add",
              "description": "PyTorch add operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "query_rope"
          }
        },
        {
          "node_id": "mul@query_rope#1",
          "kind": "layer",
          "op": "torch.mul",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "mul",
              "name": "torch.mul",
              "displayName": "torch.mul",
              "description": "PyTorch mul operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "query_rope"
          }
        },
        {
          "node_id": "mul@query_rope#2",
          "kind": "layer",
          "op": "torch.mul",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "mul",
              "name": "torch.mul",
              "displayName": "torch.mul",
              "description": "PyTorch mul operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "query_rope"
          }
        },
        {
          "node_id": "sub@query_rope#0",
          "kind": "layer",
          "op": "torch.sub",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "sub",
              "name": "torch.sub",
              "displayName": "torch.sub",
              "description": "PyTorch sub operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "query_rope"
          }
        },
        {
          "node_id": "stack@query_rope#0",
          "kind": "layer",
          "op": "torch.stack",
          "params": {
            "dim": -1
          },
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "stack",
              "name": "torch.stack",
              "displayName": "torch.stack",
              "description": "PyTorch stack operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "query_rope"
          }
        },
        {
          "node_id": "flatten@query_rope#0",
          "kind": "layer",
          "op": "Flatten",
          "params": {
            "start_dim": -2
          },
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "flatten",
              "name": "Flatten",
              "displayName": "Flatten",
              "description": "Flattens input tensor contiguously",
              "icon": "Maximize2",
              "category": "tensor",
              "parameters": [
                {
                  "name": "start_dim",
                  "type": "number",
                  "defaultValue": 1,
                  "required": false,
                  "description": "First dim to flatten",
                  "min": 0
                },
                {
                  "name": "end_dim",
                  "type": "number",
                  "defaultValue": -1,
                  "required": false,
                  "description": "Last dim to flatten"
                }
              ]
            },
            "parentId": "query_rope"
          }
        },
        {
          "node_id": "python@key_rope#1",
          "kind": "layer",
          "op": "Python",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "python",
              "name": "Python",
              "displayName": "Python",
              "description": "A statement from the source file that has no graph equivalent. Its code is kept verbatim and its shape is unknown until the model is traced.",
              "icon": "Hash",
              "category": "misc",
              "parameters": []
            },
            "parentId": "key_rope"
          }
        },
        {
          "node_id": "python@key_rope#0",
          "kind": "layer",
          "op": "Python",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "python",
              "name": "Python",
              "displayName": "Python",
              "description": "A statement from the source file that has no graph equivalent. Its code is kept verbatim and its shape is unknown until the model is traced.",
              "icon": "Hash",
              "category": "misc",
              "parameters": []
            },
            "parentId": "key_rope"
          }
        },
        {
          "node_id": "mul@key_rope#0",
          "kind": "layer",
          "op": "torch.mul",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "mul",
              "name": "torch.mul",
              "displayName": "torch.mul",
              "description": "PyTorch mul operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "key_rope"
          }
        },
        {
          "node_id": "mul@key_rope#3",
          "kind": "layer",
          "op": "torch.mul",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "mul",
              "name": "torch.mul",
              "displayName": "torch.mul",
              "description": "PyTorch mul operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "key_rope"
          }
        },
        {
          "node_id": "mul@key_rope#4",
          "kind": "layer",
          "op": "torch.mul",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "mul",
              "name": "torch.mul",
              "displayName": "torch.mul",
              "description": "PyTorch mul operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "key_rope"
          }
        },
        {
          "node_id": "add@key_rope#0",
          "kind": "layer",
          "op": "torch.add",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "add",
              "name": "torch.add",
              "displayName": "torch.add",
              "description": "PyTorch add operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "key_rope"
          }
        },
        {
          "node_id": "mul@key_rope#1",
          "kind": "layer",
          "op": "torch.mul",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "mul",
              "name": "torch.mul",
              "displayName": "torch.mul",
              "description": "PyTorch mul operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "key_rope"
          }
        },
        {
          "node_id": "mul@key_rope#2",
          "kind": "layer",
          "op": "torch.mul",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "mul",
              "name": "torch.mul",
              "displayName": "torch.mul",
              "description": "PyTorch mul operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "key_rope"
          }
        },
        {
          "node_id": "sub@key_rope#0",
          "kind": "layer",
          "op": "torch.sub",
          "params": {},
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "sub",
              "name": "torch.sub",
              "displayName": "torch.sub",
              "description": "PyTorch sub operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "key_rope"
          }
        },
        {
          "node_id": "stack@key_rope#0",
          "kind": "layer",
          "op": "torch.stack",
          "params": {
            "dim": -1
          },
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "stack",
              "name": "torch.stack",
              "displayName": "torch.stack",
              "description": "PyTorch stack operation",
              "icon": "Activity",
              "category": "tensor",
              "parameters": [
                {
                  "name": "dim",
                  "type": "string",
                  "defaultValue": "",
                  "required": false,
                  "description": "Dimension(s) to apply the operation on"
                }
              ]
            },
            "parentId": "key_rope"
          }
        },
        {
          "node_id": "flatten@key_rope#0",
          "kind": "layer",
          "op": "Flatten",
          "params": {
            "start_dim": -2
          },
          "in_ports": [
            "x"
          ],
          "out_ports": [
            "y"
          ],
          "metadata": {
            "layerType": {
              "id": "flatten",
              "name": "Flatten",
              "displayName": "Flatten",
              "description": "Flattens input tensor contiguously",
              "icon": "Maximize2",
              "category": "tensor",
              "parameters": [
                {
                  "name": "start_dim",
                  "type": "number",
                  "defaultValue": 1,
                  "required": false,
                  "description": "First dim to flatten",
                  "min": 0
                },
                {
                  "name": "end_dim",
                  "type": "number",
                  "defaultValue": -1,
                  "required": false,
                  "description": "Last dim to flatten"
                }
              ]
            },
            "parentId": "key_rope"
          }
        }
      ],
      "edges": [
        {
          "edge_id": "edge-1",
          "source_node_id": "python@query_rope#0",
          "target_node_id": "mul@query_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-2",
          "source_node_id": "python@query_rope#1",
          "target_node_id": "mul@query_rope#2",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-3",
          "source_node_id": "mul@query_rope#0",
          "target_node_id": "mul@query_rope#2",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-4",
          "source_node_id": "python@query_rope#1",
          "target_node_id": "mul@query_rope#1",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-5",
          "source_node_id": "mul@query_rope#0",
          "target_node_id": "mul@query_rope#1",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-6",
          "source_node_id": "mul@query_rope#2",
          "target_node_id": "sub@query_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-7",
          "source_node_id": "mul@query_rope#1",
          "target_node_id": "sub@query_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-8",
          "source_node_id": "python@query_rope#1",
          "target_node_id": "mul@query_rope#4",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-9",
          "source_node_id": "mul@query_rope#0",
          "target_node_id": "mul@query_rope#4",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-10",
          "source_node_id": "python@query_rope#1",
          "target_node_id": "mul@query_rope#3",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-11",
          "source_node_id": "mul@query_rope#0",
          "target_node_id": "mul@query_rope#3",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-12",
          "source_node_id": "mul@query_rope#4",
          "target_node_id": "add@query_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-13",
          "source_node_id": "mul@query_rope#3",
          "target_node_id": "add@query_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-14",
          "source_node_id": "sub@query_rope#0",
          "target_node_id": "stack@query_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-15",
          "source_node_id": "add@query_rope#0",
          "target_node_id": "stack@query_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-16",
          "source_node_id": "stack@query_rope#0",
          "target_node_id": "flatten@query_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-17",
          "source_node_id": "python@key_rope#0",
          "target_node_id": "mul@key_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-18",
          "source_node_id": "python@key_rope#1",
          "target_node_id": "mul@key_rope#2",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-19",
          "source_node_id": "mul@key_rope#0",
          "target_node_id": "mul@key_rope#2",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-20",
          "source_node_id": "python@key_rope#1",
          "target_node_id": "mul@key_rope#1",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-21",
          "source_node_id": "mul@key_rope#0",
          "target_node_id": "mul@key_rope#1",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-22",
          "source_node_id": "mul@key_rope#2",
          "target_node_id": "sub@key_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-23",
          "source_node_id": "mul@key_rope#1",
          "target_node_id": "sub@key_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-24",
          "source_node_id": "python@key_rope#1",
          "target_node_id": "mul@key_rope#4",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-25",
          "source_node_id": "mul@key_rope#0",
          "target_node_id": "mul@key_rope#4",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-26",
          "source_node_id": "python@key_rope#1",
          "target_node_id": "mul@key_rope#3",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-27",
          "source_node_id": "mul@key_rope#0",
          "target_node_id": "mul@key_rope#3",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-28",
          "source_node_id": "mul@key_rope#4",
          "target_node_id": "add@key_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-29",
          "source_node_id": "mul@key_rope#3",
          "target_node_id": "add@key_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-30",
          "source_node_id": "sub@key_rope#0",
          "target_node_id": "stack@key_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-31",
          "source_node_id": "add@key_rope#0",
          "target_node_id": "stack@key_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-32",
          "source_node_id": "stack@key_rope#0",
          "target_node_id": "flatten@key_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-33",
          "source_node_id": "input",
          "target_node_id": "query",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-34",
          "source_node_id": "query",
          "target_node_id": "python@query_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-35",
          "source_node_id": "query",
          "target_node_id": "mul@query_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-36",
          "source_node_id": "query",
          "target_node_id": "python@query_rope#1",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-37",
          "source_node_id": "query",
          "target_node_id": "query_rope",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-38",
          "source_node_id": "input",
          "target_node_id": "key",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-39",
          "source_node_id": "key",
          "target_node_id": "python@key_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-40",
          "source_node_id": "key",
          "target_node_id": "mul@key_rope#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-41",
          "source_node_id": "key",
          "target_node_id": "python@key_rope#1",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-42",
          "source_node_id": "key",
          "target_node_id": "key_rope",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-43",
          "source_node_id": "input",
          "target_node_id": "value",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-44",
          "source_node_id": "flatten@query_rope#0",
          "target_node_id": "div@RotaryAttention#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-45",
          "source_node_id": "query_rope",
          "target_node_id": "div@RotaryAttention#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-46",
          "source_node_id": "flatten@key_rope#0",
          "target_node_id": "div@RotaryAttention#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-47",
          "source_node_id": "key_rope",
          "target_node_id": "div@RotaryAttention#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-48",
          "source_node_id": "div@RotaryAttention#0",
          "target_node_id": "softmax",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-49",
          "source_node_id": "softmax",
          "target_node_id": "python@RotaryAttention#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-50",
          "source_node_id": "value",
          "target_node_id": "python@RotaryAttention#0",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-51",
          "source_node_id": "python@RotaryAttention#0",
          "target_node_id": "project",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        },
        {
          "edge_id": "edge-52",
          "source_node_id": "project",
          "target_node_id": "output",
          "source_port": "y",
          "target_port": "x",
          "metadata": {}
        }
      ],
      "inputs": [],
      "modules": [],
      "operations": [],
      "metadata": {}
    },
    "view": {
      "graph_id": "snapshot",
      "node_positions": {
        "input": {
          "x": 0,
          "y": 160
        },
        "query": {
          "x": 340,
          "y": 160
        },
        "key": {
          "x": 680,
          "y": 160
        },
        "value": {
          "x": 1020,
          "y": 160
        },
        "query_rope": {
          "x": 1360,
          "y": 160
        },
        "key_rope": {
          "x": 1700,
          "y": 160
        },
        "div@RotaryAttention#0": {
          "x": 2040,
          "y": 160
        },
        "softmax": {
          "x": 2380,
          "y": 160
        },
        "python@RotaryAttention#0": {
          "x": 2720,
          "y": 160
        },
        "project": {
          "x": 3060,
          "y": 160
        },
        "output": {
          "x": 3400,
          "y": 160
        },
        "python@query_rope#1": {
          "x": 24,
          "y": 214
        },
        "python@query_rope#0": {
          "x": 24,
          "y": 364
        },
        "mul@query_rope#0": {
          "x": 24,
          "y": 514
        },
        "mul@query_rope#3": {
          "x": 24,
          "y": 664
        },
        "mul@query_rope#4": {
          "x": 24,
          "y": 814
        },
        "add@query_rope#0": {
          "x": 24,
          "y": 964
        },
        "mul@query_rope#1": {
          "x": 24,
          "y": 1114
        },
        "mul@query_rope#2": {
          "x": 24,
          "y": 1264
        },
        "sub@query_rope#0": {
          "x": 24,
          "y": 1414
        },
        "stack@query_rope#0": {
          "x": 24,
          "y": 1564
        },
        "flatten@query_rope#0": {
          "x": 24,
          "y": 1714
        },
        "python@key_rope#1": {
          "x": 24,
          "y": 214
        },
        "python@key_rope#0": {
          "x": 24,
          "y": 364
        },
        "mul@key_rope#0": {
          "x": 24,
          "y": 514
        },
        "mul@key_rope#3": {
          "x": 24,
          "y": 664
        },
        "mul@key_rope#4": {
          "x": 24,
          "y": 814
        },
        "add@key_rope#0": {
          "x": 24,
          "y": 964
        },
        "mul@key_rope#1": {
          "x": 24,
          "y": 1114
        },
        "mul@key_rope#2": {
          "x": 24,
          "y": 1264
        },
        "sub@key_rope#0": {
          "x": 24,
          "y": 1414
        },
        "stack@key_rope#0": {
          "x": 24,
          "y": 1564
        },
        "flatten@key_rope#0": {
          "x": 24,
          "y": 1714
        }
      },
      "collapsed_modules": [
        "query_rope",
        "key_rope"
      ],
      "selection": [],
      "layout": {}
    }
  },
  "snapshotId": "snapshot-99dbcd4d6803bb8f",
  "collaboration": {
    "walkthrough": {
      "title": "Put position into attention",
      "steps": [
        {
          "id": "project",
          "title": "Start with content projections",
          "note": "The input has six tokens with eight features. Independent learned projections produce Q, K and V; position enters after Q and K have been projected.",
          "view": {
            "camera": {
              "x": -7.5,
              "y": 60,
              "z": 1.25
            },
            "nodePositions": {
              "input": {
                "x": 0,
                "y": 160
              },
              "query": {
                "x": 340,
                "y": 160
              },
              "key": {
                "x": 680,
                "y": 160
              },
              "value": {
                "x": 1020,
                "y": 160
              },
              "query_rope": {
                "x": 1360,
                "y": 160
              },
              "key_rope": {
                "x": 1700,
                "y": 160
              },
              "div@RotaryAttention#0": {
                "x": 2040,
                "y": 160
              },
              "softmax": {
                "x": 2380,
                "y": 160
              },
              "python@RotaryAttention#0": {
                "x": 2720,
                "y": 160
              },
              "project": {
                "x": 3060,
                "y": 160
              },
              "output": {
                "x": 3400,
                "y": 160
              },
              "python@query_rope#1": {
                "x": 24,
                "y": 214
              },
              "python@query_rope#0": {
                "x": 24,
                "y": 364
              },
              "mul@query_rope#0": {
                "x": 24,
                "y": 514
              },
              "mul@query_rope#3": {
                "x": 24,
                "y": 664
              },
              "mul@query_rope#4": {
                "x": 24,
                "y": 814
              },
              "add@query_rope#0": {
                "x": 24,
                "y": 964
              },
              "mul@query_rope#1": {
                "x": 24,
                "y": 1114
              },
              "mul@query_rope#2": {
                "x": 24,
                "y": 1264
              },
              "sub@query_rope#0": {
                "x": 24,
                "y": 1414
              },
              "stack@query_rope#0": {
                "x": 24,
                "y": 1564
              },
              "flatten@query_rope#0": {
                "x": 24,
                "y": 1714
              },
              "python@key_rope#1": {
                "x": 24,
                "y": 214
              },
              "python@key_rope#0": {
                "x": 24,
                "y": 364
              },
              "mul@key_rope#0": {
                "x": 24,
                "y": 514
              },
              "mul@key_rope#3": {
                "x": 24,
                "y": 664
              },
              "mul@key_rope#4": {
                "x": 24,
                "y": 814
              },
              "add@key_rope#0": {
                "x": 24,
                "y": 964
              },
              "mul@key_rope#1": {
                "x": 24,
                "y": 1114
              },
              "mul@key_rope#2": {
                "x": 24,
                "y": 1264
              },
              "sub@key_rope#0": {
                "x": 24,
                "y": 1414
              },
              "stack@key_rope#0": {
                "x": 24,
                "y": 1564
              },
              "flatten@key_rope#0": {
                "x": 24,
                "y": 1714
              }
            },
            "expandedModuleIds": [],
            "selectedNodeIds": [
              "query"
            ],
            "viewport": {
              "width": 1100,
              "height": 700
            }
          },
          "anchors": [
            {
              "target": {
                "kind": "node",
                "nodeId": "query"
              },
              "snapshotId": "snapshot-99dbcd4d6803bb8f",
              "exportedAt": "2026-09-17T05:53:58.907442+00:00",
              "modelName": "RotaryAttention",
              "context": "{\"connections\":[\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"input\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"query\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"python@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"python@query_rope#1\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"query_rope\\\",\\\"targetPort\\\":\\\"x\\\"}\"],\"contents\":[],\"node\":{\"id\":\"query\",\"kind\":\"layer\",\"op\":\"Linear\",\"params\":{\"in_features\":8,\"out_features\":8}}}"
            }
          ]
        },
        {
          "id": "rotate-query",
          "title": "Rotate query feature pairs",
          "note": "Each adjacent pair is rotated by position × frequency. The four frequencies are 1, 0.1, 0.01 and 0.001 radians per position, preserving the query norm.",
          "view": {
            "camera": {
              "x": 252.69230769230785,
              "y": 47.44055944055958,
              "z": 0.30852211434735705
            },
            "nodePositions": {
              "input": {
                "x": 0,
                "y": 160
              },
              "query": {
                "x": 340,
                "y": 160
              },
              "key": {
                "x": 680,
                "y": 160
              },
              "value": {
                "x": 1020,
                "y": 160
              },
              "query_rope": {
                "x": 1360,
                "y": 160
              },
              "key_rope": {
                "x": 1700,
                "y": 160
              },
              "div@RotaryAttention#0": {
                "x": 2040,
                "y": 160
              },
              "softmax": {
                "x": 2380,
                "y": 160
              },
              "python@RotaryAttention#0": {
                "x": 2720,
                "y": 160
              },
              "project": {
                "x": 3060,
                "y": 160
              },
              "output": {
                "x": 3400,
                "y": 160
              },
              "python@query_rope#1": {
                "x": 24,
                "y": 214
              },
              "python@query_rope#0": {
                "x": 24,
                "y": 364
              },
              "mul@query_rope#0": {
                "x": 24,
                "y": 514
              },
              "mul@query_rope#3": {
                "x": 24,
                "y": 664
              },
              "mul@query_rope#4": {
                "x": 24,
                "y": 814
              },
              "add@query_rope#0": {
                "x": 24,
                "y": 964
              },
              "mul@query_rope#1": {
                "x": 24,
                "y": 1114
              },
              "mul@query_rope#2": {
                "x": 24,
                "y": 1264
              },
              "sub@query_rope#0": {
                "x": 24,
                "y": 1414
              },
              "stack@query_rope#0": {
                "x": 24,
                "y": 1564
              },
              "flatten@query_rope#0": {
                "x": 24,
                "y": 1714
              },
              "python@key_rope#1": {
                "x": 24,
                "y": 214
              },
              "python@key_rope#0": {
                "x": 24,
                "y": 364
              },
              "mul@key_rope#0": {
                "x": 24,
                "y": 514
              },
              "mul@key_rope#3": {
                "x": 24,
                "y": 664
              },
              "mul@key_rope#4": {
                "x": 24,
                "y": 814
              },
              "add@key_rope#0": {
                "x": 24,
                "y": 964
              },
              "mul@key_rope#1": {
                "x": 24,
                "y": 1114
              },
              "mul@key_rope#2": {
                "x": 24,
                "y": 1264
              },
              "sub@key_rope#0": {
                "x": 24,
                "y": 1414
              },
              "stack@key_rope#0": {
                "x": 24,
                "y": 1564
              },
              "flatten@key_rope#0": {
                "x": 24,
                "y": 1714
              }
            },
            "expandedModuleIds": [
              "query_rope"
            ],
            "selectedNodeIds": [
              "query_rope"
            ],
            "viewport": {
              "width": 1100,
              "height": 700
            }
          },
          "anchors": [
            {
              "target": {
                "kind": "node",
                "nodeId": "query_rope"
              },
              "snapshotId": "snapshot-99dbcd4d6803bb8f",
              "exportedAt": "2026-09-17T05:53:58.907442+00:00",
              "modelName": "RotaryAttention",
              "context": "{\"connections\":[\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"add@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"stack@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"flatten@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"div@RotaryAttention#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#1\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#2\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#3\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#4\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"sub@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#2\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"sub@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#3\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"add@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#4\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"add@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@query_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#1\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@query_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#2\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@query_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#3\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@query_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#4\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"python@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"python@query_rope#1\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"query_rope\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query_rope\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"div@RotaryAttention#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"stack@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"flatten@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"sub@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"stack@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\"],\"contents\":[\"{\\\"id\\\":\\\"add@query_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.add\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"flatten@query_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"Flatten\\\",\\\"params\\\":{\\\"start_dim\\\":-2},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"mul@query_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"mul@query_rope#1\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"mul@query_rope#2\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"mul@query_rope#3\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"mul@query_rope#4\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"python@query_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"Python\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"python@query_rope#1\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"Python\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"stack@query_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.stack\\\",\\\"params\\\":{\\\"dim\\\":-1},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"sub@query_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.sub\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\"],\"node\":{\"id\":\"query_rope\",\"kind\":\"module\",\"op\":\"Module\",\"params\":{}}}"
            }
          ]
        },
        {
          "id": "rotate-key",
          "title": "Rotate keys with the same rule",
          "note": "When rotated Q and K meet, their dot product depends on relative position. Shift both positions together in the recorded comparison to see the score stay fixed.",
          "view": {
            "camera": {
              "x": -87.30769230769215,
              "y": 47.44055944055958,
              "z": 0.30852211434735705
            },
            "nodePositions": {
              "input": {
                "x": 0,
                "y": 160
              },
              "query": {
                "x": 340,
                "y": 160
              },
              "key": {
                "x": 680,
                "y": 160
              },
              "value": {
                "x": 1020,
                "y": 160
              },
              "query_rope": {
                "x": 1360,
                "y": 160
              },
              "key_rope": {
                "x": 1700,
                "y": 160
              },
              "div@RotaryAttention#0": {
                "x": 2040,
                "y": 160
              },
              "softmax": {
                "x": 2380,
                "y": 160
              },
              "python@RotaryAttention#0": {
                "x": 2720,
                "y": 160
              },
              "project": {
                "x": 3060,
                "y": 160
              },
              "output": {
                "x": 3400,
                "y": 160
              },
              "python@query_rope#1": {
                "x": 24,
                "y": 214
              },
              "python@query_rope#0": {
                "x": 24,
                "y": 364
              },
              "mul@query_rope#0": {
                "x": 24,
                "y": 514
              },
              "mul@query_rope#3": {
                "x": 24,
                "y": 664
              },
              "mul@query_rope#4": {
                "x": 24,
                "y": 814
              },
              "add@query_rope#0": {
                "x": 24,
                "y": 964
              },
              "mul@query_rope#1": {
                "x": 24,
                "y": 1114
              },
              "mul@query_rope#2": {
                "x": 24,
                "y": 1264
              },
              "sub@query_rope#0": {
                "x": 24,
                "y": 1414
              },
              "stack@query_rope#0": {
                "x": 24,
                "y": 1564
              },
              "flatten@query_rope#0": {
                "x": 24,
                "y": 1714
              },
              "python@key_rope#1": {
                "x": 24,
                "y": 214
              },
              "python@key_rope#0": {
                "x": 24,
                "y": 364
              },
              "mul@key_rope#0": {
                "x": 24,
                "y": 514
              },
              "mul@key_rope#3": {
                "x": 24,
                "y": 664
              },
              "mul@key_rope#4": {
                "x": 24,
                "y": 814
              },
              "add@key_rope#0": {
                "x": 24,
                "y": 964
              },
              "mul@key_rope#1": {
                "x": 24,
                "y": 1114
              },
              "mul@key_rope#2": {
                "x": 24,
                "y": 1264
              },
              "sub@key_rope#0": {
                "x": 24,
                "y": 1414
              },
              "stack@key_rope#0": {
                "x": 24,
                "y": 1564
              },
              "flatten@key_rope#0": {
                "x": 24,
                "y": 1714
              }
            },
            "expandedModuleIds": [
              "key_rope"
            ],
            "selectedNodeIds": [
              "key_rope"
            ],
            "viewport": {
              "width": 1100,
              "height": 700
            }
          },
          "anchors": [
            {
              "target": {
                "kind": "node",
                "nodeId": "key_rope"
              },
              "snapshotId": "snapshot-99dbcd4d6803bb8f",
              "exportedAt": "2026-09-17T05:53:58.907442+00:00",
              "modelName": "RotaryAttention",
              "context": "{\"connections\":[\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"add@key_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"stack@key_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"flatten@key_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"div@RotaryAttention#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"key\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"key_rope\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"key\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@key_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"key\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"python@key_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"key\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"python@key_rope#1\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"key_rope\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"div@RotaryAttention#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@key_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@key_rope#1\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@key_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@key_rope#2\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@key_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@key_rope#3\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@key_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@key_rope#4\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@key_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"sub@key_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@key_rope#2\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"sub@key_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@key_rope#3\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"add@key_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@key_rope#4\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"add@key_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@key_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@key_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@key_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@key_rope#1\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@key_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@key_rope#2\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@key_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@key_rope#3\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@key_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@key_rope#4\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"stack@key_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"flatten@key_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"sub@key_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"stack@key_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\"],\"contents\":[\"{\\\"id\\\":\\\"add@key_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.add\\\",\\\"params\\\":{},\\\"parent\\\":\\\"key_rope\\\"}\",\"{\\\"id\\\":\\\"flatten@key_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"Flatten\\\",\\\"params\\\":{\\\"start_dim\\\":-2},\\\"parent\\\":\\\"key_rope\\\"}\",\"{\\\"id\\\":\\\"mul@key_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"key_rope\\\"}\",\"{\\\"id\\\":\\\"mul@key_rope#1\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"key_rope\\\"}\",\"{\\\"id\\\":\\\"mul@key_rope#2\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"key_rope\\\"}\",\"{\\\"id\\\":\\\"mul@key_rope#3\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"key_rope\\\"}\",\"{\\\"id\\\":\\\"mul@key_rope#4\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"key_rope\\\"}\",\"{\\\"id\\\":\\\"python@key_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"Python\\\",\\\"params\\\":{},\\\"parent\\\":\\\"key_rope\\\"}\",\"{\\\"id\\\":\\\"python@key_rope#1\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"Python\\\",\\\"params\\\":{},\\\"parent\\\":\\\"key_rope\\\"}\",\"{\\\"id\\\":\\\"stack@key_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.stack\\\",\\\"params\\\":{\\\"dim\\\":-1},\\\"parent\\\":\\\"key_rope\\\"}\",\"{\\\"id\\\":\\\"sub@key_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.sub\\\",\\\"params\\\":{},\\\"parent\\\":\\\"key_rope\\\"}\"],\"node\":{\"id\":\"key_rope\",\"kind\":\"module\",\"op\":\"Module\",\"params\":{}}}"
            }
          ]
        },
        {
          "id": "values",
          "title": "Keep values on their content path",
          "note": "This standard RoPE attention variant leaves V unrotated. Softmax of the scaled Q/K scores chooses how to mix these value vectors before the output projection.",
          "view": {
            "camera": {
              "x": -687.5,
              "y": 60,
              "z": 1.25
            },
            "nodePositions": {
              "input": {
                "x": 0,
                "y": 160
              },
              "query": {
                "x": 340,
                "y": 160
              },
              "key": {
                "x": 680,
                "y": 160
              },
              "value": {
                "x": 1020,
                "y": 160
              },
              "query_rope": {
                "x": 1360,
                "y": 160
              },
              "key_rope": {
                "x": 1700,
                "y": 160
              },
              "div@RotaryAttention#0": {
                "x": 2040,
                "y": 160
              },
              "softmax": {
                "x": 2380,
                "y": 160
              },
              "python@RotaryAttention#0": {
                "x": 2720,
                "y": 160
              },
              "project": {
                "x": 3060,
                "y": 160
              },
              "output": {
                "x": 3400,
                "y": 160
              },
              "python@query_rope#1": {
                "x": 24,
                "y": 214
              },
              "python@query_rope#0": {
                "x": 24,
                "y": 364
              },
              "mul@query_rope#0": {
                "x": 24,
                "y": 514
              },
              "mul@query_rope#3": {
                "x": 24,
                "y": 664
              },
              "mul@query_rope#4": {
                "x": 24,
                "y": 814
              },
              "add@query_rope#0": {
                "x": 24,
                "y": 964
              },
              "mul@query_rope#1": {
                "x": 24,
                "y": 1114
              },
              "mul@query_rope#2": {
                "x": 24,
                "y": 1264
              },
              "sub@query_rope#0": {
                "x": 24,
                "y": 1414
              },
              "stack@query_rope#0": {
                "x": 24,
                "y": 1564
              },
              "flatten@query_rope#0": {
                "x": 24,
                "y": 1714
              },
              "python@key_rope#1": {
                "x": 24,
                "y": 214
              },
              "python@key_rope#0": {
                "x": 24,
                "y": 364
              },
              "mul@key_rope#0": {
                "x": 24,
                "y": 514
              },
              "mul@key_rope#3": {
                "x": 24,
                "y": 664
              },
              "mul@key_rope#4": {
                "x": 24,
                "y": 814
              },
              "add@key_rope#0": {
                "x": 24,
                "y": 964
              },
              "mul@key_rope#1": {
                "x": 24,
                "y": 1114
              },
              "mul@key_rope#2": {
                "x": 24,
                "y": 1264
              },
              "sub@key_rope#0": {
                "x": 24,
                "y": 1414
              },
              "stack@key_rope#0": {
                "x": 24,
                "y": 1564
              },
              "flatten@key_rope#0": {
                "x": 24,
                "y": 1714
              }
            },
            "expandedModuleIds": [],
            "selectedNodeIds": [
              "value"
            ],
            "viewport": {
              "width": 1100,
              "height": 700
            }
          },
          "anchors": [
            {
              "target": {
                "kind": "node",
                "nodeId": "value"
              },
              "snapshotId": "snapshot-99dbcd4d6803bb8f",
              "exportedAt": "2026-09-17T05:53:58.907442+00:00",
              "modelName": "RotaryAttention",
              "context": "{\"connections\":[\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"input\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"value\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"value\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"python@RotaryAttention#0\\\",\\\"targetPort\\\":\\\"x\\\"}\"],\"contents\":[],\"node\":{\"id\":\"value\",\"kind\":\"layer\",\"op\":\"Linear\",\"params\":{\"in_features\":8,\"out_features\":8}}}"
            }
          ]
        }
      ]
    },
    "threads": [],
    "savedViews": [
      {
        "id": "rotate-query",
        "title": "Rotate query feature pairs",
        "note": "Each adjacent pair is rotated by position × frequency. The four frequencies are 1, 0.1, 0.01 and 0.001 radians per position, preserving the query norm.",
        "view": {
          "camera": {
            "x": 252.69230769230785,
            "y": 47.44055944055958,
            "z": 0.30852211434735705
          },
          "nodePositions": {
            "input": {
              "x": 0,
              "y": 160
            },
            "query": {
              "x": 340,
              "y": 160
            },
            "key": {
              "x": 680,
              "y": 160
            },
            "value": {
              "x": 1020,
              "y": 160
            },
            "query_rope": {
              "x": 1360,
              "y": 160
            },
            "key_rope": {
              "x": 1700,
              "y": 160
            },
            "div@RotaryAttention#0": {
              "x": 2040,
              "y": 160
            },
            "softmax": {
              "x": 2380,
              "y": 160
            },
            "python@RotaryAttention#0": {
              "x": 2720,
              "y": 160
            },
            "project": {
              "x": 3060,
              "y": 160
            },
            "output": {
              "x": 3400,
              "y": 160
            },
            "python@query_rope#1": {
              "x": 24,
              "y": 214
            },
            "python@query_rope#0": {
              "x": 24,
              "y": 364
            },
            "mul@query_rope#0": {
              "x": 24,
              "y": 514
            },
            "mul@query_rope#3": {
              "x": 24,
              "y": 664
            },
            "mul@query_rope#4": {
              "x": 24,
              "y": 814
            },
            "add@query_rope#0": {
              "x": 24,
              "y": 964
            },
            "mul@query_rope#1": {
              "x": 24,
              "y": 1114
            },
            "mul@query_rope#2": {
              "x": 24,
              "y": 1264
            },
            "sub@query_rope#0": {
              "x": 24,
              "y": 1414
            },
            "stack@query_rope#0": {
              "x": 24,
              "y": 1564
            },
            "flatten@query_rope#0": {
              "x": 24,
              "y": 1714
            },
            "python@key_rope#1": {
              "x": 24,
              "y": 214
            },
            "python@key_rope#0": {
              "x": 24,
              "y": 364
            },
            "mul@key_rope#0": {
              "x": 24,
              "y": 514
            },
            "mul@key_rope#3": {
              "x": 24,
              "y": 664
            },
            "mul@key_rope#4": {
              "x": 24,
              "y": 814
            },
            "add@key_rope#0": {
              "x": 24,
              "y": 964
            },
            "mul@key_rope#1": {
              "x": 24,
              "y": 1114
            },
            "mul@key_rope#2": {
              "x": 24,
              "y": 1264
            },
            "sub@key_rope#0": {
              "x": 24,
              "y": 1414
            },
            "stack@key_rope#0": {
              "x": 24,
              "y": 1564
            },
            "flatten@key_rope#0": {
              "x": 24,
              "y": 1714
            }
          },
          "expandedModuleIds": [
            "query_rope"
          ],
          "selectedNodeIds": [
            "query_rope"
          ],
          "viewport": {
            "width": 1100,
            "height": 700
          }
        },
        "anchors": [
          {
            "target": {
              "kind": "node",
              "nodeId": "query_rope"
            },
            "snapshotId": "snapshot-99dbcd4d6803bb8f",
            "exportedAt": "2026-09-17T05:53:58.907442+00:00",
            "modelName": "RotaryAttention",
            "context": "{\"connections\":[\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"add@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"stack@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"flatten@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"div@RotaryAttention#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#1\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#2\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#3\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#4\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"sub@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#2\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"sub@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#3\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"add@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"mul@query_rope#4\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"add@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@query_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#1\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@query_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#2\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@query_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#3\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"python@query_rope#1\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#4\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"mul@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"python@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"python@query_rope#1\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"query_rope\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"query_rope\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"div@RotaryAttention#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"stack@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"flatten@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\",\"{\\\"kind\\\":\\\"edge\\\",\\\"source\\\":\\\"sub@query_rope#0\\\",\\\"sourcePort\\\":\\\"y\\\",\\\"target\\\":\\\"stack@query_rope#0\\\",\\\"targetPort\\\":\\\"x\\\"}\"],\"contents\":[\"{\\\"id\\\":\\\"add@query_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.add\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"flatten@query_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"Flatten\\\",\\\"params\\\":{\\\"start_dim\\\":-2},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"mul@query_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"mul@query_rope#1\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"mul@query_rope#2\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"mul@query_rope#3\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"mul@query_rope#4\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.mul\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"python@query_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"Python\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"python@query_rope#1\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"Python\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"stack@query_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.stack\\\",\\\"params\\\":{\\\"dim\\\":-1},\\\"parent\\\":\\\"query_rope\\\"}\",\"{\\\"id\\\":\\\"sub@query_rope#0\\\",\\\"kind\\\":\\\"layer\\\",\\\"op\\\":\\\"torch.sub\\\",\\\"params\\\":{},\\\"parent\\\":\\\"query_rope\\\"}\"],\"node\":{\"id\":\"query_rope\",\"kind\":\"module\",\"op\":\"Module\",\"params\":{}}}"
          }
        ]
      }
    ],
    "openingViewId": "rotate-query"
  }
}
