# comfyui-workspace-manager
**Repository Path**: pythonzz/comfyui-workspace-manager
## Basic Information
- **Project Name**: comfyui-workspace-manager
- **Description**: No description available
- **Primary Language**: Unknown
- **License**: GPL-3.0
- **Default Branch**: aller
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 0
- **Created**: 2024-04-30
- **Last Updated**: 2024-04-30
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
# ☕️ ComfyUI Workspace Manager - Comfyspace
A ComfyUI workflow management extension to **organize and manage all your workflows, models and generated images in one place**. Seamlessly switch between workflows, track version history and image generation history, 1 click install models from Civit ai, browse/update your installed models
If you have questions or suggestions, please [join our Discord](https://discord.gg/HHvfEurv2Z)!
## Installation
### [Option 1] via ComfyUI Manager (Preferred)
Simply search for “ComfyUI Workspace Manager”, install, and restart ComfyUI.
### [Option 2] via git
Like any other custom node installation, in your ComfyUI root folder
```
cd custom_nodes && git clone https://github.com/11cafe/comfyui-workspace-manager.git
```
and restart your ComfyUI.
It is recommended to do git clone than downloading zip folder, because you can get latest updates by `git pull`!
## Features
- 🔁Effortlessly switch between different workflows in your workspace. 1click open workflow in new browser tab.
- [new!] **Model manager**: 1click install models from civitai to `models/` subfolder of the matching model type, browse all your installed models and drag and drop to insert "load model_type" node into workflow, automatic detect and install missing models for workflow from civit ai and hugging face
- 🗂️Organize workflows with folders, 🏷️tags
- 🤏**Drag and drop** to insert subworkflows into current flow.
- 📂Saves all your workflows in a single folder (by default under `/ComfyUI/my_workflows`), customize this location in Settings
- 🖼️Gallery and thumbnail: Every image/video you generate will be saved in the gallery of the current workflow. You can set any image in the gallery as the cover photo of the workflow
- 🕛**Version control** of workflow, never lose any changes (Everytime you press save, it will log a new version in history. you can easily revert back to any versions like git)
- **Bulk import/export** workflows into your workspace or select all to download into .zip
- 📑Quickly duplicate flow in right-click menu
- cloud sync & backup workspace so you will never lose your data (Upcoming!)
- One-click share workflow (Upcoming!)
Recommend using Chrome browser for the best experience. Safari doesn't work well. Edge or firefox should be fine too.
[中文版教程](https://www.uisdc.com/workspace-manager) [Roadmap](https://github.com/orgs/11cafe/projects/1/views/1)
### v2.0 Coming soon! Two-way sync with local folder, select model install path
- Enable two way sync with selected local folder so you can move files using File Explore or Finder in your OS to add them into workspace!
- Select models downloading folder. Especially useful for people sharing models with Automatic111 or using external /models path
- Add models thumbnails image by putting a image file with the same name in models folder
- One click sharing to cloud to easily backup your workflows to cloud
### v1.7 ✨New ComfyUI model manager, view all your models, browse and install models from civit ai, find missing models in workflow automatically in civit ai and hugging face!
open workflow in new tab, 1click model install from civitai, automatic install missing models for workflow, view image gen metadata in gallery (prompt, sampler, models used).
### V1.5
Manually save your workflow by pressing the 💾 button, or ⌨**Shift+S** shortcut (customize this shortcut in Settings). Every time you save, it will create a new record in **Version History**. You can go back and switch versions in version history like git.
Every image/video you generate will be saved in the gallery of the current workflow. You can set any image in the gallery as the cover photo of the workflow.
switch between flows:
🤏drag and drop to insert sub-workflow:
Bulk import flows:
add tags to flow:
Workflow operations: Manual Save, Download, Discard unsaved changes:
duplicate flow by right click menu option:
### Where are my workflow and workspace data stored?
🍺 All your workflows are saved in a folder in `/ComfyUI/my_workflows`, you can change this path in settings.
⚠️Note: this is a ONE-WAY sync folder by default, that will only reflect changes made from your ComfyUI workspace browser; If you add some files manually using your OS file system (e.g. Finder in MacOS, File Explorer in Windows), workspace manager will not be able to pickup those changes. You need to use the "Import" button in files side bar to add new files to workspace manager.
All your data is primarily stored in your browser cache (IndexDB) and backedup in your disk under `/ComfyUI/custom_nodes/comfyui-workspace-manager/db/`. Press F12 or Inspect in right click browser menu, go to Application -> IndexedDB -> comfyui_workspace_db to see your data (workflows, version history, gallery, etc.)
### How do I save my workflow?
Save your workflow by either clicking the 💾 floppy disk icon button or ⌨**Shift+S** shortcut (customize this shortcut in Settings)
Every time you save, it will create a new record in **Version History**. You can go back and switch versions in version history like git.
By default, We also enabled auto-saving your current workflow as a cache in case you forgot to save it manually. It will NOT affect or change your manually saved versions. You can always click **"Discard unsaved changes"** to instantly revert back to your last manually saved version.
‼️**You can disable this auto-saving behabior in Settings:**
**Looking for colaborators and coworkers** to develop this ComfyUI project management tool. If you know React, Python or ML model deployment, please reach out to weixuanfu01@gmail.com We want to make it easy to **manage, share and deploy** ComfyUI project.
## Upcoming Features
1. 1-Click Install Models
Often when you import a json workflow from online, it will show lots of missing nodes or models errors, we will provide easy one-click install for missing models from Hugging face and Civiti
2. Modular
Modern software development project are all modularized, the whole system is broken down into different modules. In ComfyUI each custom node is a module and should be self contained and easy to install and depend on from other modules. So that the modules (custom nodes) can be easily reused across projects.
➡️ We need something like web bundler, e.g. webpack, vite. This will make each custom node self contained and has a clear definition of its dependency.
3. Multi workflow project
Now you can only work on one workflow at a time, this limits the potential to build large scale workflows that consists multiple sub-workflows parts. Each workflow can be seen as a custom node. You should be able to easily convert one workflow into one custom node. You can reuse workflow/custom node across your project.
➡️ We need a cross workflow, project management tool, like VSCode editor
4. Cloud running / easy deployment
Right now you need to have python and GPU server up to run ComfyUI or Automatic111, that’s really painful for people who do not own a GPU. You should be able to run UI independently without paying for GPU💰.
➡️ Share and deploy your workflow to cloud in 1click and other people can easily run in browser using cloud GPU with no setup. It should be as easy as running Google Docs or Figma.
## Beta Preview
We're constantly pushing new features in beta branch, and only wait til it's thoroghly tested then push it to main. But if you would like to join our Beta Preview Program, you can receive latest feature updates pre-launch! Here is how to switch to beta, it requires you have some basic knowledge about command line and git.
- Make sure you have [git installed](https://git-scm.com/downloads)
- Open your terminal, go to the ComfyUI directory (where you usually start your python server by `python main.py`
- in ComfyUI root directory, `cd custom_nodes && cd comfyui-workspace-manager`
- inside custom_nodes/comfyui-workspace-manager, do `git fetch origin beta && git checkout beta`, you should see something like:
```
From https://github.com/11cafe/comfyui-workspace-manager
* branch beta -> FETCH_HEAD
Switched to branch 'beta'
Your branch is up to date with 'origin/beta'.
```
- now go back to ComfyUI restart your python server by `python main.py`
‼️ Be careful that beta branch can be unstable, so please please make sure you have backups for all your workflows! **Before switching to beta, please make a copy of these folders somewhere:**
`ComfyUI/custom_nodes/comfyui-workspace-manager/db`
or for extra safety, you can make a copy of the entire `ComfyUI/custom_nodes/comfyui-workspace-manager/` folder
if anything goes wrong, you can always paste back these folders. Also, you should have your /my_workflows folder (workspace save directory) in safe place always
If anything goes wrong, and you want to revert back to main, please do the following:
- inside custom_nodes/comfyui-workspace-manager, do `git checkout main`, then restart your python server and you are back into main branch!
## Credits
ComfyUI: https://github.com/comfyanonymous/ComfyUI
ComfyUI Browser: https://github.com/talesofai/comfyui-browser (Media display code for reference)
And thanks to all custom node creators building the community!
## Dev
1. Clone ComfyUI
`git clone https://github.com/comfyanonymous/ComfyUI`
follow the install and setup instructions of ComfyUI README
2. Clone Workspace Manager
in /ComfyUI folder
```
cd custom_nodes && git clone https://github.com/11cafe/comfyui-workspace-manager.git
```
3. npm install
inside `/ComfyUI/custom_nodes/comfyui-workspace-manager`
do `cd ui && npm install`
this will install all node dependencies
4. build and run
inside `/ComfyUI/custom_nodes/comfyui-workspace-manager/ui`
`npm run build --watch`
this command will watch for your file changes and automatically rebuild, you just need to refresh to see your changes in browser everyting you change some code
5. run ComfyUI server
inside `/ComfyUI`
do `python main.py` or `python3 main.py` depending on your version
#### IndexDB trouble shooting
If you see indexdb version mismatch error in console that looks like:
```
VersionError: The requested version (10) is less than the existing version (30)."
name
:
"DatabaseClosedError"
```
please delete indexdb manually F12 Dev tools -> Application -> IndexDB -> WorkspaceManagerDB
and delete localstorage.WORKSPACE_INDEXDB_BACKFILL
only do this if you are a developer