Files
FranckyB-ComfyUI-Prompt-Man…/workflows/api/z_image_api.json
T
FranckyB 866ca71053 feat: template-driven execution engine + WAN split + collapsible UI
- workflow_executor.py: new in-process template execution engine
  - load_template() / patch_template() / execute_template()
  - WAN Video i2v latent via WanImageToVideo node
  - Dual-step math: total=high+low, high=[0..H], low=[H..100]
  - loras_to_text() for PromptApplyLora JSON serialisation

- workflow_families.py: split wan → wan_image / wan_video_i2v / wan_video_t2v
  - Added FAMILY_WORKFLOW_STEMS mapping family keys to api/ file stems
  - Sampler strategy: wan_image → single KSampler, wan_video → dual KSamplerAdvanced

- tools/convert_to_api.py: UI JSON → API JSON conversion script (8 workflows)

- workflows/api/: 16 new files (api.json + map.json) for:
  flux_1, flux_2, qwen_image, sdxl, wan_image, wan_video_i2v, wan_video_t2v, z_image

- workflow_generator.py:
  - execute() now uses template-driven path first (load_template → patch → execute_template)
  - Falls back to hardcoded samplers when no template exists (sd15, ltxv)
  - Added source_image optional param for WAN i2v
  - Added steps_high / steps_low override parsing from JS
  - Strategy check updated: wan → wan_video for both i2v and t2v

- workflow_generator.js:
  - makeSection(): collapsible with chevron toggle, all start collapsed
  - updateWanVisibility(): handles wan_image / wan_video_i2v / wan_video_t2v
  - Steps (High) / Steps (Low) rows added to SAMPLER section (WAN Video only)
  - Standard Steps row hidden when WAN Video family selected
  - LoRA Stack A title: 'LoRA Stack (High)' for WAN Video, 'LoRA Stack' otherwise
  - LoRA Stack B: visible only for wan_video_i2v / wan_video_t2v
  - Model B row: visible only for WAN Video families
  - syncHidden(), applyOverrides(), updateUI() updated for steps_high/steps_low
  - Section _setNode() wired up after _weRecalc is defined
2026-04-11 19:02:59 +00:00

111 lines
2.7 KiB
JSON

{
"95": {
"class_type": "EmptySD3LatentImage",
"inputs": {
"width": 1024,
"height": 1024,
"batch_size": 1
}
},
"96": {
"class_type": "VAELoader",
"inputs": {
"vae_name": "ae.safetensors"
}
},
"97": {
"class_type": "CLIPLoader",
"inputs": {
"clip_name": "qwen_3_4b.safetensors",
"type": "lumina2",
"device": "default"
}
},
"98": {
"class_type": "VAEDecode",
"inputs": {
"samples": [
"102",
0
],
"vae": [
"96",
0
]
}
},
"100": {
"class_type": "UNETLoader",
"inputs": {
"unet_name": "z_image_bf16.safetensors",
"weight_dtype": "default"
}
},
"102": {
"class_type": "KSampler",
"inputs": {
"model": [
"99",
0
],
"positive": [
"94",
0
],
"negative": [
"101",
0
],
"latent_image": [
"95",
0
],
"seed": 770044821593082,
"steps": 25,
"cfg": 4,
"sampler_name": "res_multistep",
"scheduler": "simple",
"denoise": 1
}
},
"94": {
"class_type": "CLIPTextEncode",
"inputs": {
"clip": [
"97",
0
],
"text": "A fashion photography work full of surreal romanticism, using a low-angle upward shooting composition, with a clear light blue sky as the background, and the visual focus concentrated on the fantasy blue vegetation and the model walking through it.\n\nThe vegetation in the picture is processed into varying shades of blue, from light ice blue to deep cobalt blue. The textures of the leaves and branches are delicate and realistic. The warm brown tree trunks form a sharp contrast with the cool blue leaves, resembling a dreamy forest from another world. An African-American model wearing a yellow and white vertical striped long dress walks slowly on the sand. The warm tones of the dress echo with the surrounding cool blue vegetation. The noon sun casts clear shadows on the sand, enhancing the sense of space and reality in the picture.\n\nThe entire scene, with its clean and transparent colors and fantasy settings, not only exudes the vastness of the natural wilderness but also presents a quiet and poetic high-fashion sense due to the surreal vegetation."
}
},
"101": {
"class_type": "CLIPTextEncode",
"inputs": {
"clip": [
"97",
0
],
"text": ""
}
},
"99": {
"class_type": "ModelSamplingAuraFlow",
"inputs": {
"model": [
"105",
0
],
"shift": 3
}
},
"105": {
"class_type": "PromptApplyLora",
"inputs": {
"model": [
"100",
0
],
"lora_stack_text": ""
}
}
}