@tb.p/sd-manager
v1.0.0
Published
Scan and manage Stable Diffusion files with CivitAI integration
Downloads
78
Maintainers
Readme
SD Manager
A NPX-runnable tool to scan, identify, and manage Stable Diffusion files with CivitAI integration.
Features
- 🔍 Recursively scans directories for Stable Diffusion files (checkpoints, LoRAs, VAEs, embeddings, etc.)
- 🌐 Integrates with CivitAI API to fetch model metadata
- 💾 Stores file information in SQLite database (located in
~/.sd-manager/) - 🎨 Beautiful web UI with tabbed interface organized by file type
- ⚡ Built with Express.js and Alpine.js
Installation
npm installUsage
As NPX Tool
npx @tb.p/sd-manager --dir "path/to/models"Example:
npx @tb.p/sd-manager --dir "C:\stable-diffusion\models"The tool will:
- Find an available port automatically
- Start a web server and display the URL in the terminal
- Automatically open the browser to the web interface
- Allow you to scan and check files against CivitAI API via the web interface
Direct Execution
node cli.js --dir "path/to/models"Web Interface
Once running, open your browser to http://localhost:3000:
- Scan & Check with CivitAI: Scans the directory and checks each file against CivitAI API
- Refresh: Reloads files from the database
- Tabs: Filter files by type (Checkpoint, LoRA, VAE, etc.)
Database
File information is stored in SQLite at:
- Windows:
%USERPROFILE%\.sd-manager\files.db - Linux/Mac:
~/.sd-manager/files.db
Supported File Types
- Checkpoints (
.ckpt,.safetensors) - LoRAs (
.safetensors,.pt) - VAEs (
.pt,.ckpt,.safetensors) - Embeddings (
.pt,.bin) - ControlNet (
.safetensors,.pt,.pth) - Upscalers (
.pth,.pt) - Hypernetworks (
.pt) - LyCORIS (
.safetensors,.pt)
API Endpoints
GET /api/scan- Scan directory for SD filesPOST /api/scan-and-check- Scan and check all files with CivitAIPOST /api/check-civitai- Check a single file with CivitAIGET /api/files- Get all files from database
License
MIT
