-
-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathFS_Types.py
More file actions
572 lines (494 loc) · 20 KB
/
FS_Types.py
File metadata and controls
572 lines (494 loc) · 20 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
# Project: FlowState Types
# Description: Global types for all nodes.
# Author: Johnathan Chivington
# Contact: flowstateeng@gmail.com | youtube.com/@flowstateeng
##
# FS IMPORTS
##
from .FS_Assets import *
from .FS_Constants import *
##
# OUTSIDE IMPORTS
##
import sys
import nodes
# -----------------------------------------------------------
# BEGIN GENERIC TYPES
# -----------------------------------------------------------
##
# ANY TYPE
##
class AnyType(str):
def __eq__(self, _) -> bool:
return True
def __ne__(self, __value: object) -> bool:
return False
TYPE_ANY = (AnyType('*'), {})
##
# GENERIC INPUT TYPES
##
# NUMERICAL
TYPE_FLOAT = ('FLOAT', {'default': 1, 'min': -sys.float_info.max, 'max': sys.float_info.max, 'step': 0.01, 'tooltip': (
f' Float\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - A floating point number.\n\n'
)})
TYPE_INT = ('INT', {'default': 1, 'min': -sys.maxsize, 'max': sys.maxsize, 'step': 1, 'tooltip': (
f' Integer\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - An integer number.\n\n'
)})
# LOGICAL
TYPE_BOOLEAN = ('BOOLEAN', {'default': True, 'tooltip': (
f' Boolean\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - A logical operator (True/False).\n\n'
)})
TYPE_BOOLEAN_FALSE = ('BOOLEAN', {'default': False, 'tooltip': (
f' Boolean (False)\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - A logical operator (True/False; default False).\n\n'
)})
TYPE_BOOLEAN_TRUE = ('BOOLEAN', {'default': True, 'tooltip': (
f' Boolean (True)\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - A logical operator (True/False; default True).\n\n'
)})
# STRING
TYPE_STRING_IN = ('STRING', {'default': 'Enter a value.', 'tooltip': (
f' String\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - String input (text).\n\n'
)})
TYPE_STRING_ML = ('STRING', {'multiline': True, 'default': 'Enter a value.', 'tooltip': (
f' Multiline String\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Multiline string input (text).\n\n'
)})
# IMAGE
TYPE_IMG_WIDTH = ('INT', {'default': 1024, 'min': 16, 'max': nodes.MAX_RESOLUTION, 'step': 1, 'tooltip': (
f' Width\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Defines the width of the image.\n\n'
)})
TYPE_IMG_HEIGHT = ('INT', {'default': 1024, 'min': 16, 'max': nodes.MAX_RESOLUTION, 'step': 1, 'tooltip': (
f' Height\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Defines the height of the image.\n\n'
)})
# VIDEO
TYPE_VIDEO_IN = ('VIDEO', {'tooltip': (
f' Video Input\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The video input.\n\n'
)})
# LATENT
TYPE_LATENT_IN = ('LATENT', {'tooltip': (
f' Latent Image\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Input latent image for diffusion sampling.\n\n'
)})
# SAMPLING
TYPE_POSITIVE_CONDITIONING = ('CONDITIONING', {'tooltip': (
f' Positive Conditioning\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Positive conditioning from encoded text prompt.\n\n'
)})
TYPE_NEGATIVE_CONDITIONING = ('CONDITIONING', {'tooltip': (
f' Negative Conditioning\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Negative conditioning from encoded text prompt.\n\n'
)})
TYPE_SEED = ('INT', {'default': 32, 'min': -sys.maxsize, 'max': sys.maxsize, 'step': 1, 'tooltip': (
f' Seed\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Seed used to generate inital random noise.\n\n'
)})
TYPE_STEPS = ('INT', {'default': 32, 'min': 1, 'max': 10000, 'tooltip': (
f' Steps\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Defines the number of steps to take in the sampling process.\n\n'
)})
TYPE_GUIDANCE = ('FLOAT', {'default': 3.2, 'min': 0.0, 'max': 100.0, 'step':0.1, 'round': 0.01, 'tooltip': (
f' Guidance\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Defines the number of steps to take in the sampling process.\n\n'
)})
TYPE_DENOISE = ('FLOAT', {
'default': 1.0, 'min': 0.0, 'max': 1.0, 'step': 0.01,
'tooltip': (
f' Sampler Denoise Amount\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The amount of denoising applied, lower values will maintain the structure of the initial image allowing for image to image sampling.\n\n'
)
})
TYPE_PROMPT_POSITIVE = ('STRING', {'multiline': True, 'default': '✅ Describe the image you want the model to create.', 'tooltip': (
f' Positive Prompt\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - ✅ Describe the image you want the model to create.\n\n'
)})
TYPE_PROMPT_NEGATIVE = ('STRING', {'multiline': True, 'default': '⛔ Describe what you do not want to see in the image.', 'tooltip': (
f' Positive Prompt\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - ⛔ Describe what you do not want to see in the image.\n\n'
)})
TYPE_TILED_DECODE = ('BOOLEAN', {'default': False, 'tooltip': (
f' Tiiled Decode\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - VAE decoding for large images can be a severe bottleneck.\n\n'
f' - Tiled decode helps reduce time by performing decoding on smaller chunks of the image instead of decoding the whole image at once.\n\n'
)})
# MODEL
TYPE_MODEL_IN = ('MODEL', {'tooltip': (
f' Input Model\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Diffusion model to be used in sampling.\n\n'
)})
TYPE_CLIP_IN = ('CLIP', {'tooltip': (
f' CLIP / Text Encoder Model\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The CLIP / Text Encoder model used for encoding the text.\n\n'
)})
TYPE_VAE_IN = ('VAE', {'tooltip': (
f' Variational AutoEncoder (VAE)\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The VAE model used for encoding and decoding images.\n\n'
)})
TYPE_CONTROL_NET_IN = ('CONTROL_NET', {'tooltip': (
f' Control Net\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The Control Net model used to patch your diffusion model.\n\n'
)})
TYPE_WEIGHT_DTYPE = (['default', 'fp8_e4m3fn', 'fp8_e4m3fn_fast', 'fp8_e5m2'], {'tooltip': (
f' Weight Datatype (DType)\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The data type to be used for your models weights.\n\n'
)})
# STYLE
TYPE_LORA_IN = ('LORA', {'tooltip': (
f' Low Rank Adaptation Model (LoRA)\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The LoRA used to patch your diffusion model.\n\n'
)})
TYPE_LORA_STRENGTH = ('FLOAT', {
'default': 1.0, 'min': 0.0, 'max': 1.0, 'step': 0.01,
'tooltip': (
f' Low Rank Adaptation Model (LoRA)\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The LoRA used to patch your diffusion model.\n\n'
)})
# MISC
TYPE_JSON_WIDGET = ('JSON', {'forceInput': True})
TYPE_METADATA_RAW = ('METADATA_RAW', {'forceInput': True})
##
# LIST INPUT TYPES
##
# MODELS
TYPE_DIFFUSION_MODELS_LIST = lambda: (DIFFUSION_MODELS_LIST(), {'tooltip': (
f' Diffusion Model List\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - List of available diffusion models.\n\n'
)})
TYPE_CHECKPOINTS_LIST = lambda: (CHECKPOINTS_LIST(), {'tooltip': (
f' Checkpoint List\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - List of available model checkpoints.\n\n'
)})
TYPE_CLIPS_LIST = lambda: (CLIPS_LIST(), {'tooltip': (
f' CLIP / Text Encoder List\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - List of available Text Encoders and CLIP models.\n'
f' - Used to convert your text prompts into semantic attention vectors (i.e., numbers) that the model can process.\n'
f' - Contrastive Language-Image Pre-training (CLIP)\n\n'
)})
TYPE_VAES_LIST = lambda: (VAES_LIST(), {'tooltip': (
f' VAE List\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - List of available Variational Autoencoders (VAE).\n'
f' - Used to encode and decode images.\n\n'
)})
TYPE_CONTROL_NETS_LIST = lambda: (['disabled'] + CONTROL_NETS_LIST(), {'tooltip': (
f' Control Net List\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - List of available Control Nets.\n'
f' - Used to transfer structure of an input image to a generated output image.\n\n'
)})
TYPE_LORAS_LIST = lambda: (['disabled'] + LORAS_LIST(), {'tooltip': (
f' LoRA List\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - List of available Low-Rank Adaptation models.\n'
f' - Used to transfer a pre-trained style (cyberpunk, anime, photorealism, disney, etc.) to a generated output image.\n\n'
)})
TYPE_ALL_MODEL_LISTS = lambda: (ALL_MODELS_LIST(), {'tooltip': (
f' Full Diffusion Model List\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - List of all available Diffusion Models (diffusion_models, checkpoints & unets folders).\n\n'
)})
# SAMPLING
TYPE_SAMPLERS = lambda: (SAMPLERS_LIST(), {'tooltip': (
f' Sampling Algorithm\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - List of available Sampling Algorithms.\n'
f' - Used to control the noise removal during the sampling process.\n\n'
)})
TYPE_SCHEDULERS = lambda: (SCHEDULERS_LIST(), {'tooltip': (
f' Scheduling Algorithm\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - List of available Scheduling Algorithms.\n'
f' - Used to control the denoising steps during the sampling process.\n\n'
)})
# FILES
TYPE_INPUT_FILES = lambda: (sorted(INPUT_FILES()), {'image_upload': True})
TYPE_OUTPUT_FILES = lambda: (sorted(OUTPUT_FILES()), {'image_upload': True})
##
# GENERIC OUTPUT TYPES
##
TYPE_MODEL = ('MODEL', )
TYPE_CONDITIONING = ('CONDITIONING', )
TYPE_STRING_OUT = ('STRING', )
TYPE_STRING_OUT_2 = ('STRING', 'STRING', )
TYPE_LATENT = ('LATENT', )
TYPE_IMAGE = ('IMAGE', )
# -----------------------------------------------------------
# BEGIN FLOWSTATE TYPES
# -----------------------------------------------------------
##
# FLOWSTATE CREATOR LABELS
##
def pad_label(label):
width = 100
len_label = len(label)
num_spaces = width - len_label
left_side = num_spaces // 2 - 10
right_side = num_spaces - left_side
padded_label = ' ' * left_side + '--- ' + label + ' ---' + ' ' * right_side
return padded_label
# GENERIC LABELS
TYPE_FLOWSTATE_LABEL_MODEL = ('STRING', {'default': pad_label('🤖 Model Settings'), 'tooltip': (
f' Label\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - This field is not functional. It is just a label for the group of settings below.\n\n'
)})
TYPE_FLOWSTATE_LABEL_AUG = ('STRING', {'default': pad_label('🔥 Augmentation Settings'), 'tooltip': (
f' Label\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - This field is not functional. It is just a label for the group of settings below.\n\n'
)})
TYPE_FLOWSTATE_LABEL_ENCODER = ('STRING', {'default': pad_label('🔣 Encoder Settings'), 'tooltip': (
f' Label\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - This field is not functional. It is just a label for the group of settings below.\n\n'
)})
TYPE_FLOWSTATE_LABEL_IMAGE = ('STRING', {'default': pad_label('🖼️ Image Settings'), 'tooltip': (
f' Label\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - This field is not functional. It is just a label for the group of settings below.\n\n'
)})
TYPE_FLOWSTATE_LABEL_VIDEO = ('STRING', {'default': pad_label('🎥 Video Settings'), 'tooltip': (
f' Label\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - This field is not functional. It is just a label for the group of settings below.\n\n'
)})
TYPE_FLOWSTATE_LABEL_SAVING = ('STRING', {'default': pad_label('💾 File Save Settings'), 'tooltip': (
f' Label\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - This field is not functional. It is just a label for the group of settings below.\n\n'
)})
TYPE_FLOWSTATE_LABEL_SAMPLING = ('STRING', {'default': pad_label('🧪 Sampling Settings'), 'tooltip': (
f' Label\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - This field is not functional. It is just a label for the group of settings below.\n\n'
)})
TYPE_FLOWSTATE_LABEL_PROMPT = ('STRING', {'default': pad_label('📝 Prompt(s)'), 'tooltip': (
f' Label\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - This field is not functional. It is just a label for the group of settings below.\n\n'
)})
TYPE_FLOWSTATE_LABEL_PROMPT_CHEF_QWEN = ('STRING', {'default': pad_label('✏️ Qwen Edit Prompt'), 'tooltip': (
f' Label\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - This field is not functional. It is just a label for the group of settings below.\n\n'
)})
TYPE_FLOWSTATE_LABEL_PROMPT_CHEF_FLUX = ('STRING', {'default': pad_label('✨ Flux Refinement Prompt'), 'tooltip': (
f' Label\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - This field is not functional. It is just a label for the group of settings below.\n\n'
)})
##
# FLOWSTATE CREATOR GENERIC TYPES
##
# BOOLEAN
TYPE_SEED_SELECT = ('BOOLEAN', {'default': True, 'tooltip': (
f' Fixed Output\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Choose to get the same output every time or get variations.\n\n'
)})
# SAGE ATTENTION
enabled_sage_modes = [
"disabled",
"auto",
"sageattn_qk_int8_pv_fp16_cuda",
"sageattn_qk_int8_pv_fp16_triton",
"sageattn_qk_int8_pv_fp8_cuda",
"sageattn_qk_int8_pv_fp8_cuda++"
] if SAGE_ATTENTION_INSTALLED else ['disabled']
TYPE_SAGE_ATTENTION_MODE = (enabled_sage_modes, {'tooltip': (
f' Sage Attention Mode\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The type of Sage Attention to use.\n'
f' - This field will only show as "disabled" if you do not have the capability to run Sage Attention.\n\n'
)})
# MODEL
TYPE_MODEL_FILE_TYPE = (['solo_model', 'checkpoint'], {'tooltip': (
f' Model File Type\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The type of model file to load.\n'
f' - Checkpoints (typically for fp8 models) contain the CLIP & VAE.\n'
f' - If using a checkpoint, then the weight_dtype, clip_1_name, clip_2_name & vae_name fields will ignored.\n\n'
)})
# VIDEO
TYPE_NUM_VIDEO_FRAMES = ('INT', {'default': 25, 'min': 1, 'max': nodes.MAX_RESOLUTION, 'step': 1, 'tooltip': (
f' Number of Video Frames\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The number of frames you want in your final video.\n\n'
)})
TYPE_FPS = ('INT', {'default': 12, 'min': 1, 'max': 120, 'tooltip': (
f' Frames Per Second\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The number of frames per second in the created video.\n\n'
)})
TYPE_AUDIO_IN = ('AUDIO', {'tooltip': (
f' Video Audio\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Optional audio to be added to the video.\n\n'
)})
TYPE_VIDEO_FORMAT = (['mp4', 'auto'], {
'tooltip': (
f' Video Format\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The format to save the video as.\n\n'
)
})
TYPE_SAVE_VIDEO_TYPE = (['mp4', 'gif'], {
'tooltip': (
f' Video Save Type\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Save the video as an MP4 or a GIF.\n\n'
)
})
TYPE_VIDEO_CODEC = (['h264', 'auto'], {
'tooltip': (
f' Video Codec\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The codec to use for the video.\n\n'
)
})
TYPE_FRAMES_IN = ('IMAGE', {'tooltip': (
f' Video Frames\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The frames used to create the video.\n\n'
)})
TYPE_BOOLEAN_SAVE_VIDEO = ('BOOLEAN', {'default': False, 'tooltip': (
f' Save Video\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Choose whether to save the video.\n\n'
)})
TYPE_FILENAME_PREFIX = ('STRING', {'default': 'video/WANStudio', 'tooltip': (
f' Filename Prefix\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The prefix for the file to save.\n'
f' - This may include formatting information such as %date:yyyy-MM-dd% or %Empty Latent Image.width% to include values from nodes.\n\n'
)})
##
# FLOWSTATE VIDEO CREATOR
##
# NONE
##
# FLOWSTATE SIMPLE LATENT
##
TYPE_SIMPLE_LATENT_INPUT_TYPE = (['Empty Latent', 'Input Image'], {
'tooltip': (
f' Latent Type\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Your choice of an empty latent (all zeros) or an image as a latent.\n\n'
)
})
##
# FLOWSTATE LATENT SOURCE
##
TYPE_LATENT_BATCH_SIZE = ('INT', {'default': 1, 'min': 1, 'max': 4096, 'tooltip': (
f' Custom Batch Size\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The number of images you want to generate.\n\n'
)})
TYPE_LATENT_SOURCE_INPUT_TYPE = (['Empty Latent', 'Input Image', 'Uploaded Image'], {
'tooltip': (
f' Latent Type\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Your choice of an empty latent (all zeros) or an image as a latent.\n\n'
)
})
TYPE_LATENT_SOURCE_RESOLUTION = ([
'Custom',
# HORIZONTAL
'1920x1080 - 16:9',
'1280x720 - 16:9',
'1280x768 - 5:3',
'1280x960 - 4:3',
'1024x768 - 4:3',
'2048x512 - 4:1',
'1152x896 - 9:7',
'4096x2048 - 2:1',
'2048x1024 - 2:1',
'1564x670 - 21:9',
'2212x948 - 21:9',
# SQUARE
'4096x4096 - 1:1',
'3072x3072 - 1:1',
'2048x2048 - 1:1',
'1024x1024 - 1:1',
'720x720 - 1:1',
'512x512 - 1:1'
], {
'tooltip': (
f' Resolution Selector\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Select "Custom" to use the entered custom_width & custom_height.\n'
f' - Select a preset resolution & orientation.\n\n'
)
})
TYPE_LATENT_SOURCE_ORIENTATION = (['Horizontal', 'Vertical'], {
'tooltip': (
f' Orientaion Selector\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Resolutions given in horizontal orientation. Select vertical to swap resolution aspect ratio.\n\n'
)
})
TYPE_LATENT_SOURCE_OUT = ('LATENT',)
##
# FLOWSTATE FLUX ENGINE
##
TYPE_PROMPT_FLUX_ENGINE = ('STRING', {'multiline': True, 'default': '✅ Describe the image you want Flux to create.', 'tooltip': (
f' Positive Prompt\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - ✅ Describe the image you want Flux to create.\n\n'
)})
TYPE_FLUX_ENGINE_OUT = ('MODEL', 'CLIP', 'VAE', 'IMAGE', 'LATENT')
##
# FLOWSTATE FLUX ENGINE
##
TYPE_FLUX_ENGINE_OUT = ('MODEL', 'CLIP', 'VAE', 'MODEL', 'CLIP', 'VAE', 'IMAGE', 'IMAGE')
##
# FLOWSTATE WAN STUDIO
##
TYPE_PROMPT_WAN_STUDIO_POSITIVE = ('STRING', {'multiline': True, 'default': '✅ Describe the video you want WAN to create.', 'tooltip': (
f' Positive Prompt\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - ✅ Describe the video you want WAN to create.\n\n'
)})
TYPE_PROMPT_WAN_STUDIO_NEGATIVE = ('STRING', {'multiline': True, 'default': '⛔ Describe what you do not want to see in the video.', 'tooltip': (
f' Positive Prompt\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - ⛔ Describe what you do not want to see in the video.\n\n'
)})
TYPE_WAN_STUDIO_STARTING_FRAME = ('IMAGE', {'tooltip': (
f' Starting Frame\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Optionally, select an input image to use as the starting frame.\n\n'
)})
TYPE_WAN_STUDIO_RESOLUTION = ([
'Custom',
'Use Starting Frame Resolution',
# HORIZONTAL
'1920x1080 - 16:9',
'1280x720 - 16:9',
'1280x768 - 5:3',
'1280x960 - 4:3',
'1024x768 - 4:3',
'2048x512 - 4:1',
'1152x896 - 9:7',
'4096x2048 - 2:1',
'2048x1024 - 2:1',
'1564x670 - 21:9',
'2212x948 - 21:9',
# SQUARE
'4096x4096 - 1:1',
'3072x3072 - 1:1',
'2048x2048 - 1:1',
'1024x1024 - 1:1',
'720x720 - 1:1',
'512x512 - 1:1'
], {
'tooltip': (
f' Resolution Selector\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Select "Custom" to use the entered custom_width & custom_height.\n'
f' - Select "Use Starting Frame Resolution" to use the resolution of the input image.\n'
f' - Select a preset resolution & orientation.\n\n'
)
})
TYPE_WAN_CLIP_VISION = ('CLIP_VISION', {'tooltip': (
f' CLIP Vision Output\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - Optionally, use a CLIP Vision model.\n\n'
)})
TYPE_WAN_STUDIO_OUT = ('VIDEO', )
TYPE_WAN_STUDIO_FILENAME_PREFIX = ('STRING', {'default': 'video/FlowState_WANStudio', 'tooltip': (
f' Filename Prefix\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The prefix for the file to save.\n'
f' - This may include formatting information such as %date:yyyy-MM-dd% or %Empty Latent Image.width% to include values from nodes.\n'
f' - This is ignored if you choose not to save the video.\n\n'
)})
##
# FLOWSTATE QUICK EDIT
##
TYPE_PROMPT_CHEF_QWEN = ('STRING', {'multiline': True, 'default': '✏️ Describe the edits you want Qwen to make.', 'tooltip': (
f' Edit Prompt\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - ✏️ Describe the edits you want Qwen to make.\n\n'
)})
TYPE_PROMPT_CHEF_FLUX = ('STRING', {'multiline': True, 'default': '✨ Describe the final output image after edits are made.', 'tooltip': (
f' Refinement Prompt\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - ✨ Describe the final output image after edits are made.\n\n'
)})
TYPE_REFINE_DENOISE = ('FLOAT', {
'default': 0.24, 'min': 0.0, 'max': 1.0, 'step': 0.01,
'tooltip': (
f' Sampler Denoise Amount\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - The amount of denoising applied, lower values will maintain the structure of the initial image allowing for image to image sampling.\n\n'
)
})
TYPE_CHEF_IMAGE_IN = ('IMAGE', {'tooltip': (
f' 🥗 Ingredients Image\n {"-" * TOOLTIP_UNDERLINE}\n'
f' - An image input for the FlowState Chef to work with.\n\n'
)})