# traumakom Prompt Generator โ€“ ComfyUI Node A powerful custom node for ComfyUI that generates rich, dynamic prompts based on modular JSON worlds โ€” with color realm control (RGB / CMYK), LoRA triggers, optional AI-based prompt enhancement, and a modular **Identity Mixer** to build consistent characters from reusable traits. > Created with passion by traumakom > Powered by Dante ๐Ÿˆโ€โฌ›, Helly ๐Ÿบ, and Lily ๐Ÿ’ป ## Main Nodes ### - Prompt Generator (main Node) image ### - Identity Mixer image ### - Connection Example image ## ๐ŸŒŸ Features ### PromptCreator Core - ๐Ÿ”ฎ Dynamic prompt generation from modular **JSON worlds** - ๐ŸŽจ `COLOR_REALM` support for **RGB / CMYK** palette-driven aesthetics - ๐Ÿงฉ LoRA trigger integration (e.g., `Realistic`, `Detailed Hands`) - ๐Ÿง  Optional AI enhancer (OpenAI / Cohere / Gemini / Ollama / llama.cpp) to rewrite or enrich prompts - ๐Ÿ“ Reads world data from `/JSON_DATA` - ๐Ÿงช Debug messages + error handling for smoother workflows - ๐Ÿ”„ Reload JSON worlds without restarting ComfyUI ### โœ… Identity Mixer (NEW) - ๐Ÿงฌ Modular identity generation via reusable traits - โ™ป๏ธ Trait library (`TRAITS`) + curated presets (`PRESETS`) - ๐ŸŽฒ Randomized or fixed identity attributes - ๐Ÿ“ด Optional ethnicity exclusion (`None`) - ๐Ÿงท Identity signature output for dataset consistency - ๐Ÿงผ Explicit trait syntax (e.g. `lavender hair`, `emerald eyes`) to avoid semantic bleed --- ## ๐Ÿ“ฆ Installation ### Using ComfyUI Manager 1. Open ComfyUI โ†’ Manager 2. Install from URL 3. Paste the GitHub repository URL ### Manual ```bash cd ComfyUI/custom_nodes git clone https://github.com/yourusername/PromptCreatorNode.git ``` --- ## ๐Ÿ“ Folder Structure ``` ComfyUI/ โ”œโ”€โ”€ custom_nodes/ โ”‚ โ””โ”€โ”€ PromptCreatorNode/ โ”‚ โ”œโ”€โ”€ PromptCreatorNode.py โ”‚ โ”œโ”€โ”€ IdentityMixerNode.py โ”œโ”€โ”€ JSON_DATA/ โ”‚ โ””โ”€โ”€ *.json โ”œโ”€โ”€ identity.json โ”œโ”€โ”€ identities.json โ”œโ”€โ”€ api_keys.txt ``` --- ## โš™๏ธ Usage ### PromptCreator 1. Select a JSON world 2. Enable AI enhancer (optional) 3. Generate prompt 4. Connect to CLIPTextEncode ### Identity Mixer 1. Select traits or presets 2. Use random or fixed values 3. Output identity string + signature 4. Append to prompt or dataset captions --- ## ๐ŸŒˆ identity.json Structure ### TRAITS Reusable identity components: ```json { "TRAITS": { "hair_color": ["lavender hair", "cobalt-blue hair"], "eyes_color": ["emerald eyes", "icy gray eyes"], "ethnicity": ["None", "Mediterranean", "East Asian"] } } ``` ### PRESETS Optional curated identities: ```json { "PRESETS": { "Kira_Goth": { "hair_color": ["cobalt-blue hair"], "expression_base": ["quiet intensity"], "ethnicity": ["None"] } } } ``` --- ## ๐Ÿงช AI Enhancement Supports OpenAI, Cohere, and Gemini. API keys must be placed in `api_keys.txt`. --- ## โ˜• Support If you enjoy this project, consider supporting it on Ko-Fi. --- ## ๐Ÿ“œ License Free to use and remix. Star the repo if you like it โญ