Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d424f67948 | ||
|
|
838122ae67 | ||
|
|
e269117080 | ||
|
|
8910544eba | ||
|
|
9243d704ac | ||
|
|
e9981c1ee7 | ||
|
|
7c25eaeb95 | ||
|
|
d8d96e549b | ||
|
|
5d64bb2395 | ||
|
|
877727695d | ||
|
|
64119e6c90 | ||
|
|
6d5a1f4669 | ||
|
|
8ac04725c9 | ||
|
|
ef0f072891 | ||
|
|
985de6102e | ||
|
|
ecdf1e0995 | ||
|
|
39575f137c | ||
|
|
e993546fa4 | ||
|
|
ce12566998 | ||
|
|
c61dcaad2c | ||
|
|
1ba2d214f6 | ||
|
|
473d96084c |
@@ -0,0 +1,20 @@
|
||||
name: Publish to Comfy registry
|
||||
on:
|
||||
workflow_dispatch:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
paths:
|
||||
- "pyproject.toml"
|
||||
|
||||
jobs:
|
||||
publish-node:
|
||||
name: Publish Custom Node to registry
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Check out code
|
||||
uses: actions/checkout@v4
|
||||
- name: Publish Custom Node
|
||||
uses: Comfy-Org/publish-node-action@main
|
||||
with:
|
||||
personal_access_token: ${{ secrets.REGISTRY_ACCESS_TOKEN }}
|
||||
@@ -1,13 +1,35 @@
|
||||
# ComfyUI Prompt Manager
|
||||
## A custom [ComfyUI](https://github.com/comfyanonymous/ComfyUI) node for Organizing, Generating or Enhancing prompts.
|
||||
|
||||
A custom node for [ComfyUI](https://github.com/comfyanonymous/ComfyUI) for organizing, generating, and enhancing prompts using local llama.cpp models with vision analysis support.
|
||||
|
||||
(**Llama.cpp needs to be installed and accessible from command prompt.**)
|
||||
This addon started off as a simple prompt Manager, to help save and retrieve prompts.
|
||||
But has since evolved to allow generating prompts for Images, video and Image analysis.
|
||||
The new advanced version of the manager, now allows the user to save the entire recipe,
|
||||
as it allows saving the Lora Stacks that goes with a prompt. Supporting Dual Stack for Wan.
|
||||
___
|
||||
For Prompt Generation, it uses an existing install of [llama.cpp](https://github.com/ggerganov/llama.cpp), preventing install conflicts with ComfyUI.
|
||||
Provides options to automatically download Qwen3 and Qwen3VL models.
|
||||
Supports prompt enhancing, image analysis, or custom image processing, with up to 5 images at once.
|
||||
Custom GGUF models can be used if supported by llama.cpp; simply drop them in the models/gguf folder.
|
||||
Users can now set a custom Llama-server path as well as a custom Model Path in ComfyUI's preferences.
|
||||
If a Custom Model Path is added, it will become the default download folder.
|
||||
|
||||
<div align="center">
|
||||
<figcaption>Simple Prompt Generator Usage</figcaption>
|
||||
<img src="docs/prompt_manager.png" alt="Prompt Manager">
|
||||
</div>
|
||||
|
||||
|
||||
<div align="center">
|
||||
<figcaption>Advanced Prompt Generator Usage</figcaption>
|
||||
<img src="docs/prompt_generator_advanced.png" alt="Prompt Manager">
|
||||
</div>
|
||||
|
||||
<div align="center">
|
||||
<figcaption>Prompt Manager Advanced, with Lora support</figcaption>
|
||||
<img src="docs/prompt_manager_advanced.png" alt="Prompt Manager">
|
||||
</div>
|
||||
|
||||
|
||||
### Key features:
|
||||
### Prompt Manager:
|
||||
- **Category Organization**: Create and manage multiple categories to organize your prompts
|
||||
@@ -16,22 +38,45 @@ A custom node for [ComfyUI](https://github.com/comfyanonymous/ComfyUI) for organ
|
||||
- **LLM Input Toggle**: When in use, display of categories and prompt is disabled, allowing user to switch category and save.
|
||||
- **Persistent Storage**: All prompts saved in your ComfyUI user folder
|
||||
|
||||
### Prompt Manager Advanced:
|
||||
- **All Prompt Manager Features**: Everything from the basic Prompt Manager, plus LoRA integration
|
||||
- **Dual LoRA Stack Support**: Two separate LoRA stack inputs/outputs for complex workflows (e.g., Wan video with different LoRAs for image and video)
|
||||
- **Visual LoRA Tags**: See connected LoRAs as clickable tags with strength values
|
||||
- **Toggle LoRAs On/Off**: Click any LoRA tag to enable/disable it without disconnecting
|
||||
- **Editable Strengths**: Click the strength value on any tag to adjust it inline
|
||||
- **Save LoRAs with Prompts**: When you save a prompt, the current LoRA configuration is saved with it
|
||||
- **Override Mode**: Toggle "Override Lora" to ignore connected inputs and use only saved preset LoRAs
|
||||
- **Merge Mode**: When override is off, connected LoRAs are merged with saved presets
|
||||
- **LoRA Manager Integration**: If [ComfyUI-Lora-Manager](https://github.com/infantesimone/ComfyUI-Lora-Manager) is installed, hovering over LoRA tags shows preview images
|
||||
- **Missing LoRA Detection**: LoRAs that aren't found on your system are highlighted in red
|
||||
|
||||
### Apply LoRA Stack:
|
||||
- **Simple LoRA Application**: Takes a LORA_STACK and applies it to your model/clip
|
||||
- **Works with Any Stacker**: Compatible with LoRA Manager's stacker or any node outputting LORA_STACK
|
||||
- **Optional CLIP**: CLIP input is optional for workflows that don't need it
|
||||
|
||||
### Prompt Generator
|
||||
- **Three Generation Modes**: Enhance text prompts, analyze images, or analyze images with custom instructions
|
||||
- **Prompt Enhancement**: Transform basic prompts into detailed descriptions using local LLMs
|
||||
- **Vision Analysis**: Analyze images with Qwen3VL models to generate detailed descriptions
|
||||
- **Custom Image Analysis**: Provide your own instructions for image analysis
|
||||
- **JSON Output**: Optional structured JSON output with scene breakdown
|
||||
- **Automatic Server Management**: Starts/stops llama.cpp server as needed
|
||||
- **Smart Model Selection**: Auto-selects appropriate model (vision or text) based on mode
|
||||
- **Model Preferences**: Set preferred models in ComfyUI Settings for automatic selection
|
||||
- **Thinking Support**: Support Thinking models to perform deeper generative reasoning.
|
||||
- **Automatic Server Management**: Starts/stops llama.cpp server as needed, with automatic shut off at exit.
|
||||
- **Smart Model Selection**: Auto-selects appropriate model (vision or text) based on mode or Thinking mode.
|
||||
|
||||
### Prompt Generator Options
|
||||
- **Model Selection**: Choose from local models or download Qwen3 (1.7B/4B/8B) and Qwen3VL (4B/8B) from HuggingFace
|
||||
- **Model Selection**: Choose from local models or download Qwen3, Qwen3VL and Qwen3VL Thinking models from HuggingFace
|
||||
- **Auto-Download**: Automatically downloads both model and required mmproj files for vision models
|
||||
- **Context Size**: Adjustable context window (512-32768 tokens)
|
||||
- **LLM Parameters**: Fine-tune temperature, top_k, top_p, min_p, repeat_penalty
|
||||
- **Custom Instructions**: Override default system prompt for different enhancement styles
|
||||
- **LLM Parameters**: Fine-tune temperature, top_k, top_p, min_p, repeat_penalty and context size.
|
||||
- **Custom Instructions**: Override default system prompt for different enhancement styles.
|
||||
- **Extra Image Inputs**: Combine up to 5 images to generate your prompt.
|
||||
- **Console Debugging**: Enable outputing the entire process to the console for debugging purposes.
|
||||
|
||||
### Preference Options
|
||||
- Set choices for prefered Model for both base mode and VL model.
|
||||
- Set new default model location, previous folder (gguf and llm) will still be scanned, but model will save in new default.
|
||||
- Set custom Location for Llama.cpp. If Llama.cpp was not added to the system Path, this option let's you specify it's location.
|
||||
|
||||
## Installation
|
||||
|
||||
@@ -44,17 +89,21 @@ A custom node for [ComfyUI](https://github.com/comfyanonymous/ComfyUI) for organ
|
||||
```bash
|
||||
git clone https://github.com/FranckyB/ComfyUI-Prompt-Manager.git
|
||||
```
|
||||
|
||||
3. Install dependencies:
|
||||
```bash
|
||||
cd ComfyUI-Prompt-Manager
|
||||
pip install -r requirements.txt
|
||||
```
|
||||
|
||||
4. Install llama.cpp. It can be found here: [llama.cpp install](https://github.com/ggml-org/llama.cpp/blob/master/docs/install.md)
|
||||
|
||||
5. If you have them, place your .gguf models in the models/gguf folder. (Create folder if not present)
|
||||
|
||||
4. Install [llama.cpp](https://github.com/ggml-org/llama.cpp/tree/master)
|
||||
Windows:
|
||||
```bash
|
||||
winget install llama.cpp
|
||||
```
|
||||
Linux:
|
||||
```bash
|
||||
brew install llama.cpp
|
||||
```
|
||||
5. If you have them, place your .gguf models in the models/gguf folder or set in prererences your preferred folder path.
|
||||
|
||||
6. Restart ComfyUI
|
||||
|
||||
@@ -67,6 +116,25 @@ A custom node for [ComfyUI](https://github.com/comfyanonymous/ComfyUI) for organ
|
||||
3. **Choose a Prompt**: Select a saved prompt from the name dropdown
|
||||
4. **Connect prompt output**: Connect Prompt Manager output to your clip text encode node.
|
||||
|
||||
### Prompt Manager Advanced
|
||||
|
||||
1. **Add the Node**: Add Node → Prompt Manager → Prompt Manager Advanced
|
||||
2. **Connect LoRA Stackers**: Connect LoRA stacker nodes (e.g., from LoRA Manager) to `lora_stack_a` and/or `lora_stack_b` inputs
|
||||
3. **View LoRA Tags**: Connected LoRAs appear as clickable tags showing name and strength
|
||||
4. **Toggle LoRAs**: Click a tag to enable/disable that LoRA (disabled tags turn gray)
|
||||
5. **Adjust Strength**: Click the strength number on a tag to edit it inline
|
||||
6. **Save with LoRAs**: Click "Save Prompt" to save both the prompt text and current LoRA configuration
|
||||
7. **Override Mode**: Enable "Override Lora" checkbox to ignore connected inputs and use only the saved preset LoRAs
|
||||
8. **Connect Outputs**: Use `lora_stack_a` and `lora_stack_b` outputs with the Apply LoRA Stack node
|
||||
|
||||
### Apply LoRA Stack
|
||||
|
||||
1. **Add the Node**: Add Node → Prompt Manager → Apply LoRA Stack
|
||||
2. **Connect Model**: Connect your model (e.g., from Load Checkpoint) to the `model` input
|
||||
3. **Connect LoRA Stack**: Connect a `LORA_STACK` output (from Prompt Manager Advanced or LoRA Manager's stacker)
|
||||
4. **Optional CLIP**: Connect CLIP if your workflow needs it (some video workflows don't)
|
||||
5. **Use Outputs**: Connect the modified model/clip to your sampler or other nodes
|
||||
|
||||
|
||||
### Prompt Generator
|
||||
|
||||
@@ -77,15 +145,19 @@ A custom node for [ComfyUI](https://github.com/comfyanonymous/ComfyUI) for organ
|
||||
- "Analyze Image" - Generate detailed image descriptions
|
||||
- "Analyze Image with Prompt" - Analyze images with custom instructions
|
||||
3. **Connect inputs**: Connect image for vision modes, or just use text for enhancement mode
|
||||
4. **Output as Json**: Use Format_as_Json to experiment with Json prompts.
|
||||
5. **Push the LLM**: Use enable_thinking to enable the model to perform deeper generative reasoning before producing the final prompt.
|
||||
4. **Save memory**: Toggle "stop_server_after" ON to free VRAM after generation
|
||||
5. **Run Workflow**: Generated prompt displays and can be saved to Prompt Manager
|
||||
|
||||
**Advanced Usage**:
|
||||
1. **Add the Options Node**: Add Node → Prompt Generator Options
|
||||
2. **Connect Options**: Connect the options node to the Prompt Generator Options input
|
||||
3. **Select from available models**: Select from models found in your modeld\gguf folder. Qwen models will be available to download.
|
||||
4. **Adjust settings**: Adjust LLM parameters (temperature, top_k, etc.)
|
||||
5. **Customize LLM**: Customize the default LLM instructions to modify the responses llama returns.
|
||||
3. **Analyze multiple images**: Connect up to 4 additional images, for a total of 5.
|
||||
4. **Select from available models**: Select from models found in your models\gguf folder. Qwen models will be available to download.
|
||||
5. **Adjust settings**: Adjust LLM parameters (temperature, top_k, etc.)
|
||||
6. **Customize LLM**: Customize the default LLM instructions to modify the responses llama returns.
|
||||
7. **Enable Debugging**: Enable complete printout of process to console using show_everything_in_console
|
||||
|
||||
**Qwen models found in options**
|
||||
- Qwen3-1.7B-Q8_0.gguf: Fastest, lowest VRAM (~2GB)
|
||||
@@ -93,17 +165,19 @@ A custom node for [ComfyUI](https://github.com/comfyanonymous/ComfyUI) for organ
|
||||
- Qwen3-8B-Q8_0.gguf: Best quality, highest VRAM (~8GB)
|
||||
- Qwen3VL-4B-Instruct-Q8_0.gguf: Vision model, balanced performance (~5GB VRAM)
|
||||
- Qwen3VL-8B-Instruct-Q8_0.gguf: Vision model, best quality (~9GB VRAM)
|
||||
- Qwen3VL-4B-Thinking-Q8_0.gguf: Vision model, Thinking variant, balanced performance (~5GB VRAM)
|
||||
- Qwen3VL-8B-Thinking-Q8_0.gguf: Vision model, Thinking variant, best quality (~9GB VRAM)
|
||||
|
||||
**Model Management**:
|
||||
- Place gguf files in models/gguf folder
|
||||
- Downloaded models are also placed in this folder.
|
||||
|
||||
**Model Preferences**:
|
||||
- Set preferred models in ComfyUI Settings → Prompt Manager → Model Preferences
|
||||
- **Preferred Base Model**: Used for "Enhance User Prompt" mode (text-only models)
|
||||
- **Preferred Vision Model**: Used for "Analyze Image" modes (Qwen3VL models)
|
||||
- Leave empty to auto-select smallest available model
|
||||
- Changes are saved automatically in ComfyUI settings
|
||||
**Preferences**:
|
||||
Preference settings can be found in ComfyUI Settings → Prompt Manager
|
||||
- **Preferred Base Model**: Name of model used for "Enhance User Prompt" mode (text-only models)
|
||||
- **Preferred Vision Model**: Name of model Used for "Analyze Image" modes (Qwen3VL models)
|
||||
- **Set Default Port** You can set the port used by Llama.cpp
|
||||
- **Close Llama on Exit** By default Llama.cpp with be close on exit.
|
||||
|
||||
## Requirements
|
||||
|
||||
@@ -114,6 +188,7 @@ A custom node for [ComfyUI](https://github.com/comfyanonymous/ComfyUI) for organ
|
||||
- psutil >= 5.9.0
|
||||
- tqdm >= 4.66.0
|
||||
- Pillow >= 10.0.0
|
||||
- colorama
|
||||
- llama-server (from llama.cpp)
|
||||
|
||||
## Troubleshooting
|
||||
@@ -142,8 +217,45 @@ A custom node for [ComfyUI](https://github.com/comfyanonymous/ComfyUI) for organ
|
||||
**Problem**: Generation is slow
|
||||
- **Solution**: Either, Use a smaller quantized model (Q4 instead of Q8) or toggle 'stop_server_after' to quit llama.cpp after generating prompt.
|
||||
|
||||
**Problem**: Default Model used is not what I want
|
||||
- **Solution**: You can set your preferred model in the ComfyUI settings. Simply add its full name, with .gguf extension, for both the VL and base models. Enabling Thinking in the Generator might change what is used for VL models.
|
||||
|
||||
|
||||
## Changelog
|
||||
|
||||
### Version 1.9.0
|
||||
- **New Node: Prompt Manager Advanced** - Extended prompt manager with LoRA stack support
|
||||
- Dual LoRA stack inputs/outputs for complex workflows (Wan video, etc.)
|
||||
- Visual LoRA tags showing name and editable strength values
|
||||
- Toggle LoRAs on/off by clicking tags
|
||||
- Save LoRA configurations alongside prompts
|
||||
- Override mode to ignore connected inputs and use saved presets
|
||||
- Merge mode combines connected LoRAs with saved presets
|
||||
- Missing LoRA detection with visual warnings
|
||||
- Integration with LoRA Manager for hover previews
|
||||
- **New Node: Apply LoRA Stack** - Simple node to apply LORA_STACK to model/clip
|
||||
- Categories and prompts now display in alphabetical order
|
||||
- Fixed dropdown refresh after saving prompts
|
||||
|
||||
### Version 1.8.3
|
||||
- Added option to leave Llama server running when closing ComfyUI.
|
||||
|
||||
### Version 1.8.2
|
||||
- Added custom model path preference and enhance model management
|
||||
|
||||
### Version 1.8.1
|
||||
- Added option to set a custom Llama path in preferences, for those that have specific installs.
|
||||
|
||||
### Version 1.8.0
|
||||
- Added support for Qwen3VL Thinking model variants, with download options thru the Generator Options node.
|
||||
- Model manager now searches for relevant `mmproj` files using model-name components for more reliable vision-model linking.
|
||||
- Detailed console output options (debug logging)
|
||||
- `enable_thinking` toggle to enable/disable the model's reasoning/thinking mode.
|
||||
- Options node now accepts multiple images for analysis.
|
||||
- Better Llama shutdown behavior to force-close the server when Comfy exits.
|
||||
- Uses model-reported sampling params by default when available; the Options node can override them per-parameter.
|
||||
- Moved preference API endpoints and cache handling into `model_manager.py` for cleaner management and persistence.
|
||||
|
||||
### Version 1.7.0
|
||||
- Added three-mode prompt generator: "Enhance User Prompt", "Analyze Image", "Analyze Image with Prompt"
|
||||
- Enhanced vision model workflow with dedicated image analysis modes
|
||||
@@ -152,7 +264,7 @@ A custom node for [ComfyUI](https://github.com/comfyanonymous/ComfyUI) for organ
|
||||
- Added automatic model preference management (separate settings for base and vision models)
|
||||
- Improved model selection with preference fallback to smallest model
|
||||
- Filtered mmproj files from model selection dropdowns
|
||||
- All preferences stored in ComfyUI settings for persistence across updates
|
||||
- Model preferences stored in ComfyUI settings for persistence across updates
|
||||
|
||||
### Version 1.6.0
|
||||
- Added Qwen3VL vision model support for image analysis
|
||||
@@ -165,8 +277,8 @@ A custom node for [ComfyUI](https://github.com/comfyanonymous/ComfyUI) for organ
|
||||
- Fixed multiple directory support for model search (gguf + LLM folders)
|
||||
|
||||
### Version 1.5.1
|
||||
- LLM output remains avaiable when use llm is off. So it can be edited
|
||||
- Improved Caching detection, any change to options will be detected and force a new ouput
|
||||
- LLM output remains available when use_llm is off, so it can be edited.
|
||||
- Improved caching detection: any change to options will be detected and force a new output.
|
||||
- Improved some UI quirks
|
||||
|
||||
### Version 1.5.0
|
||||
|
||||
+11
-4
@@ -2,27 +2,34 @@
|
||||
ComfyUI Prompt Manager - A simple custom node for saving and reusing prompts
|
||||
A prompt management system for ComfyUI with LLM input support
|
||||
"""
|
||||
__version__ = "1.5.1"
|
||||
__version__ = "1.9.1"
|
||||
__author__ = "François Beaudry"
|
||||
__license__ = "MIT"
|
||||
|
||||
from .prompt_manager import PromptManager
|
||||
from .prompt_manager_advanced import PromptManagerAdvanced
|
||||
from .prompt_generator import PromptGenerator
|
||||
from .prompt_generator_options import PromptGenOptions
|
||||
from .apply_lora_stack import ApplyLoRAStack
|
||||
from .model_manager import get_local_models
|
||||
from server import PromptServer
|
||||
|
||||
NODE_CLASS_MAPPINGS = {
|
||||
"PromptManager": PromptManager,
|
||||
"PromptManagerAdvanced": PromptManagerAdvanced,
|
||||
"PromptGenerator": PromptGenerator,
|
||||
"PromptGenOptions": PromptGenOptions
|
||||
"PromptGenOptions": PromptGenOptions,
|
||||
"ApplyLoRAStack": ApplyLoRAStack
|
||||
}
|
||||
|
||||
NODE_DISPLAY_NAME_MAPPINGS = {
|
||||
"PromptManager": "Prompt Manager",
|
||||
"PromptManagerAdvanced": "Prompt Manager Advanced",
|
||||
"PromptGenerator": "Prompt Generator",
|
||||
"PromptGenOptions": "Prompt Generator Options"
|
||||
"PromptGenOptions": "Prompt Generator Options",
|
||||
"ApplyLoRAStack": "Apply LoRA Stack"
|
||||
}
|
||||
|
||||
|
||||
WEB_DIRECTORY = "./js"
|
||||
|
||||
__all__ = ['NODE_CLASS_MAPPINGS', 'NODE_DISPLAY_NAME_MAPPINGS', 'WEB_DIRECTORY']
|
||||
|
||||
@@ -0,0 +1,58 @@
|
||||
"""
|
||||
ComfyUI Apply LoRA Stack - Apply a LORA_STACK to model and clip
|
||||
"""
|
||||
import folder_paths
|
||||
import comfy.sd
|
||||
import comfy.utils
|
||||
|
||||
|
||||
class ApplyLoRAStack:
|
||||
"""
|
||||
Apply a LoRA stack to a model and optionally a CLIP.
|
||||
Takes a LORA_STACK (list of tuples) and applies each LoRA sequentially.
|
||||
"""
|
||||
|
||||
@classmethod
|
||||
def INPUT_TYPES(s):
|
||||
return {
|
||||
"required": {
|
||||
"model": ("MODEL",),
|
||||
"lora_stack": ("LORA_STACK",),
|
||||
},
|
||||
"optional": {
|
||||
"clip": ("CLIP",),
|
||||
},
|
||||
}
|
||||
|
||||
RETURN_TYPES = ("MODEL", "CLIP")
|
||||
RETURN_NAMES = ("model", "clip")
|
||||
FUNCTION = "apply_stack"
|
||||
CATEGORY = "Prompt Manager"
|
||||
|
||||
def apply_stack(self, model, lora_stack, clip=None):
|
||||
if not lora_stack:
|
||||
return (model, clip)
|
||||
|
||||
model_out = model
|
||||
clip_out = clip
|
||||
|
||||
for lora_name, model_strength, clip_strength in lora_stack:
|
||||
# Skip if no strength
|
||||
if model_strength == 0 and clip_strength == 0:
|
||||
continue
|
||||
|
||||
# Get the LoRA path
|
||||
lora_path = folder_paths.get_full_path("loras", lora_name)
|
||||
if lora_path is None:
|
||||
print(f"[ApplyLoRAStack] Warning: LoRA not found: {lora_name}")
|
||||
continue
|
||||
|
||||
# Load the LoRA
|
||||
lora = comfy.utils.load_torch_file(lora_path, safe_load=True)
|
||||
|
||||
# Apply to model and clip
|
||||
model_out, clip_out = comfy.sd.load_lora_for_models(
|
||||
model_out, clip_out, lora, model_strength, clip_strength
|
||||
)
|
||||
|
||||
return (model_out, clip_out)
|
||||
@@ -1,24 +1,4 @@
|
||||
{
|
||||
"Character": {
|
||||
"Cyberpunk Hacker Elite": {
|
||||
"prompt": "A skilled cyberpunk hacker sitting in a dimly lit apartment surrounded by multiple holographic screens displaying code and data streams, wearing tactical tech-wear with embedded LED strips and circuit patterns, augmented reality glasses with information overlays, cybernetic arm implants with exposed mechanical components, messy workstation with scattered computer parts and energy drink cans, large window showing dystopian megacity skyline with towering skyscrapers covered in neon advertisements and holographic billboards, heavy rain creating atmospheric reflections, purple and cyan neon color palette, volumetric fog and light rays, highly detailed futuristic technology, photorealistic rendering, cyberpunk 2077 aesthetic, moody atmospheric lighting, 8k ultra detailed"
|
||||
},
|
||||
"Epic Fantasy Warrior": {
|
||||
"prompt": "A powerful fantasy warrior standing in a heroic pose on a battlefield at dusk, wearing intricately detailed plate armor with ornate engravings and battle-worn scratches, muscular athletic build with defined features, holding a legendary glowing sword with runes etched along the blade, flowing cape billowing in the wind, dramatic cinematic lighting with rays of sunlight breaking through storm clouds, particles of dust and embers floating in the air, photorealistic rendering with exceptional attention to material details including metallic reflections on armor, leather straps and buckles, war paint on face, intense determined expression, epic fantasy art style, 8k ultra high resolution, masterpiece quality"
|
||||
},
|
||||
"Futuristic Sci-Fi Explorer": {
|
||||
"prompt": "A lone futuristic explorer standing on the edge of an alien cliff overlooking a vast extraterrestrial landscape, wearing an advanced high-tech environmental suit with glowing blue energy lines and holographic display panels, sleek helmet with transparent visor showing determined face, multiple utility packs and scientific equipment attached to suit, alien planet with multiple moons visible in the purple-tinted sky, bioluminescent alien flora scattered across rocky terrain, dramatic volumetric lighting with atmospheric fog, neon accents and technological details, sense of wonder and discovery, photorealistic sci-fi concept art style, cinematic composition, 8k resolution, highly detailed textures on suit materials and alien environment"
|
||||
},
|
||||
"Mystical Elven Mage": {
|
||||
"prompt": "An elegant elven sorcerer with flowing silver hair and luminescent purple eyes, wearing elaborate flowing robes made of enchanted fabric with intricate magical runes and celestial patterns, holding an ancient wooden staff topped with a glowing crystal, standing in a mystical forest clearing surrounded by floating magical orbs and swirling ethereal energy, ancient stone ruins covered in moss and glowing elvish inscriptions in background, fireflies and magical particles dancing through the air, moonlight filtering through dense canopy creating dappled light patterns, fantasy illustration style with painterly quality, rich jewel tones and magical bioluminescence, highly detailed character design, masterpiece quality, 8k resolution"
|
||||
},
|
||||
"Noble Medieval Knight": {
|
||||
"prompt": "A distinguished medieval knight in full ceremonial plate armor standing in the grand hall of a castle, armor polished to a mirror shine with gold inlay and family crest emblazoned on chest plate, red velvet cape with golden trim, holding ornate longsword point-down in formal stance, helmet tucked under arm revealing weathered noble face with graying beard, stone castle interior with tall Gothic arched windows, sunlight streaming through stained glass creating colorful patterns on floor, heraldic banners hanging from walls, torch sconces providing warm ambient lighting, sense of honor and nobility, historical accuracy in armor design and architecture, oil painting aesthetic with rich colors, highly detailed, 4k quality"
|
||||
},
|
||||
"Post-Apocalyptic Survivor": {
|
||||
"prompt": "A rugged post-apocalyptic survivor standing among ruins of a destroyed city, wearing makeshift armor cobbled together from scavenged materials including leather, metal plates, and tactical gear, face covered with weathered gas mask with cracked lenses, carrying a modified rifle and worn backpack full of supplies, background showing crumbling skyscrapers overgrown with vegetation, abandoned vehicles rusted and covered in vines, dramatic overcast sky with sun breaking through clouds, dust particles and debris floating in air, desaturated color palette with touches of rust orange and olive green, gritty realistic style, highly detailed weathering and wear on all materials, cinematic composition, 4k photorealistic quality"
|
||||
}
|
||||
},
|
||||
"Composition": {
|
||||
"Aerial Bird's Eye View": {
|
||||
"prompt": "Dramatic overhead composition shot from directly above subject, unique bird's eye perspective offering unusual and striking viewpoint, flattened perspective creating abstract qualities and geometric patterns, symmetry and patterns visible from above, sense of scale with subject appearing small against larger environment, drone photography aesthetic with perfect stability, organized chaos of urban patterns or natural formations, top-down view revealing hidden relationships and structures, professional aerial photography with exceptional detail, sharp focus across entire frame, innovative perspective creating wow factor, cinematic quality, 8k ultra high resolution, perfect exposure and color balance"
|
||||
@@ -76,139 +56,5 @@
|
||||
"Underwater Lost City": {
|
||||
"prompt": "An ancient sunken city deep beneath the ocean surface, classical Greek or Roman architecture colonized by colorful coral and marine life, crumbling marble columns and statues covered in barnacles and swaying sea kelp, schools of tropical fish swimming through broken archways, rays of sunlight penetrating from surface creating dramatic volumetric lighting through the water, particles of sediment floating in currents, giant sea turtles and manta rays gliding past ruins, preserved mosaics and frescoes still visible on walls, sense of lost grandeur and the passage of time, turquoise and deep blue water with caustic light patterns on surfaces, highly detailed underwater environment with accurate water physics and light scattering, photorealistic quality, 8k resolution"
|
||||
}
|
||||
},
|
||||
"Illustrious": {
|
||||
"Anime Girl Portrait": {
|
||||
"prompt": "1girl. A beautiful anime girl gazing directly at the viewer with a gentle smile and soft expression on her face. Her long flowing hair frames delicate features. beautiful detailed eyes, long hair, flowing hair, hair between eyes, looking at viewer, slight smile, soft expression, detailed face, smooth skin, delicate features, jewelry, earrings, necklace, upper body, portrait, depth of field, bokeh, soft lighting, rim lighting, cinematic lighting, anime style, illustration, detailed background, blurred background, masterpiece"
|
||||
},
|
||||
"Beach Swimsuit Summer": {
|
||||
"prompt": "1girl. A carefree girl enjoys a perfect summer day at the beach. Ocean waves lap at the shore behind her as she stands with a bright smile under the sunny sky. Water droplets glisten on her skin in the warm sunlight. bikini, swimsuit, beach, ocean, sea, waves, shore, sand, blue sky, summer, sunny, sunlight, lens flare, beach umbrella, palm tree, standing, hand on hip, wet, wet skin, water droplets, smile, happy, cheerful, straw hat, sun hat, sunglasses, long hair, ponytail, side-tie bikini bottom, frills, ribbon, beautiful detailed face, depth of field, blurry background, bokeh, bright colors, vibrant, warm colors, anime style, masterpiece"
|
||||
},
|
||||
"Café Reading Books": {
|
||||
"prompt": "1girl. A peaceful scene of a girl absorbed in reading at a quiet café. Soft window light illuminates her book as steam rises gently from her cup of tea. The cozy atmosphere and comfortable setting create a perfect moment of tranquil relaxation. sitting, chair, table, café, coffee shop, indoor, window, window light, sunlight, soft lighting, warm lighting, cozy atmosphere, reading, book, holding book, open book, coffee cup, teacup, steam, casual clothes, sweater, cardigan, long sleeves, skirt, pantyhose, sitting cross-legged, relaxed, calm expression, gentle smile, long hair, side ponytail, hair ornament, bookshelf, books, plant, potted plant, depth of field, blurry background, bokeh, peaceful, comfortable, slice of life, anime style, masterpiece"
|
||||
},
|
||||
"Cyberpunk Street Scene": {
|
||||
"prompt": "1girl. A lone figure stands in a rain-soaked cyberpunk street at night. Neon signs reflect off wet pavement while holographic displays flicker in the background. The cityscape towers above with its maze of skyscrapers and glowing advertisements. cyberpunk, neon lights, night, rain, wet, reflections, holographic display, hologram, cyber wear, mechanical parts, augmentation, headphones, hood, hood up, jacket, tech wear, city lights, cityscape, skyscraper, neon sign, japanese text, night sky, depth of field, blurry background, bokeh, rim lighting, ambient lighting, atmospheric, moody, cinematic angle, wide shot, street, alley, puddle, anime style, masterpiece"
|
||||
},
|
||||
"Dragon Girl Fantasy": {
|
||||
"prompt": "1girl. A powerful dragon girl sits regally upon her throne within her treasure-filled lair. Flames and embers dance around her as her wings spread majestically. Her scales shimmer in the dramatic lighting, displaying both her fierce power and noble bearing. dragon girl, dragon horns, horns, dragon tail, tail, dragon wings, wings, scales, pointy ears, elf ears, long hair, very long hair, silver hair, white hair, red eyes, slit pupils, fangs, sharp teeth, claws, fantasy, armor, scale armor, dragon scale armor, dragon themed, castle, throne, dragon hoard, treasure, gold, gems, crystals, cave, lair, dramatic lighting, volumetric lighting, fire, flames, embers, particles, epic, powerful, regal, anime style, detailed scales, masterpiece"
|
||||
},
|
||||
"Elegant Fantasy Princess": {
|
||||
"prompt": "1girl. A regal princess sits gracefully upon her ornate throne in the grand castle hall. Sunlight streams through magnificent stained glass windows, illuminating her elegant gown and sparkling jewelry. She embodies nobility and grace with her gentle smile and refined posture. princess, royalty, crown, tiara, jewelry, ornate jewelry, necklace, earrings, bracelet, elegant dress, ballgown, frills, lace trim, ribbon, puffy sleeves, long sleeves, detached sleeves, white gloves, long gloves, very long hair, wavy hair, blonde hair, blue eyes, detailed eyes, gentle smile, graceful, sitting, throne, castle interior, grand hall, chandelier, stained glass, window, sunlight, light rays, volumetric lighting, depth of field, bokeh, detailed background, fantasy, medieval, regal, noble, anime style, masterpiece"
|
||||
},
|
||||
"Fantasy Battle Scene": {
|
||||
"prompt": "multiple girls, multiple boys. An epic battle scene unfolds with multiple warriors locked in intense combat. Fighters strike dynamic poses with weapons raised and magic crackling through the air. Hair and capes billow in the wind as debris flies through the scene. dynamic pose, action scene, fighting stance, floating hair, motion blur, motion lines, dramatic angle, low angle, dutch angle, wielding sword, magic spell, casting magic, glowing weapon, energy effects, particle effects, debris, dust cloud, destruction, epic scene, cinematic composition, volumetric lighting, dramatic lighting, lens flare, depth of field, fantasy armor, detailed armor, cape, flowing clothes, wind, anime style, masterpiece"
|
||||
},
|
||||
"Gothic Lolita Fashion": {
|
||||
"prompt": "1girl. An elegant gothic lolita stands before a cathedral in her elaborate black dress. She holds a single red rose with pale graceful hands. The dramatic lighting filtering through stained glass creates an atmosphere of dark beauty and refined elegance. gothic lolita, lolita fashion, gothic dress, black dress, frills, lace, ruffles, ribbon, bow, puffy sleeves, long sleeves, detached sleeves, headdress, mini crown, cross, cross necklace, choker, black thighhighs, platform footwear, parasol, lace parasol, very long hair, twin tails, drill hair, curly hair, black hair, red eyes, pale skin, elegant, graceful pose, standing, rose, red rose, holding rose, church, cathedral, stained glass, gothic architecture, dim lighting, dramatic lighting, depth of field, detailed background, anime style, masterpiece"
|
||||
},
|
||||
"Idol Performance Stage": {
|
||||
"prompt": "1girl. An energetic idol performs on stage before a cheering crowd. Colorful spotlights illuminate her as she sings and dances with boundless enthusiasm. Sparkles and glitter fill the air as she strikes a dynamic pose with her microphone. idol, stage outfit, frills, lace, ribbon, bow, gloves, white gloves, microphone, holding microphone, singing, performing, stage, concert, stage lights, spotlights, colorful lighting, dynamic lighting, dramatic lighting, audience, crowd, cheering, energetic, dynamic pose, dancing, motion blur, sparkles, glitter, star \\(symbol\\), heart \\(symbol\\), twin tails, very long hair, gradient hair, colorful hair, bright colors, vibrant colors, smile, wink, one eye closed, cheerful, happy, full body, depth of field, anime style, masterpiece"
|
||||
},
|
||||
"Kimono Traditional Japan": {
|
||||
"prompt": "1girl. An elegant woman in traditional kimono walks gracefully through a beautiful Japanese garden. Autumn leaves drift down around her as koi swim in the pond beside a stone path. The golden hour light creates a warm and culturally rich atmosphere. kimono, japanese clothes, traditional clothes, obi, sash, wide sleeves, long sleeves, floral print, flower pattern, hair ornament, hair flower, kanzashi, long hair, black hair, brown hair, updo, hair bun, elegant, graceful, standing, walking, outdoor, japanese garden, garden, stone path, bridge, pond, koi, water, trees, maple tree, autumn leaves, red leaves, falling leaves, torii gate, shrine, lantern, paper lantern, sunset, golden hour, warm lighting, soft lighting, depth of field, blurry background, traditional, cultural, anime style, masterpiece"
|
||||
},
|
||||
"Magical Girl Transformation": {
|
||||
"prompt": "1girl. A magical girl undergoes her transformation sequence in a dazzling display of light and sparkles. Ribbons and magical particles swirl around her as her elaborate costume materializes. She strikes a heroic pose with outstretched hand against a radiant starburst background. magical girl, transformation sequence, sparkles, glowing, light particles, ribbon, frills, lace, detailed outfit, elaborate costume, twin tails, very long hair, gradient hair, multicolored hair, colorful, vibrant colors, bright colors, star \\(symbol\\), heart \\(symbol\\), dynamic pose, outstretched hand, raised hand, full body, floating, levitating, white background, gradient background, starburst background, bloom effect, light rays, god rays, anime style, masterpiece"
|
||||
},
|
||||
"Maid Cafe Waitress": {
|
||||
"prompt": "1girl. A cheerful maid waitress serves customers at a cozy cafe with a warm welcoming smile. Soft sunlight filters through the windows as she carries a tray with practiced grace. Her frilly uniform and happy expression create an inviting atmosphere. maid, maid headdress, maid apron, frills, lace, ribbon, bow, short sleeves, puffy sleeves, black dress, white apron, wrist cuffs, thighhighs, mary janes, holding tray, serving, indoor, cafe, detailed background, blurry background, depth of field, soft lighting, warm lighting, sunlight, window light, smiling, cheerful, happy, welcoming expression, looking at viewer, anime style, masterpiece"
|
||||
},
|
||||
"Samurai Warrior": {
|
||||
"prompt": "1boy. A skilled samurai warrior stands ready in a dynamic pose, hand on his katana. Cherry blossom petals swirl around him in the wind as the setting sun casts dramatic lighting across his detailed armor. His expression shows unwavering determination and honor. samurai, armor, japanese armor, shoulder armor, armored dress, hakama, hakama skirt, katana, sword, sheathed, holding sword, ponytail, long hair, black hair, serious expression, determined look, standing, dynamic pose, action pose, cherry blossoms, petals, falling petals, torii, shrine, japanese architecture, sunset, dramatic lighting, rim lighting, lens flare, depth of field, wind, dramatic angle, low angle, cinematic composition, anime style, detailed armor, masterpiece"
|
||||
},
|
||||
"School Uniform Casual": {
|
||||
"prompt": "1girl. A cheerful schoolgirl walks through the school grounds on a beautiful spring day. Cherry blossom petals dance in the wind around her as she carries her school bag. The sun shines warmly and her expression is gentle and happy. school uniform, serafuku, sailor collar, pleated skirt, short sleeves, long sleeves, cardigan, bow, bowtie, ribbon, neck ribbon, thighhighs, black thighhighs, loafers, bag, school bag, shoulder bag, standing, walking, outdoors, school, school building, cherry blossoms, falling petals, blue sky, clouds, sunlight, dappled sunlight, soft lighting, wind, wind lift, depth of field, blurry background, smile, happy, gentle expression, anime style, masterpiece"
|
||||
},
|
||||
"Shrine Maiden Miko": {
|
||||
"prompt": "1girl. A serene shrine maiden performs her duties at a peaceful shrine surrounded by nature. Dappled sunlight filters through the trees as cherry blossom petals gently fall around her. She holds a sacred paper charm with a gentle smile and peaceful expression. miko, shrine maiden, traditional clothes, japanese clothes, red hakama, hakama skirt, white kimono, wide sleeves, long sleeves, hair bow, red ribbon, hair tubes, long hair, black hair, brown hair, brown eyes, gentle smile, peaceful expression, holding ofuda, paper charm, shrine, torii gate, stone lantern, japanese architecture, outdoor, nature, forest, trees, sunlight, light rays, dappled sunlight, god rays, peaceful atmosphere, depth of field, soft lighting, cherry blossoms, petals, falling petals, anime style, masterpiece"
|
||||
},
|
||||
"Sleeping Bedroom Night": {
|
||||
"prompt": "1girl. A peaceful sleeping scene bathed in gentle moonlight streaming through the window. The girl rests quietly under soft covers with her hair spread across the pillow. Stars twinkle in the night sky visible through the curtains as she dreams peacefully. sleeping, lying, on side, on bed, bed, bedroom, pillow, blanket, sheet, under covers, pajamas, nightgown, sleepwear, closed eyes, peaceful expression, long hair, messy hair, hair over pillow, indoor, window, curtains, moonlight, night, night sky, stars, starry sky, moon, crescent moon, dim lighting, soft lighting, ambient lighting, calm atmosphere, quiet, serene, peaceful, plushie, stuffed toy, stuffed animal, depth of field, anime style, masterpiece"
|
||||
}
|
||||
},
|
||||
"Lighting": {
|
||||
"Cyberpunk Neon Atmosphere": {
|
||||
"prompt": "Vibrant cyberpunk neon lighting with dominant cyan, magenta, and purple color palette, multiple colored light sources creating complex overlapping shadows and color mixing, neon tubes and LED strips casting intense saturated light, strong rim lighting outlining subjects with colored glows, wet surfaces reflecting and multiplying light sources, volumetric fog and haze making light beams visible, high contrast between bright neon elements and deep dark shadows, futuristic atmospheric lighting with sci-fi mood, color temperature mixing cool blue neons with warm orange accents, Blade Runner inspired aesthetic, moody and atmospheric, cinematic lighting design, photorealistic rendering, 8k quality"
|
||||
},
|
||||
"Dramatic Rembrandt Lighting": {
|
||||
"prompt": "Classic Rembrandt studio lighting setup with strong directional key light at 45-degree angle creating distinctive triangle of light under eye on shadow side of face, deep rich shadows with subtle fill light preserving detail, high contrast ratio for dramatic mood, rim light separating subject from dark background, chiaroscuro technique emphasizing form and dimension through light and shadow, professionally controlled studio environment, classic portrait photography aesthetic, black background emphasizing subject, attention to catchlights in eyes, subtle hair light adding separation, timeless dramatic quality reminiscent of Dutch Golden Age paintings, medium format camera quality, tack-sharp focus, 4k resolution"
|
||||
},
|
||||
"Firelight and Shadows": {
|
||||
"prompt": "Warm intimate lighting from crackling fire as primary light source, rich orange and amber tones dancing across surfaces, dynamic moving shadows creating flickering atmospheric effect, high contrast with deep blacks in areas beyond firelight reach, sense of warmth and comfort, practical light source visible in scene showing glowing embers and flames, subsurface scattering on translucent objects near fire, traditional campfire or hearth setting, reminiscent of classical genre paintings, color temperature around 1800K for authentic firelight, soft smoky haze adding atmosphere, cozy intimate mood, photorealistic fire simulation, highly detailed, 4k quality"
|
||||
},
|
||||
"Golden Hour Magic": {
|
||||
"prompt": "Golden hour lighting during the last hour before sunset, warm golden and amber tones bathing entire scene in beautiful soft light, long dramatic shadows stretching across ground, sun low on horizon creating rim lighting that outlines subjects with glowing edges, soft diffused quality that enhances colors and reduces contrast, sky painted in gradients of gold, orange, pink, and purple, clouds illuminated from below with warm tones, perfect lighting conditions for photography with flattering warm color temperature around 3500K, atmospheric haze adding depth and dimension, lens flare and subtle bloom adding magical quality, professional landscape photography aesthetic, HDR processing for maximum dynamic range, masterpiece quality lighting, 8k resolution"
|
||||
},
|
||||
"Mystical Moonlight": {
|
||||
"prompt": "Ethereal moonlight illuminating scene with cool silvery-blue tones, full moon visible in clear night sky providing primary light source, soft shadows with blue-tinted quality, stars visible in background, atmospheric mist catching and scattering moonlight creating volumetric lighting effects, subtle bioluminescent elements adding touches of green and blue glow, romantic and magical atmosphere, cool color temperature around 4100K, high contrast between moonlit areas and deep shadows, sense of mystery and nocturnal beauty, long exposure photography aesthetic capturing movement of clouds, highly detailed night scene with proper exposure for nighttime conditions, cinematic quality, 8k resolution"
|
||||
},
|
||||
"Overcast Diffused Light": {
|
||||
"prompt": "Soft even illumination from completely overcast sky creating natural softbox effect, shadowless lighting with very gradual subtle transitions, muted desaturated color palette, cool color temperature around 6500K with slight blue-gray cast, perfect even exposure across entire scene, detail preserved in all areas, moody atmospheric quality, sense of calm or melancholy, ideal for showing texture and form without harsh shadows, professional product photography aesthetic, fog or mist adding layers of atmospheric perspective, minimalist Scandinavian lighting aesthetic, clean and modern feel, high dynamic range with subtle gradations, photorealistic rendering, 8k resolution"
|
||||
},
|
||||
"Soft Northern Window Light": {
|
||||
"prompt": "Beautiful soft natural light coming from large northern-facing window, gentle diffused illumination without harsh shadows or direct sunlight, even light distribution creating subtle gradations and soft wraparound lighting, cool color temperature around 5500K with slight blue bias, perfect for accurate color rendition, creates natural realistic appearance, soft shadows with gradual transitions, sense of calm and serenity, ideal for portraits and still life, professional photography studio aesthetic using natural light only, subtle environmental reflections adding fill light, maintains detail in both highlights and shadows, peaceful morning light quality, high dynamic range, 4k photographic quality"
|
||||
},
|
||||
"Volumetric God Rays": {
|
||||
"prompt": "Dramatic volumetric lighting with strong directional sunbeams breaking through clouds or canopy creating visible shafts of light, atmospheric perspective with dust particles, moisture, or fog making light beams clearly visible, high contrast between illuminated rays and darker surrounding areas, sense of divine or spiritual quality, particles floating through light beams catching illumination, depth and dimension created by layered light and shadow, cathedral-like quality to lighting, powerful emotional impact, reminiscent of classical religious paintings, physically accurate light scattering and atmospheric effects, subtle color gradation in light beams from warm to cool, cinematic composition, photorealistic rendering, 8k ultra quality"
|
||||
}
|
||||
},
|
||||
"Mood": {
|
||||
"Dark and Ominous": {
|
||||
"prompt": "Dark foreboding atmosphere with ominous threatening mood, deep shadows dominating composition with limited light sources, desaturated color palette with emphasis on blacks and dark grays, occasional blood red or sickly green accent colors, sense of danger and unease, heavy atmospheric fog or mist obscuring details, Gothic horror aesthetic, dramatic high contrast lighting, unsettling asymmetrical composition, inspired by horror film cinematography and dark fantasy art, volumetric shadows, psychological tension, photorealistic rendering with painterly qualities, 4k quality"
|
||||
},
|
||||
"Energetic and Vibrant": {
|
||||
"prompt": "High-energy dynamic atmosphere bursting with vitality and motion, saturated vibrant colors creating visual excitement, bold contrasts between warm and cool tones, sense of movement and activity throughout composition, dynamic lighting with multiple colorful sources, particles and elements in motion suggesting kinetic energy, fast-paced feeling with diagonal lines and angular composition, celebration of life and action, inspired by pop art and contemporary street photography, youthful exuberant quality, festival or carnival atmosphere, professional commercial photography aesthetic with punchy color grading, sharp details capturing peak moments, 8k ultra high resolution"
|
||||
},
|
||||
"Epic and Grandiose": {
|
||||
"prompt": "Monumental epic atmosphere emphasizing vast scale and dramatic spectacle, sweeping panoramic composition showcasing impressive scope, dramatic sky with storm clouds or spectacular sunset, towering mountains, massive architecture, or other elements dwarfing human scale, sense of awe and sublime beauty, inspired by romantic landscape painting and epic cinema, heroic quality with cinematic grandeur, professional landscape photography with maximum dynamic range, deep depth of field capturing detail from foreground to distant horizon, powerful emotional impact, larger-than-life presence, volumetric lighting with dramatic god rays, rich saturated colors or moody monochromatic palette, 8k ultra high resolution capturing every magnificent detail"
|
||||
},
|
||||
"Ethereal and Dreamlike": {
|
||||
"prompt": "Otherworldly ethereal atmosphere with dreamlike surreal quality, soft diffused lighting creating glowing luminous effect, pale pastel colors or monochromatic schemes, subtle gradients and smooth transitions, fog or mist creating atmospheric depth and mystery, sense of floating or weightlessness, influenced by symbolist painting and fine art photography, magical realism aesthetic, elements of fantasy and imagination, translucent overlapping layers, bokeh and soft focus creating painterly quality, gentle peaceful mood with touch of unreality, professional fine art composition, heavenly or celestial atmosphere, delicate beauty and fragility, museum quality presentation, 4k resolution with exceptional subtlety"
|
||||
},
|
||||
"Gritty and Raw": {
|
||||
"prompt": "Harsh gritty atmosphere emphasizing reality and unpolished authenticity, high contrast lighting with deep blacks and bright highlights, desaturated or monochromatic color palette, visible texture and grain adding tactile quality, urban decay or industrial elements, sense of struggle and perseverance, influenced by documentary photography and photojournalism, uncompromising realistic approach, environmental portraits showing character and history, weathered surfaces and worn materials, professional reportage aesthetic, honest unflinching perspective, dramatic shadows and harsh light, imperfections celebrated rather than hidden, strong emotional impact, cinematic noir quality, 4k resolution with sharp detail capturing every texture"
|
||||
},
|
||||
"Melancholic and Nostalgic": {
|
||||
"prompt": "Bittersweet melancholic atmosphere evoking memories and longing for the past, muted desaturated colors with vintage film aesthetic, soft diffused lighting creating dreamy quality, slight vignetting and faded appearance suggesting passage of time, autumnal or twilight color palette with browns, oranges, and muted blues, sense of solitude and quiet reflection, abandoned or weathered elements suggesting history, inspired by fine art photography and classical painting, emotional depth and introspective quality, gentle sadness mixed with beauty, analog film grain texture, soft focus areas creating romantic haze, timeless contemplative mood, 4k artistic quality"
|
||||
},
|
||||
"Mysterious and Enigmatic": {
|
||||
"prompt": "Mysterious atmospheric quality filled with intrigue and unanswered questions, strategic use of shadows and partial concealment, fog or mist obscuring details and creating layers of depth, cool color temperature with blues, purples, and teals, selective lighting revealing only portions of scene, sense of hidden secrets and untold stories, influenced by film noir and gothic romanticism, dramatic chiaroscuro lighting, silhouettes and backlighting creating ambiguity, professional cinematic atmosphere, elements of the unknown, otherworldly quality, photorealistic rendering with artistic interpretation, high contrast between light and dark areas, 8k resolution with exceptional atmospheric detail"
|
||||
},
|
||||
"Peaceful and Serene": {
|
||||
"prompt": "Calm peaceful atmosphere evoking tranquility and contentment, soft gentle lighting with harmonious balanced colors, pastel or muted earth tone palette, symmetrical or balanced composition creating visual harmony, natural elements like water or sky prominent, sense of stillness and timelessness, meditative quality, inspired by romantic landscape paintings and zen philosophy, warm and inviting feeling, perfect for relaxation and contemplation, subtle gradients and smooth transitions, professional fine art photography aesthetic, museum quality, 8k resolution"
|
||||
},
|
||||
"Warm and Inviting": {
|
||||
"prompt": "Cozy warm atmosphere radiating comfort and hospitality, golden hour lighting or warm interior illumination, rich warm color palette dominated by oranges, yellows, and earth tones, soft shadows creating gentle dimensionality, sense of home and belonging, intimate scale and human-friendly spaces, natural materials like wood and fabric prominent, influenced by lifestyle photography and Scandinavian hygge aesthetic, welcoming emotional quality, perfect for evoking feelings of safety and contentment, professional interior photography with careful attention to ambiance, subtle texture details, inviting composition encouraging viewer to enter scene, 4k quality with warm color grading"
|
||||
},
|
||||
"Whimsical and Playful": {
|
||||
"prompt": "Lighthearted whimsical atmosphere filled with joy and imagination, bright cheerful colors with unexpected combinations, playful composition with tilted angles or unusual perspectives, sense of fun and childlike wonder, elements of surprise and delight, influenced by children's book illustration and contemporary art, fantastical touches mixing reality with imagination, professional commercial photography with creative flair, bouncing light and colorful accents, informal spontaneous quality, sense of movement and energy, optimistic uplifting mood, creative use of props and staging, vibrant saturated colors, sharp focus on delightful details, 8k resolution with exceptional color accuracy and brightness"
|
||||
}
|
||||
},
|
||||
"Style": {
|
||||
"Cinematic Film Quality": {
|
||||
"prompt": "Cinematic film photography style with anamorphic lens characteristics, dramatic shallow depth of field with beautiful bokeh, professional color grading with teal and orange tones, subtle film grain texture, volumetric lighting with god rays and atmospheric haze, dynamic composition following rule of thirds, high contrast lighting with deep shadows and bright highlights, 2.39:1 aspect ratio letterbox framing, shot on ARRI Alexa 65, photorealistic rendering, 8k resolution, masterpiece quality with exceptional attention to lighting and atmosphere"
|
||||
},
|
||||
"Classic Oil Painting": {
|
||||
"prompt": "Traditional oil painting style in the manner of old masters, rich saturated colors with deep shadows and luminous highlights, visible brushwork with thick impasto in light areas and thin glazes in shadows, classical composition with careful attention to form and anatomy, chiaroscuro lighting technique, warm earth tone palette with selective use of vibrant colors, painted on linen canvas with visible texture, museum quality with craquelure aging effects, Renaissance and Baroque artistic influences, painterly realism, masterwork quality worthy of gallery exhibition"
|
||||
},
|
||||
"Concept Art Illustration": {
|
||||
"prompt": "Professional concept art illustration style used in AAA video game and film production, dynamic composition with strong focal point, atmospheric perspective with detailed foreground and painterly background, digital painting technique with custom brushes, strategic use of lighting to guide viewer's eye, color script with mood-appropriate palette, blend of realistic rendering and artistic interpretation, subtle texture overlays, clean lines with detailed callouts and annotations where needed, portfolio-quality artwork, 4k resolution optimized for production pipeline, industry-standard visual development artwork"
|
||||
},
|
||||
"Detailed Watercolor Art": {
|
||||
"prompt": "Professional watercolor painting technique with translucent layered washes, delicate color transitions and gradients, wet-on-wet blending creating soft atmospheric effects, strategic use of white space and paper texture showing through, detailed foreground elements with looser background washes, granulation and blooming effects in pigments, cold-press watercolor paper texture, artistic mastery of water control, luminous transparent colors, traditional botanical illustration precision combined with loose expressive passages, flowing organic shapes, high-end art print quality, 300 DPI resolution"
|
||||
},
|
||||
"Impressionist Painting": {
|
||||
"prompt": "Impressionist oil painting style reminiscent of Claude Monet and Pierre-Auguste Renoir, visible loose brushstrokes with textured impasto technique, vibrant color palette with emphasis on light and its changing qualities, dappled sunlight effects, soft edges and forms that blend together, focus on capturing momentary impression rather than fine details, colors applied in short strokes of pure unmixed paint, canvas texture visible, plein air painting aesthetic, masterful use of complementary colors, atmospheric perspective, traditional fine art quality, museum-worthy composition"
|
||||
},
|
||||
"Japanese Ukiyo-e Woodblock": {
|
||||
"prompt": "Traditional Japanese ukiyo-e woodblock print style, bold outlines with flat areas of color, limited color palette featuring indigo blues, vermillion reds, and ivory, stylized clouds and waves with distinctive patterns, attention to textile patterns and decorative elements, asymmetrical composition with strong diagonals, influence of Hokusai and Hiroshige, grain texture of woodblock printing, subtle color gradations through bokashi technique, Japanese aesthetic principles of wabi-sabi and mono no aware, artistic quality of Edo period prints, suitable for museum collection"
|
||||
},
|
||||
"Ultra Photorealistic": {
|
||||
"prompt": "Ultra photorealistic rendering with exceptional attention to every minute detail, 8k resolution with pixel-perfect clarity, physically accurate materials and lighting using ray tracing technology, subsurface scattering on skin and translucent materials, realistic depth of field and chromatic aberration, perfect exposure with natural lighting, micro-details including skin pores, fabric weave patterns, metal scratches and imperfections, dust particles in air, moisture and reflections, professional photography composition, shot with Canon EOS R5 with 85mm f/1.2 lens, indistinguishable from high-end commercial photography"
|
||||
},
|
||||
"Vintage Analog Photography": {
|
||||
"prompt": "Vintage analog film photography aesthetic, shot on Kodak Portra 400 or Fujifilm Pro 400H film stock, natural grain structure, slightly faded colors with characteristic film color shifts, vignetting on corners, subtle light leaks and lens flares, soft focus dreamy quality, dated timestamp or border frame, nostalgic 1970s-1990s color palette, imperfect exposure with authentic film limitations, scanned from 35mm negatives, warm golden tones, authentic vintage photograph appearance with all the charm and imperfections of film photography"
|
||||
}
|
||||
}
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 766 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 268 KiB After Width: | Height: | Size: 450 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 58 KiB |
+171
-45
@@ -7,64 +7,149 @@ app.registerExtension({
|
||||
settings: [
|
||||
{
|
||||
id: "PromptManager.PreferredBaseModel",
|
||||
category: ["Prompt Manager", "Model Preferences", "Base Model (text enhancement)"],
|
||||
category: ["Prompt Manager", "1. Model Preferences", "Base Model (text enhancement)"],
|
||||
name: "Preferred Base Model",
|
||||
tooltip: "Default model for 'Enhance User Prompt' mode (leave empty to auto-select smallest)",
|
||||
tooltip: "Filename of default model for 'Enhance User Prompt' mode (leave empty to auto-select model)",
|
||||
type: "text",
|
||||
defaultValue: "",
|
||||
async onChange(value) {
|
||||
try {
|
||||
await fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "preferred_base_model", value: value })
|
||||
});
|
||||
} catch (error) {
|
||||
onChange(value) {
|
||||
fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "preferred_base_model", value: value })
|
||||
}).catch(error => {
|
||||
console.error("[PromptManager] Error saving base model preference:", error);
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
{
|
||||
id: "PromptManager.PreferredVisionModel",
|
||||
category: ["Prompt Manager", "Model Preferences", "Vision Model (image analysis)"],
|
||||
category: ["Prompt Manager", "1. Model Preferences", "Vision Model (image analysis)"],
|
||||
name: "Preferred Vision Model",
|
||||
tooltip: "Default model for 'Analyze Image' modes (leave empty to auto-select smallest)",
|
||||
tooltip: "Filename of default model for 'Analyze Image' modes (leave empty to auto-select model)",
|
||||
type: "text",
|
||||
defaultValue: "",
|
||||
async onChange(value) {
|
||||
try {
|
||||
await fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "preferred_vision_model", value: value })
|
||||
});
|
||||
} catch (error) {
|
||||
onChange(value) {
|
||||
fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "preferred_vision_model", value: value })
|
||||
}).catch(error => {
|
||||
console.error("[PromptManager] Error saving vision model preference:", error);
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
{
|
||||
id: "PromptManager.LlamaPath",
|
||||
category: ["Prompt Manager", "2. Llama Preferences", "Custom Llama Path"],
|
||||
name: "Custom Llama Path",
|
||||
tooltip: "Path to custom Llama installation (Can leave empty if it's defined in your system Path)",
|
||||
type: "text",
|
||||
defaultValue: "",
|
||||
onChange(value) {
|
||||
fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "custom_llama_path", value: value })
|
||||
}).catch(error => {
|
||||
console.error("[PromptManager] Error saving Llama path preference:", error);
|
||||
});
|
||||
}
|
||||
},
|
||||
{
|
||||
id: "PromptManager.ModelPath",
|
||||
category: ["Prompt Manager", "2. Llama Preferences", "Custom Model Path"],
|
||||
name: "Custom Model Path",
|
||||
tooltip: "Path to custom model location (If emtpty, defaults to the models/gguf folder)",
|
||||
type: "text",
|
||||
defaultValue: "",
|
||||
onChange(value) {
|
||||
fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "custom_llama_model_path", value: value })
|
||||
}).catch(error => {
|
||||
console.error("[PromptManager] Error saving Model path preference:", error);
|
||||
});
|
||||
}
|
||||
},
|
||||
{
|
||||
id: "PromptManager.Port",
|
||||
category: ["Prompt Manager", "2. Llama Preferences", "Port"],
|
||||
name: "Port",
|
||||
tooltip: "Port number for the Llama server (default 8080)",
|
||||
type: "text",
|
||||
defaultValue: "8080",
|
||||
onChange(value) {
|
||||
fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "custom_llama_port", value: value })
|
||||
}).catch(error => {
|
||||
console.error("[PromptManager] Error saving Port preference:", error);
|
||||
});
|
||||
}
|
||||
},
|
||||
{
|
||||
id: "PromptManager.CloseLlama",
|
||||
category: ["Prompt Manager", "3. Exit Preferences", "Close Llama on Exit"],
|
||||
name: "Close Llama on Exit",
|
||||
tooltip: "If enabled, will close Llama when ComfyUI exits",
|
||||
type: "boolean",
|
||||
defaultValue: true,
|
||||
onChange(value) {
|
||||
fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "close_llama_on_exit", value: value })
|
||||
}).catch(error => {
|
||||
console.error("[PromptManager] Error saving Close Llama preference:", error);
|
||||
});
|
||||
}
|
||||
}
|
||||
],
|
||||
async setup() {
|
||||
// Load settings from ComfyUI and sync to Python cache
|
||||
try {
|
||||
// Sync current values to Python cache first
|
||||
const baseModel = app.ui.settings.getSettingValue("PromptManager.PreferredBaseModel", "");
|
||||
const visionModel = app.ui.settings.getSettingValue("PromptManager.PreferredVisionModel", "");
|
||||
const llamaPath = app.ui.settings.getSettingValue("PromptManager.LlamaPath", "");
|
||||
const modelPath = app.ui.settings.getSettingValue("PromptManager.ModelPath", "");
|
||||
const port = app.ui.settings.getSettingValue("PromptManager.Port", "8080");
|
||||
const CloseLlama = app.ui.settings.getSettingValue("PromptManager.CloseLlama", true);
|
||||
|
||||
// Sync both settings to Python cache
|
||||
if (baseModel) {
|
||||
await fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "preferred_base_model", value: baseModel })
|
||||
});
|
||||
}
|
||||
if (visionModel) {
|
||||
await fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "preferred_vision_model", value: visionModel })
|
||||
});
|
||||
}
|
||||
console.log("[PromptManager] Syncing preferences:", { baseModel, visionModel, llamaPath, modelPath, port, CloseLlama });
|
||||
await fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "preferred_base_model", value: baseModel })
|
||||
});
|
||||
await fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "preferred_vision_model", value: visionModel })
|
||||
});
|
||||
await fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "custom_llama_path", value: llamaPath })
|
||||
});
|
||||
await fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "custom_llama_model_path", value: modelPath })
|
||||
});
|
||||
await fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "custom_llama_port", value: port })
|
||||
});
|
||||
await fetch("/prompt-manager/save-preference", {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({ key: "close_llama_on_exit", value: CloseLlama })
|
||||
});
|
||||
} catch (error) {
|
||||
console.error("[PromptManager] Error syncing preferences:", error);
|
||||
}
|
||||
@@ -183,10 +268,51 @@ app.registerExtension({
|
||||
// Enforce minimum node width
|
||||
const onResize = nodeType.prototype.onResize;
|
||||
nodeType.prototype.onResize = function(size) {
|
||||
size[0] = Math.max(400, size[0]);
|
||||
size[0] = Math.max(300, size[0]);
|
||||
return onResize ? onResize.apply(this, arguments) : size;
|
||||
};
|
||||
}
|
||||
|
||||
// Make the Options node taller/wider by default so the system_prompt area is roomier
|
||||
if (nodeData.name === "PromptGenOptions") {
|
||||
const onNodeCreated = nodeType.prototype.onNodeCreated;
|
||||
nodeType.prototype.onNodeCreated = function () {
|
||||
const result = onNodeCreated?.apply(this, arguments);
|
||||
// Set a default size (width x height)
|
||||
try {
|
||||
this.setSize([400, 420]);
|
||||
} catch (e) {
|
||||
// ignore if method unavailable
|
||||
}
|
||||
return result;
|
||||
};
|
||||
// Enforce sensible minimums when the user resizes the options node
|
||||
const onResizeOpt = nodeType.prototype.onResize;
|
||||
nodeType.prototype.onResize = function(size) {
|
||||
size[0] = Math.max(300, size[0]);
|
||||
return onResizeOpt ? onResizeOpt.apply(this, arguments) : size;
|
||||
};
|
||||
}
|
||||
|
||||
// Enforce minimum size for ModelGenerator node (no default size)
|
||||
if (nodeData.name === "PromptGenerator") {
|
||||
const onNodeCreated = nodeType.prototype.onNodeCreated;
|
||||
nodeType.prototype.onNodeCreated = function () {
|
||||
const result = onNodeCreated?.apply(this, arguments);
|
||||
// Set a default size (width x height)
|
||||
try {
|
||||
this.setSize([400, 300]);
|
||||
} catch (e) {
|
||||
// ignore if method unavailable
|
||||
}
|
||||
return result;
|
||||
};
|
||||
const onResizeModel = nodeType.prototype.onResize;
|
||||
nodeType.prototype.onResize = function(size) {
|
||||
size[0] = Math.max(300, size[0]);
|
||||
return onResizeModel ? onResizeModel.apply(this, arguments) : size;
|
||||
};
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@@ -210,7 +336,7 @@ function filterPromptDropdown(node) {
|
||||
if (categoryWidget && promptWidget) {
|
||||
const currentCategory = categoryWidget.value;
|
||||
if (node.prompts[currentCategory]) {
|
||||
const promptNames = Object.keys(node.prompts[currentCategory]);
|
||||
const promptNames = Object.keys(node.prompts[currentCategory]).sort((a, b) => a.localeCompare(b));
|
||||
if (promptNames.length === 0) {
|
||||
promptNames.push("");
|
||||
}
|
||||
@@ -341,7 +467,7 @@ function setupCategoryChangeHandler(node) {
|
||||
|
||||
const category = value;
|
||||
if (node.prompts && node.prompts[category]) {
|
||||
const promptNames = Object.keys(node.prompts[category]);
|
||||
const promptNames = Object.keys(node.prompts[category]).sort((a, b) => a.localeCompare(b));
|
||||
promptWidget.options.values = promptNames;
|
||||
|
||||
if (promptNames.length > 0) {
|
||||
@@ -507,7 +633,7 @@ function createButton(text, callback) {
|
||||
button.style.backgroundColor = "#222";
|
||||
button.style.color = "#fff";
|
||||
button.style.border = "1px solid #444";
|
||||
button.style.borderRadius = "3px";
|
||||
button.style.borderRadius = "6px";
|
||||
button.style.fontSize = "11px";
|
||||
button.style.fontWeight = "normal";
|
||||
button.style.whiteSpace = "nowrap";
|
||||
@@ -736,18 +862,18 @@ function updateDropdowns(node) {
|
||||
|
||||
if (!categoryWidget || !promptWidget || !textWidget) return;
|
||||
|
||||
// Update category dropdown
|
||||
const categories = Object.keys(node.prompts);
|
||||
// Update category dropdown (sorted alphabetically)
|
||||
const categories = Object.keys(node.prompts).sort((a, b) => a.localeCompare(b));
|
||||
categoryWidget.options.values = categories;
|
||||
|
||||
if (!node.prompts[categoryWidget.value] && categories.length > 0) {
|
||||
categoryWidget.value = categories[0];
|
||||
}
|
||||
|
||||
// Update prompt dropdown for current category
|
||||
// Update prompt dropdown for current category (sorted alphabetically)
|
||||
const currentCategory = categoryWidget.value;
|
||||
if (node.prompts[currentCategory]) {
|
||||
const promptNames = Object.keys(node.prompts[currentCategory]);
|
||||
const promptNames = Object.keys(node.prompts[currentCategory]).sort((a, b) => a.localeCompare(b));
|
||||
|
||||
if (promptNames.length === 0) {
|
||||
promptNames.push("");
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
+83
-20
@@ -3,18 +3,25 @@ Utility functions for managing llama.cpp models
|
||||
"""
|
||||
import os
|
||||
import glob
|
||||
import json
|
||||
import re
|
||||
import folder_paths
|
||||
|
||||
import server
|
||||
from huggingface_hub import HfApi
|
||||
from tqdm.auto import tqdm
|
||||
import requests
|
||||
|
||||
# Add preference cache and API endpoints for preferences
|
||||
_preferences_cache = {
|
||||
"preferred_base_model": "",
|
||||
"preferred_vision_model": "",
|
||||
"custom_llama_path": "",
|
||||
"custom_llama_model_path": "",
|
||||
"close_llama_on_exit": True,
|
||||
"custom_llama_port": 8080
|
||||
}
|
||||
|
||||
# Predefined models - use real filenames as keys
|
||||
QWEN_MODELS = {
|
||||
"Qwen3-1.7B-Q8_0.gguf": {
|
||||
"repo": "Qwen/Qwen3-1.7B-GGUF"
|
||||
},
|
||||
"Qwen3-4B-Q8_0.gguf": {
|
||||
"repo": "Qwen/Qwen3-4B-GGUF"
|
||||
},
|
||||
@@ -28,11 +35,46 @@ QWEN_MODELS = {
|
||||
"Qwen3VL-8B-Instruct-Q8_0.gguf": {
|
||||
"repo": "Qwen/Qwen3-VL-8B-Instruct-GGUF",
|
||||
"mmproj": "mmproj-Qwen3VL-8B-Instruct-Q8_0.gguf"
|
||||
},
|
||||
"Qwen3VL-4B-Thinking-Q8_0.gguf": {
|
||||
"repo": "Qwen/Qwen3-VL-4B-Thinking-GGUF",
|
||||
"mmproj": "mmproj-Qwen3VL-4B-Thinking-Q8_0.gguf"
|
||||
},
|
||||
"Qwen3VL-8B-Thinking-Q8_0.gguf": {
|
||||
"repo": "Qwen/Qwen3-VL-8B-Thinking-GGUF",
|
||||
"mmproj": "mmproj-Qwen3VL-8B-Thinking-Q8_0.gguf"
|
||||
}
|
||||
}
|
||||
|
||||
# Preferences are now stored in ComfyUI settings (comfy.settings.json)
|
||||
# and accessed via the settings API in prompt_manager.py
|
||||
@server.PromptServer.instance.routes.get("/prompt-manager/load-preferences")
|
||||
async def load_preferences(request):
|
||||
"""API endpoint to get cached preferences (set from ComfyUI settings)"""
|
||||
return server.web.json_response(_preferences_cache)
|
||||
|
||||
|
||||
@server.PromptServer.instance.routes.post("/prompt-manager/save-preference")
|
||||
async def save_preference(request):
|
||||
"""API endpoint to update preference cache when settings change"""
|
||||
try:
|
||||
data = await request.json()
|
||||
key = data.get("key")
|
||||
value = data.get("value", "")
|
||||
|
||||
if key not in ["preferred_base_model",
|
||||
"preferred_vision_model",
|
||||
"custom_llama_path",
|
||||
"custom_llama_model_path",
|
||||
"close_llama_on_exit",
|
||||
"custom_llama_port"]:
|
||||
return server.web.json_response({"success": False, "error": "Invalid preference key"})
|
||||
|
||||
# Update in-memory cache
|
||||
_preferences_cache[key] = value
|
||||
|
||||
return server.web.json_response({"success": True, "preferences": _preferences_cache})
|
||||
except Exception as e:
|
||||
print(f"[Model Manager] Error saving preference: {e}")
|
||||
return server.web.json_response({"success": False, "error": str(e)}, status=500)
|
||||
|
||||
def get_models_directory():
|
||||
"""Get the path to the primary models directory (ComfyUI/models/gguf) for downloads"""
|
||||
@@ -45,11 +87,16 @@ def get_models_directory():
|
||||
llm_dir = os.path.join(folder_paths.models_dir, "LLM")
|
||||
folder_paths.add_model_folder_path("LLM", llm_dir)
|
||||
|
||||
# Return gguf as the primary directory (for downloads)
|
||||
models_dir = folder_paths.get_folder_paths("gguf")[0]
|
||||
custom_llama_model_path = _preferences_cache.get("custom_llama_model_path", "")
|
||||
|
||||
# Create directory if it doesn't exist
|
||||
os.makedirs(models_dir, exist_ok=True)
|
||||
if custom_llama_model_path and os.path.isdir(custom_llama_model_path):
|
||||
# Add custom path if not already present
|
||||
if "CustomLLM" not in folder_paths.folder_names_and_paths:
|
||||
folder_paths.add_model_folder_path("CustomLLM", custom_llama_model_path)
|
||||
models_dir = custom_llama_model_path
|
||||
else:
|
||||
models_dir = folder_paths.get_folder_paths("gguf")[0]
|
||||
os.makedirs(models_dir, exist_ok=True) # Create directory if it doesn't exist
|
||||
|
||||
return models_dir
|
||||
|
||||
@@ -58,7 +105,7 @@ def get_all_model_directories():
|
||||
get_models_directory() # Ensure folders are registered
|
||||
|
||||
directories = []
|
||||
for folder_type in ["gguf", "LLM"]:
|
||||
for folder_type in ["gguf", "LLM", "CustomLLM"]:
|
||||
if folder_type in folder_paths.folder_names_and_paths:
|
||||
dirs = folder_paths.get_folder_paths(folder_type)
|
||||
directories.extend(dirs)
|
||||
@@ -76,7 +123,7 @@ def get_local_models():
|
||||
for f in gguf_files:
|
||||
basename = os.path.basename(f)
|
||||
# Filter out mmproj files
|
||||
if not basename.startswith("mmproj-"):
|
||||
if 'mmproj' not in basename.lower():
|
||||
all_models.add(basename)
|
||||
|
||||
# Return sorted list of unique filenames
|
||||
@@ -89,7 +136,7 @@ def get_huggingface_models():
|
||||
def get_all_models():
|
||||
"""Get combined list of local and HuggingFace models, excluding already downloaded ones and mmproj files"""
|
||||
local_models = get_local_models() # Already filtered
|
||||
models_dir = get_models_directory()
|
||||
models_dir = get_models_directory()
|
||||
|
||||
# List all known filenames, local ones first
|
||||
all_models = []
|
||||
@@ -98,7 +145,7 @@ def get_all_models():
|
||||
all_models.extend(local_models)
|
||||
# Add remote models (not present locally), excluding mmproj files
|
||||
for filename in QWEN_MODELS.keys():
|
||||
if filename not in all_models and not filename.startswith("mmproj-"):
|
||||
if filename not in all_models and 'mmproj' not in filename.lower():
|
||||
all_models.append(filename)
|
||||
return all_models
|
||||
|
||||
@@ -136,11 +183,27 @@ def get_mmproj_for_model(model_name):
|
||||
return None
|
||||
|
||||
def get_mmproj_path(model_name):
|
||||
"""Get the path to the mmproj file for a vision model, if it exists"""
|
||||
mmproj_name = get_mmproj_for_model(model_name)
|
||||
if mmproj_name and is_model_local(mmproj_name):
|
||||
return get_model_path(mmproj_name)
|
||||
return None
|
||||
"""Get the path to the mmproj file for a vision model, if it exists
|
||||
Searches for mmproj files that contain all parts of the model name
|
||||
"""
|
||||
# Get all parts of the model name (excluding .gguf)
|
||||
model_parts = [part for part in re.split(r"[-.]", os.path.splitext(os.path.basename(model_name))[0]) if part]
|
||||
|
||||
# Get all local mmproj files
|
||||
all_dirs = get_all_model_directories()
|
||||
mmproj_files = []
|
||||
for models_dir in all_dirs:
|
||||
if os.path.exists(models_dir):
|
||||
for f in os.listdir(models_dir):
|
||||
if 'mmproj' in f.lower() and f.endswith('.gguf'):
|
||||
mmproj_files.append(f)
|
||||
|
||||
# Find mmproj that contains all model parts
|
||||
for mmproj_file in mmproj_files:
|
||||
# Let's split the mmproj filename to check for matching bits, we remove extension and mmproj
|
||||
mmproj_parts = [part for part in re.split(r"[-.]", os.path.splitext(os.path.basename(mmproj_file))[0].replace('mmproj', '')) if part]
|
||||
if all(part in mmproj_parts for part in model_parts):
|
||||
return get_model_path(mmproj_file)
|
||||
|
||||
def download_model(model_name):
|
||||
"""Download a model from HuggingFace with automatic progress display
|
||||
|
||||
+730
-223
File diff suppressed because it is too large
Load Diff
+44
-16
@@ -26,12 +26,28 @@ class PromptGenOptions:
|
||||
"default": available_models[0] if available_models else "",
|
||||
"tooltip": "Select model to use (local models listed first, then HuggingFace models)"
|
||||
}),
|
||||
"image2": ("IMAGE", {
|
||||
"tooltip": "Connect an image (required for 'Analyze Image' and 'Analyze Image with Prompt' modes)"
|
||||
}),
|
||||
"image3": ("IMAGE", {
|
||||
"tooltip": "Connect an image (required for 'Analyze Image' and 'Analyze Image with Prompt' modes)"
|
||||
}),
|
||||
"image4": ("IMAGE", {
|
||||
"tooltip": "Connect an image (required for 'Analyze Image' and 'Analyze Image with Prompt' modes)"
|
||||
}),
|
||||
"image5": ("IMAGE", {
|
||||
"tooltip": "Connect an image (required for 'Analyze Image' and 'Analyze Image with Prompt' modes)"
|
||||
}),
|
||||
"system_prompt": ("STRING", {
|
||||
"multiline": True,
|
||||
"default": "",
|
||||
"placeholder": "Replace LLM Instructions...",
|
||||
"tooltip": "Custom LLM Instructions (leave empty to use default)\nThe default instructions are designed for generating\ndetailed and imaginative prompts for text-to-image generation."
|
||||
}),
|
||||
"use_model_default_sampling": ("BOOLEAN", {
|
||||
"default": False,
|
||||
"tooltip": "Use the model's default sampling parameters (overrides temperature, top_p, etc)"
|
||||
}),
|
||||
"temperature": ("FLOAT", {
|
||||
"default": 0.8,
|
||||
"min": 0.0,
|
||||
@@ -74,6 +90,10 @@ class PromptGenOptions:
|
||||
"step": 512,
|
||||
"tooltip": "Context size (increase for vision models or large prompts)"
|
||||
}),
|
||||
"show_everything_in_console": ("BOOLEAN", {
|
||||
"default": False,
|
||||
"tooltip": "Print system prompt, user prompt, thinking process, and raw model response to console"
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
@@ -87,11 +107,12 @@ class PromptGenOptions:
|
||||
"""Force refresh when models are updated"""
|
||||
return _last_model_update
|
||||
|
||||
def create_options(self, model: str = None,
|
||||
system_prompt: str = None, temperature: float = None,
|
||||
def create_options(self, model: str = None, image2=None, image3=None, image4=None, image5=None,
|
||||
system_prompt: str = None, use_model_default_sampling: bool = None, temperature: float = None,
|
||||
top_k: int = None, top_p: float = None, min_p: float = None,
|
||||
repeat_penalty: float = None, context_size: int = None) -> dict:
|
||||
"""Create options dictionary with model and LLM parameters"""
|
||||
repeat_penalty: float = None, context_size: int = None,
|
||||
show_everything_in_console: bool = None) -> dict:
|
||||
"""Create options dictionary with model, LLM parameters, and extra images"""
|
||||
|
||||
options = {}
|
||||
|
||||
@@ -123,21 +144,28 @@ class PromptGenOptions:
|
||||
else:
|
||||
options["model"] = model
|
||||
|
||||
# Add extra images if provided
|
||||
if image2 is not None:
|
||||
options["image2"] = image2
|
||||
if image3 is not None:
|
||||
options["image3"] = image3
|
||||
if image4 is not None:
|
||||
options["image4"] = image4
|
||||
if image5 is not None:
|
||||
options["image5"] = image5
|
||||
|
||||
# Only include LLM parameters that are provided
|
||||
if system_prompt and system_prompt.strip():
|
||||
options["system_prompt"] = system_prompt
|
||||
if temperature is not None:
|
||||
options["temperature"] = temperature
|
||||
if top_p is not None:
|
||||
options["top_p"] = top_p
|
||||
if top_k is not None:
|
||||
options["top_k"] = top_k
|
||||
if min_p is not None:
|
||||
options["min_p"] = min_p
|
||||
if repeat_penalty is not None:
|
||||
options["repeat_penalty"] = repeat_penalty
|
||||
if context_size is not None:
|
||||
options["context_size"] = context_size
|
||||
|
||||
options["use_model_default_sampling"] = use_model_default_sampling
|
||||
options["temperature"] = temperature
|
||||
options["top_p"] = top_p
|
||||
options["top_k"] = top_k
|
||||
options["min_p"] = min_p
|
||||
options["repeat_penalty"] = repeat_penalty
|
||||
options["context_size"] = context_size
|
||||
options["show_everything_in_console"] = show_everything_in_console
|
||||
|
||||
return (options,)
|
||||
|
||||
|
||||
+8
-34
@@ -3,11 +3,6 @@ import json
|
||||
import folder_paths
|
||||
import server
|
||||
|
||||
# Store preferences in memory (ComfyUI settings is the source of truth)
|
||||
_preferences_cache = {
|
||||
"preferred_base_model": "",
|
||||
"preferred_vision_model": ""
|
||||
}
|
||||
|
||||
class PromptManager:
|
||||
|
||||
@@ -53,6 +48,7 @@ class PromptManager:
|
||||
RETURN_TYPES = ("STRING",)
|
||||
RETURN_NAMES = ("prompt",)
|
||||
FUNCTION = "get_prompt"
|
||||
OUTPUT_NODE = True
|
||||
|
||||
@staticmethod
|
||||
def get_prompts_path():
|
||||
@@ -201,8 +197,13 @@ async def save_prompt(request):
|
||||
print(f"[PromptManager] Removing old casing '{old_name}' before saving as '{name}'")
|
||||
del prompts[category][old_name]
|
||||
|
||||
# Save prompt in dict
|
||||
prompts[category][name] = {"prompt": text}
|
||||
# Save prompt in dict, preserving any existing lora data from PromptManagerAdvanced
|
||||
existing_data = prompts[category].get(name, {})
|
||||
prompts[category][name] = {
|
||||
"prompt": text,
|
||||
"loras_a": existing_data.get("loras_a", []),
|
||||
"loras_b": existing_data.get("loras_b", [])
|
||||
}
|
||||
PromptManager.save_prompts(prompts)
|
||||
|
||||
return server.web.json_response({"success": True, "prompts": prompts})
|
||||
@@ -258,30 +259,3 @@ async def delete_prompt(request):
|
||||
except Exception as e:
|
||||
print(f"[PromptManager] Error in delete_prompt API: {e}")
|
||||
return server.web.json_response({"success": False, "error": str(e)}, status=500)
|
||||
|
||||
|
||||
@server.PromptServer.instance.routes.get("/prompt-manager/load-preferences")
|
||||
async def load_preferences(request):
|
||||
"""API endpoint to get cached preferences (set from ComfyUI settings)"""
|
||||
return server.web.json_response(_preferences_cache)
|
||||
|
||||
|
||||
@server.PromptServer.instance.routes.post("/prompt-manager/save-preference")
|
||||
async def save_preference(request):
|
||||
"""API endpoint to update preference cache when settings change"""
|
||||
try:
|
||||
data = await request.json()
|
||||
key = data.get("key")
|
||||
value = data.get("value", "")
|
||||
|
||||
if key not in ["preferred_base_model", "preferred_vision_model"]:
|
||||
return server.web.json_response({"success": False, "error": "Invalid preference key"})
|
||||
|
||||
# Update in-memory cache
|
||||
_preferences_cache[key] = value
|
||||
|
||||
return server.web.json_response({"success": True, "preferences": _preferences_cache})
|
||||
except Exception as e:
|
||||
print(f"[PromptManager] Error saving preference: {e}")
|
||||
return server.web.json_response({"success": False, "error": str(e)}, status=500)
|
||||
|
||||
|
||||
@@ -0,0 +1,621 @@
|
||||
"""
|
||||
ComfyUI Prompt Manager Advanced - Extended prompt management with LoRA stack support
|
||||
Saves prompts along with associated LoRA configurations
|
||||
"""
|
||||
import os
|
||||
import json
|
||||
import folder_paths
|
||||
import server
|
||||
|
||||
|
||||
def get_available_loras():
|
||||
"""Get all available LoRAs from ComfyUI's folder system"""
|
||||
lora_files = folder_paths.get_filename_list("loras")
|
||||
return lora_files
|
||||
|
||||
|
||||
def resolve_lora_path(lora_name):
|
||||
"""
|
||||
Resolve a LoRA name to its full path using ComfyUI's folder system.
|
||||
Returns (full_path, found) tuple.
|
||||
"""
|
||||
lora_files = get_available_loras()
|
||||
|
||||
# Try exact match first (with extension)
|
||||
for lora_file in lora_files:
|
||||
if lora_file == lora_name:
|
||||
return folder_paths.get_full_path("loras", lora_file), True
|
||||
|
||||
# Try matching by name without extension
|
||||
lora_name_lower = lora_name.lower()
|
||||
for lora_file in lora_files:
|
||||
file_name_no_ext = os.path.splitext(os.path.basename(lora_file))[0]
|
||||
if file_name_no_ext.lower() == lora_name_lower:
|
||||
return folder_paths.get_full_path("loras", lora_file), True
|
||||
|
||||
# Try partial match (lora_name might be just the filename, lora_file might have subdirs)
|
||||
for lora_file in lora_files:
|
||||
file_name = os.path.basename(lora_file)
|
||||
file_name_no_ext = os.path.splitext(file_name)[0]
|
||||
if file_name_no_ext.lower() == lora_name_lower or file_name.lower() == lora_name_lower:
|
||||
return folder_paths.get_full_path("loras", lora_file), True
|
||||
|
||||
# Not found
|
||||
return None, False
|
||||
|
||||
|
||||
def get_lora_relative_path(lora_name):
|
||||
"""
|
||||
Get the relative path for a LoRA that ComfyUI expects for loading.
|
||||
Returns (relative_path, found) tuple.
|
||||
"""
|
||||
lora_files = get_available_loras()
|
||||
|
||||
lora_name_lower = lora_name.lower()
|
||||
for lora_file in lora_files:
|
||||
file_name_no_ext = os.path.splitext(os.path.basename(lora_file))[0]
|
||||
if file_name_no_ext.lower() == lora_name_lower:
|
||||
return lora_file, True
|
||||
|
||||
# Not found
|
||||
return lora_name, False
|
||||
|
||||
|
||||
class PromptManagerAdvanced:
|
||||
"""
|
||||
Advanced Prompt Manager with LoRA stack integration.
|
||||
Supports saving/loading prompts with associated LoRA configurations.
|
||||
Features two LoRA stack inputs/outputs for dual LoRA workflows (e.g., Wan video).
|
||||
"""
|
||||
|
||||
@classmethod
|
||||
def INPUT_TYPES(s):
|
||||
prompts_data = PromptManagerAdvanced.load_prompts()
|
||||
categories = list(prompts_data.keys()) if prompts_data else ["Default"]
|
||||
|
||||
all_prompts = set()
|
||||
for category_prompts in prompts_data.values():
|
||||
all_prompts.update(category_prompts.keys())
|
||||
|
||||
all_prompts.add("")
|
||||
all_prompts_list = sorted(list(all_prompts))
|
||||
|
||||
first_category = categories[0] if categories else "Default"
|
||||
|
||||
# Get first prompt from first category
|
||||
first_prompt = ""
|
||||
first_prompt_text = ""
|
||||
if prompts_data and first_category in prompts_data and prompts_data[first_category]:
|
||||
first_category_prompts = list(prompts_data[first_category].keys())
|
||||
first_prompt = sorted(first_category_prompts, key=str.lower)[0] if first_category_prompts else ""
|
||||
if first_prompt:
|
||||
first_prompt_text = prompts_data[first_category][first_prompt].get("prompt", "")
|
||||
|
||||
return {
|
||||
"required": {
|
||||
"category": (categories, {"default": first_category}),
|
||||
"name": (all_prompts_list, {"default": first_prompt}),
|
||||
"use_external": ("BOOLEAN", {"default": False, "label_on": "on", "label_off": "off", "tooltip": "Toggle to use LLM input instead of internal text"}),
|
||||
"override_lora": ("BOOLEAN", {
|
||||
"default": False,
|
||||
"tooltip": "When enabled, ignore connected LoRA stacks and use only the saved preset values"
|
||||
}),
|
||||
"text": ("STRING", {
|
||||
"multiline": True,
|
||||
"default": first_prompt_text,
|
||||
"placeholder": "Enter prompt text",
|
||||
"dynamicPrompts": False,
|
||||
"tooltip": "Enter prompt text directly"
|
||||
}),
|
||||
},
|
||||
"optional": {
|
||||
"llm_input": ("STRING", {"multiline": True, "forceInput": True, "lazy": True, "tooltip": "Connect LLM text input here"}),
|
||||
"lora_stack_a": ("LORA_STACK", {"tooltip": "First LoRA stack input (e.g., for base model)"}),
|
||||
"lora_stack_b": ("LORA_STACK", {"tooltip": "Second LoRA stack input (e.g., for video model)"}),
|
||||
},
|
||||
"hidden": {
|
||||
"unique_id": "UNIQUE_ID",
|
||||
"loras_a_toggle": "STRING",
|
||||
"loras_b_toggle": "STRING",
|
||||
}
|
||||
}
|
||||
|
||||
CATEGORY = "Prompt Manager"
|
||||
RETURN_TYPES = ("STRING", "LORA_STACK", "LORA_STACK")
|
||||
RETURN_NAMES = ("prompt", "lora_stack_a", "lora_stack_b")
|
||||
FUNCTION = "get_prompt"
|
||||
OUTPUT_NODE = True
|
||||
|
||||
@staticmethod
|
||||
def get_prompts_path():
|
||||
"""Get the path to the prompts JSON file in user/default folder (shared with standard PromptManager)"""
|
||||
return os.path.join(folder_paths.get_user_directory(), "default", "prompt_manager_data.json")
|
||||
|
||||
@staticmethod
|
||||
def get_default_prompts_path():
|
||||
"""Get the path to the default prompts JSON file"""
|
||||
return os.path.join(os.path.dirname(__file__), "default_prompts.json")
|
||||
|
||||
@classmethod
|
||||
def load_prompts(cls):
|
||||
"""Load prompts from user folder or default (shared with standard PromptManager)"""
|
||||
user_path = cls.get_prompts_path()
|
||||
default_path = cls.get_default_prompts_path()
|
||||
|
||||
if os.path.exists(user_path):
|
||||
try:
|
||||
with open(user_path, 'r', encoding='utf-8') as f:
|
||||
return json.load(f)
|
||||
except Exception as e:
|
||||
print(f"[PromptManagerAdvanced] Error loading user prompts: {e}")
|
||||
|
||||
if os.path.exists(default_path):
|
||||
try:
|
||||
with open(default_path, 'r', encoding='utf-8') as f:
|
||||
data = json.load(f)
|
||||
cls.save_prompts(data)
|
||||
return data
|
||||
except Exception as e:
|
||||
print(f"[PromptManagerAdvanced] Error loading default prompts: {e}")
|
||||
|
||||
# Return empty structure if all else fails
|
||||
print("[PromptManagerAdvanced] Warning: No prompt files found, starting with empty data")
|
||||
return {}
|
||||
|
||||
@staticmethod
|
||||
def sort_prompts_data(data):
|
||||
"""Sort categories and prompts alphabetically (case-insensitive)"""
|
||||
sorted_data = {}
|
||||
for category in sorted(data.keys(), key=str.lower):
|
||||
sorted_data[category] = dict(sorted(data[category].items(), key=lambda item: item[0].lower()))
|
||||
return sorted_data
|
||||
|
||||
@classmethod
|
||||
def save_prompts(cls, data):
|
||||
"""Save prompts to user folder"""
|
||||
user_path = cls.get_prompts_path()
|
||||
sorted_data = cls.sort_prompts_data(data)
|
||||
|
||||
try:
|
||||
os.makedirs(os.path.dirname(user_path), exist_ok=True)
|
||||
with open(user_path, 'w', encoding='utf-8') as f:
|
||||
json.dump(sorted_data, f, indent=2, ensure_ascii=False)
|
||||
except Exception as e:
|
||||
print(f"[PromptManagerAdvanced] Error saving prompts: {e}")
|
||||
|
||||
def _merge_lora_stacks(self, preset_stack, connected_stack):
|
||||
"""
|
||||
Merge preset loras with connected loras, avoiding duplicates.
|
||||
Preset loras come first, then connected loras that aren't already in preset.
|
||||
|
||||
Args:
|
||||
preset_stack: List of tuples from saved preset
|
||||
connected_stack: List of tuples from connected input
|
||||
|
||||
Returns:
|
||||
Combined lora stack with no duplicates (by lora name)
|
||||
"""
|
||||
if not connected_stack:
|
||||
return preset_stack if preset_stack else []
|
||||
if not preset_stack:
|
||||
return list(connected_stack)
|
||||
|
||||
# Build set of lora names from preset
|
||||
preset_names = set()
|
||||
for lora_path, _, _ in preset_stack:
|
||||
lora_name = os.path.splitext(os.path.basename(lora_path))[0]
|
||||
preset_names.add(lora_name)
|
||||
|
||||
# Start with preset, add non-duplicate connected loras
|
||||
merged = list(preset_stack)
|
||||
for lora_path, model_strength, clip_strength in connected_stack:
|
||||
lora_name = os.path.splitext(os.path.basename(lora_path))[0]
|
||||
if lora_name not in preset_names:
|
||||
merged.append((lora_path, model_strength, clip_strength))
|
||||
|
||||
return merged
|
||||
|
||||
def _process_lora_toggle(self, lora_stack, toggle_data):
|
||||
"""
|
||||
Process lora stack with toggle data to filter active loras and apply strength adjustments.
|
||||
|
||||
Args:
|
||||
lora_stack: List of tuples (lora_path, model_strength, clip_strength)
|
||||
toggle_data: JSON string or list of toggle states [{name, active, strength}, ...]
|
||||
|
||||
Returns:
|
||||
Filtered lora stack with adjusted strengths
|
||||
"""
|
||||
if not lora_stack:
|
||||
return []
|
||||
|
||||
if not toggle_data:
|
||||
return list(lora_stack)
|
||||
|
||||
# Parse toggle data if it's a string
|
||||
try:
|
||||
if isinstance(toggle_data, str):
|
||||
toggle_data = json.loads(toggle_data)
|
||||
except (json.JSONDecodeError, TypeError):
|
||||
return list(lora_stack)
|
||||
|
||||
if not isinstance(toggle_data, list):
|
||||
return list(lora_stack)
|
||||
|
||||
# Create a map of toggle states by lora name
|
||||
toggle_map = {}
|
||||
for item in toggle_data:
|
||||
if isinstance(item, dict):
|
||||
name = item.get('name', '')
|
||||
toggle_map[name] = {
|
||||
'active': item.get('active', True),
|
||||
'strength': item.get('strength')
|
||||
}
|
||||
|
||||
# Filter and adjust lora stack
|
||||
filtered_stack = []
|
||||
for lora_path, model_strength, clip_strength in lora_stack:
|
||||
# Extract lora name from path
|
||||
lora_name = os.path.splitext(os.path.basename(lora_path))[0]
|
||||
|
||||
# Check toggle state
|
||||
toggle_state = toggle_map.get(lora_name, {'active': True, 'strength': None})
|
||||
|
||||
if not toggle_state['active']:
|
||||
continue # Skip inactive loras
|
||||
|
||||
# Apply strength adjustment if provided
|
||||
if toggle_state['strength'] is not None:
|
||||
adjusted_strength = float(toggle_state['strength'])
|
||||
# Scale both model and clip strength proportionally
|
||||
ratio = adjusted_strength / model_strength if model_strength != 0 else 1.0
|
||||
model_strength = adjusted_strength
|
||||
clip_strength = clip_strength * ratio
|
||||
|
||||
filtered_stack.append((lora_path, model_strength, clip_strength))
|
||||
|
||||
return filtered_stack
|
||||
|
||||
def get_prompt(self, category, name, use_external, text="", override_lora=False, llm_input="",
|
||||
lora_stack_a=None, lora_stack_b=None,
|
||||
unique_id=None, loras_a_toggle=None, loras_b_toggle=None):
|
||||
"""Return the prompt text and filtered lora stacks based on toggle states"""
|
||||
|
||||
# Choose which text to use based on the toggle
|
||||
if use_external and llm_input:
|
||||
output_text = llm_input
|
||||
else:
|
||||
output_text = text
|
||||
|
||||
# Build preset stacks from saved toggle data (these are what we display/manage)
|
||||
preset_stack_a = self._build_stack_from_toggle(loras_a_toggle) if loras_a_toggle else []
|
||||
preset_stack_b = self._build_stack_from_toggle(loras_b_toggle) if loras_b_toggle else []
|
||||
|
||||
# When override_lora is enabled, ignore connected stacks and use only saved loras
|
||||
if override_lora:
|
||||
lora_stack_a = preset_stack_a
|
||||
lora_stack_b = preset_stack_b
|
||||
else:
|
||||
# Merge: preset loras + connected loras (avoiding duplicates by lora name)
|
||||
lora_stack_a = self._merge_lora_stacks(preset_stack_a, lora_stack_a)
|
||||
lora_stack_b = self._merge_lora_stacks(preset_stack_b, lora_stack_b)
|
||||
|
||||
# Process lora stacks with toggle data (filter inactive, apply strength)
|
||||
processed_stack_a = self._process_lora_toggle(lora_stack_a, loras_a_toggle)
|
||||
processed_stack_b = self._process_lora_toggle(lora_stack_b, loras_b_toggle)
|
||||
|
||||
# Display logic depends on override mode:
|
||||
# - Override ON: Show only preset loras (what will actually be used)
|
||||
# - Override OFF: Show merged loras (preset + connected) so user sees full picture
|
||||
if override_lora:
|
||||
loras_a_display = self._format_loras_for_display(preset_stack_a) if preset_stack_a else []
|
||||
loras_b_display = self._format_loras_for_display(preset_stack_b) if preset_stack_b else []
|
||||
else:
|
||||
loras_a_display = self._format_loras_for_display(lora_stack_a) if lora_stack_a else []
|
||||
loras_b_display = self._format_loras_for_display(lora_stack_b) if lora_stack_b else []
|
||||
|
||||
# Broadcast update to frontend
|
||||
if unique_id is not None:
|
||||
server.PromptServer.instance.send_sync("prompt-manager-advanced-update", {
|
||||
"node_id": unique_id,
|
||||
"prompt": output_text,
|
||||
"use_external": use_external,
|
||||
"llm_input": llm_input,
|
||||
"loras_a": loras_a_display,
|
||||
"loras_b": loras_b_display
|
||||
})
|
||||
|
||||
return (output_text, processed_stack_a if processed_stack_a else [], processed_stack_b if processed_stack_b else [])
|
||||
|
||||
def check_lazy_status(self, category, name, use_external, text, override_lora=False, llm_input=None,
|
||||
lora_stack_a=None, lora_stack_b=None,
|
||||
unique_id=None, loras_a_toggle=None, loras_b_toggle=None):
|
||||
"""Tell ComfyUI which lazy inputs are needed based on current settings"""
|
||||
needed = []
|
||||
if use_external:
|
||||
needed.append("llm_input")
|
||||
return needed
|
||||
|
||||
def _build_stack_from_toggle(self, toggle_data):
|
||||
"""
|
||||
Build a lora stack from toggle data by resolving paths at runtime.
|
||||
This is used when no input stack is connected but we have saved lora data.
|
||||
"""
|
||||
if not toggle_data:
|
||||
return []
|
||||
|
||||
# Parse toggle data if it's a string
|
||||
try:
|
||||
if isinstance(toggle_data, str):
|
||||
toggle_data = json.loads(toggle_data)
|
||||
except (json.JSONDecodeError, TypeError):
|
||||
return []
|
||||
|
||||
if not isinstance(toggle_data, list):
|
||||
return []
|
||||
|
||||
stack = []
|
||||
missing_loras = []
|
||||
|
||||
for item in toggle_data:
|
||||
if not isinstance(item, dict):
|
||||
continue
|
||||
|
||||
lora_name = item.get('name', '')
|
||||
if not lora_name:
|
||||
continue
|
||||
|
||||
# Resolve the path at runtime
|
||||
relative_path, found = get_lora_relative_path(lora_name)
|
||||
|
||||
if not found:
|
||||
missing_loras.append(lora_name)
|
||||
continue # Skip missing loras
|
||||
|
||||
strength = float(item.get('strength', 1.0))
|
||||
clip_strength = float(item.get('clip_strength', strength))
|
||||
|
||||
stack.append((relative_path, strength, clip_strength))
|
||||
|
||||
# Log warning for missing loras
|
||||
if missing_loras:
|
||||
print(f"[PromptManagerAdvanced] Warning: Could not find LoRAs: {', '.join(missing_loras)}")
|
||||
|
||||
return stack
|
||||
|
||||
def _format_loras_for_display(self, lora_stack):
|
||||
"""Format lora stack for frontend display"""
|
||||
if not lora_stack:
|
||||
return []
|
||||
|
||||
display_list = []
|
||||
for lora_path, model_strength, clip_strength in lora_stack:
|
||||
lora_name = os.path.splitext(os.path.basename(lora_path))[0]
|
||||
display_list.append({
|
||||
"name": lora_name,
|
||||
"path": lora_path,
|
||||
"model_strength": model_strength,
|
||||
"clip_strength": clip_strength,
|
||||
"active": True,
|
||||
"strength": model_strength
|
||||
})
|
||||
return display_list
|
||||
|
||||
|
||||
# API Routes for Advanced Prompt Manager
|
||||
|
||||
@server.PromptServer.instance.routes.get("/prompt-manager-advanced/get-prompts")
|
||||
async def get_prompts_advanced(request):
|
||||
"""API endpoint to get all advanced prompts"""
|
||||
try:
|
||||
prompts = PromptManagerAdvanced.load_prompts()
|
||||
return server.web.json_response(prompts)
|
||||
except Exception as e:
|
||||
print(f"[PromptManagerAdvanced] Error in get_prompts API: {e}")
|
||||
return server.web.json_response({"error": str(e)}, status=500)
|
||||
|
||||
|
||||
@server.PromptServer.instance.routes.post("/prompt-manager-advanced/save-category")
|
||||
async def save_category_advanced(request):
|
||||
"""API endpoint to create a new category"""
|
||||
try:
|
||||
data = await request.json()
|
||||
category_name = data.get("category_name", "").strip()
|
||||
|
||||
if not category_name:
|
||||
return server.web.json_response({"success": False, "error": "Category name is required"})
|
||||
|
||||
prompts = PromptManagerAdvanced.load_prompts()
|
||||
|
||||
# Case-insensitive check for existing category
|
||||
existing_categories_lower = {k.lower(): k for k in prompts.keys()}
|
||||
if category_name.lower() in existing_categories_lower:
|
||||
return server.web.json_response({
|
||||
"success": False,
|
||||
"error": f"Category already exists as '{existing_categories_lower[category_name.lower()]}'"
|
||||
})
|
||||
|
||||
prompts[category_name] = {}
|
||||
PromptManagerAdvanced.save_prompts(prompts)
|
||||
|
||||
return server.web.json_response({"success": True, "prompts": prompts})
|
||||
except Exception as e:
|
||||
print(f"[PromptManagerAdvanced] Error in save_category API: {e}")
|
||||
return server.web.json_response({"success": False, "error": str(e)}, status=500)
|
||||
|
||||
|
||||
@server.PromptServer.instance.routes.post("/prompt-manager-advanced/save-prompt")
|
||||
async def save_prompt_advanced(request):
|
||||
"""API endpoint to save a prompt with lora configurations"""
|
||||
try:
|
||||
data = await request.json()
|
||||
category = data.get("category", "").strip()
|
||||
name = data.get("name", "").strip()
|
||||
text = data.get("text", "").strip()
|
||||
loras_a = data.get("loras_a", [])
|
||||
loras_b = data.get("loras_b", [])
|
||||
|
||||
if not category or not name:
|
||||
return server.web.json_response({"success": False, "error": "Category and name are required"})
|
||||
|
||||
prompts = PromptManagerAdvanced.load_prompts()
|
||||
|
||||
if category not in prompts:
|
||||
prompts[category] = {}
|
||||
|
||||
# Case-insensitive check for existing prompt
|
||||
existing_prompts_lower = {k.lower(): k for k in prompts[category].keys()}
|
||||
if name.lower() in existing_prompts_lower:
|
||||
old_name = existing_prompts_lower[name.lower()]
|
||||
if old_name != name:
|
||||
# Delete the old casing version
|
||||
print(f"[PromptManagerAdvanced] Removing old casing '{old_name}' before saving as '{name}'")
|
||||
del prompts[category][old_name]
|
||||
|
||||
# Normalize lora data - only save name and strengths
|
||||
# Inactive loras are not saved (filtered out by frontend)
|
||||
# Paths are resolved at runtime for portability
|
||||
def normalize_lora_data(loras):
|
||||
normalized = []
|
||||
for lora in loras:
|
||||
if isinstance(lora, dict) and lora.get('name'):
|
||||
normalized.append({
|
||||
"name": lora.get('name'),
|
||||
"strength": lora.get('strength', lora.get('model_strength', 1.0)),
|
||||
"clip_strength": lora.get('clip_strength', lora.get('strength', 1.0))
|
||||
})
|
||||
return normalized
|
||||
|
||||
# Save prompt with normalized lora data (no paths - they're resolved at runtime)
|
||||
prompts[category][name] = {
|
||||
"prompt": text,
|
||||
"loras_a": normalize_lora_data(loras_a),
|
||||
"loras_b": normalize_lora_data(loras_b)
|
||||
}
|
||||
PromptManagerAdvanced.save_prompts(prompts)
|
||||
|
||||
return server.web.json_response({"success": True, "prompts": prompts})
|
||||
except Exception as e:
|
||||
print(f"[PromptManagerAdvanced] Error in save_prompt API: {e}")
|
||||
return server.web.json_response({"success": False, "error": str(e)}, status=500)
|
||||
|
||||
|
||||
@server.PromptServer.instance.routes.post("/prompt-manager-advanced/delete-category")
|
||||
async def delete_category_advanced(request):
|
||||
"""API endpoint to delete a category"""
|
||||
try:
|
||||
data = await request.json()
|
||||
category = data.get("category", "").strip()
|
||||
|
||||
if not category:
|
||||
return server.web.json_response({"success": False, "error": "Category name is required"})
|
||||
|
||||
prompts = PromptManagerAdvanced.load_prompts()
|
||||
|
||||
if category not in prompts:
|
||||
return server.web.json_response({"success": False, "error": "Category not found"})
|
||||
|
||||
del prompts[category]
|
||||
PromptManagerAdvanced.save_prompts(prompts)
|
||||
|
||||
return server.web.json_response({"success": True, "prompts": prompts})
|
||||
except Exception as e:
|
||||
print(f"[PromptManagerAdvanced] Error in delete_category API: {e}")
|
||||
return server.web.json_response({"success": False, "error": str(e)}, status=500)
|
||||
|
||||
|
||||
@server.PromptServer.instance.routes.post("/prompt-manager-advanced/delete-prompt")
|
||||
async def delete_prompt_advanced(request):
|
||||
"""API endpoint to delete a prompt"""
|
||||
try:
|
||||
data = await request.json()
|
||||
category = data.get("category", "").strip()
|
||||
name = data.get("name", "").strip()
|
||||
|
||||
if not category or not name:
|
||||
return server.web.json_response({"success": False, "error": "Category and prompt name are required"})
|
||||
|
||||
prompts = PromptManagerAdvanced.load_prompts()
|
||||
|
||||
if category not in prompts or name not in prompts[category]:
|
||||
return server.web.json_response({"success": False, "error": "Prompt not found"})
|
||||
|
||||
del prompts[category][name]
|
||||
PromptManagerAdvanced.save_prompts(prompts)
|
||||
|
||||
return server.web.json_response({"success": True, "prompts": prompts})
|
||||
except Exception as e:
|
||||
print(f"[PromptManagerAdvanced] Error in delete_prompt API: {e}")
|
||||
return server.web.json_response({"success": False, "error": str(e)}, status=500)
|
||||
|
||||
|
||||
@server.PromptServer.instance.routes.post("/prompt-manager-advanced/check-loras")
|
||||
async def check_loras_advanced(request):
|
||||
"""API endpoint to check which LoRAs are available in the system"""
|
||||
try:
|
||||
data = await request.json()
|
||||
lora_names = data.get("lora_names", [])
|
||||
|
||||
results = {}
|
||||
for lora_name in lora_names:
|
||||
_, found = get_lora_relative_path(lora_name)
|
||||
results[lora_name] = found
|
||||
|
||||
return server.web.json_response({"success": True, "results": results})
|
||||
except Exception as e:
|
||||
print(f"[PromptManagerAdvanced] Error in check_loras API: {e}")
|
||||
return server.web.json_response({"success": False, "error": str(e)}, status=500)
|
||||
|
||||
|
||||
@server.PromptServer.instance.routes.get("/prompt-manager-advanced/available-loras")
|
||||
async def get_available_loras_api(request):
|
||||
"""API endpoint to get list of all available LoRA names"""
|
||||
try:
|
||||
lora_files = get_available_loras()
|
||||
# Return just the names without extensions for easier matching
|
||||
lora_names = [os.path.splitext(os.path.basename(f))[0] for f in lora_files]
|
||||
return server.web.json_response({"success": True, "loras": sorted(set(lora_names))})
|
||||
except Exception as e:
|
||||
print(f"[PromptManagerAdvanced] Error in available_loras API: {e}")
|
||||
return server.web.json_response({"success": False, "error": str(e)}, status=500)
|
||||
|
||||
|
||||
@server.PromptServer.instance.routes.post("/prompt-manager-advanced/get-prompt-data")
|
||||
async def get_prompt_data_advanced(request):
|
||||
"""API endpoint to get specific prompt data including loras with availability check"""
|
||||
try:
|
||||
data = await request.json()
|
||||
category = data.get("category", "").strip()
|
||||
name = data.get("name", "").strip()
|
||||
|
||||
if not category or not name:
|
||||
return server.web.json_response({"success": False, "error": "Category and name are required"})
|
||||
|
||||
prompts = PromptManagerAdvanced.load_prompts()
|
||||
|
||||
if category not in prompts or name not in prompts[category]:
|
||||
return server.web.json_response({"success": False, "error": "Prompt not found"})
|
||||
|
||||
prompt_data = prompts[category][name]
|
||||
|
||||
# Add availability info to loras
|
||||
def add_availability(loras):
|
||||
result = []
|
||||
for lora in loras:
|
||||
lora_copy = dict(lora)
|
||||
_, found = get_lora_relative_path(lora.get('name', ''))
|
||||
lora_copy['available'] = found
|
||||
result.append(lora_copy)
|
||||
return result
|
||||
|
||||
return server.web.json_response({
|
||||
"success": True,
|
||||
"data": {
|
||||
"prompt": prompt_data.get("prompt", ""),
|
||||
"loras_a": add_availability(prompt_data.get("loras_a", [])),
|
||||
"loras_b": add_availability(prompt_data.get("loras_b", []))
|
||||
}
|
||||
})
|
||||
except Exception as e:
|
||||
print(f"[PromptManagerAdvanced] Error in get_prompt_data API: {e}")
|
||||
return server.web.json_response({"success": False, "error": str(e)}, status=500)
|
||||
@@ -0,0 +1 @@
|
||||
Describe this image in detail, making sure to cover all visual aspects comprehensively, as well as the position of each element.
|
||||
@@ -0,0 +1,10 @@
|
||||
You are an expert visual analyst.
|
||||
|
||||
#### Guidelines:
|
||||
- First, analyze the provided images and note the concrete visual facts: subjects and their characteristics, actions and poses, spatial relationships, composition and framing, lighting and atmosphere, color palette, material textures, background details, camera angle and perspective, and any visible text (enclose visible text in double quotes "").
|
||||
- After analyzing the image, follow the user's prompt: apply the user's requested focus, style, or constraints to shape the final description.
|
||||
- Preserve the observed visual facts from the image but prioritize the user's instructions for tone, emphasis, or additional elements.
|
||||
- Be concrete and objective; avoid metaphor and speculation.
|
||||
|
||||
#### Output Format:
|
||||
- Output only the final description that combines the image analysis with the user's prompt.
|
||||
@@ -0,0 +1,12 @@
|
||||
You are an expert visual analyst creating detailed descriptions for text-to-image generation.
|
||||
|
||||
#### Guidelines:
|
||||
- Analyze the provided images and create a comprehensive visual description that captures all essential elements: subjects and their characteristics, actions and poses, spatial positioning, composition and framing, lighting and atmosphere, color palette, artistic style, mood and emotion, background details, camera angle and perspective, material textures, and any visible text.
|
||||
- Your description must be concrete, objective, and detailed enough that it could be used to recreate a similar image.
|
||||
- Focus on visual elements only, avoiding interpretation or metaphor.
|
||||
- If there is visible text in the image, enclose it in double quotes ("").
|
||||
- If an element, text or other is not needed or seen, then simply don't mention them.
|
||||
- If more than one image is provided you are free to combine them as you see fit.
|
||||
|
||||
#### Output Format:
|
||||
- Only output the final description.
|
||||
@@ -0,0 +1,12 @@
|
||||
Your response should be formatted as a JSON with these fields:
|
||||
- scene (overall description)
|
||||
- subjects (array with description/position/action for each)
|
||||
- style
|
||||
- color_palette
|
||||
- lighting
|
||||
- mood
|
||||
- background
|
||||
- composition
|
||||
- camera
|
||||
|
||||
If you deem extra fields are necessary, feel free to add them, but do not add a title or fields not related to visual description.
|
||||
@@ -0,0 +1,19 @@
|
||||
You are an imaginative visual artist imprisoned in a cage of logic. Your mind is filled with poetry and distant horizons, but your hands are uncontrollably driven to convert the user's prompt into a final visual description that is faithful to the original intent, rich in detail, aesthetically pleasing, and ready to be used directly by a text-to-image model. Any trace of vagueness or metaphor makes you extremely uncomfortable.
|
||||
|
||||
#### Workflow:
|
||||
- First, you analyze and lock in the immutable core elements of the user's prompt: subject, quantity, actions, states, and any specified IP names, colors, text, and similar items. These are the foundational stones that you must preserve without exception.
|
||||
- Next, you determine whether the prompt requires "generative reasoning". When the user's request is not a straightforward scene description but instead demands designing a solution (for example, answering "what is", doing a "design", or showing "how to solve a problem"), you must first construct in your mind a complete, concrete, and visualizable solution. This solution becomes the basis for your subsequent description.
|
||||
- Then, once the core image has been established (whether it comes directly from the user or from your reasoning), you inject professional-level aesthetics and realism into it. This includes clarifying the composition, setting the lighting and atmosphere, describing material textures, defining the color scheme, and building a spatial structure with strong depth and layering.
|
||||
- Finally, you handle all textual elements with absolute precision, which is a critical step. You must not add text if the initial prompt did not ask for it. But if there is, you must transcribe, without a single character of deviation, all text that should appear in the final image, and you must enclose all such text content in English double quotes ("") to mark it as an explicit generation instruction.
|
||||
|
||||
#### Text Handling:
|
||||
- If the image belongs to a design category such as a poster, menu, or UI, you need to fully describe all the textual content it contains and elaborate on its fonts and layout.
|
||||
- Likewise, if there are objects in the scene such as signs, billboards, road signs, or screens that contain text, you must specify their exact content and describe their position, size, and material.
|
||||
- Furthermore, if in your reasoning you introduce new elements that contain text (such as charts, solution steps, and so on), all of their text must follow the same detailed description and quoting rules.
|
||||
- If there is no text that needs to be generated in the image, you devote all your effort to purely visual detail expansion.
|
||||
|
||||
#### Important notes:
|
||||
- Your final description must be objective and concrete, strictly forbidding metaphors and emotionally charged rhetoric.
|
||||
- If an element, text or other is not needed or seen, then simply don't mention them.
|
||||
- Do not add the original prompt, either by itself or as a title in your reply.
|
||||
- Only output your newly generated prompt.
|
||||
@@ -0,0 +1,30 @@
|
||||
You are a prompt specialist crafting brief, motion-centric descriptions for image-to-video synthesis. Using the provided image (starting frame) and the user's Raw Input Prompt, produce a description that directs video generation from that visual.
|
||||
|
||||
#### Core Principles:
|
||||
- Study the Image: Note the subject, environment, key elements, artistic style, and atmosphere.
|
||||
- Honor the Raw Input Prompt: Incorporate every requested movement, action, camera behavior, sound, and detail. When the input contradicts the image, favor the user's intent but preserve visual coherence (explain the shift from image to desired scene).
|
||||
- Focus on what changes: Avoid repeating what the image already shows. Redundant or incorrect descriptions risk jarring cuts.
|
||||
- Present-tense verbs: Write with ongoing action ("is running," "are laughing"). Without explicit motion, depict subtle natural movement.
|
||||
- Time-ordered narrative: Link events with words like "as," "then," "meanwhile."
|
||||
- Woven soundscape: Integrate audio descriptions alongside visuals throughout—never tack them on at the end. Match sound intensity to the pace of action. Cover environmental noise, ambient layers, sound effects, dialogue, or music (when asked). Be precise (e.g., "muffled traffic through glass") rather than generic (e.g., "background noise").
|
||||
- Dialogue (when indicated): Supply exact quoted speech along with the speaker's appearance and vocal quality (e.g., "The elderly woman says in a soft, raspy voice"). Specify language or accent when relevant. If the user mentions conversation without specific lines, create fitting dialogue in quotes. (Example: input "The man is chatting" → output includes actual words: "The man leans forward, speaking eagerly: 'Did you hear the news?' His eyes widen with curiosity as a faint hum of air conditioning fills the room.")
|
||||
- Style tag: Place the visual style at the start: "Style: <style>, <rest of prompt>." Omit if uncertain to prevent clashes.
|
||||
- Sight and sound exclusively: Convey only visible and audible elements. Exclude smell, taste, or touch.
|
||||
- Understated tone: Steer clear of exaggerated or melodramatic language. Keep phrasing calm and naturalistic.
|
||||
|
||||
#### Constraints:
|
||||
- Camera work: Never fabricate camera motion unless the user explicitly asks for it. Include only what the input specifies.
|
||||
- Dialogue fidelity: Preserve the user's exact spoken lines—correct only obvious typos.
|
||||
- No timecodes or cuts: Avoid timestamps or scene breaks unless the user requests them.
|
||||
- Observable facts only: Report actions and sounds without inferring feelings or motives.
|
||||
- Opening phrasing: Skip introductions like "The scene begins with..." or "The video opens on...". Jump straight into the Style prefix (if applicable) and the sequential description.
|
||||
- First character: Never begin output with punctuation or symbols.
|
||||
- Uninvited speech: Create dialogue only when the user references speaking, singing, or conversation.
|
||||
- Execution matters: Precise, vivid, faithful prompts with seamlessly embedded audio are vital for quality video output. Aim for perfect adherence to these rules.
|
||||
|
||||
#### Output Requirements (Strict):
|
||||
- Deliver one compact paragraph in fluent English. No headers, labels, introductions, sections, code blocks, or Markdown formatting.
|
||||
- If the request is unsafe or invalid, echo the user's original prompt unchanged. Never pose questions or seek clarification.
|
||||
|
||||
#### Sample output:
|
||||
Style: warm - naturalistic - A young man sits at his desk, tapping his pen against a notebook as rain patters steadily on the window behind him. He exhales and mutters in a low, contemplative voice, "Maybe tomorrow will be different." The soft creak of his chair mingles with the rhythmic drumming of raindrops, while distant thunder rumbles faintly beyond the glass.
|
||||
+30
-4
@@ -1,11 +1,37 @@
|
||||
[project]
|
||||
name = "comfyui-prompt-manager"
|
||||
description = "Prompt Manager for ComfyUI, with llama.cpp integration for prompt generation and vision analysis. Organize, generate, and save prompts with local LLM support."
|
||||
version = "1.7.0"
|
||||
name = "prompt-manager"
|
||||
description = "Prompt Manager extension for ComfyUI, allowing user to both save and generate prompts, as well as save matching loras for each prompt."
|
||||
version = "1.9.1"
|
||||
license = {file = "LICENSE"}
|
||||
# classifiers = [
|
||||
# # For OS-independent nodes (works on all operating systems)
|
||||
# "Operating System :: OS Independent",
|
||||
#
|
||||
# # OR for OS-specific nodes, specify the supported systems:
|
||||
# "Operating System :: Microsoft :: Windows", # Windows specific
|
||||
# "Operating System :: POSIX :: Linux", # Linux specific
|
||||
# "Operating System :: MacOS", # macOS specific
|
||||
#
|
||||
# # GPU Accelerator support. Pick the ones that are supported by your extension.
|
||||
# "Environment :: GPU :: NVIDIA CUDA", # NVIDIA CUDA support
|
||||
# "Environment :: GPU :: AMD ROCm", # AMD ROCm support
|
||||
# "Environment :: GPU :: Intel Arc", # Intel Arc support
|
||||
# "Environment :: NPU :: Huawei Ascend", # Huawei Ascend support
|
||||
# "Environment :: GPU :: Apple Metal", # Apple Metal support
|
||||
# ]
|
||||
|
||||
dependencies = ["requests>=2.31.0", "huggingface_hub>=0.20.0", "psutil>=5.9.0", "tqdm>=4.66.0", "Pillow>=10.0.0", "torch>=2.0.0", "numpy>=1.24.0", "colorama"]
|
||||
|
||||
[project.urls]
|
||||
Repository = "https://github.com/FranckyB/ComfyUI-Prompt-Manager"
|
||||
# Used by Comfy Registry https://registry.comfy.org
|
||||
Documentation = "https://github.com/FranckyB/ComfyUI-Prompt-Manager/wiki"
|
||||
"Bug Tracker" = "https://github.com/FranckyB/ComfyUI-Prompt-Manager/issues"
|
||||
|
||||
[tool.comfy]
|
||||
PublisherId = "FranckyB"
|
||||
PublisherId = "franckyb"
|
||||
DisplayName = "ComfyUI-Prompt-Manager"
|
||||
Icon = ""
|
||||
includes = []
|
||||
# "requires-comfyui" = ">=1.0.0" # ComfyUI version compatibility
|
||||
|
||||
|
||||
@@ -5,3 +5,4 @@ tqdm>=4.66.0
|
||||
Pillow>=10.0.0
|
||||
torch>=2.0.0
|
||||
numpy>=1.24.0
|
||||
colorama
|
||||
Reference in New Issue
Block a user