工作流 /
图像 /
风格迁移 - Recraft 文生图

风格迁移 - Recraft 文生图
Style Transfer - Recraft Text-to-Image
上传1-5个风格参考并创建风格ID,以生成一致且符合品牌形象的图片。
图像
15 个节点 5 个输入 23 次使用 ComfyUI ≥ 0.12.0 hellorob 14 KB
节点构成
LoadImage
× 5
PrimitiveNode
× 2
RecraftStyleV3InfiniteStyleLibrary
× 2
MarkdownNote
× 2
PreviewAny
× 1
RecraftCreateStyleNode
× 1
SaveImage
× 1
RecraftTextToImageNode
× 1
官方标注的模型
Recraft
工作流 JSON
和上面「下载工作流 JSON」是同一份文件。
1{
2 "id": "8adaff5b-e25c-4560-83c5-981d160a9e2c",
3 "revision": 0,
4 "last_node_id": 45,
5 "last_link_id": 62,
6 "nodes": [
7 {
8 "id": 8,
9 "type": "PreviewAny",
10 "pos": [
11 2606.666856870048,
12 -1893.3333486577985
13 ],
14 "size": [
15 391.6666666666667,
16 112
17 ],
18 "flags": [],
19 "order": 12,
20 "mode": 0,
21 "inputs": [
22 {
23 "name": "source",
24 "type": "*",
25 "link": 6
26 }
27 ],
28 "outputs": [],
29 "title": "Preview Recraft Style ID",
30 "properties": {
31 "cnr_id": "comfy-core",
32 "ver": "0.12.3",
33 "Node name for S&R": "PreviewAny"
34 },
35 "widgets_values": [
36 null,
37 null,
38 null
39 ]
40 },
41 {
42 "id": 6,
43 "type": "RecraftCreateStyleNode",
44 "pos": [
45 2606.666856870048,
46 -1718.3334089659274
47 ],
48 "size": [
49 391.6666666666667,
50 158
51 ],
52 "flags": [],
53 "order": 10,
54 "mode": 0,
55 "inputs": [
56 {
57 "label": "image0",
58 "name": "images.image0",
59 "type": "IMAGE",
60 "link": 7
61 },
62 {
63 "label": "image1",
64 "name": "images.image1",
65 "shape": 7,
66 "type": "IMAGE",
67 "link": 38
68 },
69 {
70 "label": "image2",
71 "name": "images.image2",
72 "shape": 7,
73 "type": "IMAGE",
74 "link": 39
75 },
76 {
77 "label": "image3",
78 "name": "images.image3",
79 "shape": 7,
80 "type": "IMAGE",
81 "link": 40
82 },
83 {
84 "label": "image4",
85 "name": "images.image4",
86 "shape": 7,
87 "type": "IMAGE",
88 "link": 42
89 },
90 {
91 "name": "style",
92 "type": "COMBO",
93 "widget": {
94 "name": "style"
95 },
96 "link": 49
97 }
98 ],
99 "outputs": [
100 {
101 "name": "style_id",
102 "type": "STRING",
103 "links": [
104 5,
105 6
106 ]
107 }
108 ],
109 "properties": {
110 "cnr_id": "comfy-core",
111 "ver": "0.12.3",
112 "Node name for S&R": "RecraftCreateStyleNode"
113 },
114 "widgets_values": [
115 "realistic_image"
116 ],
117 "color": "#432",
118 "bgcolor": "#653"
119 },
120 {
121 "id": 23,
122 "type": "LoadImage",
123 "pos": [
124 590.0000243266884,
125 -1718.3334089659274
126 ],
127 "size": [
128 441.328125,
129 613.2942708333334
130 ],
131 "flags": {
132 "collapsed": false
133 },
134 "order": 0,
135 "mode": 0,
136 "inputs": [],
137 "outputs": [
138 {
139 "name": "IMAGE",
140 "type": "IMAGE",
141 "links": [
142 38
143 ]
144 },
145 {
146 "name": "MASK",
147 "type": "MASK",
148 "links": null
149 }
150 ],
151 "title": "Load Style Image 2",
152 "properties": {
153 "cnr_id": "comfy-core",
154 "ver": "0.12.3",
155 "Node name for S&R": "LoadImage"
156 },
157 "widgets_values": [
158 "input_style_2.png",
159 "image"
160 ]
161 },
162 {
163 "id": 1,
164 "type": "LoadImage",
165 "pos": [
166 81.66682188569453,
167 -1718.3331764517445
168 ],
169 "size": [
170 441.6666666666667,
171 613.75
172 ],
173 "flags": {
174 "collapsed": false
175 },
176 "order": 1,
177 "mode": 0,
178 "inputs": [],
179 "outputs": [
180 {
181 "name": "IMAGE",
182 "type": "IMAGE",
183 "links": [
184 7
185 ]
186 },
187 {
188 "name": "MASK",
189 "type": "MASK",
190 "links": null
191 }
192 ],
193 "title": "Load Style Image 1",
194 "properties": {
195 "cnr_id": "comfy-core",
196 "ver": "0.12.3",
197 "Node name for S&R": "LoadImage"
198 },
199 "widgets_values": [
200 "input_style_1.png",
201 "image"
202 ]
203 },
204 {
205 "id": 26,
206 "type": "LoadImage",
207 "pos": [
208 2081.66668902316,
209 -1718.3334089659274
210 ],
211 "size": [
212 441.328125,
213 613.2942708333334
214 ],
215 "flags": {
216 "collapsed": false
217 },
218 "order": 2,
219 "mode": 0,
220 "inputs": [],
221 "outputs": [
222 {
223 "name": "IMAGE",
224 "type": "IMAGE",
225 "links": [
226 42
227 ]
228 },
229 {
230 "name": "MASK",
231 "type": "MASK",
232 "links": null
233 }
234 ],
235 "title": "Load Style Image 5",
236 "properties": {
237 "cnr_id": "comfy-core",
238 "ver": "0.12.3",
239 "Node name for S&R": "LoadImage"
240 },
241 "widgets_values": [
242 "input_style_5.png",
243 "image"
244 ]
245 },
246 {
247 "id": 34,
248 "type": "PrimitiveNode",
249 "pos": [
250 2606.666856870048,
251 -1451.6667290123744
252 ],
253 "size": [
254 391.6666666666667,
255 106
256 ],
257 "flags": [],
258 "order": 3,
259 "mode": 0,
260 "inputs": [],
261 "outputs": [
262 {
263 "name": "COMBO",
264 "type": "COMBO",
265 "widget": {
266 "name": "style"
267 },
268 "links": [
269 49
270 ]
271 }
272 ],
273 "title": "style",
274 "properties": {
275 "Run widget replace on values": false
276 },
277 "widgets_values": [
278 "realistic_image",
279 "fixed",
280 ""
281 ],
282 "color": "#232",
283 "bgcolor": "#353"
284 },
285 {
286 "id": 37,
287 "type": "SaveImage",
288 "pos": [
289 3898.3333662799896,
290 -1726.6659034835968
291 ],
292 "size": [
293 600,
294 660
295 ],
296 "flags": [],
297 "order": 14,
298 "mode": 0,
299 "inputs": [
300 {
301 "name": "images",
302 "type": "IMAGE",
303 "link": 62
304 }
305 ],
306 "outputs": [],
307 "properties": {
308 "cnr_id": "comfy-core",
309 "ver": "0.12.3"
310 },
311 "widgets_values": [
312 "ComfyUI-t2i_style_transfer"
313 ]
314 },
315 {
316 "id": 41,
317 "type": "RecraftStyleV3InfiniteStyleLibrary",
318 "pos": [
319 3081.666605777702,
320 -1851.6666433964099
321 ],
322 "size": [
323 333.75,
324 58
325 ],
326 "flags": [],
327 "order": 4,
328 "mode": 0,
329 "inputs": [],
330 "outputs": [
331 {
332 "name": "recraft_style",
333 "type": "RECRAFT_V3_STYLE",
334 "links": []
335 }
336 ],
337 "title": "Recraft - Infinite Style Library (Manual)",
338 "properties": {
339 "cnr_id": "comfy-core",
340 "ver": "0.12.3",
341 "Node name for S&R": "RecraftStyleV3InfiniteStyleLibrary"
342 },
343 "widgets_values": [
344 "COPY PASTE STYLE ID HERE AND CONNECT"
345 ]
346 },
347 {
348 "id": 43,
349 "type": "MarkdownNote",
350 "pos": [
351 -193.3333321803293,
352 -1718.3333146163932
353 ],
354 "size": [
355 225,
356 100
357 ],
358 "flags": {
359 "collapsed": false
360 },
361 "order": 5,
362 "mode": 0,
363 "inputs": [],
364 "outputs": [],
365 "properties": [],
366 "widgets_values": [
367 "Load **up to** 5 style reference images to create your Recraft style ID.\n\nIf you do not have 5 style images, bypass unused 'Load Style Image' nodes with `CTRL/CMD + B`"
368 ],
369 "color": "#222",
370 "bgcolor": "#000"
371 },
372 {
373 "id": 44,
374 "type": "MarkdownNote",
375 "pos": [
376 3081.666666666667,
377 -2068.3333333333335
378 ],
379 "size": [
380 333.33333333333337,
381 141.06770833333334
382 ],
383 "flags": [],
384 "order": 6,
385 "mode": 0,
386 "inputs": [],
387 "outputs": [],
388 "properties": [],
389 "widgets_values": [
390 "After running the workflow once, you can view your ID in the \"Preview Recraft Style ID\" node.\n\nTo avoid creating a new style ID on each job, copy/paste the ID into the \"Recraft - Infinite Style Library (Manual)\". Connect the output into the Recraft Text to Image input.\n\nThen, bypass `CTRL/CMD + B` the 'Recraft Create Style' API node."
391 ],
392 "color": "#222",
393 "bgcolor": "#000"
394 },
395 {
396 "id": 24,
397 "type": "LoadImage",
398 "pos": [
399 1085.8459944432348,
400 -1719.6547870676925
401 ],
402 "size": [
403 441.328125,
404 613.2942708333334
405 ],
406 "flags": {
407 "collapsed": false
408 },
409 "order": 7,
410 "mode": 0,
411 "inputs": [],
412 "outputs": [
413 {
414 "name": "IMAGE",
415 "type": "IMAGE",
416 "links": [
417 39
418 ]
419 },
420 {
421 "name": "MASK",
422 "type": "MASK",
423 "links": null
424 }
425 ],
426 "title": "Load Style Image 3",
427 "properties": {
428 "cnr_id": "comfy-core",
429 "ver": "0.12.3",
430 "Node name for S&R": "LoadImage"
431 },
432 "widgets_values": [
433 "input_style_3.png",
434 "image"
435 ]
436 },
437 {
438 "id": 25,
439 "type": "LoadImage",
440 "pos": [
441 1581.666911156567,
442 -1718.3334089659274
443 ],
444 "size": [
445 441.328125,
446 613.2942708333334
447 ],
448 "flags": {
449 "collapsed": false
450 },
451 "order": 8,
452 "mode": 0,
453 "inputs": [],
454 "outputs": [
455 {
456 "name": "IMAGE",
457 "type": "IMAGE",
458 "links": [
459 40
460 ]
461 },
462 {
463 "name": "MASK",
464 "type": "MASK",
465 "links": null
466 }
467 ],
468 "title": "Load Style Image 4",
469 "properties": {
470 "cnr_id": "comfy-core",
471 "ver": "0.12.3",
472 "Node name for S&R": "LoadImage"
473 },
474 "widgets_values": [
475 "input_style_4.png",
476 "image"
477 ]
478 },
479 {
480 "id": 7,
481 "type": "RecraftStyleV3InfiniteStyleLibrary",
482 "pos": [
483 3081.6667703425533,
484 -1726.6666793654929
485 ],
486 "size": [
487 333.33333333333337,
488 58
489 ],
490 "flags": {
491 "collapsed": false
492 },
493 "order": 11,
494 "mode": 0,
495 "inputs": [
496 {
497 "name": "style_id",
498 "type": "STRING",
499 "widget": {
500 "name": "style_id"
501 },
502 "link": 5
503 }
504 ],
505 "outputs": [
506 {
507 "name": "recraft_style",
508 "type": "RECRAFT_V3_STYLE",
509 "links": [
510 60
511 ]
512 }
513 ],
514 "title": "Recraft - Infinite Style Library",
515 "properties": {
516 "cnr_id": "comfy-core",
517 "ver": "0.12.3",
518 "Node name for S&R": "RecraftStyleV3InfiniteStyleLibrary"
519 },
520 "widgets_values": [
521 ""
522 ]
523 },
524 {
525 "id": 33,
526 "type": "PrimitiveNode",
527 "pos": [
528 3081.666772157593,
529 -1610.0012089958566
530 ],
531 "size": [
532 333.33333333333337,
533 233.33333333333334
534 ],
535 "flags": [],
536 "order": 9,
537 "mode": 0,
538 "inputs": [],
539 "outputs": [
540 {
541 "name": "STRING",
542 "type": "STRING",
543 "widget": {
544 "name": "prompt"
545 },
546 "links": [
547 61
548 ]
549 }
550 ],
551 "title": "prompt",
552 "properties": {
553 "Run widget replace on values": false
554 },
555 "widgets_values": [
556 "extreme wide shot of an grand colosseum, dynamic angled composition"
557 ],
558 "color": "#232",
559 "bgcolor": "#353"
560 },
561 {
562 "id": 45,
563 "type": "RecraftTextToImageNode",
564 "pos": [
565 3450,
566 -1720
567 ],
568 "size": [
569 400,
570 224
571 ],
572 "flags": [],
573 "order": 13,
574 "mode": 0,
575 "inputs": [
576 {
577 "name": "recraft_style",
578 "shape": 7,
579 "type": "RECRAFT_V3_STYLE",
580 "link": 60
581 },
582 {
583 "name": "negative_prompt",
584 "shape": 7,
585 "type": "STRING",
586 "link": null
587 },
588 {
589 "name": "recraft_controls",
590 "shape": 7,
591 "type": "RECRAFT_CONTROLS",
592 "link": null
593 },
594 {
595 "name": "prompt",
596 "type": "STRING",
597 "widget": {
598 "name": "prompt"
599 },
600 "link": 61
601 }
602 ],
603 "outputs": [
604 {
605 "name": "IMAGE",
606 "type": "IMAGE",
607 "links": [
608 62
609 ]
610 }
611 ],
612 "properties": {
613 "cnr_id": "comfy-core",
614 "ver": "0.16.1",
615 "Node name for S&R": "RecraftTextToImageNode"
616 },
617 "widgets_values": [
618 "extreme wide shot of an grand colosseum, dynamic angled composition",
619 "1024x1024",
620 1,
621 0,
622 "randomize"
623 ],
624 "color": "#432",
625 "bgcolor": "#653"
626 }
627 ],
628 "links": [
629 [
630 5,
631 6,
632 0,
633 7,
634 0,
635 "STRING"
636 ],
637 [
638 6,
639 6,
640 0,
641 8,
642 0,
643 "STRING"
644 ],
645 [
646 7,
647 1,
648 0,
649 6,
650 0,
651 "IMAGE"
652 ],
653 [
654 38,
655 23,
656 0,
657 6,
658 1,
659 "IMAGE"
660 ],
661 [
662 39,
663 24,
664 0,
665 6,
666 2,
667 "IMAGE"
668 ],
669 [
670 40,
671 25,
672 0,
673 6,
674 3,
675 "IMAGE"
676 ],
677 [
678 42,
679 26,
680 0,
681 6,
682 4,
683 "IMAGE"
684 ],
685 [
686 49,
687 34,
688 0,
689 6,
690 5,
691 "COMBO"
692 ],
693 [
694 60,
695 7,
696 0,
697 45,
698 0,
699 "RECRAFT_V3_STYLE"
700 ],
701 [
702 61,
703 33,
704 0,
705 45,
706 3,
707 "STRING"
708 ],
709 [
710 62,
711 45,
712 0,
713 37,
714 0,
715 "IMAGE"
716 ]
717 ],
718 "groups": [],
719 "config": [],
720 "extra": {
721 "ds": {
722 "scale": 0.39772846667743733,
723 "offset": [
724 -1452.089060515248,
725 2599.430564269309
726 ]
727 },
728 "frontendVersion": "1.39.19",
729 "workflowRendererVersion": "LG",
730 "favoritedWidgets": {
731 "favorites": []
732 },
733 "VHS_latentpreview": false,
734 "VHS_latentpreviewrate": 0,
735 "VHS_MetadataImage": true,
736 "VHS_KeepIntermediate": true
737 },
738 "version": 0.4
739}