Skip to content

verqqa/PromptNodethingLD

Repository files navigation

PromptNodethingLD

Cinematic AI prompt generation for ComfyUI — a custom node that runs a three-pass pipeline to produce high-quality, camera-locked cinematic prompts for LTX video generation using Gemma 4 26B (or Qwen) via llama.cpp.

Decide → Write → Check → Fix


What It Does

Most prompt nodes write once and hope for the best. PromptNodethingLD runs three passes:

  1. Choreography Pre-Pass — A fast JSON-forced call locks in a per-beat camera plan before writing. Style-specific allowed moves only, no drift.
  2. Main Generation — The LLM writes against the locked plan. Word budget scales with beat count (120 + 95 × beats).
  3. Lint + Auto-Repair — Regex checks catch teleport words, hype words, camera restatements, style violations, and speed conflicts. One surgical repair turn fires automatically if needed.

Features

  • Per-style camera palettes — each style enforces its own allowed moves (e.g. INTIMATE only allows dolly-in)
  • Per-style negative prompts sent directly to LTX conditioning — never through the LLM
  • JUMPCUT mode — every beat after the first opens with "The scene suddenly jump cuts to…", supporting insert shots, angle changes, and bounce-backs
  • LTX-2.3 guide rules baked in — main action first, one action per beat, chronological mechanics, explicit light source + direction
  • Camera LoRA hints — tells you which dolly/jib/static LoRAs match the generated plan
  • Cinematic UI — clapper-stripe header, viewfinder frame, filmstrip timeline, pulsing REC dot, gradient generate button

Requirements


Installation

1. Install llama.cpp

Windows: Install to C:\llama\ or use the included bat installer.

Linux / macOS:

mkdir -p ~/llama
# Download the llama-server binary from https://github.com/ggerganov/llama.cpp/releases
chmod +x ~/llama/llama-server

2. Download a model

Get a GGUF model from HuggingFace — both Gemma 4 26B and Qwen work well:

Model placement:

Platform Path
Windows C:\models\
Linux / macOS ~/models/

The mmproj filename must start with mmproj — rename it if needed. Example: mmproj-gemma-4-26b-a4b-it-heretic.q4_k_m.f16.gguf

VRAM guide:

  • 16 GB — q4_k_s (~13 GB) works well
  • 24 GB — q4_k_m (~15 GB) recommended
  • Don't use a model that fills your VRAM before generation starts — it hurts output quality

3. Install the node

Option A — ComfyUI Manager (recommended):

  1. Open Manager → Install via Git URL
  2. Paste this repo's URL
  3. Restart ComfyUI

Option B — Manual:

cd ComfyUI/custom_nodes
git clone https://github.com/YOUR_USERNAME/PromptNodethingLD.git

Then restart ComfyUI.

4. Load the workflow

Load workflowLD2.json from this repo into ComfyUI. The Cinematic Prompt LD node will appear in the canvas.


Models

Model Size (q4_k_m) VRAM Notes
Gemma 4 26B ~15 GB 24 GB Best output quality
Gemma 4 26B ~13 GB (q4_k_s) 16 GB Good balance
Qwen 2.5 varies varies Also supported

Cross-Platform Paths

The node auto-detects your OS:

if sys.platform == "win32":
    LLAMA_EXE  = r"C:\llama\llama-server.exe"
    MODELS_DIR = r"C:\models"
else:
    LLAMA_EXE  = os.path.expanduser("~/llama/llama-server")
    MODELS_DIR = os.path.expanduser("~/models")

Changelog

v4 — Current

  • Choreography pre-pass (JSON-forced camera plan before main generation)
  • Lint + auto-repair pass
  • Per-style negative prompts to LTX
  • Locked camera palettes per style
  • JUMPCUT mode
  • Scaled word budget (120 + 95 × beats)
  • LTX-2.3 guide rules baked in
  • Camera LoRA hints
  • Full cinematic UI redesign
  • Linux / macOS support

Credits

**Sean (Lora-Daddy

About

Cinematic AI prompt node for ComfyUI - three-pass pipeline (Decide -> Write -> Check -> Fix)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors