SwarmUI Preset Deleter v1.0: Bulk T2I Preset Deletion via CLI #609
DevNullInc
started this conversation in
Show and tell
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello SwarmUI community,
I'm releasing a small command-line utility, SwarmUI Preset Deleter v1.0, designed to address a specific need for users managing a large number of Text-to-Image (T2I) presets within SwarmUI.
Background and Motivation:
As some users may have experienced (including myself), importing various preset collections into SwarmUI can lead to a rapid accumulation of presets in the
t2i_presets
collection of theUsers.ldb
database. While SwarmUI provides preset management features, bulk deletion of presets is not directly supported, making it a time-consuming task to clear out unwanted presets manually through the UI.To address this, I developed the SwarmUI Preset Deleter as a command-line tool for efficiently clearing the entire
t2i_presets
collection.Technical Details and Functionality:
Users.ldb
). It utilizes the LiteDB C# library to connect to the database and execute a targeted deletion operation.t2i_presets
collection within theUsers.ldb
database. It is designed to remove all documents within this collection, effectively wiping all Text-to-Image presets.Users.ldb
file by combining the provided installation directory with the expected relative path (e.g.,<InstallDir>/Data/Users.ldb
).t2i_presets
collection:_db.GetCollection<Preset>("t2i_presets").DeleteAll();
try-catch
exception handling, primarily for scenarios such as incorrect directory paths or database access issues.win-x64
).Key Features:
.exe
file (and associated DLLs and data files) for easy deployment on Windows.Important Considerations and Warnings (Data Loss):
This tool is designed for permanent data deletion. It is crucial to understand and acknowledge the following before use:
Users.ldb
file prior to execution. Data recovery after using this tool is only possible from a backup.GitHub Release and Download:
The SwarmUI Preset Deleter v1.0 is available for download as a self-contained executable (ZIP archive) on the GitHub Releases page:
https://github.com/DevNullInc/SwarmUI-Preset-Deleter/releases/tag/v1.0
This utility is offered as a basic solution to a specific workflow issue. I welcome feedback from the SwarmUI community, including:
This is a simple tool, but hopefully, it can be helpful to SwarmUI users who need to quickly manage their T2I preset collections.
Thank you,
Beta Was this translation helpful? Give feedback.
All reactions