Prompt Studio (TJ)
Prompt Studio (TJ)
- image
- clip
- prompt
- thought_process
Prompt Studio (TJ) is the all-in-one of the TJ LLM family: it's both a Prompt Enhancer (rewrite your text into the right model dialect) and an Image to Prompt (turn a picture into text), with the mode picked automatically from what you have connected. Connect an image and it captions/analyzes it; leave the image socket empty and it behaves exactly like the enhancer. One node, two jobs, no mode-switching by hand.
How it works
The mode widget gives you Auto (default), Image to Prompt, or Prompt Enhancer. In Auto, the presence of the optional image input decides: image connected → vision mode, otherwise text rewrite. When it's doing vision, the vision_task dropdown sets what you want out of the picture:
- Caption (plain description) - just describe it.
- Caption + Format - describe it, then rewrite the caption through the
model_formatrules below. - SD/Booru Tags - extract tag-style tokens, great for feeding back into tag-trained models.
- Pose & Anatomy Focus - analysis aimed at composition/pose detail.
- Content Quality Check - a review-style pass (feeds the pack's quality-gate workflows).
- Custom Instruction - your own ask in
custom_instruction.
Everything else mirrors the Prompt Enhancer: purpose (Image/Video/Edit/Custom), model_format (Krea2, Flux natural language, booru tags, LTX prose, and friends), aesthetic style injection, raw_prompt plus raw_prompt_input for a wired-in prompt, extra_instructions and system_prompt_override. The LLM knobs are the same too - model_backend (GGUF/llama.cpp or ComfyUI TextGenerate), gguf_model, mmproj_file (needed for the vision mode, it's the multimodal projector), n_gpu_layers, n_ctx, max_tokens, temperature, top_p, repeat_penalty, seed, and lock_in.
Outputs: prompt (the result) and thought_process (reasoning trace). Wireless is built in via get_name_prompt / get_name_image and set_name, so a remote prompt or image can be received and the result published without wires.
Installing it
Standard pack install:
cd ComfyUI/custom_nodes
git clone https://github.com/designloves2/ComfyUI-TJ_NODE
Then the LLM setup: llama-cpp-python (GPU build via build_llama_gemma4.bat / LLAMA_GPU_SETUP.md for speed and newest-model support), and GGUF files in ComfyUI/models/text_encoders/. For vision you need both the main GGUF and its mmproj projector file - the pack recommends Qwen2.5-VL 3B/7B (bartowski's quantized versions) or MiniCPM-V if you're tight on VRAM.
The honest take
Prompt Studio is the node to reach for if you do a lot of img2img and image-conditioned work - one node that captions a reference and rewrites prompts for the same model saves you from juggling two separate LLM setups. The gotcha is the usual one for this pack's LLM nodes: it's only as good as your GGUF setup, and a CPU-only llama-cpp build will make every vision call slow enough to annoy you. Get the GPU build right once and it's the rare single node that actually replaces two.
Inputs (30)
| Name | Type | Default | Description |
|---|---|---|---|
| get_name_prompt | COMBO | (none) | 1 options: (none) |
| get_name_image | COMBO | (none) | 1 options: (none) |
| set_name | STRING | Prompt_Studio | — |
| mode | COMBO | Auto | 3 options: Auto, Image to Prompt, Prompt Enhancer |
| raw_prompt | STRING | — | |
| model_backend | COMBO | GGUF / llama.cpp | 2 options: GGUF / llama.cpp, ComfyUI TextGenerate |
| gguf_model | COMBO | qwen3.5-4B-Uncensored-HauhauCS-Aggressive-Q8_0.gguf | 1 options: qwen3.5-4B-Uncensored-HauhauCS-Aggressive-Q8_0.gguf |
| mmproj_file | COMBO | mmproj-qwen3.5-4B-Uncensored-HauhauCS-Aggressive-BF16.gguf | 2 options: none, mmproj-qwen3.5-4B-Uncensored-HauhauCS-Aggressive-BF16.gguf |
| chat_handler | COMBO | 1 options: NO_VISION_HANDLERS_AVAILABLE | |
| text_encoder_name | COMBO | gemma4_e4b_it_fp8_scaled.safetensors | 1 options: gemma4_e4b_it_fp8_scaled.safetensors |
| clip_loader_type | COMBO | Auto | 29 options: Auto, krea2, stable_diffusion, stable_cascade, sd3, stable_audio, +23 |
| purpose | COMBO | 4 options: Image, Video, Edit (Inpainting/I2V), Custom | |
| vision_task | COMBO | 6 options: Caption (plain description), Caption + Format (apply model_format below), SD/Booru Tags, Pose & Anatomy Focus, Content Quality Check, Custom Instruction | |
| model_format | COMBO | 15 options: KREA2 (Prompt Enhance), Flux & Chroma (natural language), Z-Image & Lumina-2 (LLM text encoder), HiDream (hybrid prose + descriptors), SDXL (tags + weights), SD 1.5 (tags + weights), +9 | |
| aesthetic | COMBO | 22 options: None (no aesthetic injection), Photorealistic, Cinematic Film, Anime / Manga, Studio Ghibli, Pixar / 3D Animation, +16 | |
| extra_instructions | STRING | — | |
| system_prompt_override | STRING | — | |
| custom_instruction | STRING | — | |
| append_no_think | BOOLEAN | true | — |
| n_gpu_layers | INT | -1-1–999 | — |
| n_ctx | INT | 4096512–32768 | — |
| max_tokens | INT | 100050–4096 | — |
| temperature | FLOAT | 0.700–2 | — |
| top_p | FLOAT | 0.900–1 | — |
| repeat_penalty | FLOAT | 1.151–2 | — |
| seed | INT | 00–18446744073709550000 | — |
| lock_in | BOOLEAN | false | — |
| raw_prompt_inputopt | STRING | — | |
| imageopt | IMAGE | — | |
| clipopt | CLIP | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| prompt | STRING | — |
| thought_process | STRING | — |