---
title: "Build a graph"
description: "Add nodes to a stream in Tato Studio, connect their pins, set the values their inputs hold, and organize the graph with frames, notes and subgraphs."
type: "docs-page"
url: "https://tatolab.com/docs/studio/graph"
site: "Tatolab"
section: "Tato Studio"
---

# Build a graph

> Add nodes to a stream in Tato Studio, connect their pins, set the values their inputs hold, and organize the graph with frames, notes and subgraphs.

A stream's graph is where you build. Each node is a card with its inputs down the left and its outputs down the right, and each input and output is a **pin**. Wires carry data from an output pin to the input pins it feeds. Every change you make is applied to the running stream at once and saved with the project.

## Add a node

Click the graph and press **Tab**, or press **+** in the graph's toolbar, or right-click the graph and choose **Add node…**. The search lists every node type the stream can use, filed by category, and the project's graph generators: the [core nodes](https://tatolab.com/docs/reference/built-in-nodes#core-nodes) every project has, the nodes of each module the project added, and the nodes you wrote. Type to narrow it; the card of the highlighted node shows beside the list, with its pins. Press Enter to place it.

You can also add a node from a pin. Drag a wire off an output pin and let go over empty graph: the search opens narrowed to node types with an input that takes what the pin carries, and the node you pick is placed on the end of the wire, already connected.

When the node you want isn't there, choose **Install modules from marketplace** at the bottom of the search. See [Marketplace and modules](https://tatolab.com/docs/studio/marketplace).

## Pins and their types

Every pin has one type, shown by its name and its colour. A wire only joins pins whose types fit, so the graph never holds a connection that can't carry data.

| Type | Carries |
|---|---|
| **Boolean**, **Integer**, **Float**, **String** | True or false, a whole number, a number, text |
| **Menu** | One of a fixed list of options |
| **Color** | An sRGB colour with alpha |
| **Vector**, **Rectangle**, **Transform** | Two to four numbers, a rectangle, a 4 × 4 matrix |
| **Texture** | Pictures, on the GPU |
| **Audio** | A stream of audio samples |
| **Encoded video**, **Encoded audio** | Compressed media, such as H.264 or Opus |
| **Tensor** | An array of numbers with a shape |
| **Asset** | One of the project's assets: a picture, a video, a model, a scene |
| **Trigger** | An event with no payload: a press, a beat, a cue |
| **List**, **Bundle** | A list of values of one type, or several named values together |

Most types can be a single value that changes now and then, such as a threshold or a colour, or a stream of them, such as a level measured every frame. Pictures, audio and encoded media always arrive as a stream.

## Connect pins

Drag from an output pin to an input pin. If the types fit, the wire is made and data starts to flow; if they don't, no wire is made.

An output can feed as many inputs as you like: the camera can go to the visualizer, an effect and a recorder at once, and each reader takes it at its own pace. A reader that falls behind drops data at its own input, and never slows the others down.

To remove a wire, click it and press Delete, or right-click it and choose **Delete link**.

## Set values

An input with no wire into it holds a value, shown on the card. Change it right there:

- A number has a slider or a field: drag it, or click and type.
- A menu opens a list, a Boolean toggles, a colour opens a picker.
- An Asset input chooses one of the project's assets, or imports a new one. See [Library and assets](https://tatolab.com/docs/studio/library).

The stream follows as you drag. Each value is saved with the stream, and connecting a wire into the input takes over from it until the wire is removed.

Select a node to see all of it in **Properties**: its name, which you can change, its inputs and their values, its settings, and what each pin is connected to. A setting can also become an input that's controlled from outside the stream; see [Graph Inputs](https://tatolab.com/docs/studio/streams#graph-inputs-and-controls).

## Select, move and delete

Click a card to select it, and hold ⌘ (Ctrl on Linux) to add more, or hold Shift and drag a box around several. Drag cards to move them. **Delete** or **Backspace** removes the selection, with its wires.

**⌘F** finds a node in the graph by name. The toolbar has **Frame the whole graph**, to bring every node into view, and zoom in and out.

## Frames and notes

Press **F** to put the selected nodes in a **frame**: a box around them with a title, a description and a colour, which moves with them. Right-click a frame to rename it, describe it, change its colour or remove it. Frames are for people; they change nothing that runs.

Right-click the graph and choose **Add note** to leave a note on the canvas, or press the note button in the toolbar.

## Subgraphs

Select some nodes and press **⇧⌘G** to collapse them into a **subgraph**: one card in their place, with a pin for each wire that crossed the selection. The nodes inside are saved as a stream of their own, which you can place again elsewhere. Right-click a subgraph and choose **Step inside** to edit it, and use the trail at the top of the graph to step back out. [Streams as compositions](https://tatolab.com/docs/studio/streams) is all about this.

## Undo

**Edit › Undo** (⌘Z) takes back your last edit, and **Redo** (⇧⌘Z) puts it back. Undo takes back only your own edits, never an agent's or someone else's: the [History](https://tatolab.com/docs/studio/run#history) view lists everyone's, and can step back to any of them.

## When something's wrong

A node that has failed, or isn't ready, says why on its card and in Properties, in its own words: a setting left empty, a file it can't find, an exception its code raised. A wire that can't carry data shows as an error, with the reason. Fix what it names and the stream carries on; [Troubleshooting](https://tatolab.com/docs/reference/troubleshooting) has the common ones.
