overview.md 2.48 KB
Newer Older
YiYi Xu's avatar
YiYi Xu committed
1
2
3
4
5
6
7
8
9
10
11
12
<!--Copyright 2025 The HuggingFace Team. All rights reserved.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on
an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the
specific language governing permissions and limitations under the License.
-->

Steven Liu's avatar
Steven Liu committed
13
# Overview
YiYi Xu's avatar
YiYi Xu committed
14

Steven Liu's avatar
Steven Liu committed
15
16
> [!WARNING]
> Modular Diffusers is under active development and it's API may change.
YiYi Xu's avatar
YiYi Xu committed
17

Steven Liu's avatar
Steven Liu committed
18
Modular Diffusers is a unified pipeline system that simplifies your workflow with *pipeline blocks*.
YiYi Xu's avatar
YiYi Xu committed
19

Steven Liu's avatar
Steven Liu committed
20
21
- Blocks are reusable and you only need to create new blocks that are unique to your pipeline.
- Blocks can be mixed and matched to adapt to or create a pipeline for a specific workflow or multiple workflows.
YiYi Xu's avatar
YiYi Xu committed
22

Steven Liu's avatar
Steven Liu committed
23
The Modular Diffusers docs are organized as shown below.
YiYi Xu's avatar
YiYi Xu committed
24

Steven Liu's avatar
Steven Liu committed
25
## Quickstart
YiYi Xu's avatar
YiYi Xu committed
26

Steven Liu's avatar
Steven Liu committed
27
- A [quickstart](./quickstart) demonstrating how to implement an example workflow with Modular Diffusers.
YiYi Xu's avatar
YiYi Xu committed
28

Steven Liu's avatar
Steven Liu committed
29
## ModularPipelineBlocks
YiYi Xu's avatar
YiYi Xu committed
30

Steven Liu's avatar
Steven Liu committed
31
32
33
34
35
- [States](./modular_diffusers_states) explains how data is shared and communicated between blocks and [`ModularPipeline`].
- [ModularPipelineBlocks](./pipeline_block) is the most basic unit of a [`ModularPipeline`] and this guide shows you how to create one.
- [SequentialPipelineBlocks](./sequential_pipeline_blocks) is a type of block that chains multiple blocks so they run one after another, passing data along the chain. This guide shows you how to create [`~modular_pipelines.SequentialPipelineBlocks`] and how they connect and work together.
- [LoopSequentialPipelineBlocks](./loop_sequential_pipeline_blocks) is a type of block that runs a series of blocks in a loop. This guide shows you how to create [`~modular_pipelines.LoopSequentialPipelineBlocks`].
- [AutoPipelineBlocks](./auto_pipeline_blocks) is a type of block that automatically chooses which blocks to run based on the input. This guide shows you how to create [`~modular_pipelines.AutoPipelineBlocks`].
YiYi Xu's avatar
YiYi Xu committed
36

Steven Liu's avatar
Steven Liu committed
37
## ModularPipeline
YiYi Xu's avatar
YiYi Xu committed
38

Steven Liu's avatar
Steven Liu committed
39
40
41
- [ModularPipeline](./modular_pipeline) shows you how to create and convert pipeline blocks into an executable [`ModularPipeline`].
- [ComponentsManager](./components_manager) shows you how to manage and reuse components across multiple pipelines.
- [Guiders](./guiders) shows you how to use different guidance methods in the pipeline.