Extensions/ComfyUI-LTX2PromptArchitectOllama
ComfyUI Extension

ComfyUI-LTX2PromptArchitectOllama

Generate LTX-Video 2.3 optimized prompts using a local Ollama LLM. Drop-in replacement with 100% local processing, no cloud API keys needed.

By cody-li·Created 2 months ago·Updated 2 months ago· 1
cody-li/ComfyUI-LTX2PromptArchitectOllama
Nodes
On cloudLocal install
Stars1
Updated2 months ago
Readme

LTX2 Prompt Architect (Ollama Edition)

Generate LTX-Video 2.3 optimized prompts using a local Ollama LLM.

Drop-in replacement for the proprietary LTX2PromptArchitectQwen node.

Features

  • 🏠 100% Local — Calls your local Ollama, no cloud API keys needed
  • 🎬 LTX-Video 2.3 Optimized — System prompt tuned for LTX-Video's attention mechanism
  • 🎛️ 6 Preset Selectors — Quality / Style / Mood / Camera / Lighting / Audio
  • 🖼️ Image-Aware — Accepts scene_context from Qwen-VL or other vision models
  • 🔄 Compatible — Same 3-output interface (PROMPT, NEG_PROMPT, PREVIEW) as the original node
  • 🪶 Zero Dependencies — Uses Python stdlib only (json, urllib, random)

Requirements

  • ComfyUI (any recent version)
  • Ollama running locally with a model installed
    • Recommended: qwen3.5-9b or qwen3-14b
    • Check available models: ollama list

Installation

cd ComfyUI/custom_nodes
git clone https://github.com/ForMyQQ/ComfyUI-LTX2PromptArchitectOllama.git
# Or copy the folder manually

Restart ComfyUI. The node will appear under LTX-Video/Prompt as 🔄 LTX2 Prompt Architect (Ollama).

Usage

  1. Make sure Ollama is running: ollama serve
  2. Add the node to your workflow
  3. Fill in user_input with your creative intent
  4. Optionally connect scene_context from a vision model (e.g. Qwen-VL)
  5. Adjust presets as needed
  6. Run — the node outputs PROMPT / NEG_PROMPT / PREVIEW

Wiring in AI2V Audio Workflow

Replace the original LTX2PromptArchitectQwen node:

| Original Output | This Node Output | Connect To | |---|---|---| | PROMPT | PROMPT | → CLIPTextEncode (positive) | | NEG_PROMPT | NEG_PROMPT | → Text Concatenate → CLIPTextEncode (negative) | | PREVIEW | PREVIEW | → ShowText (debug) |

Parameters

| Parameter | Type | Default | Description | |---|---|---|---| | user_input | STRING | "" | Your creative intent | | model_name | STRING | writer-fast-qwen3.5-9b-q8_0 | Ollama model name | | quality_preset | COMBO | 0.8 - Balanced Professional | Quality level | | max_tokens | INT | 512 | LLM max output tokens | | temperature | FLOAT | 0.7 | LLM sampling temperature | | seed | INT | -1 | Random seed (-1 = random) | | scene_context | STRING | "" | Image description from VL model | | frame_count | INT | 97 | Target frame count | | width | INT | 832 | Video width | | height | INT | 480 | Video height | | style | COMBO | None | Visual style override | | mood | COMBO | None | Emotional atmosphere | | camera | COMBO | None | Camera movement | | lighting | COMBO | None | Lighting style | | audio_style | COMBO | None | Audio generation hint | | ollama_base_url | STRING | http://localhost:11434 | Ollama API URL |

Troubleshooting

| Issue | Solution | |---|---| | Cannot connect to Ollama | Run ollama serve in a terminal | | model not found | Run ollama pull writer-fast-qwen3.5-9b-q8_0 | | LLM output is not valid JSON | Try lowering temperature or switching model | | Slow generation | Normal for CPU inference; GPU-accelerated Ollama is faster |

License

MIT License — see LICENSE.