workflow-comfyui-single-image-to-lora-flux  by lovisdotio

Create custom LoRA models from a single image

Created 2 months ago
258 stars

Top 98.2% on SourcePulse

GitHubView on GitHub
Project Summary

This workflow automates the creation of custom LoRA models for ComfyUI using a single reference image. It leverages LLM (Gemini) for prompt generation and FLUX.1 Kontext for image variations, making it accessible for users looking to quickly generate personalized LoRA models without extensive manual prompt engineering or dataset curation.

How It Works

The process begins with Gemini analyzing a reference image to generate 20 diverse prompts. These prompts are then used by FLUX.1 Kontext to create 20 consistent image variations. The workflow automatically organizes these images into a dataset with corresponding caption files, and then integrates LoRA training directly within ComfyUI, streamlining the entire LoRA creation pipeline.

Quick Start & Requirements

  • Install: Install required custom nodes via the ComfyUI Manager: ComfyUI-Impact-Pack, WAS Node Suite, ComfyUI_Fill-Nodes, ComfyUI-KJNodes, comfyui_tinyterranodes, ComfyUI-FluxTrainer, ComfyUI-SP-Nodes, ComfyUI-Custom-Scripts.
  • Models: Download FLUX.1 Kontext model (flux1-dev-kontext_fp8_scaled.safetensors), FLUX VAE (ae.safetensors), FLUX CLIP encoders (clip_l.safetensors, t5xxl_fp8_e4m3fn_scaled.safetensors), and training models (flux1-dev.safetensors, t5xxl_fp16.safetensors).
  • Setup: Load workflow.json, connect a reference image, set Gemini API key, configure trigger word, dataset folder, and output path.
  • Links: FLUX.1 Kontext Paper

Highlighted Details

  • Automated LLM-based prompt generation for diverse image variations.
  • Integrated LoRA training directly within the ComfyUI environment.
  • Streamlined dataset creation with automatic image and caption saving.

Maintenance & Community

No specific information on maintainers, community channels, or roadmap is provided in the README.

Licensing & Compatibility

The license is not specified in the README. Compatibility for commercial use or closed-source linking is not detailed.

Limitations & Caveats

The workflow requires specific custom nodes and several large model files to be downloaded and configured correctly. The README does not specify the operating system requirements or provide details on potential performance bottlenecks or known issues.

Health Check
Last Commit

2 months ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
0
Star History
9 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.