Snapshot network graph
snapshot_td_graphCapture a compact, serializable snapshot of a network — nodes, connections, and structural issues — for review, diffing, or documentation. Optionally include node parameters.
Instructions
Read-only: capture a compact, serializable snapshot of a network — nodes, connections, structural issues, and optionally each node's parameters — for review, diffing, or documentation. Returns {nodeCount, connectionCount, issues[], nodes[], connections[]}. Set compact for a token-cheap whole-COMP read that hoists per-type default parameters and stores only each node's deltas. Feed two of these snapshots to diff_snapshots to see exactly what changed across an edit.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Network root to snapshot. | /project1 |
| include_params | No | Also fetch each node's parameters (one request per node; capped for large graphs). | |
| compact | No | Token-cheap whole-COMP read: hoist each operator type's most-common parameter values into a shared `typeDefaults` map and store only each node's *deltas* from them (Embody-style read_tdn). Implies fetching parameters. Use for feeding a large network to an agent without paying for repeated identical values. | |
| include_parameter_modes | No | Also preserve TouchDesigner parameter modes/expressions/binds where available. Compact mode implies this so reactive expressions are not flattened to their current value. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | The network root that was snapshotted, echoing the request. | |
| nodeCount | Yes | Total number of nodes captured. | |
| connectionCount | Yes | Total number of connections captured. | |
| issues | Yes | Plain-language structural problems detected in the graph. | |
| params_truncated | Yes | True if params were requested (`include_params` or `compact`) but the graph exceeded the per-node fetch cap. | |
| parameter_modes_truncated | No | True if parameter modes were requested (`include_parameter_modes` or `compact`) but the graph exceeded the per-node fetch cap. | |
| compact | No | True when compact mode hoisted per-type default parameters and delta-encoded nodes. | |
| typeDefaults | No | Compact mode only: each operator type's hoisted default parameter values; nodes store only their deltas from these. | |
| nodes | Yes | Every captured node, optionally with its parameters. | |
| connections | Yes | Every wire as {source_path, target_path, …}, suitable for diffing. |