# Building Flows (https://docs.fuser.studio/docs/interface/flows)

Flows are complete workflows made by connecting multiple nodes together. They are the heart of Fuser, turning individual AI operations into a cohesive, powerful process. Learn how to design, build, and optimize complex AI workflows that solve real problems.

![A Fuser flow showing multiple nodes connected together](/canvas-organize.jpg)

## What Are Flows? [#what-are-flows]

A **flow** is a connected sequence of nodes that work together to accomplish a task. Think of flows as visual programs where data moves from left to right, being transformed and enhanced at each step.

### Key Characteristics [#key-characteristics]

* **Data-driven**: Execution follows the path of data from one node to the next.
* **Automatic**: Changes to one node automatically trigger updates in all connected nodes downstream.
* **Visual**: The entire process is laid out on the canvas, making it easy to understand and debug.
* **Modular**: Flows are built from individual nodes, which can be combined in limitless ways.

## Flow Execution [#flow-execution]

You execute nodes one at a time today — pick the node you want output from and run it. Fuser identifies the upstream nodes it depends on and evaluates them automatically as part of the run.

> [!NOTE] Out-of-Order Execution
>
> If you trigger multiple executions simultaneously, the order in which the affected nodes finish isn't guaranteed. Wait for one to complete before triggering the next if order matters.

### Execution Considerations [#execution-considerations]

* **Dependency Analysis**: Fuser identifies which nodes depend on others and will automatically resolve dependencies. Remember, data always flows from left to right.
* **Automatic Updates**: When an input changes or a node's parameters are adjusted, all downstream nodes that depend on that output will be updated automatically.
* **Parallel Processing**: You can execute multiple nodes at once by selecting them and pressing the  button in the node toolbar or using the primary toolbar at the bottom of the canvas.

> [!WARNING] Dependency Resolution
>
> Nodes resolve their dependencies **the moment they are executed*&#x2A;. Let's say you want to execute a node &#x2A;*`Node B`*&#x2A; that depends on the output of another node &#x2A;*`Node A`*&#x2A;. If you execute &#x2A;*`Node B`*&#x2A; first, and then immediately execute &#x2A;*`Node A`*&#x2A;, &#x2A;*`Node B`*&#x2A; will not use the updated output of &#x2A;*`Node A`*&#x2A;, because &#x2A;*`Node A`** was not fully executed. The video below shows this in action.
>
> [Video: flows-dependency.mp4]

## Common Flow Patterns [#common-flow-patterns]

Understanding these common patterns will help you design more effective and efficient flows.

### Linear Pipeline [#linear-pipeline]

A sequential process where each step builds on the last. This is the most common pattern.

* **Pattern**: `Node A → Node B → Node C`
* **Use Case**: A content creation pipeline, like turning a prompt into an enhanced image.

[Video: flows-linear.mp4]

### One-to-Many [#one-to-many]

Use a single input to create multiple, parallel outputs.

* **Pattern**: `Node A → [Node B, Node C, Node D]`
* **Use Case**: A/B testing different prompts or applying different styles to the same source image.

![One-to-Many](/sockets-one-to-many.jpg)

### Many-to-One [#many-to-one]

Combine multiple inputs into a single node that can process them as a batch.

* **Pattern**: `[Node A, Node B, Node C] → Node D`
* **Use Case**: Analyze multiple images at once to derive their common characteristics.

![Many-to-One](/sockets-many-to-one.jpg)

### Combined Patterns [#combined-patterns]

By combining these patterns, you can build sophisticated workflows tailored to complex tasks. This approach allows you to tackle many parts of a project within a single canvas, managing everything from copy and images to videos and 3D assets. You can start from a single inception point and then branch out to explore different creative possibilities and ideas in parallel.

For example, you might use a one-to-many pattern to generate several variations of an image from a single prompt, then a many-to-one pattern to have a vision model analyze and select the best option, while another branch generates marketing copy based on the initial concept.

![Combine](/flows-combine.jpg)

In the example above, the flow starts with a single prompt to generate two different styles of photoshoots, demonstrating a **one-to-many** pattern for creative exploration. Selected images are then combined with various clothing items to create new outfits, a form of **many-to-one** processing. Finally, these new images are fed into a **linear pipeline** to generate video animations. This complex workflow lives on a single canvas, streamlining a creative project from initial concept to final photo and video deliverables.

## Building Effective Flows [#building-effective-flows]

### Planning Your Flow [#planning-your-flow]

1. **Define the Goal**: What is the final output you want to create? What are your starting inputs?
2. **Break It Down**: Identify the discrete steps needed to get from input to output. Each step is likely a node.
3. **Choose Your Nodes**: Select the right AI models and utility nodes for each step, considering the balance of cost, speed, and quality.

### Flow Design Principles [#flow-design-principles]

* **Left-to-Right Data Flow**: Always arrange your nodes so that data flows consistently from left to right. This makes your workflow intuitive to read.
* **Logical Grouping**: Place related nodes together. Create distinct areas for input preparation, core processing, and output exploration.
* **Clear Naming**: Rename your nodes to be descriptive. `Product Description` is much clearer than `Text`. Double-click a node's title to rename it.

> [!NOTE] Organize Your Canvas
>
> Organize your canvas for clarity. A well-organized flow is easier to understand, debug, and share.

## Advanced Flow Techniques [#advanced-flow-techniques]

### Conditional Logic [#conditional-logic]

While Fuser doesn't have explicit `if`/`else` nodes, you can create conditional logic by building different branches and manually choosing which one to execute for the final output.

### Batch Processing [#batch-processing]

Process multiple items at once by connecting them to an input socket that accepts multiple properties . This is highly efficient for processing large numbers of items.

### Creating Templates [#creating-templates]

If you create a flow you use often, save it as a template. This allows you to reuse successful patterns quickly.

1. Build and test your flow.
2. Add text nodes to document how it works.
3. In the **Share Panel**, choose "**Allow Remixing**".

### Cost and Speed [#cost-and-speed]

* Use faster, cheaper models during development (e.g., Flux Dev or OpenRouter's free models).
* Switch to higher-quality, more expensive models for final production runs.
* Design flows with parallel branches to run independent operations simultaneously, saving time.

## What's Next? [#whats-next]

Now that you understand the principles of building flows:

1. **[Sockets & Connections](https://docs.fuser.studio/docs/interface/sockets.md)** - Learn the details of how data moves between nodes.
2. **[Templates](https://docs.fuser.studio/docs/interface/templates.md)** - Explore pre-built flows to see these patterns in action.
3. **[AI Providers](https://docs.fuser.studio/docs/interface/providers.md)** - Discover the services that power your flows.
4. **[Sharing & Collaboration](https://docs.fuser.studio/docs/interface/sharing.md)** - Share your creations with others.