John6666 commited on
Commit
5404b87
1 Parent(s): 4bfc942

Upload 55 files

Browse files
app.py CHANGED
@@ -521,10 +521,11 @@ with gr.Blocks(theme='Nymbo/Nymbo_Theme', fill_width=True, css=css) as app:
521
 
522
  with gr.Tab("FLUX Prompt Generator"):
523
  from prompt import (PromptGenerator, HuggingFaceInferenceNode, florence_caption,
524
- ARTFORM, PHOTO_TYPE, BODY_TYPES, DEFAULT_TAGS, ROLES, HAIRSTYLES, ADDITIONAL_DETAILS,
525
  PHOTOGRAPHY_STYLES, DEVICE, PHOTOGRAPHER, ARTIST, DIGITAL_ARTFORM, PLACE,
526
- LIGHTING, CLOTHING, COMPOSITION, POSE, BACKGROUND, pg_title)
527
-
 
528
  prompt_generator = PromptGenerator()
529
  huggingface_node = HuggingFaceInferenceNode()
530
 
@@ -533,9 +534,9 @@ with gr.Blocks(theme='Nymbo/Nymbo_Theme', fill_width=True, css=css) as app:
533
  with gr.Row():
534
  with gr.Column(scale=2):
535
  with gr.Accordion("Basic Settings"):
536
- pg_seed = gr.Slider(0, 30000, label='Seed', step=1, value=random.randint(0,30000))
537
  pg_custom = gr.Textbox(label="Custom Input Prompt (optional)")
538
  pg_subject = gr.Textbox(label="Subject (optional)")
 
539
 
540
  # Add the radio button for global option selection
541
  pg_global_option = gr.Radio(
@@ -549,11 +550,11 @@ with gr.Blocks(theme='Nymbo/Nymbo_Theme', fill_width=True, css=css) as app:
549
  pg_photo_type = gr.Dropdown(["disabled", "random"] + PHOTO_TYPE, label="Photo Type", value="disabled")
550
 
551
  with gr.Accordion("Character Details", open=False):
552
- pg_body_types = gr.Dropdown(["disabled", "random"] + BODY_TYPES, label="Body Types", value="disabled")
553
- pg_default_tags = gr.Dropdown(["disabled", "random"] + DEFAULT_TAGS, label="Default Tags", value="disabled")
554
  pg_roles = gr.Dropdown(["disabled", "random"] + ROLES, label="Roles", value="disabled")
555
  pg_hairstyles = gr.Dropdown(["disabled", "random"] + HAIRSTYLES, label="Hairstyles", value="disabled")
556
- pg_clothing = gr.Dropdown(["disabled", "random"] + CLOTHING, label="Clothing", value="disabled")
557
 
558
  with gr.Accordion("Scene Details", open=False):
559
  pg_place = gr.Dropdown(["disabled", "random"] + PLACE, label="Place", value="disabled")
@@ -563,7 +564,7 @@ with gr.Blocks(theme='Nymbo/Nymbo_Theme', fill_width=True, css=css) as app:
563
  pg_background = gr.Dropdown(["disabled", "random"] + BACKGROUND, label="Background", value="disabled")
564
 
565
  with gr.Accordion("Style and Artist", open=False):
566
- pg_additional_details = gr.Dropdown(["disabled", "random"] + ADDITIONAL_DETAILS, label="Additional Details", value="disabled")
567
  pg_photography_styles = gr.Dropdown(["disabled", "random"] + PHOTOGRAPHY_STYLES, label="Photography Styles", value="disabled")
568
  pg_device = gr.Dropdown(["disabled", "random"] + DEVICE, label="Device", value="disabled")
569
  pg_photographer = gr.Dropdown(["disabled", "random"] + PHOTOGRAPHER, label="Photographer", value="disabled")
@@ -587,94 +588,87 @@ with gr.Blocks(theme='Nymbo/Nymbo_Theme', fill_width=True, css=css) as app:
587
 
588
  with gr.Column(scale=2):
589
  with gr.Accordion("Prompt Generation with LLM", open=False):
590
- pg_model = gr.Dropdown(["Mixtral", "Mistral", "Llama 3", "Mistral-Nemo"], label="Model", value="Llama 3")
591
  pg_happy_talk = gr.Checkbox(label="Happy Talk", value=True)
592
  pg_compress = gr.Checkbox(label="Compress", value=True)
593
  pg_compression_level = gr.Radio(["soft", "medium", "hard"], label="Compression Level", value="hard")
594
  pg_poster = gr.Checkbox(label="Poster", value=False)
595
  pg_custom_base_prompt = gr.Textbox(label="Custom Base Prompt", lines=5)
596
- pg_generate_text_button = gr.Button("Generate Prompt with LLM")
597
  pg_text_output = gr.Textbox(label="Generated Text", lines=10)
598
 
599
- description_ui()
600
-
601
- def create_caption(image):
602
- if image is not None:
603
- return florence_caption(image)
604
- return ""
605
 
606
- pg_create_caption_button.click(
607
- create_caption,
608
- inputs=[pg_input_image],
609
- outputs=[pg_caption_output],
610
- show_api=False,
611
- )
612
 
613
- pg_generate_button.click(
614
- prompt_generator.generate_prompt,
615
- inputs=[pg_seed, pg_custom, pg_subject, pg_artform, pg_photo_type, pg_body_types,
616
- pg_default_tags, pg_roles, pg_hairstyles,
617
- pg_additional_details, pg_photography_styles, pg_device, pg_photographer,
618
- pg_artist, pg_digital_artform,
619
- pg_place, pg_lighting, pg_clothing, pg_composition, pg_pose, pg_background],
620
- outputs=[pg_output, gr.Number(visible=False), pg_t5xxl_output, pg_clip_l_output, pg_clip_g_output],
621
- show_api=False,
622
- )
 
 
 
 
 
 
 
623
 
624
- pg_add_caption_button.click(
625
- prompt_generator.add_caption_to_prompt,
626
- inputs=[pg_output, pg_caption_output],
627
- outputs=[pg_output],
628
- show_api=False,
629
- )
630
 
631
- pg_generate_text_button.click(
632
- huggingface_node.generate,
633
- inputs=[pg_model, pg_output, pg_happy_talk, pg_compress, pg_compression_level,
634
- pg_poster, pg_custom_base_prompt],
635
- outputs=pg_text_output,
636
- show_api=False,
637
- )
638
 
639
- def update_all_options(choice):
640
- updates = {}
641
- if choice == "Disabled":
642
- for dropdown in [
643
- pg_artform, pg_photo_type, pg_body_types, pg_default_tags,
644
- pg_roles, pg_hairstyles, pg_clothing,
645
- pg_place, pg_lighting, pg_composition, pg_pose, pg_background, pg_additional_details,
646
- pg_photography_styles, pg_device, pg_photographer, pg_artist, pg_digital_artform
647
- ]:
648
- updates[dropdown] = gr.update(value="disabled")
649
- elif choice == "Random":
650
- for dropdown in [
651
- pg_artform, pg_photo_type, pg_body_types, pg_default_tags,
652
- pg_roles, pg_hairstyles, pg_clothing,
 
 
 
 
 
 
 
 
 
 
 
 
 
 
653
  pg_place, pg_lighting, pg_composition, pg_pose, pg_background, pg_additional_details,
654
  pg_photography_styles, pg_device, pg_photographer, pg_artist, pg_digital_artform
655
- ]:
656
- updates[dropdown] = gr.update(value="random")
657
- else: # No Figure Random
658
- for dropdown in [pg_photo_type, pg_body_types, pg_default_tags,
659
- pg_roles, pg_hairstyles, pg_clothing, pg_pose, pg_additional_details]:
660
- updates[dropdown] = gr.update(value="disabled")
661
- for dropdown in [pg_artform, pg_place, pg_lighting, pg_composition,
662
- pg_background, pg_photography_styles, pg_device, pg_photographer,
663
- pg_artist, pg_digital_artform]:
664
- updates[dropdown] = gr.update(value="random")
665
- return updates
666
-
667
- pg_global_option.change(
668
- update_all_options,
669
- inputs=[pg_global_option],
670
- outputs=[
671
- pg_artform, pg_photo_type, pg_body_types, pg_default_tags,
672
- pg_roles, pg_hairstyles, pg_clothing,
673
- pg_place, pg_lighting, pg_composition, pg_pose, pg_background, pg_additional_details,
674
- pg_photography_styles, pg_device, pg_photographer, pg_artist, pg_digital_artform
675
- ],
676
- show_api=False,
677
- )
678
 
679
  app.queue()
680
  app.launch()
 
521
 
522
  with gr.Tab("FLUX Prompt Generator"):
523
  from prompt import (PromptGenerator, HuggingFaceInferenceNode, florence_caption,
524
+ ARTFORM, PHOTO_TYPE, ROLES, HAIRSTYLES, LIGHTING, COMPOSITION, POSE, BACKGROUND,
525
  PHOTOGRAPHY_STYLES, DEVICE, PHOTOGRAPHER, ARTIST, DIGITAL_ARTFORM, PLACE,
526
+ FEMALE_DEFAULT_TAGS, MALE_DEFAULT_TAGS, FEMALE_BODY_TYPES, MALE_BODY_TYPES,
527
+ FEMALE_CLOTHING, MALE_CLOTHING, FEMALE_ADDITIONAL_DETAILS, MALE_ADDITIONAL_DETAILS, pg_title)
528
+
529
  prompt_generator = PromptGenerator()
530
  huggingface_node = HuggingFaceInferenceNode()
531
 
 
534
  with gr.Row():
535
  with gr.Column(scale=2):
536
  with gr.Accordion("Basic Settings"):
 
537
  pg_custom = gr.Textbox(label="Custom Input Prompt (optional)")
538
  pg_subject = gr.Textbox(label="Subject (optional)")
539
+ pg_gender = gr.Radio(["female", "male"], label="Gender", value="female")
540
 
541
  # Add the radio button for global option selection
542
  pg_global_option = gr.Radio(
 
550
  pg_photo_type = gr.Dropdown(["disabled", "random"] + PHOTO_TYPE, label="Photo Type", value="disabled")
551
 
552
  with gr.Accordion("Character Details", open=False):
553
+ pg_body_types = gr.Dropdown(["disabled", "random"] + FEMALE_BODY_TYPES + MALE_BODY_TYPES, label="Body Types", value="disabled")
554
+ pg_default_tags = gr.Dropdown(["disabled", "random"] + FEMALE_DEFAULT_TAGS + MALE_DEFAULT_TAGS, label="Default Tags", value="disabled")
555
  pg_roles = gr.Dropdown(["disabled", "random"] + ROLES, label="Roles", value="disabled")
556
  pg_hairstyles = gr.Dropdown(["disabled", "random"] + HAIRSTYLES, label="Hairstyles", value="disabled")
557
+ pg_clothing = gr.Dropdown(["disabled", "random"] + FEMALE_CLOTHING + MALE_CLOTHING, label="Clothing", value="disabled")
558
 
559
  with gr.Accordion("Scene Details", open=False):
560
  pg_place = gr.Dropdown(["disabled", "random"] + PLACE, label="Place", value="disabled")
 
564
  pg_background = gr.Dropdown(["disabled", "random"] + BACKGROUND, label="Background", value="disabled")
565
 
566
  with gr.Accordion("Style and Artist", open=False):
567
+ pg_additional_details = gr.Dropdown(["disabled", "random"] + FEMALE_ADDITIONAL_DETAILS + MALE_ADDITIONAL_DETAILS, label="Additional Details", value="disabled")
568
  pg_photography_styles = gr.Dropdown(["disabled", "random"] + PHOTOGRAPHY_STYLES, label="Photography Styles", value="disabled")
569
  pg_device = gr.Dropdown(["disabled", "random"] + DEVICE, label="Device", value="disabled")
570
  pg_photographer = gr.Dropdown(["disabled", "random"] + PHOTOGRAPHER, label="Photographer", value="disabled")
 
588
 
589
  with gr.Column(scale=2):
590
  with gr.Accordion("Prompt Generation with LLM", open=False):
 
591
  pg_happy_talk = gr.Checkbox(label="Happy Talk", value=True)
592
  pg_compress = gr.Checkbox(label="Compress", value=True)
593
  pg_compression_level = gr.Radio(["soft", "medium", "hard"], label="Compression Level", value="hard")
594
  pg_poster = gr.Checkbox(label="Poster", value=False)
595
  pg_custom_base_prompt = gr.Textbox(label="Custom Base Prompt", lines=5)
596
+ pg_generate_text_button = gr.Button("Generate Prompt with LLM (Llama 3.1 70B)")
597
  pg_text_output = gr.Textbox(label="Generated Text", lines=10)
598
 
599
+ def create_caption(image):
600
+ if image is not None:
601
+ return florence_caption(image)
602
+ return ""
 
 
603
 
604
+ pg_create_caption_button.click(
605
+ create_caption,
606
+ inputs=[pg_input_image],
607
+ outputs=[pg_caption_output]
608
+ )
 
609
 
610
+ def generate_prompt_with_dynamic_seed(*args):
611
+ # Generate a new random seed
612
+ dynamic_seed = random.randint(0, 1000000)
613
+
614
+ # Call the generate_prompt function with the dynamic seed
615
+ result = prompt_generator.generate_prompt(dynamic_seed, *args)
616
+
617
+ # Return the result along with the used seed
618
+ return [dynamic_seed] + list(result)
619
+
620
+ pg_generate_button.click(
621
+ generate_prompt_with_dynamic_seed,
622
+ inputs=[pg_custom, pg_subject, pg_gender, pg_artform, pg_photo_type, pg_body_types, pg_default_tags, pg_roles, pg_hairstyles,
623
+ pg_additional_details, pg_photography_styles, pg_device, pg_photographer, pg_artist, pg_digital_artform,
624
+ pg_place, pg_lighting, pg_clothing, pg_composition, pg_pose, pg_background, pg_input_image],
625
+ outputs=[gr.Number(label="Used Seed", visible=True), pg_output, gr.Number(visible=False), pg_t5xxl_output, pg_clip_l_output, pg_clip_g_output]
626
+ )
627
 
628
+ pg_add_caption_button.click(
629
+ prompt_generator.add_caption_to_prompt,
630
+ inputs=[pg_output, pg_caption_output],
631
+ outputs=[pg_output]
632
+ )
 
633
 
634
+ pg_generate_text_button.click(
635
+ huggingface_node.generate,
636
+ inputs=[pg_output, pg_happy_talk, pg_compress, pg_compression_level, pg_poster, pg_custom_base_prompt],
637
+ outputs=pg_text_output
638
+ )
 
 
639
 
640
+ def update_all_options(choice):
641
+ updates = {}
642
+ if choice == "Disabled":
643
+ for dropdown in [
644
+ pg_artform, pg_photo_type, pg_body_types, pg_default_tags, pg_roles, pg_hairstyles, pg_clothing,
645
+ pg_place, pg_lighting, pg_composition, pg_pose, pg_background, pg_additional_details,
646
+ pg_photography_styles, pg_device, pg_photographer, pg_artist, pg_digital_artform
647
+ ]:
648
+ updates[dropdown] = gr.update(value="disabled")
649
+ elif choice == "Random":
650
+ for dropdown in [
651
+ pg_artform, pg_photo_type, pg_body_types, pg_default_tags, pg_roles, pg_hairstyles, pg_clothing,
652
+ pg_place, pg_lighting, pg_composition, pg_pose, pg_background, pg_additional_details,
653
+ pg_photography_styles, pg_device, pg_photographer, pg_artist, pg_digital_artform
654
+ ]:
655
+ updates[dropdown] = gr.update(value="random")
656
+ else: # No Figure Random
657
+ for dropdown in [pg_photo_type, pg_body_types, pg_default_tags, pg_roles, pg_hairstyles, pg_clothing, pg_pose, pg_additional_details]:
658
+ updates[dropdown] = gr.update(value="disabled")
659
+ for dropdown in [pg_artform, pg_place, pg_lighting, pg_composition, pg_background, pg_photography_styles, pg_device, pg_photographer, pg_artist, pg_digital_artform]:
660
+ updates[dropdown] = gr.update(value="random")
661
+ return updates
662
+
663
+ pg_global_option.change(
664
+ update_all_options,
665
+ inputs=[pg_global_option],
666
+ outputs=[
667
+ pg_artform, pg_photo_type, pg_body_types, pg_default_tags, pg_roles, pg_hairstyles, pg_clothing,
668
  pg_place, pg_lighting, pg_composition, pg_pose, pg_background, pg_additional_details,
669
  pg_photography_styles, pg_device, pg_photographer, pg_artist, pg_digital_artform
670
+ ]
671
+ )
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
672
 
673
  app.queue()
674
  app.launch()
data/female_additional_details.json ADDED
@@ -0,0 +1,183 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ "a purple iridescent suit",
3
+ "wearing a (necklace)",
4
+ "wearing ((earrings))",
5
+ "wearing a (bracelet)",
6
+ "wearing one or multiple (rings)",
7
+ "wearing a (brooch)",
8
+ "wearing (eyeglasses)",
9
+ "wearing (sunglasses)",
10
+ "wearing a (hat)",
11
+ "wearing a (scarf)",
12
+ "wearing a (headband)",
13
+ "wearing a (nose ring)",
14
+ "wearing a (lip ring)",
15
+ "wearing a (tongue ring)",
16
+ "wearing an (eyebrow ring)",
17
+ "wearing (face tattoos)",
18
+ "wearing a (wreath)",
19
+ "wearing a (crown)",
20
+ "wearing a (tiara)",
21
+ "wearing a (crown of thorns)",
22
+ "wearing a (crown of jewels)",
23
+ "wearing (bohemian clothes)",
24
+ "wearing (chic clothes)",
25
+ "wearing (glamorous clothes)",
26
+ "wearing (grunge clothes)",
27
+ "wearing (preppy clothes)",
28
+ "wearing (punk clothes)",
29
+ "wearing (retro clothes)",
30
+ "wearing (rockabilly clothes)",
31
+ "wearing (romantic clothes)",
32
+ "wearing (tomboy clothes)",
33
+ "wearing (urban clothes)",
34
+ "wearing (camo clothes)",
35
+ "wearing (robes)",
36
+ "wearing (excessive amount of jewellery)",
37
+ "wearing (vintage clothes)",
38
+ "wearing (western clothes)",
39
+ "wearing (minimalist clothes)",
40
+ "wearing (sportswear clothes)",
41
+ "wearing (flapper clothes)",
42
+ "wearing (pin-up clothes)",
43
+ "wearing (mid-century modern clothes)",
44
+ "wearing (art deco clothes)",
45
+ "wearing (victorian clothes)",
46
+ "wearing (edwardian clothes)",
47
+ "wearing (elizabethan clothes)",
48
+ "wearing (retro 70s clothes)",
49
+ "wearing (retro 80s clothes)",
50
+ "wearing (retro 90s clothes)",
51
+ "wearing (retro 00s clothes)",
52
+ "wearing (musical equipment)",
53
+ "wearing (leather)",
54
+ "wearing (bdsm leather)",
55
+ "wearing (shiny latex)",
56
+ "wearing (shiny latex suit)",
57
+ "wearing (silk)",
58
+ "wearing (full tweed set)",
59
+ "wearing (clothes made entirely of feathers)",
60
+ "wearing (clothes made entirely of fur)",
61
+ "wearing (clothes made entirely of leather)",
62
+ "wearing (clothes made entirely of metal)",
63
+ "wearing (clothes made entirely of plastic)",
64
+ "wearing (clothes adorned with shimmering jewels or crystals)",
65
+ "waring (clothes adorned with sequins)",
66
+ "wearing (clothes with exaggerated or extreme silhouettes)",
67
+ "wearing (clothes with exaggerated or extreme footwear)",
68
+ "wearing (clothes with exaggerated or extreme headwear)",
69
+ "wearing (clothes with exaggerated or extreme facial or body piercings or tattoos)",
70
+ "wearing (clothes with multiple layers or tiers)",
71
+ "wearing (clothes with exaggerated or extreme colors)",
72
+ "wearing (clothes with exaggerated or extreme patterns)",
73
+ "wearing (cloak)",
74
+ "wearing an astronaut armor",
75
+ "wearing a bio mechanical suit",
76
+ "wearing a bio hazard suit",
77
+ "(( working with laptop))",
78
+ "with Heat deformation",
79
+ "(((future soldier, full body armor, futuristic football, shoulder pads, guns, grenades, weapons, bullet proof vest, high tech, straps, belts, camouflage)))",
80
+ "((full body, zoomed out)) long slender legs 80mm",
81
+ "(((sci-fi, future war, cyberpunk, cyborg, future fashion, beautiful face, glowing tattoos)))",
82
+ "((angry expression, pretty face))",
83
+ "(((full body, athletic body, action pose, detailed black soldier outfit, slender long legs)))",
84
+ "playing epic electric guitar solo in front of a huge crowd",
85
+ "singing epic solo into a microphone in front of a huge crowd",
86
+ "as a ((gelatinous horror dripping alien creature))",
87
+ "in a tie or bowtie, lending a touch of formal elegance or quirky charm, knotted around the collar to elevate the outfit",
88
+ "with anklets, delicate chains or beads that gracefully encircle the ankle, adding a touch of femininity with every step",
89
+ "donning a belt, functional yet fashionable, cinching the waist or sitting low on the hips, often with a statement buckle",
90
+ "wearing gloves, either elegant satin for formal events or rugged leather for a tougher look, complementing the attire and mood",
91
+ "with a choker, snugly encircling the neck, often made of lace, velvet, or leather, exuding a mix of elegance and edge",
92
+ "in stockings or tights, sheer or opaque, enhancing the legs while adding a touch of sophistication or playful patterns",
93
+ "with a satchel or bag, a functional accessory that speaks volumes about personal style, be it a minimalist tote or an embellished clutch",
94
+ "wearing cufflinks, subtle symbols of elegance, adorning the sleeves of a formal shirt, showcasing attention to detail",
95
+ "with a pendant, a piece of jewelry that dangles gracefully from a necklace, often holding sentimental or symbolic value",
96
+ "in layered necklaces, a blend of chains of varying lengths, creating depth and showcasing multiple pendants or charms",
97
+ "sporting a watch, a timeless accessory that blends functionality with style, either minimalist or grand, reflecting personal tastes",
98
+ "wearing a veil, a delicate piece of fabric that adds mystery and allure, often seen in bridal or ceremonial attire",
99
+ "donning a cape or cloak, adding drama to the ensemble, flowing gracefully with every movement, evoking a sense of fantasy or regality",
100
+ "with a tiara or diadem, a jeweled headpiece that signifies royalty or celebration, resting gracefully atop the head",
101
+ "Adorned with a crown, symbolizing royalty and authority with gemstones and metals",
102
+ "With a sparkling tiara, reminiscent of princesses or beauty queens",
103
+ "With a poignant crown of thorns, symbolizing sacrifice and resilience",
104
+ "With a jewel-encrusted crown, reflecting affluence and grandeur",
105
+ "In bohemian attire, embodying the free spirits with patterns and fringes",
106
+ "Dressed in chic fashion, blending comfort with high style",
107
+ "In glamorous attire, shiny or sequined, perfect for red-carpet events",
108
+ "Donning grunge wear, with flannels and combat boots, reflecting a rebellious spirit",
109
+ "In preppy clothes, with clean lines and classic patterns",
110
+ "Sporting punk fashion, with leather, studs, and bold hairstyles",
111
+ "In retro outfits, channeling specific decades with authentic pieces",
112
+ "Wearing rockabilly style, with pin-up influences and rock 'n' roll flair",
113
+ "In romantic attire, featuring soft fabrics and feminine silhouettes",
114
+ "Dressed in tomboy fashion, with boyish charm and comfort-focused pieces",
115
+ "In urban streetwear, blending comfort with trendy, city-inspired looks",
116
+ "Wearing camouflage, either for function or as a bold fashion statement",
117
+ "Draped in robes, from casual bathrobes to formal ceremonial garments",
118
+ "Adorned with excessive jewelry, creating a bold and opulent look",
119
+ "In vintage clothes, authentically representing past eras and styles",
120
+ "Sporting western wear, with cowboy hats, boots, and denim",
121
+ "In minimalist attire, focusing on clean lines and a less-is-more approach",
122
+ "Wearing sportswear, blending function and style for athletic pursuits",
123
+ "In flapper style, with dropped waists and ornate beading from the 1920s",
124
+ "Dressed as a pin-up, channeling retro glamour with curve-hugging styles",
125
+ "In mid-century modern fashion, reflecting the sleek designs of the 1950s and 60s",
126
+ "Wearing art deco inspired clothes, with geometric patterns and luxurious fabrics",
127
+ "In Victorian-style attire, with high necklines, corsets, and full skirts",
128
+ "Dressed in Edwardian fashion, featuring S-shaped silhouettes and large hats",
129
+ "In Elizabethan costume, with ruffs, farthingales, and ornate embroidery",
130
+ "Sporting 70s retro looks, with bell-bottoms, platforms, and psychedelic prints",
131
+ "In 80s inspired outfits, featuring bold colors, shoulder pads, and leg warmers",
132
+ "Wearing 90s fashion, with crop tops, high-waisted jeans, and chunky shoes",
133
+ "In early 2000s style, featuring low-rise jeans, crop tops, and platform sandals",
134
+ "With musical equipment, like guitars, drumsticks, or headphones as accessories",
135
+ "In leather attire, from sleek jackets to edgy pants or skirts",
136
+ "Wearing BDSM-inspired leather, with harnesses, collars, or studded accessories",
137
+ "In shiny latex, hugging every curve with a glossy, futuristic appeal",
138
+ "Sporting a full latex suit, covering from neck to toe in sleek, shiny material",
139
+ "Draped in silk, with flowing fabrics that catch the light beautifully",
140
+ "In a full tweed set, channeling British countryside chic",
141
+ "Wearing an outfit made entirely of feathers, creating a bold, avian-inspired look",
142
+ "In a fur ensemble, either faux or real, exuding luxury and warmth",
143
+ "Sporting an all-leather outfit, from jacket to pants and accessories",
144
+ "In a metallic outfit, with clothes seemingly forged from shining metals",
145
+ "Wearing an ensemble made entirely of plastic, futuristic and unconventional",
146
+ "Adorned in clothes shimmering with jewels or crystals, catching light at every angle",
147
+ "In a sequin-covered outfit, sparkling and eye-catching from every view",
148
+ "Wearing clothes with exaggerated silhouettes, pushing the boundaries of shape and form",
149
+ "In footwear with extreme designs, from towering platforms to avant-garde shapes",
150
+ "Sporting headwear with exaggerated proportions or unconventional materials",
151
+ "With extreme facial piercings or full-body tattoos, turning the skin into a canvas",
152
+ "In an outfit with multiple layers or tiers, creating depth and visual interest",
153
+ "Wearing clothes in extremely bold or neon colors, making a vibrant statement",
154
+ "In attire with exaggerated or surreal patterns, creating visual intrigue",
155
+ "Draped in a mysterious cloak, adding an air of intrigue or fantasy",
156
+ "In astronaut armor, representing space exploration and futuristic concepts",
157
+ "Wearing a bio-mechanical suit, blending organic forms with mechanical elements",
158
+ "In a biohazard suit, fully enclosed for protection or as a fashion statement",
159
+ "Engaged with a laptop, representing technology integration in fashion",
160
+ "Surrounded by heat deformation effects, as if the very air is bending around them",
161
+ "In futuristic soldier gear, with high-tech armor, weapons, and camouflage",
162
+ "Posed to accentuate long, slender legs, often with 80mm or higher heels",
163
+ "In sci-fi inspired wear, with cyberpunk elements and glowing tattoos",
164
+ "With an angry expression juxtaposed against delicate features",
165
+ "In a detailed black tactical outfit, emphasizing an athletic build and long legs",
166
+ "Mid-performance with an electric guitar, captivating an imaginary audience",
167
+ "Belting out a solo performance, microphone in hand, before a cheering crowd",
168
+ "Transformed into a gelatinous alien creature, dripping and otherworldly",
169
+ "With a tie or bowtie, adding a formal or quirky touch to the ensemble",
170
+ "Wearing delicate anklets, adding a feminine charm to the overall look",
171
+ "With a statement belt, either cinching the waist or riding low on the hips",
172
+ "In elegant or rugged gloves, complementing the outfit's overall mood",
173
+ "Sporting a choker, from delicate lace to edgy leather designs",
174
+ "In stockings or tights, either sheer for elegance or patterned for fun",
175
+ "Carrying a stylish bag, from minimalist totes to ornate clutches",
176
+ "With cufflinks, adding a touch of sophistication to formal wear",
177
+ "Wearing a meaningful pendant, dangling from a necklace",
178
+ "In layered necklaces, creating depth with varying lengths and styles",
179
+ "Sporting a watch, balancing functionality with personal style",
180
+ "Wearing a veil, adding mystery and allure to the overall look",
181
+ "Draped in a cape or cloak, bringing drama and movement to the ensemble",
182
+ "Crowned with a tiara or diadem, adding a regal touch to the outfit"
183
+ ]
data/female_body_types.json ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ "pretty",
3
+ "chubby",
4
+ "midweight",
5
+ "overweight",
6
+ "fat",
7
+ "flabby",
8
+ "buxom",
9
+ "voluptuous",
10
+ "hefty",
11
+ "pudgy",
12
+ "plump",
13
+ "obese",
14
+ "morbidly obese",
15
+ "stout",
16
+ "rotund",
17
+ "thick-bodied",
18
+ "thicc",
19
+ "thick",
20
+ "beefy",
21
+ "portly",
22
+ "tubby",
23
+ "overweight",
24
+ "(slightly overweight)",
25
+ "buff",
26
+ "burly",
27
+ "fit",
28
+ "well-built",
29
+ "well-endowed",
30
+ "muscular",
31
+ "stocky",
32
+ "big-boned",
33
+ "curvy",
34
+ "flabby",
35
+ "flyweight",
36
+ "skinny",
37
+ "too skinny",
38
+ "anorexic",
39
+ "not skinny",
40
+ "slender",
41
+ "lanky",
42
+ "slim",
43
+ "slight"
44
+ ]
data/female_clothing.json ADDED
@@ -0,0 +1,344 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ "white crop top, denim shorts,silver bracelet,white texture,denim texture",
3
+ "white top, sleeveless, button-up, white bottoms, ribbed texture",
4
+ "white crop top, blue jeans, silver belt, textured fabric, denim texture",
5
+ "white tank top, black pants, pink and blue goalie pads, black belt, white skates",
6
+ "black long-sleeve dress, fishnet stockings",
7
+ "black bikini top, black bikini bottom, hoop earrings",
8
+ "white towel, white head wrap",
9
+ "gray crop top, black skirt, ribbed texture, v-neckline",
10
+ "black bodysuit, sheer texture, light wash jeans, golden bangles",
11
+ "pink dress, spaghetti straps, form-fitting, floor-length",
12
+ "black sports bra, black leggings, textured fabric, small white logo",
13
+ "black bikini, knit texture, gold accessories, aviator sunglasses",
14
+ "patterned crop top, green leather pants, silver necklaces, red bracelet, hoop earrings",
15
+ "black bikini top, striped pants, beige textures, open white shirt",
16
+ "pink dress, orange sash, gold heels, floral headpiece",
17
+ "pastel pink tank top, blue ripped jeans, black platform heels, neutral shoulder bag",
18
+ "white sleeveless top, ribbed texture, high-cut white bottoms",
19
+ "black dress, plunging neckline, satin texture, brown handbag, chain strap, diamond necklace, wristwatch, silver bracelet",
20
+ "brown crop top, brown skirt, smooth texture",
21
+ "black sports bra, black leggings, white sneakers, textured fabric",
22
+ "blue dress, bodycon fit, sleeveless, zipper detail, V-neckline, subtle sheen",
23
+ "beige tank top, black denim shorts, smooth fabric, ripped texture",
24
+ "black tube top, gold necklace, gold arm cuff, red headwrap",
25
+ "black jumpsuit, zipper detail, form-fitting, long-sleeved",
26
+ "white crop top, blue jeans, silver necklace",
27
+ "light blue crop top, ribbed texture, long sleeves, denim jeans",
28
+ "black swimsuit, plunging neckline, sleeveless",
29
+ "blue dress, strap sleeves, high slit, textured fabric, hoop earrings, wristwatch, bracelet",
30
+ "black sleeveless top, black leather pants, gold necklace",
31
+ "black tank top, chain belt, black shorts, patterned boots",
32
+ "pink hoodie, pink shorts, textured fabric",
33
+ "black bikini top, denim shorts, frayed hems",
34
+ "blue bikini, tie-up detail, vibrant prints, double-strap top, high-cut bottoms, textured fabric",
35
+ "tan crop top, tan high-waisted pants, ripped knee, checked shirt tied, white sneakers",
36
+ "brown tank top, plaid skirt, smooth texture, fitted top, flared skirt",
37
+ "white dress, black sandals, dark sunglasses, textured fabric, sheer sleeves, leather bag",
38
+ "black sports bra, black shorts, black arm band, dark wrist watch, clear eyeglasses",
39
+ "beige hoodie, matching pants, textured fabric",
40
+ "red satin dress, off-shoulder style, knotted front",
41
+ "white crop top, lace details, high-waisted skirt, pleated texture",
42
+ "black dress, sleeveless top, plunging neckline, white cross necklace, textured handbag, silver bracelet",
43
+ "pink halter-neck dress, ribbed texture, form-fitting",
44
+ "yellow lace-up top, white lace bralette, blue denim shorts, green handbag",
45
+ "white crop top, white jeans, glasses",
46
+ "red dress, sleeveless, v-neckline",
47
+ "white blouse, intricate lace, sheer sleeves",
48
+ "white bikini top, white mesh cover-up, white skirt, silver necklace",
49
+ "black oversized t-shirt, white sport socks",
50
+ "black strap top, lace trim, glossy texture",
51
+ "white crop top, ribbed texture, short sleeves, high-waisted shorts, elastic waistband",
52
+ "pink blazer, white top, pink trousers, silky fabric",
53
+ "green sports bra, green shorts, white sneakers, textured fabric",
54
+ "blue crop top, blue shorts, white sneakers, texture appears smooth",
55
+ "black tank top, denim shorts, textured fabric, light blue, frayed hems",
56
+ "green sports bra, green shorts, white socks, multicolored sneakers",
57
+ "straw hat, fringe bikini top, bikini bottom, earth tones",
58
+ "black dress, strap details, sheer textures",
59
+ "grey sweatshirt, soft texture, round neckline",
60
+ "white bikini top, ruffled edges, light fabric, headscarf with print, necklace",
61
+ "red bikini top, snakeskin pattern, textured fabric",
62
+ "white tank top, form-fitting, sleeveless",
63
+ "pink shiny dress, plunging neckline, sleeveless, textured fabric",
64
+ "strawberry-print top, white with red, matching shorts, silver loop earrings",
65
+ "pink crop-top, blue denim shorts, smooth texture, subtle sheen",
66
+ "textured fabric",
67
+ "white top, off-shoulder design, ruffled texture",
68
+ "beige strapless top, golden necklace",
69
+ "pink bikini top, shiny fabric, thin straps, pendant necklace, aviator sunglasses",
70
+ "white top, blue headband, black headphones",
71
+ "dark blue top, v-neckline, smooth texture, necklace with pendant",
72
+ "white top, black accents, mesh details, logo text",
73
+ "yellow crop top, yellow skirt, white high heels, gold necklace",
74
+ "white floral dress, off-shoulder design, sheer fabric",
75
+ "colorful bikini top, gold chain necklace, gold hoop earrings",
76
+ "denim jumpsuit, blue color, zipper front, sleeveless",
77
+ "white halter top, smooth texture",
78
+ "beige fedora, black bikini top, patterned cover-up, light-colored textures",
79
+ "green bikini top, white necklace",
80
+ "black halter top, glossy texture",
81
+ "black jacket, black crop top, black pants, various textures",
82
+ "black strapless top, golden necklace, golden bracelet",
83
+ "tie-dye bikini, blue-green-black hues, sports shorts, black with green and blue patterns",
84
+ "grey turtleneck, sleeveless, soft texture",
85
+ "beige tracksuit, zipper hoodie, matching pants, soft fabric",
86
+ "white tank top, blue jeans, black hair tie, gold necklace, blonde hair",
87
+ "satin top, silver color, strapless design, necklace, bracelet",
88
+ "red dress, plunging neckline, sleeveless, smooth texture, large hoop earrings",
89
+ "white floral dress, puff sleeves, low-cut neckline, butterfly pendant necklace",
90
+ "white fluffy robe, gold chain necklace, red lipstick",
91
+ "blue dress, sleeveless, plunging neckline, cinched waist, flowy texture",
92
+ "black jacket, purple shirt, denim overalls, white hair accessory, cream cardigan, simple necklace",
93
+ "sleeveless top, beige color, ribbed texture, high-waisted pants, black color, button details",
94
+ "white halter top, knotted center, sleeveless, smooth texture",
95
+ "cream crop top, beige striped shirt, blue ripped jeans",
96
+ "patterned white hat, large black glasses, denim jacket, red top, gold ring, white manicure",
97
+ "black rimmed glasses, beige blazer, black top, gold necklace",
98
+ "brown blouse, shoulder strap, gold necklace, stud earrings, eyeglasses, white manicure, gold rings",
99
+ "light green tank top, white drawstrings, ribbed texture, light green bottoms, fitted waistband, casual style",
100
+ "white strapless top, satin texture",
101
+ "white lace top, denim bottoms",
102
+ "camouflage crop top, camouflage shorts, brown boots, silver bracelets, sunglasses, hoop earrings",
103
+ "black top, sheer sleeves, black skirt, black boots, glasses",
104
+ "white ribbed top, plunging neckline, long sleeves, drawstring front, black jeans, distressed details",
105
+ "sleeveless top, beige color, snug fit, shorts, sitting",
106
+ "red dress, textured fabric, thin straps",
107
+ "yellow shirt, lace bralette, hoop earrings",
108
+ "white top, sheer sleeves, lace details, pastel pink bralette",
109
+ "black bodysuit, sheer gloves, patterned scarf, hoop earrings",
110
+ "black corset top, plaid skirt, glossy texture, lace details",
111
+ "beige bikini top, gold chain necklace",
112
+ "blue lace top, cleavage-revealing, long sleeves",
113
+ "black tank top, smooth texture",
114
+ "black halter top, white flower accessory",
115
+ "light pink hairband, green floral dress, gold earrings, light pink nail polish",
116
+ "white top, low neckline, soft texture",
117
+ "black tank top, black headband, headphones",
118
+ "black polka-dot bikini, thin necklace",
119
+ "black sleeveless top, textured fabric, shiny accessories",
120
+ "grey cardigan, white shirt, denim overalls, purple jacket, black hair ties",
121
+ "black leather dress, high-heel boots",
122
+ "blue camo sports bra, blue camo leggings",
123
+ "long-sleeve top, white bandeau, pink hues, sheer texture, butterfly prints",
124
+ "black tank top, white shirt, denim jeans",
125
+ "blue bikini top, blue high-waisted bottoms, large hoop earrings, white sneakers",
126
+ "beige hoodie, blue highlights, black sunglasses, blue sneakers, textured sole",
127
+ "beige hoodie, blue t-shirt, black leggings, blue sneakers, textured materials, oversized top, fitted bottoms",
128
+ "black crop top, black sheer-panelled bottoms, solid colors, smooth textures",
129
+ "straw hat, leopard print bikini, white cover-up",
130
+ "black sports bra, black leggings, smooth textures",
131
+ "black bikini top, shiny texture, gold necklace",
132
+ "white sports bra, white leggings, cream textured cardigan",
133
+ "red dress, thin straps, v-neckline, satin texture",
134
+ "black tank top, smooth texture",
135
+ "white halter top, gold necklace",
136
+ "black bikini, strap details",
137
+ "black bodysuit, white snow jacket, visible textures",
138
+ "no visible clothing",
139
+ "pink beret, light blouse, pink jacket, soft textures",
140
+ "fur-lined hood, beige coat, texture-soft",
141
+ "graphic jacket, multicolored, white hoodie, blue jeans",
142
+ "white tank top, spaghetti straps, lace details, natural textures",
143
+ "red crop top, white bikini bottoms, ribbed fabric",
144
+ "red strapless dress, smooth texture",
145
+ "sleeveless top, neutral color, soft texture",
146
+ "black sleeveless dress, textured fabric, sheer details",
147
+ "metallic green dress, crystal choker necklace",
148
+ "white tank top, gold necklace, natural texture",
149
+ "pearl headpiece, white textured dress, bejeweled adornments, sheer sleeves",
150
+ "white dress, deep neckline, sleeveless, lace-up sides, figure-hugging",
151
+ "white deep v-neck top, gold necklace, neutral makeup, straight hair",
152
+ "none visible",
153
+ "patterned blazer, patterned shorts, black bralette, warm colors, glossy texture",
154
+ "sleeveless top, beige color, denim shorts, light wash, leather seat texture",
155
+ "floral bikini top, white color, printed texture",
156
+ "blue dress, white trim, sparkling necklace, silver earrings, silver bracelet",
157
+ "silver chain necklace, pink pendant, gold bracelet",
158
+ "white headband, white ribbed top, black undergarment, light-colored jacket",
159
+ "yellow bikini top, black phone case",
160
+ "white crop top, light blue ripped jeans, smooth texture, silver necklace",
161
+ "peach sports bra, peach skirt, smooth fabric",
162
+ "patterned dress, black and white, deep neckline, short sleeves, textured fabric, black boots, laced footwear",
163
+ "black sleeveless dress, black heels, silver bracelet, silver necklace",
164
+ "light pink dress, sheer texture, fringe details, brown belt",
165
+ "red lace dress, black fur hat, red gloves",
166
+ "white cropped top, light blue jeans, textured fabric",
167
+ "pink cropped top, ribbed texture, tie-front detail, blue ripped jeans, casual style, light wash denim, black shoulder bag, brown belt",
168
+ "blue patterned bikini, sheer sleeves, ruffled cuffs",
169
+ "red dress, low neckline, sleeveless, smooth texture",
170
+ "pink sports bra, pink leggings, barefoot, black accents",
171
+ "striped one-piece swimsuit, blue and white colors, textured fabric",
172
+ "red ribbed sweater, black leather pants",
173
+ "white crop top, long sleeves, white skirt, textured fabric, green handbag, gold necklace, white wristwatch",
174
+ "white crop top, crisscross neckline, white pants, silver chain accents, white handbag, quilted texture",
175
+ "ribbed beige turtleneck dress, chest cut-out, black handbag, black and white sneakers",
176
+ "white tank top, black pants, smooth textures",
177
+ "White long-sleeve top, ribbed texture",
178
+ "black hoodie, pink leggings, brown shoes, white socks",
179
+ "Blue-purple bikini top, white lace-up detail, purple patterned skirt",
180
+ "strapless top, aqua color, textured fabric, high-waisted trousers, matching color, cinched ankles",
181
+ "pink dress, white cardigan, lacy sleeves",
182
+ "denim jumpsuit, light blue, sleeveless, lace-up front, fringed hem",
183
+ "bikini top, bikini bottom, earth tones, string ties",
184
+ "geometric pattern bodysuit, brown and black colors, plunging neckline, long sleeves, glossy black belt, black shoulder bag",
185
+ "white sleeveless top, silver zipper, textured fabric, blue denim shorts, frayed hems",
186
+ "red frilly dress, white heels, blue hair",
187
+ "white cropped shirt, white shorts, smooth fabric",
188
+ "yellow patterned bikini top, white bikini bottom, sunglasses, wrist accessories",
189
+ "grey bikini top, grey skirt, textured fabric, silver wrist accessory",
190
+ "strapless yellow dress, blue waist sash, beige high heels, black floral hair accessory",
191
+ "white crop top, black pants, pink and blue leg pads, vaughn glove, white skates",
192
+ "purple bikini top, lace-up detail, purple print skirt, textured fabric",
193
+ "pink tank top, blue ripped jeans, black strappy heels, beige shoulder bag",
194
+ "white tank top, blue denim shorts, textured fabric, visible brand writing",
195
+ "white cropped top, textured fabric, light-wash denim jeans, high-waisted, lace-up sides",
196
+ "white cropped cardigan, white pleated skirt, black shoulder bag, dark sunglasses, white bralette, gold necklace",
197
+ "pink crop top, white midriff band, pink shorts, glossy tan heels",
198
+ "black bikini top, black bikini bottoms, smooth fabric",
199
+ "sleeveless top, tan cropped pants, black sunglasses, black backpack straps, ribbed texture top, light colors",
200
+ "white crochet dress, brown belt, textures visible",
201
+ "white off-shoulder top, white shorts, textured fabric, ruffled sleeves",
202
+ "blue crop top, long sleeves, ribbed texture, plunging neckline, gray plaid skirt, pleated design",
203
+ "floral dress, white base, red and green patterns, V-neckline, long sleeves, brown belt, textured fabric",
204
+ "purple dress, gold heels, textured fabric, sleeveless, cut-out detailing",
205
+ "white hat, white dress, tiered ruffles, lace texture, small purse, silver watch, neutral heels",
206
+ "pink crop top, pink skirt, pink high heels, sleeveless, button details, smooth texture",
207
+ "black bodysuit, lace texture, sheer fabric",
208
+ "left: tan bodysuit, right: black dress, plunging neckline, short sleeves",
209
+ "sleeveless sequined dress, black and blue tones, sheer fabric, high slit, silver sequined dress, beige tones, strappy sandals, ankle strap, heeled footwear",
210
+ "black corset, lace texture, black gloves, chandelier earrings, silver necklace",
211
+ "brown polka-dot swimsuit, wide-brimmed straw hat, smooth texture",
212
+ "pink hearts bodysuit, white base, long sleeves",
213
+ "gray crop top, gold necklace, gold earrings, light makeup",
214
+ "Tan crochet bikini top, tan bikini bottom, gold waist chain, black halterneck bikini top, black tie-side bikini bottom, tan crochet bikini top, tan crochet skirt, gold waist chain",
215
+ "white hat, sunglasses, olive green cropped shirt, olive green skirt, black belt, black bikini bottom visible",
216
+ "beige dress, deep neckline, ribbed texture, white heels, criss-cross straps",
217
+ "blue tank top, textured fabric, lace-up front, white shorts, striped pattern, white sneakers",
218
+ "grey cardigan, white crop top, animal print shorts, blue hair",
219
+ "green dress, deep neckline, long sleeves, smooth texture, waist belt",
220
+ "pink bikini, pink heels, pink sunglasses",
221
+ "patterned jacket, patterned skirt, bikini top, vibrant colors, shiny texture",
222
+ "white cropped t-shirt, black graphic design, casual style",
223
+ "Red bikini, white polka dots, bow details",
224
+ "blue polka-dot dress, front buttoning, sleeveless design, white sunglasses, tied waist belt",
225
+ "white sports bra, white leggings, black sneakers, textures visible",
226
+ "lavender floral dress, white sunglasses, silver hoop earrings",
227
+ "sports bra, leggings, pastel green, form-fitting, sleeveless, high-waisted",
228
+ "white top, sheer overlay, light textures",
229
+ "white crop top, blue denim shorts, black and white sneakers, ribbed texture top",
230
+ "red crop top, blue jeans, light textures",
231
+ "blue sports bra, blue leggings, smooth texture",
232
+ "white crop top, high-waisted skirt, textured pink heels, black shoulder bag",
233
+ "striped swimsuit, blue and white, thin straps",
234
+ "white bikini top, white bikini bottoms, smooth texture",
235
+ "denim tube top, denim shorts, light blue, frayed hems, gold necklace, gold bracelet, navel piercing",
236
+ "black cap, black-framed glasses, red and black striped sweater, denim shorts, black belt, clear-lens glasses",
237
+ "crocheted bikini, white color, tassel details, tied straps",
238
+ "black halter dress, cut-out details, form-fitting, knee-length",
239
+ "white bikini, halter neck top, string bikini bottom, smooth texture",
240
+ "black dress, sleeveless, cut-out details, form-fitting",
241
+ "sports bra, leggings, pastel colors, form-fitting, athletic wear",
242
+ "blue and white striped top, front zipper, black shorts, denim texture",
243
+ "patterned dress, white with blue spots, short sleeves, v-neckline, textured fabric",
244
+ "blue bikini, white-orange socks, red-yellow roller skates",
245
+ "white long-sleeve top, distressed blue jeans, white sneakers",
246
+ "Black blazer, v-neckline, satin texture",
247
+ "white off-shoulder top, white bikini bottom, gold necklace, black sunglasses, textured fabrics",
248
+ "floral bikini, vibrant colors, textured fabric",
249
+ "green jumpsuit, cut-out torso, wide-leg pants, sleeveless top, flowy fabric",
250
+ "Pink dress, text patterns, sleeveless, high neckline, cut-out detail",
251
+ "black corset top, ripped blue jeans, white blazer, golden necklace, sunglasses on head",
252
+ "pink tank top, blue denim shorts, diamond choker necklace, brown patterned handbag",
253
+ "black corset top, patterned skirt, glossy texture",
254
+ "White halter top, blue denim jeans, gold bracelet, beige handbag",
255
+ "blue fringe haircut, pink sunglasses, pink denim jacket, white tank top, pink skirt, pink heart-shaped purse",
256
+ "pink crop top, pink shorts, ribbed texture, athletic wear",
257
+ "white off-shoulder top, wide sleeves, straw hat, textured fabric",
258
+ "denim jacket, black dress, white sneakers, blue backpack",
259
+ "white sports bra, black shorts, white sneakers, white socks",
260
+ "brown corset top, brown leather pants, glossy texture",
261
+ "brown cropped top, denim shorts, eyeglasses, wrist watch",
262
+ "white cropped top, blue denim jeans, smooth texture, frayed edges",
263
+ "light blue corset, denim jeans, silver necklace, black belt, light blue handbag",
264
+ "white cropped top, patterned green skirt, fabric texture visible, white undergarment",
265
+ "yellow crop top, blue denim shorts, white strapless top, tan belt, frayed hems",
266
+ "white crochet top, fringed detailing, denim jeans, tan shoulder bag",
267
+ "leopard print halter-top, blue ripped jeans",
268
+ "white long-sleeve top, plunging neckline, high-waisted jeans, distressed denim, blue color, tan ankle boots",
269
+ "black cut-out dress, gold bracelet, black and white heels, beige handbag",
270
+ "black crop top, deep neckline, long sleeves, denim shorts, frayed hem, black bralette, multiple straps, sheer sleeves, mesh pattern, choker necklace, high-waisted shorts, button closure",
271
+ "beige hoodie, matching sweatpants, visible drawstrings, soft texture",
272
+ "gray t-shirt, blue jeans, smooth texture, casual style",
273
+ "pink bikini top, pink skirt, sunglasses, gold watch",
274
+ "lace top, brown skirt, strapless design, textured fabric",
275
+ "strappy dress, beige color, form-fitting, textured fabric, sleeveless, knee-length",
276
+ "black t-shirt, rib cage print, white shorts",
277
+ "light blue hoodie, matching shorts, soft, cotton texture, hoodie drawstrings, exposed midriff",
278
+ "blue patterned top, blue patterned shorts, black glasses",
279
+ "black sequin dress, high neckline, sleeveless, side slit, strappy high heels, silver earrings",
280
+ "black sequined dress, high neckline, sleeveless, back slit, strappy high heels, metallic color",
281
+ "transparent patterned top, black bralette, glossy black pants, glittery sneakers",
282
+ "black eyeliner, silver hoop earrings, gray-scale makeup, camouflage long sleeve top, black crop top, glossy black pants, glittery silver sneakers",
283
+ "blue dress, short sleeves, shiny texture, watch, ring",
284
+ "white crop top, black headphones, black sunglasses",
285
+ "button-up dress, peach color, short sleeves, collar, thigh length, fabric texture",
286
+ "white crop top, yellow sweatpants, textured fabric",
287
+ "striped swimsuit, glasses",
288
+ "pink dress, short sleeves, crew neckline, ribbed texture",
289
+ "pink dress, tiered layers, spaghetti straps, v-neckline, pleated texture, silver watch",
290
+ "red sports bra, red leggings, smooth texture, athletic wear",
291
+ "light jacket, matching trousers, white sneakers, black bag",
292
+ "Yellow checkered bikini, white straps, smooth texture",
293
+ "white ribbed dress, yellow-tinted sunglasses",
294
+ "long-sleeve top, ribbed texture, brown color, matching skirt, high-waisted",
295
+ "black sports bra, striped sheer pants",
296
+ "golden bikini, textured fabric",
297
+ "white crop top, blue denim shorts, cow print boots, silver necklace",
298
+ "orange dress, ribbed texture, short sleeves, side cut-outs, tie-up details",
299
+ "red bikini top, red bikini bottom, ribbed texture, tied sides",
300
+ "black bikini, textured fabric",
301
+ "white corset top, floral pattern, denim jeans, corset laces",
302
+ "white tank top, grey sports bra, grey shorts, textured fabrics, visible branding",
303
+ "white ribbed top, front tie, long sleeves, black leather pants, high-waisted",
304
+ "brown hat, black tank top, white denim shorts, frayed shorts hem",
305
+ "black crop top, mesh sleeves, checkered mini skirt, black boots, textured fabrics",
306
+ "black sweatshirt, cartoon graphic, glasses, light shorts, casual style",
307
+ "crop top, olive green, ribbed texture, high-waisted leggings, olive green, fitted",
308
+ "black bikini, glossy texture, gold earrings",
309
+ "black v-neck top, black belt, black trousers, blue handbag, golden necklace",
310
+ "black crop top, long sleeves, high-waisted leggings, mesh panels, dark hues, white sneakers",
311
+ "white crop top, gray trousers, white sandals, black sunglasses, gold belt",
312
+ "gray cardigan, white crop top, leopard print shorts, blue hair",
313
+ "white v-neck top, knotted waist, light-colored pants, fitted texture",
314
+ "white crop top, grey shorts, white sneakers, text on top",
315
+ "black swimsuit, straw hat, textured fabric",
316
+ "off-shoulder top, white with stripes, casual shorts",
317
+ "white crop top, glitter texture, black leather jacket, black leather pants",
318
+ "black tank top, shoulder straps, scoop neckline",
319
+ "Sleeveless top, pink hue, denim shorts, ripped texture, sunglasses on head",
320
+ "black long-sleeve top, light blue jeans, silver belt, form-fitting, casual style",
321
+ "floral jumpsuit, red and beige, texture visible, high heels, tan-colored",
322
+ "red dress, sleeveless, V-neckline",
323
+ "dark sunglasses, white collared shirt, navy blue sweater, pleated white skirt, black shoulder bag with gold hardware",
324
+ "white tank top, textured fabric, large hoop earrings, headscarf with print",
325
+ "black swimsuit, red headband, sunglasses",
326
+ "black tank top, sheer fabric, patterned design, golden bracelet",
327
+ "camouflage bikini, white-brown-beige tones, high-waisted bottoms, sleeveless top, hoop earrings",
328
+ "patterned crop top, light colors, tie front, long sleeves, white pants, soft texture",
329
+ "green tank top, white shorts, black glasses",
330
+ "Red patterned top, deep neckline, short sleeves",
331
+ "white crop top, lace-up detail, textured skirt, cream color, sleeveless, midriff-baring",
332
+ "white bathrobe, textured fabric, glasses",
333
+ "white cropped top, blue trim, long sleeves, blue track pants",
334
+ "white crop top, pastel green leggings, textured fabric",
335
+ "spotted swimsuit, light-dark contrast, thin straps, skin exposure",
336
+ "black dress, double-breasted, v-neckline, sleeveless, silver necklace",
337
+ "black beanie, black cropped top, black leggings, black boots, red bag, gold watch",
338
+ "beige fedora, white cropped top, textured terracotta skirt",
339
+ "blue denim jeans, blue strapless top, texture appears soft",
340
+ "White lace dress, Off-shoulder sleeves, Corset-style top, Drawstring details",
341
+ "sleeveless top, beige color, ribbed texture, high neckline, light blue jeans, fitted style, denim material, wrist accessory, silver color, sparkling texture",
342
+ "white strapless top, white skirt, shiny fabric",
343
+ "light white dress, thin straps, sheer texture"
344
+ ]
data/female_default_tags.json ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
 
1
+ [
2
+ "a woman",
3
+ "a young woman",
4
+ "a middle aged woman",
5
+ "an old woman"
6
+ ]
data/male_additional_details.json ADDED
@@ -0,0 +1,183 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ "a purple iridescent suit",
3
+ "wearing a (necklace)",
4
+ "wearing ((earrings))",
5
+ "wearing a (bracelet)",
6
+ "wearing one or multiple (rings)",
7
+ "wearing a (brooch)",
8
+ "wearing (eyeglasses)",
9
+ "wearing (sunglasses)",
10
+ "wearing a (hat)",
11
+ "wearing a (scarf)",
12
+ "wearing a (headband)",
13
+ "wearing a (nose ring)",
14
+ "wearing a (lip ring)",
15
+ "wearing a (tongue ring)",
16
+ "wearing an (eyebrow ring)",
17
+ "wearing (face tattoos)",
18
+ "wearing a (wreath)",
19
+ "wearing a (crown)",
20
+ "wearing a (tiara)",
21
+ "wearing a (crown of thorns)",
22
+ "wearing a (crown of jewels)",
23
+ "wearing (bohemian clothes)",
24
+ "wearing (chic clothes)",
25
+ "wearing (glamorous clothes)",
26
+ "wearing (grunge clothes)",
27
+ "wearing (preppy clothes)",
28
+ "wearing (punk clothes)",
29
+ "wearing (retro clothes)",
30
+ "wearing (rockabilly clothes)",
31
+ "wearing (romantic clothes)",
32
+ "wearing (tomboy clothes)",
33
+ "wearing (urban clothes)",
34
+ "wearing (camo clothes)",
35
+ "wearing (robes)",
36
+ "wearing (excessive amount of jewellery)",
37
+ "wearing (vintage clothes)",
38
+ "wearing (western clothes)",
39
+ "wearing (minimalist clothes)",
40
+ "wearing (sportswear clothes)",
41
+ "wearing (flapper clothes)",
42
+ "wearing (pin-up clothes)",
43
+ "wearing (mid-century modern clothes)",
44
+ "wearing (art deco clothes)",
45
+ "wearing (victorian clothes)",
46
+ "wearing (edwardian clothes)",
47
+ "wearing (elizabethan clothes)",
48
+ "wearing (retro 70s clothes)",
49
+ "wearing (retro 80s clothes)",
50
+ "wearing (retro 90s clothes)",
51
+ "wearing (retro 00s clothes)",
52
+ "wearing (musical equipment)",
53
+ "wearing (leather)",
54
+ "wearing (bdsm leather)",
55
+ "wearing (shiny latex)",
56
+ "wearing (shiny latex suit)",
57
+ "wearing (silk)",
58
+ "wearing (full tweed set)",
59
+ "wearing (clothes made entirely of feathers)",
60
+ "wearing (clothes made entirely of fur)",
61
+ "wearing (clothes made entirely of leather)",
62
+ "wearing (clothes made entirely of metal)",
63
+ "wearing (clothes made entirely of plastic)",
64
+ "wearing (clothes adorned with shimmering jewels or crystals)",
65
+ "waring (clothes adorned with sequins)",
66
+ "wearing (clothes with exaggerated or extreme silhouettes)",
67
+ "wearing (clothes with exaggerated or extreme footwear)",
68
+ "wearing (clothes with exaggerated or extreme headwear)",
69
+ "wearing (clothes with exaggerated or extreme facial or body piercings or tattoos)",
70
+ "wearing (clothes with multiple layers or tiers)",
71
+ "wearing (clothes with exaggerated or extreme colors)",
72
+ "wearing (clothes with exaggerated or extreme patterns)",
73
+ "wearing (cloak)",
74
+ "wearing an astronaut armor",
75
+ "wearing a bio mechanical suit",
76
+ "wearing a bio hazard suit",
77
+ "(( working with laptop))",
78
+ "with Heat deformation",
79
+ "(((future soldier, full body armor, futuristic football, shoulder pads, guns, grenades, weapons, bullet proof vest, high tech, straps, belts, camouflage)))",
80
+ "((full body, zoomed out)) long slender legs 80mm",
81
+ "(((sci-fi, future war, cyberpunk, cyborg, future fashion, beautiful face, glowing tattoos)))",
82
+ "((angry expression, pretty face))",
83
+ "(((full body, athletic body, action pose, detailed black soldier outfit, slender long legs)))",
84
+ "playing epic electric guitar solo in front of a huge crowd",
85
+ "singing epic solo into a microphone in front of a huge crowd",
86
+ "as a ((gelatinous horror dripping alien creature))",
87
+ "in a tie or bowtie, lending a touch of formal elegance or quirky charm, knotted around the collar to elevate the outfit",
88
+ "with anklets, delicate chains or beads that gracefully encircle the ankle, adding a touch of femininity with every step",
89
+ "donning a belt, functional yet fashionable, cinching the waist or sitting low on the hips, often with a statement buckle",
90
+ "wearing gloves, either elegant satin for formal events or rugged leather for a tougher look, complementing the attire and mood",
91
+ "with a choker, snugly encircling the neck, often made of lace, velvet, or leather, exuding a mix of elegance and edge",
92
+ "in stockings or tights, sheer or opaque, enhancing the legs while adding a touch of sophistication or playful patterns",
93
+ "with a satchel or bag, a functional accessory that speaks volumes about personal style, be it a minimalist tote or an embellished clutch",
94
+ "wearing cufflinks, subtle symbols of elegance, adorning the sleeves of a formal shirt, showcasing attention to detail",
95
+ "with a pendant, a piece of jewelry that dangles gracefully from a necklace, often holding sentimental or symbolic value",
96
+ "in layered necklaces, a blend of chains of varying lengths, creating depth and showcasing multiple pendants or charms",
97
+ "sporting a watch, a timeless accessory that blends functionality with style, either minimalist or grand, reflecting personal tastes",
98
+ "wearing a veil, a delicate piece of fabric that adds mystery and allure, often seen in bridal or ceremonial attire",
99
+ "donning a cape or cloak, adding drama to the ensemble, flowing gracefully with every movement, evoking a sense of fantasy or regality",
100
+ "with a tiara or diadem, a jeweled headpiece that signifies royalty or celebration, resting gracefully atop the head",
101
+ "Adorned with a crown, symbolizing royalty and authority with gemstones and metals",
102
+ "With a sparkling tiara, reminiscent of princesses or beauty queens",
103
+ "With a poignant crown of thorns, symbolizing sacrifice and resilience",
104
+ "With a jewel-encrusted crown, reflecting affluence and grandeur",
105
+ "In bohemian attire, embodying the free spirits with patterns and fringes",
106
+ "Dressed in chic fashion, blending comfort with high style",
107
+ "In glamorous attire, shiny or sequined, perfect for red-carpet events",
108
+ "Donning grunge wear, with flannels and combat boots, reflecting a rebellious spirit",
109
+ "In preppy clothes, with clean lines and classic patterns",
110
+ "Sporting punk fashion, with leather, studs, and bold hairstyles",
111
+ "In retro outfits, channeling specific decades with authentic pieces",
112
+ "Wearing rockabilly style, with pin-up influences and rock 'n' roll flair",
113
+ "In romantic attire, featuring soft fabrics and feminine silhouettes",
114
+ "Dressed in tomboy fashion, with boyish charm and comfort-focused pieces",
115
+ "In urban streetwear, blending comfort with trendy, city-inspired looks",
116
+ "Wearing camouflage, either for function or as a bold fashion statement",
117
+ "Draped in robes, from casual bathrobes to formal ceremonial garments",
118
+ "Adorned with excessive jewelry, creating a bold and opulent look",
119
+ "In vintage clothes, authentically representing past eras and styles",
120
+ "Sporting western wear, with cowboy hats, boots, and denim",
121
+ "In minimalist attire, focusing on clean lines and a less-is-more approach",
122
+ "Wearing sportswear, blending function and style for athletic pursuits",
123
+ "In flapper style, with dropped waists and ornate beading from the 1920s",
124
+ "Dressed as a pin-up, channeling retro glamour with curve-hugging styles",
125
+ "In mid-century modern fashion, reflecting the sleek designs of the 1950s and 60s",
126
+ "Wearing art deco inspired clothes, with geometric patterns and luxurious fabrics",
127
+ "In Victorian-style attire, with high necklines, corsets, and full skirts",
128
+ "Dressed in Edwardian fashion, featuring S-shaped silhouettes and large hats",
129
+ "In Elizabethan costume, with ruffs, farthingales, and ornate embroidery",
130
+ "Sporting 70s retro looks, with bell-bottoms, platforms, and psychedelic prints",
131
+ "In 80s inspired outfits, featuring bold colors, shoulder pads, and leg warmers",
132
+ "Wearing 90s fashion, with crop tops, high-waisted jeans, and chunky shoes",
133
+ "In early 2000s style, featuring low-rise jeans, crop tops, and platform sandals",
134
+ "With musical equipment, like guitars, drumsticks, or headphones as accessories",
135
+ "In leather attire, from sleek jackets to edgy pants or skirts",
136
+ "Wearing BDSM-inspired leather, with harnesses, collars, or studded accessories",
137
+ "In shiny latex, hugging every curve with a glossy, futuristic appeal",
138
+ "Sporting a full latex suit, covering from neck to toe in sleek, shiny material",
139
+ "Draped in silk, with flowing fabrics that catch the light beautifully",
140
+ "In a full tweed set, channeling British countryside chic",
141
+ "Wearing an outfit made entirely of feathers, creating a bold, avian-inspired look",
142
+ "In a fur ensemble, either faux or real, exuding luxury and warmth",
143
+ "Sporting an all-leather outfit, from jacket to pants and accessories",
144
+ "In a metallic outfit, with clothes seemingly forged from shining metals",
145
+ "Wearing an ensemble made entirely of plastic, futuristic and unconventional",
146
+ "Adorned in clothes shimmering with jewels or crystals, catching light at every angle",
147
+ "In a sequin-covered outfit, sparkling and eye-catching from every view",
148
+ "Wearing clothes with exaggerated silhouettes, pushing the boundaries of shape and form",
149
+ "In footwear with extreme designs, from towering platforms to avant-garde shapes",
150
+ "Sporting headwear with exaggerated proportions or unconventional materials",
151
+ "With extreme facial piercings or full-body tattoos, turning the skin into a canvas",
152
+ "In an outfit with multiple layers or tiers, creating depth and visual interest",
153
+ "Wearing clothes in extremely bold or neon colors, making a vibrant statement",
154
+ "In attire with exaggerated or surreal patterns, creating visual intrigue",
155
+ "Draped in a mysterious cloak, adding an air of intrigue or fantasy",
156
+ "In astronaut armor, representing space exploration and futuristic concepts",
157
+ "Wearing a bio-mechanical suit, blending organic forms with mechanical elements",
158
+ "In a biohazard suit, fully enclosed for protection or as a fashion statement",
159
+ "Engaged with a laptop, representing technology integration in fashion",
160
+ "Surrounded by heat deformation effects, as if the very air is bending around them",
161
+ "In futuristic soldier gear, with high-tech armor, weapons, and camouflage",
162
+ "Posed to accentuate long, slender legs, often with 80mm or higher heels",
163
+ "In sci-fi inspired wear, with cyberpunk elements and glowing tattoos",
164
+ "With an angry expression juxtaposed against delicate features",
165
+ "In a detailed black tactical outfit, emphasizing an athletic build and long legs",
166
+ "Mid-performance with an electric guitar, captivating an imaginary audience",
167
+ "Belting out a solo performance, microphone in hand, before a cheering crowd",
168
+ "Transformed into a gelatinous alien creature, dripping and otherworldly",
169
+ "With a tie or bowtie, adding a formal or quirky touch to the ensemble",
170
+ "Wearing delicate anklets, adding a subtle charm to the overall look",
171
+ "With a statement belt, either cinching the waist or riding low on the hips",
172
+ "In elegant or rugged gloves, complementing the outfit's overall mood",
173
+ "Sporting a choker, from delicate designs to edgy leather styles",
174
+ "In dress socks or patterned socks, adding a pop of color or sophistication",
175
+ "Carrying a stylish bag, from minimalist briefcases to trendy messenger bags",
176
+ "With cufflinks, adding a touch of sophistication to formal wear",
177
+ "Wearing a meaningful pendant, dangling from a necklace",
178
+ "In layered necklaces, creating depth with varying lengths and styles",
179
+ "Sporting a watch, balancing functionality with personal style",
180
+ "Wearing a ceremonial sash, adding formality and significance to the attire",
181
+ "Draped in a cape or cloak, bringing drama and movement to the ensemble",
182
+ "Crowned with a laurel wreath, symbolizing victory or achievement"
183
+ ]
data/male_body_types.json ADDED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ "chubby",
3
+ "midweight",
4
+ "overweight",
5
+ "fat",
6
+ "flabby",
7
+ "hefty",
8
+ "pudgy",
9
+ "plump",
10
+ "obese",
11
+ "morbidly obese",
12
+ "stout",
13
+ "rotund",
14
+ "thick-bodied",
15
+ "thicc",
16
+ "thick",
17
+ "beefy",
18
+ "portly",
19
+ "tubby",
20
+ "overweight",
21
+ "(slightly overweight)",
22
+ "buff",
23
+ "burly",
24
+ "fit",
25
+ "well-built",
26
+ "well-endowed",
27
+ "muscular",
28
+ "stocky",
29
+ "big-boned",
30
+ "flabby",
31
+ "flyweight",
32
+ "skinny",
33
+ "too skinny",
34
+ "anorexic",
35
+ "not skinny",
36
+ "slender",
37
+ "lanky",
38
+ "slim",
39
+ "slight"
40
+ ]
data/male_clothing.json ADDED
@@ -0,0 +1,196 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ [
2
+ "white t-shirt, blue jeans, brown leather belt, white sneakers",
3
+ "black suit, white dress shirt, red tie, polished black shoes",
4
+ "gray hoodie, black sweatpants, white athletic shoes",
5
+ "blue denim jacket, white t-shirt, black jeans, brown boots",
6
+ "khaki chinos, light blue button-up shirt, brown loafers",
7
+ "navy blue blazer, white dress shirt, gray slacks, black dress shoes",
8
+ "red and black plaid flannel shirt, dark wash jeans, work boots",
9
+ "black leather jacket, white t-shirt, dark jeans, black motorcycle boots",
10
+ "green cargo pants, black t-shirt, hiking boots",
11
+ "white polo shirt, khaki shorts, boat shoes",
12
+ "black tuxedo, white dress shirt, black bow tie, patent leather shoes",
13
+ "blue swim trunks, white tank top, flip flops",
14
+ "gray sweatshirt, black joggers, running shoes",
15
+ "brown tweed jacket, cream sweater, dark brown trousers, oxford shoes",
16
+ "black turtleneck, dark gray slacks, Chelsea boots",
17
+ "white linen shirt, light blue shorts, sandals",
18
+ "red basketball jersey, black shorts, high-top sneakers",
19
+ "navy blue pea coat, gray scarf, dark jeans, leather gloves",
20
+ "olive green military jacket, white t-shirt, camouflage pants, combat boots",
21
+ "purple v-neck sweater, light gray chinos, brown brogues",
22
+ "black wetsuit, surfboard shorts",
23
+ "white chef's jacket, black and white checkered pants, non-slip shoes",
24
+ "orange high-visibility vest, blue work shirt, denim jeans, steel-toe boots",
25
+ "light blue scrubs, white lab coat, comfortable shoes",
26
+ "black clergy shirt with white collar, black trousers",
27
+ "tan safari jacket, khaki shorts, hiking boots, wide-brimmed hat",
28
+ "red and white striped rugby shirt, white shorts, cleats",
29
+ "gray pinstripe suit, light blue dress shirt, patterned tie, oxford shoes",
30
+ "black leather vest, white t-shirt, ripped jeans, cowboy boots",
31
+ "yellow raincoat, waterproof pants, rubber boots",
32
+ "white martial arts gi, black belt",
33
+ "blue and white striped sailor shirt, white pants, boat shoes",
34
+ "green scrubs, surgical cap, face mask",
35
+ "black wetsuit, diving boots, gloves",
36
+ "red and black checkered lumberjack shirt, jeans, work boots",
37
+ "white cricket uniform, protective pads, spiked shoes",
38
+ "blue denim overalls, red plaid shirt, work boots",
39
+ "black judge's robe, white collar",
40
+ "tan fishing vest, khaki shorts, waterproof boots",
41
+ "white chef's hat, double-breasted chef's jacket, black pants",
42
+ "orange prison jumpsuit",
43
+ "blue letter carrier uniform, shorts, comfortable walking shoes",
44
+ "green surgical gown, cap, mask, gloves",
45
+ "black cassock, white collar",
46
+ "red and yellow firefighter turnout gear, helmet",
47
+ "blue police uniform, badge, utility belt",
48
+ "white karate uniform, colored belt",
49
+ "gray sweatshirt, matching sweatpants, running shoes",
50
+ "black leather punk jacket with studs, ripped jeans, combat boots",
51
+ "colorful Hawaiian shirt, khaki shorts, sandals",
52
+ "white dress shirt, suspenders, bow tie, black trousers",
53
+ "blue coveralls, work boots, hard hat",
54
+ "camouflage hunting jacket and pants, boots",
55
+ "black graduation gown, cap with tassel",
56
+ "red and white Santa Claus suit, black boots",
57
+ "green elf costume, pointy shoes, hat with bell",
58
+ "white space suit, helmet",
59
+ "blue jeans, flannel shirt, cowboy hat, boots",
60
+ "black ninja outfit, face mask",
61
+ "brown monk's robe, rope belt, sandals",
62
+ "colorful clown costume, oversized shoes, red nose",
63
+ "gray business suit, white shirt, tie, dress shoes",
64
+ "white sailor's uniform, hat",
65
+ "green army uniform, combat boots, beret",
66
+ "blue airline pilot uniform, hat",
67
+ "orange astronaut suit, white helmet",
68
+ "red and white striped Where's Waldo shirt, blue jeans, glasses",
69
+ "black and white referee uniform, whistle",
70
+ "blue mailman uniform, hat, mail bag",
71
+ "white lab coat, stethoscope, scrubs",
72
+ "brown UPS uniform, shorts, brown shoes",
73
+ "gray janitor uniform, name tag",
74
+ "black and white striped prisoner uniform",
75
+ "blue denim jacket, white t-shirt, ripped jeans, sneakers",
76
+ "green camouflage military uniform, boots, hat",
77
+ "red lifeguard swimsuit, whistle, sunglasses",
78
+ "white cricket uniform, protective gear",
79
+ "blue mechanic's coveralls, work boots, tool belt",
80
+ "black tuxedo t-shirt, jeans, sneakers",
81
+ "tan safari outfit, pith helmet",
82
+ "red and white candy striper uniform",
83
+ "blue air force uniform, hat",
84
+ "green park ranger uniform, hat",
85
+ "white naval officer uniform, hat",
86
+ "black and white waiter uniform, bow tie",
87
+ "orange construction worker vest, hard hat, jeans",
88
+ "purple wizard robe, pointed hat",
89
+ "brown Franciscan monk habit",
90
+ "red and gold matador outfit",
91
+ "blue train conductor uniform, hat",
92
+ "green Robin Hood costume, feathered cap",
93
+ "white fencing uniform, mask",
94
+ "black gothic outfit, leather pants, boots",
95
+ "red and white baseball uniform, cap",
96
+ "blue Olympic gymnast uniform",
97
+ "green Boy Scout uniform, badges",
98
+ "white martial arts gi, black belt",
99
+ "tan zookeeper uniform, khaki shorts",
100
+ "blue NASCAR driver uniform, helmet",
101
+ "red Canadian Mountie uniform, hat",
102
+ "black and white mime outfit, face paint",
103
+ "green leprechaun costume, top hat",
104
+ "white ice cream man uniform, hat",
105
+ "blue and white Greek evzone uniform, pom-pom shoes",
106
+ "red British Royal Guard uniform, bearskin hat",
107
+ "black ninja outfit, mask",
108
+ "white chef uniform, tall hat",
109
+ "brown cowboy outfit, hat, boots",
110
+ "blue and white sailor uniform, hat",
111
+ "green army camouflage, helmet",
112
+ "red firefighter uniform, helmet",
113
+ "black SWAT team uniform, bulletproof vest",
114
+ "white astronaut spacesuit, helmet",
115
+ "blue airline pilot uniform, cap",
116
+ "tan safari guide outfit, hat",
117
+ "purple and gold king costume, crown",
118
+ "gray business suit, red tie",
119
+ "blue denim overalls, plaid shirt",
120
+ "black leather biker jacket, jeans",
121
+ "white doctor's coat, stethoscope",
122
+ "green surgical scrubs, mask",
123
+ "red and white Santa Claus outfit",
124
+ "brown UPS delivery uniform",
125
+ "orange prisoner jumpsuit",
126
+ "blue postal worker uniform",
127
+ "black and white referee shirt, whistle",
128
+ "tan park ranger uniform, hat",
129
+ "white naval officer uniform, hat",
130
+ "green army dress uniform, medals",
131
+ "blue air force flight suit",
132
+ "red and white lifeguard outfit",
133
+ "black tuxedo, bow tie",
134
+ "white chef's jacket, checkered pants",
135
+ "blue mechanic's coveralls",
136
+ "green landscaper uniform, work boots",
137
+ "tan archaeologist outfit, hat",
138
+ "purple wizard costume, star-covered robe",
139
+ "red and gold circus ringmaster outfit",
140
+ "blue train conductor uniform, hat",
141
+ "white cricket player uniform",
142
+ "black gothic outfit, leather jacket",
143
+ "red and white racing driver suit",
144
+ "blue Olympic swimmer outfit",
145
+ "green environmental activist t-shirt, cargo pants",
146
+ "white karate uniform, black belt",
147
+ "tan wildlife photographer vest, khaki pants",
148
+ "blue NASCAR pit crew uniform",
149
+ "red Canadian Mountie uniform, hat",
150
+ "black and white mime costume",
151
+ "green St. Patrick's Day outfit, shamrock accessories",
152
+ "white ice cream vendor uniform",
153
+ "blue Greek fisherman outfit",
154
+ "red British Royal Guard uniform",
155
+ "black martial arts uniform",
156
+ "white sushi chef outfit",
157
+ "brown cowboy costume, hat and boots",
158
+ "blue sailor uniform, white hat",
159
+ "green camouflage hunting outfit",
160
+ "red firefighter turnout gear",
161
+ "black tactical police uniform",
162
+ "white space shuttle astronaut suit",
163
+ "blue commercial pilot uniform",
164
+ "tan desert explorer outfit",
165
+ "purple medieval jester costume",
166
+ "gray Wall Street businessman suit",
167
+ "blue denim farmer overalls",
168
+ "black rock band leather outfit",
169
+ "white lab researcher coat",
170
+ "green hospital scrubs",
171
+ "red holiday elf costume",
172
+ "brown delivery driver uniform",
173
+ "orange highway worker safety vest",
174
+ "blue meter reader uniform",
175
+ "black and white soccer referee jersey",
176
+ "tan zookeeper uniform",
177
+ "white cruise ship officer uniform",
178
+ "green military cadet uniform",
179
+ "blue coast guard uniform",
180
+ "red ski patrol jacket",
181
+ "black formal waiter uniform",
182
+ "white professional tennis outfit",
183
+ "blue auto mechanic uniform",
184
+ "green waste management worker uniform",
185
+ "tan construction site manager outfit",
186
+ "purple comic book superhero costume",
187
+ "red circus acrobat leotard",
188
+ "blue ship captain uniform",
189
+ "white cricket umpire outfit",
190
+ "black nightclub bouncer attire",
191
+ "red and white sports mascot costume",
192
+ "blue competitive swimmer outfit",
193
+ "green eco-tour guide uniform",
194
+ "white Taekwondo uniform",
195
+ "tan nature documentary filmmaker outfit"
196
+ ]
data/male_default_tags.json ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
 
1
+ [
2
+ "a man",
3
+ "a young man",
4
+ "a middle aged man",
5
+ "an old man"
6
+ ]
prompt.py CHANGED
@@ -1,3 +1,4 @@
 
1
  import gradio as gr
2
  import random
3
  import json
@@ -10,14 +11,13 @@ import torch
10
  from PIL import Image
11
  from transformers import AutoProcessor, AutoModelForCausalLM
12
  import random
13
- import spaces
14
 
15
  subprocess.run('pip install flash-attn --no-build-isolation', env={'FLASH_ATTENTION_SKIP_CUDA_BUILD': "TRUE"}, shell=True)
16
 
17
  # Initialize Florence model
18
  device = "cuda" if torch.cuda.is_available() else "cpu"
19
- florence_model = AutoModelForCausalLM.from_pretrained('gokaygokay/Florence-2-Flux', trust_remote_code=True).to("cpu").eval()
20
- florence_processor = AutoProcessor.from_pretrained('gokaygokay/Florence-2-Flux', trust_remote_code=True)
21
 
22
  # Florence caption function
23
  @spaces.GPU(duration=30)
@@ -50,24 +50,31 @@ def load_json_file(file_name):
50
  with open(file_path, "r") as file:
51
  return json.load(file)
52
 
 
 
 
 
 
 
 
 
 
 
 
53
  ARTFORM = load_json_file("artform.json")
54
  PHOTO_TYPE = load_json_file("photo_type.json")
55
- BODY_TYPES = load_json_file("body_types.json")
56
- DEFAULT_TAGS = load_json_file("default_tags.json")
57
  ROLES = load_json_file("roles.json")
58
  HAIRSTYLES = load_json_file("hairstyles.json")
59
- ADDITIONAL_DETAILS = load_json_file("additional_details.json")
60
- PHOTOGRAPHY_STYLES = load_json_file("photography_styles.json")
61
- DEVICE = load_json_file("device.json")
62
- PHOTOGRAPHER = load_json_file("photographer.json")
63
- ARTIST = load_json_file("artist.json")
64
- DIGITAL_ARTFORM = load_json_file("digital_artform.json")
65
  PLACE = load_json_file("place.json")
66
  LIGHTING = load_json_file("lighting.json")
67
- CLOTHING = load_json_file("clothing.json")
68
  COMPOSITION = load_json_file("composition.json")
69
  POSE = load_json_file("pose.json")
70
  BACKGROUND = load_json_file("background.json")
 
 
 
 
 
71
 
72
  class PromptGenerator:
73
  def __init__(self, seed=None):
@@ -88,12 +95,12 @@ class PromptGenerator:
88
  return input_str
89
 
90
  def clean_consecutive_commas(self, input_string):
91
- cleaned_string = re.sub(r',\s*,', ',', input_string)
92
  return cleaned_string
93
 
94
  def process_string(self, replaced, seed):
95
- replaced = re.sub(r'\s*,\s*', ',', replaced)
96
- replaced = re.sub(r',+', ',', replaced)
97
  original = replaced
98
 
99
  first_break_clipl_index = replaced.find("BREAK_CLIPL")
@@ -119,24 +126,31 @@ class PromptGenerator:
119
  t5xxl = replaced
120
 
121
  original = original.replace("BREAK_CLIPL", "").replace("BREAK_CLIPG", "")
122
- original = re.sub(r'\s*,\s*', ',', original)
123
- original = re.sub(r',+', ',', original)
124
- clip_l = re.sub(r'\s*,\s*', ',', clip_l)
125
- clip_l = re.sub(r',+', ',', clip_l)
126
- clip_g = re.sub(r'\s*,\s*', ',', clip_g)
127
- clip_g = re.sub(r',+', ',', clip_g)
128
- if clip_l.startswith(","):
129
- clip_l = clip_l[1:]
130
- if clip_g.startswith(","):
131
- clip_g = clip_g[1:]
132
- if original.startswith(","):
133
- original = original[1:]
134
- if t5xxl.startswith(","):
135
- t5xxl = t5xxl[1:]
 
 
 
 
 
 
 
136
 
137
  return original, seed, t5xxl, clip_l, clip_g
138
 
139
- def generate_prompt(self, seed, custom, subject, artform, photo_type, body_types, default_tags, roles, hairstyles,
140
  additional_details, photography_styles, device, photographer, artist, digital_artform,
141
  place, lighting, clothing, composition, pose, background, input_image):
142
  kwargs = locals()
@@ -155,6 +169,7 @@ class PromptGenerator:
155
  )
156
 
157
  subject = kwargs.get("subject", "")
 
158
 
159
  if is_photographer:
160
  selected_photo_style = self.get_choice(kwargs.get("photography_styles", ""), PHOTOGRAPHY_STYLES)
@@ -169,18 +184,18 @@ class PromptGenerator:
169
  if not subject:
170
  if default_tags == "random":
171
  if body_type != "disabled" and body_type != "random":
172
- selected_subject = self.get_choice(kwargs.get("default_tags", ""), DEFAULT_TAGS).replace("a ", "").replace("an ", "")
173
  components.append("a ")
174
  components.append(body_type)
175
  components.append(selected_subject)
176
  elif body_type == "disabled":
177
- selected_subject = self.get_choice(kwargs.get("default_tags", ""), DEFAULT_TAGS)
178
  components.append(selected_subject)
179
  else:
180
- body_type = self.get_choice(body_type, BODY_TYPES)
181
  components.append("a ")
182
  components.append(body_type)
183
- selected_subject = self.get_choice(kwargs.get("default_tags", ""), DEFAULT_TAGS).replace("a ", "").replace("an ", "")
184
  components.append(selected_subject)
185
  elif default_tags == "disabled":
186
  pass
@@ -193,7 +208,7 @@ class PromptGenerator:
193
  elif body_type == "disabled":
194
  pass
195
  else:
196
- body_type = self.get_choice(body_type, BODY_TYPES)
197
  components.append("a ")
198
  components.append(body_type)
199
  components.append(subject)
@@ -201,13 +216,13 @@ class PromptGenerator:
201
  params = [
202
  ("roles", ROLES),
203
  ("hairstyles", HAIRSTYLES),
204
- ("additional_details", ADDITIONAL_DETAILS),
205
  ]
206
  for param in params:
207
  components.append(self.get_choice(kwargs.get(param[0], ""), param[1]))
208
  for i in reversed(range(len(components))):
209
  if components[i] in PLACE:
210
- components[i] += ","
211
  break
212
  if kwargs.get("clothing", "") != "disabled" and kwargs.get("clothing", "") != "random":
213
  components.append(", dressed in ")
@@ -215,49 +230,49 @@ class PromptGenerator:
215
  components.append(clothing)
216
  elif kwargs.get("clothing", "") == "random":
217
  components.append(", dressed in ")
218
- clothing = self.get_choice(kwargs.get("clothing", ""), CLOTHING)
219
  components.append(clothing)
220
 
221
  if kwargs.get("composition", "") != "disabled" and kwargs.get("composition", "") != "random":
222
- components.append(",")
223
  composition = kwargs.get("composition", "")
224
  components.append(composition)
225
  elif kwargs.get("composition", "") == "random":
226
- components.append(",")
227
  composition = self.get_choice(kwargs.get("composition", ""), COMPOSITION)
228
  components.append(composition)
229
 
230
  if kwargs.get("pose", "") != "disabled" and kwargs.get("pose", "") != "random":
231
- components.append(",")
232
  pose = kwargs.get("pose", "")
233
  components.append(pose)
234
  elif kwargs.get("pose", "") == "random":
235
- components.append(",")
236
  pose = self.get_choice(kwargs.get("pose", ""), POSE)
237
  components.append(pose)
238
  components.append("BREAK_CLIPG")
239
  if kwargs.get("background", "") != "disabled" and kwargs.get("background", "") != "random":
240
- components.append(",")
241
  background = kwargs.get("background", "")
242
  components.append(background)
243
  elif kwargs.get("background", "") == "random":
244
- components.append(",")
245
  background = self.get_choice(kwargs.get("background", ""), BACKGROUND)
246
  components.append(background)
247
 
248
  if kwargs.get("place", "") != "disabled" and kwargs.get("place", "") != "random":
249
- components.append(",")
250
  place = kwargs.get("place", "")
251
  components.append(place)
252
  elif kwargs.get("place", "") == "random":
253
- components.append(",")
254
  place = self.get_choice(kwargs.get("place", ""), PLACE)
255
- components.append(place + ",")
256
 
257
  lighting = kwargs.get("lighting", "").lower()
258
  if lighting == "random":
259
  selected_lighting = ", ".join(self.rng.sample(LIGHTING, self.rng.randint(2, 5)))
260
- components.append(",")
261
  components.append(selected_lighting)
262
  elif lighting == "disabled":
263
  pass
@@ -302,14 +317,15 @@ class PromptGenerator:
302
  return f"{prompt}, {caption}"
303
  return prompt
304
 
 
 
 
305
  class HuggingFaceInferenceNode:
306
  def __init__(self):
307
- self.clients = {
308
- "Mixtral": InferenceClient("NousResearch/Nous-Hermes-2-Mixtral-8x7B-DPO"),
309
- "Mistral": InferenceClient("mistralai/Mistral-7B-Instruct-v0.3"),
310
- "Llama 3": InferenceClient("meta-llama/Meta-Llama-3-8B-Instruct"),
311
- "Mistral-Nemo": InferenceClient("mistralai/Mistral-Nemo-Instruct-2407")
312
- }
313
  self.prompts_dir = "./prompts"
314
  os.makedirs(self.prompts_dir, exist_ok=True)
315
 
@@ -326,10 +342,8 @@ class HuggingFaceInferenceNode:
326
 
327
  print(f"Prompt saved to {filename}")
328
 
329
- def generate(self, model, input_text, happy_talk, compress, compression_level, poster, custom_base_prompt=""):
330
  try:
331
- client = self.clients[model]
332
-
333
  default_happy_prompt = """Create a detailed visually descriptive caption of this description, which will be used as a prompt for a text to image AI system (caption only, no instructions like "create an image").Remove any mention of digital artwork or artwork style. Give detailed visual descriptions of the character(s), including ethnicity, skin tone, expression etc. Imagine using keywords for a still for someone who has aphantasia. Describe the image style, e.g. any photographic or art styles / techniques utilized. Make sure to fully describe all aspects of the cinematography, with abundant technical details and visual descriptions. If there is more than one image, combine the elements and characters from all of the images creatively into a single cohesive composition with a single background, inventing an interaction between the characters. Be creative in combining the characters into a single cohesive scene. Focus on two primary characters (or one) and describe an interesting interaction between them, such as a hug, a kiss, a fight, giving an object, an emotional reaction / interaction. If there is more than one background in the images, pick the most appropriate one. Your output is only the caption itself, no comments or extra formatting. The caption is in a single long paragraph. If you feel the images are inappropriate, invent a new scene / characters inspired by these. Additionally, incorporate a specific movie director's visual style and describe the lighting setup in detail, including the type, color, and placement of light sources to create the desired mood and atmosphere. Always frame the scene, including details about the film grain, color grading, and any artifacts or characteristics specific."""
334
 
335
  default_simple_prompt = """Create a brief, straightforward caption for this description, suitable for a text-to-image AI system. Focus on the main elements, key characters, and overall scene without elaborate details. Provide a clear and concise description in one or two sentences."""
@@ -360,23 +374,24 @@ You are allowed to make up film and branding names, and do them like 80's, 90's
360
  char_limit = compression_chars[compression_level]
361
  base_prompt += f" Compress the output to be concise while retaining key visual details. MAX OUTPUT SIZE no more than {char_limit} characters."
362
 
363
- messages = f"<|im_start|>system\nYou are a helpful assistant. Try your best to give best response possible to user.<|im_end|>"
364
- messages += f"\n<|im_start|>user\n{base_prompt}\nDescription: {input_text}<|im_end|>\n<|im_start|>assistant\n"
365
-
366
- stream = client.text_generation(messages, max_new_tokens=4000, do_sample=True, stream=True, details=True, return_full_text=False)
367
- output = ""
368
- for response in stream:
369
- if not response.token.text == "<|im_end|>":
370
- output += response.token.text
371
-
372
- # Remove specific tokens based on the model
373
- if model == "Llama 3":
374
- output = output.rstrip("<|eot_id|>")
375
- elif model == "Mistral":
376
- output = output.rstrip("</s>")
377
- elif model == "Mistral-Nemo":
378
- output = output.rstrip("<|im_end|></s>")
379
-
 
380
  # Clean up the output
381
  if ": " in output:
382
  output = output.split(": ", 1)[1].strip()
@@ -549,6 +564,160 @@ def create_interface():
549
 
550
  return demo
551
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
552
  if __name__ == "__main__":
553
  demo = create_interface()
554
  demo.launch()
 
1
+ import spaces
2
  import gradio as gr
3
  import random
4
  import json
 
11
  from PIL import Image
12
  from transformers import AutoProcessor, AutoModelForCausalLM
13
  import random
 
14
 
15
  subprocess.run('pip install flash-attn --no-build-isolation', env={'FLASH_ATTENTION_SKIP_CUDA_BUILD': "TRUE"}, shell=True)
16
 
17
  # Initialize Florence model
18
  device = "cuda" if torch.cuda.is_available() else "cpu"
19
+ florence_model = AutoModelForCausalLM.from_pretrained('microsoft/Florence-2-base', trust_remote_code=True).to("cpu").eval()
20
+ florence_processor = AutoProcessor.from_pretrained('microsoft/Florence-2-base', trust_remote_code=True)
21
 
22
  # Florence caption function
23
  @spaces.GPU(duration=30)
 
50
  with open(file_path, "r") as file:
51
  return json.load(file)
52
 
53
+ # Load gender-specific JSON files
54
+ FEMALE_DEFAULT_TAGS = load_json_file("female_default_tags.json")
55
+ MALE_DEFAULT_TAGS = load_json_file("male_default_tags.json")
56
+ FEMALE_BODY_TYPES = load_json_file("female_body_types.json")
57
+ MALE_BODY_TYPES = load_json_file("male_body_types.json")
58
+ FEMALE_CLOTHING = load_json_file("female_clothing.json")
59
+ MALE_CLOTHING = load_json_file("male_clothing.json")
60
+ FEMALE_ADDITIONAL_DETAILS = load_json_file("female_additional_details.json")
61
+ MALE_ADDITIONAL_DETAILS = load_json_file("male_additional_details.json")
62
+
63
+ # Load non-gender-specific JSON files
64
  ARTFORM = load_json_file("artform.json")
65
  PHOTO_TYPE = load_json_file("photo_type.json")
 
 
66
  ROLES = load_json_file("roles.json")
67
  HAIRSTYLES = load_json_file("hairstyles.json")
 
 
 
 
 
 
68
  PLACE = load_json_file("place.json")
69
  LIGHTING = load_json_file("lighting.json")
 
70
  COMPOSITION = load_json_file("composition.json")
71
  POSE = load_json_file("pose.json")
72
  BACKGROUND = load_json_file("background.json")
73
+ PHOTOGRAPHY_STYLES = load_json_file("photography_styles.json")
74
+ DEVICE = load_json_file("device.json")
75
+ PHOTOGRAPHER = load_json_file("photographer.json")
76
+ ARTIST = load_json_file("artist.json")
77
+ DIGITAL_ARTFORM = load_json_file("digital_artform.json")
78
 
79
  class PromptGenerator:
80
  def __init__(self, seed=None):
 
95
  return input_str
96
 
97
  def clean_consecutive_commas(self, input_string):
98
+ cleaned_string = re.sub(r',\s*,', ', ', input_string)
99
  return cleaned_string
100
 
101
  def process_string(self, replaced, seed):
102
+ replaced = re.sub(r'\s*,\s*', ', ', replaced)
103
+ replaced = re.sub(r',+', ', ', replaced)
104
  original = replaced
105
 
106
  first_break_clipl_index = replaced.find("BREAK_CLIPL")
 
126
  t5xxl = replaced
127
 
128
  original = original.replace("BREAK_CLIPL", "").replace("BREAK_CLIPG", "")
129
+ original = re.sub(r'\s*,\s*', ', ', original)
130
+ original = re.sub(r',+', ', ', original)
131
+ clip_l = re.sub(r'\s*,\s*', ', ', clip_l)
132
+ clip_l = re.sub(r',+', ', ', clip_l)
133
+ clip_g = re.sub(r'\s*,\s*', ', ', clip_g)
134
+ clip_g = re.sub(r',+', ', ', clip_g)
135
+ if clip_l.startswith(", "):
136
+ clip_l = clip_l[2:]
137
+ if clip_g.startswith(", "):
138
+ clip_g = clip_g[2:]
139
+ if original.startswith(", "):
140
+ original = original[2:]
141
+ if t5xxl.startswith(", "):
142
+ t5xxl = t5xxl[2:]
143
+
144
+ # Add spaces after commas
145
+ replaced = re.sub(r',(?!\s)', ', ', replaced)
146
+ original = re.sub(r',(?!\s)', ', ', original)
147
+ clip_l = re.sub(r',(?!\s)', ', ', clip_l)
148
+ clip_g = re.sub(r',(?!\s)', ', ', clip_g)
149
+ t5xxl = re.sub(r',(?!\s)', ', ', t5xxl)
150
 
151
  return original, seed, t5xxl, clip_l, clip_g
152
 
153
+ def generate_prompt(self, seed, custom, subject, gender, artform, photo_type, body_types, default_tags, roles, hairstyles,
154
  additional_details, photography_styles, device, photographer, artist, digital_artform,
155
  place, lighting, clothing, composition, pose, background, input_image):
156
  kwargs = locals()
 
169
  )
170
 
171
  subject = kwargs.get("subject", "")
172
+ gender = kwargs.get("gender", "female")
173
 
174
  if is_photographer:
175
  selected_photo_style = self.get_choice(kwargs.get("photography_styles", ""), PHOTOGRAPHY_STYLES)
 
184
  if not subject:
185
  if default_tags == "random":
186
  if body_type != "disabled" and body_type != "random":
187
+ selected_subject = self.get_choice(kwargs.get("default_tags", ""), FEMALE_DEFAULT_TAGS if gender == "female" else MALE_DEFAULT_TAGS).replace("a ", "").replace("an ", "")
188
  components.append("a ")
189
  components.append(body_type)
190
  components.append(selected_subject)
191
  elif body_type == "disabled":
192
+ selected_subject = self.get_choice(kwargs.get("default_tags", ""), FEMALE_DEFAULT_TAGS if gender == "female" else MALE_DEFAULT_TAGS)
193
  components.append(selected_subject)
194
  else:
195
+ body_type = self.get_choice(body_type, FEMALE_BODY_TYPES if gender == "female" else MALE_BODY_TYPES)
196
  components.append("a ")
197
  components.append(body_type)
198
+ selected_subject = self.get_choice(kwargs.get("default_tags", ""), FEMALE_DEFAULT_TAGS if gender == "female" else MALE_DEFAULT_TAGS).replace("a ", "").replace("an ", "")
199
  components.append(selected_subject)
200
  elif default_tags == "disabled":
201
  pass
 
208
  elif body_type == "disabled":
209
  pass
210
  else:
211
+ body_type = self.get_choice(body_type, FEMALE_BODY_TYPES if gender == "female" else MALE_BODY_TYPES)
212
  components.append("a ")
213
  components.append(body_type)
214
  components.append(subject)
 
216
  params = [
217
  ("roles", ROLES),
218
  ("hairstyles", HAIRSTYLES),
219
+ ("additional_details", FEMALE_ADDITIONAL_DETAILS if gender == "female" else MALE_ADDITIONAL_DETAILS),
220
  ]
221
  for param in params:
222
  components.append(self.get_choice(kwargs.get(param[0], ""), param[1]))
223
  for i in reversed(range(len(components))):
224
  if components[i] in PLACE:
225
+ components[i] += ", "
226
  break
227
  if kwargs.get("clothing", "") != "disabled" and kwargs.get("clothing", "") != "random":
228
  components.append(", dressed in ")
 
230
  components.append(clothing)
231
  elif kwargs.get("clothing", "") == "random":
232
  components.append(", dressed in ")
233
+ clothing = self.get_choice(kwargs.get("clothing", ""), FEMALE_CLOTHING if gender == "female" else MALE_CLOTHING)
234
  components.append(clothing)
235
 
236
  if kwargs.get("composition", "") != "disabled" and kwargs.get("composition", "") != "random":
237
+ components.append(", ")
238
  composition = kwargs.get("composition", "")
239
  components.append(composition)
240
  elif kwargs.get("composition", "") == "random":
241
+ components.append(", ")
242
  composition = self.get_choice(kwargs.get("composition", ""), COMPOSITION)
243
  components.append(composition)
244
 
245
  if kwargs.get("pose", "") != "disabled" and kwargs.get("pose", "") != "random":
246
+ components.append(", ")
247
  pose = kwargs.get("pose", "")
248
  components.append(pose)
249
  elif kwargs.get("pose", "") == "random":
250
+ components.append(", ")
251
  pose = self.get_choice(kwargs.get("pose", ""), POSE)
252
  components.append(pose)
253
  components.append("BREAK_CLIPG")
254
  if kwargs.get("background", "") != "disabled" and kwargs.get("background", "") != "random":
255
+ components.append(", ")
256
  background = kwargs.get("background", "")
257
  components.append(background)
258
  elif kwargs.get("background", "") == "random":
259
+ components.append(", ")
260
  background = self.get_choice(kwargs.get("background", ""), BACKGROUND)
261
  components.append(background)
262
 
263
  if kwargs.get("place", "") != "disabled" and kwargs.get("place", "") != "random":
264
+ components.append(", ")
265
  place = kwargs.get("place", "")
266
  components.append(place)
267
  elif kwargs.get("place", "") == "random":
268
+ components.append(", ")
269
  place = self.get_choice(kwargs.get("place", ""), PLACE)
270
+ components.append(place + ", ")
271
 
272
  lighting = kwargs.get("lighting", "").lower()
273
  if lighting == "random":
274
  selected_lighting = ", ".join(self.rng.sample(LIGHTING, self.rng.randint(2, 5)))
275
+ components.append(", ")
276
  components.append(selected_lighting)
277
  elif lighting == "disabled":
278
  pass
 
317
  return f"{prompt}, {caption}"
318
  return prompt
319
 
320
+ import os
321
+ from openai import OpenAI
322
+
323
  class HuggingFaceInferenceNode:
324
  def __init__(self):
325
+ self.client = OpenAI(
326
+ base_url="https://api-inference.huggingface.co/v1/",
327
+ #api_key=huggingface_token,
328
+ )
 
 
329
  self.prompts_dir = "./prompts"
330
  os.makedirs(self.prompts_dir, exist_ok=True)
331
 
 
342
 
343
  print(f"Prompt saved to {filename}")
344
 
345
+ def generate(self, input_text, happy_talk, compress, compression_level, poster, custom_base_prompt=""):
346
  try:
 
 
347
  default_happy_prompt = """Create a detailed visually descriptive caption of this description, which will be used as a prompt for a text to image AI system (caption only, no instructions like "create an image").Remove any mention of digital artwork or artwork style. Give detailed visual descriptions of the character(s), including ethnicity, skin tone, expression etc. Imagine using keywords for a still for someone who has aphantasia. Describe the image style, e.g. any photographic or art styles / techniques utilized. Make sure to fully describe all aspects of the cinematography, with abundant technical details and visual descriptions. If there is more than one image, combine the elements and characters from all of the images creatively into a single cohesive composition with a single background, inventing an interaction between the characters. Be creative in combining the characters into a single cohesive scene. Focus on two primary characters (or one) and describe an interesting interaction between them, such as a hug, a kiss, a fight, giving an object, an emotional reaction / interaction. If there is more than one background in the images, pick the most appropriate one. Your output is only the caption itself, no comments or extra formatting. The caption is in a single long paragraph. If you feel the images are inappropriate, invent a new scene / characters inspired by these. Additionally, incorporate a specific movie director's visual style and describe the lighting setup in detail, including the type, color, and placement of light sources to create the desired mood and atmosphere. Always frame the scene, including details about the film grain, color grading, and any artifacts or characteristics specific."""
348
 
349
  default_simple_prompt = """Create a brief, straightforward caption for this description, suitable for a text-to-image AI system. Focus on the main elements, key characters, and overall scene without elaborate details. Provide a clear and concise description in one or two sentences."""
 
374
  char_limit = compression_chars[compression_level]
375
  base_prompt += f" Compress the output to be concise while retaining key visual details. MAX OUTPUT SIZE no more than {char_limit} characters."
376
 
377
+ system_message = "You are a helpful assistant. Try your best to give the best response possible to the user."
378
+ user_message = f"{base_prompt}\nDescription: {input_text}"
379
+
380
+ messages = [
381
+ {"role": "system", "content": system_message},
382
+ {"role": "user", "content": user_message}
383
+ ]
384
+
385
+ response = self.client.chat.completions.create(
386
+ model="meta-llama/Meta-Llama-3.1-70B-Instruct",
387
+ max_tokens=1024,
388
+ temperature=0.7,
389
+ top_p=0.95,
390
+ messages=messages,
391
+ )
392
+
393
+ output = response.choices[0].message.content.strip()
394
+
395
  # Clean up the output
396
  if ": " in output:
397
  output = output.split(": ", 1)[1].strip()
 
564
 
565
  return demo
566
 
567
+ if __name__ == "__main__":
568
+ demo = create_interface()
569
+ demo.launch()
570
+
571
+
572
+ def create_interface():
573
+ prompt_generator = PromptGenerator()
574
+ huggingface_node = HuggingFaceInferenceNode()
575
+
576
+ with gr.Blocks(theme='bethecloud/storj_theme') as demo:
577
+
578
+ gr.HTML(pg_title)
579
+
580
+ with gr.Row():
581
+ with gr.Column(scale=2):
582
+ with gr.Accordion("Basic Settings"):
583
+ pg_custom = gr.Textbox(label="Custom Input Prompt (optional)")
584
+ pg_subject = gr.Textbox(label="Subject (optional)")
585
+ pg_gender = gr.Radio(["female", "male"], label="Gender", value="female")
586
+
587
+ # Add the radio button for global option selection
588
+ pg_global_option = gr.Radio(
589
+ ["Disabled", "Random", "No Figure Rand"],
590
+ label="Set all options to:",
591
+ value="Disabled"
592
+ )
593
+
594
+ with gr.Accordion("Artform and Photo Type", open=False):
595
+ pg_artform = gr.Dropdown(["disabled", "random"] + ARTFORM, label="Artform", value="disabled")
596
+ pg_photo_type = gr.Dropdown(["disabled", "random"] + PHOTO_TYPE, label="Photo Type", value="disabled")
597
+
598
+ with gr.Accordion("Character Details", open=False):
599
+ pg_body_types = gr.Dropdown(["disabled", "random"] + FEMALE_BODY_TYPES + MALE_BODY_TYPES, label="Body Types", value="disabled")
600
+ pg_default_tags = gr.Dropdown(["disabled", "random"] + FEMALE_DEFAULT_TAGS + MALE_DEFAULT_TAGS, label="Default Tags", value="disabled")
601
+ pg_roles = gr.Dropdown(["disabled", "random"] + ROLES, label="Roles", value="disabled")
602
+ pg_hairstyles = gr.Dropdown(["disabled", "random"] + HAIRSTYLES, label="Hairstyles", value="disabled")
603
+ pg_clothing = gr.Dropdown(["disabled", "random"] + FEMALE_CLOTHING + MALE_CLOTHING, label="Clothing", value="disabled")
604
+
605
+ with gr.Accordion("Scene Details", open=False):
606
+ pg_place = gr.Dropdown(["disabled", "random"] + PLACE, label="Place", value="disabled")
607
+ pg_lighting = gr.Dropdown(["disabled", "random"] + LIGHTING, label="Lighting", value="disabled")
608
+ pg_composition = gr.Dropdown(["disabled", "random"] + COMPOSITION, label="Composition", value="disabled")
609
+ pg_pose = gr.Dropdown(["disabled", "random"] + POSE, label="Pose", value="disabled")
610
+ pg_background = gr.Dropdown(["disabled", "random"] + BACKGROUND, label="Background", value="disabled")
611
+
612
+ with gr.Accordion("Style and Artist", open=False):
613
+ pg_additional_details = gr.Dropdown(["disabled", "random"] + FEMALE_ADDITIONAL_DETAILS + MALE_ADDITIONAL_DETAILS, label="Additional Details", value="disabled")
614
+ pg_photography_styles = gr.Dropdown(["disabled", "random"] + PHOTOGRAPHY_STYLES, label="Photography Styles", value="disabled")
615
+ pg_device = gr.Dropdown(["disabled", "random"] + DEVICE, label="Device", value="disabled")
616
+ pg_photographer = gr.Dropdown(["disabled", "random"] + PHOTOGRAPHER, label="Photographer", value="disabled")
617
+ pg_artist = gr.Dropdown(["disabled", "random"] + ARTIST, label="Artist", value="disabled")
618
+ pg_digital_artform = gr.Dropdown(["disabled", "random"] + DIGITAL_ARTFORM, label="Digital Artform", value="disabled")
619
+
620
+ pg_generate_button = gr.Button("Generate Prompt")
621
+
622
+ with gr.Column(scale=2):
623
+ with gr.Accordion("Image and Caption", open=False):
624
+ pg_input_image = gr.Image(label="Input Image (optional)")
625
+ pg_caption_output = gr.Textbox(label="Generated Caption", lines=3)
626
+ pg_create_caption_button = gr.Button("Create Caption")
627
+ pg_add_caption_button = gr.Button("Add Caption to Prompt")
628
+
629
+ with gr.Accordion("Prompt Generation", open=True):
630
+ pg_output = gr.Textbox(label="Generated Prompt / Input Text", lines=4)
631
+ pg_t5xxl_output = gr.Textbox(label="T5XXL Output", visible=True)
632
+ pg_clip_l_output = gr.Textbox(label="CLIP L Output", visible=True)
633
+ pg_clip_g_output = gr.Textbox(label="CLIP G Output", visible=True)
634
+
635
+ with gr.Column(scale=2):
636
+ with gr.Accordion("Prompt Generation with LLM", open=False):
637
+ pg_happy_talk = gr.Checkbox(label="Happy Talk", value=True)
638
+ pg_compress = gr.Checkbox(label="Compress", value=True)
639
+ pg_compression_level = gr.Radio(["soft", "medium", "hard"], label="Compression Level", value="hard")
640
+ pg_poster = gr.Checkbox(label="Poster", value=False)
641
+ pg_custom_base_prompt = gr.Textbox(label="Custom Base Prompt", lines=5)
642
+ pg_generate_text_button = gr.Button("Generate Prompt with LLM (Llama 3.1 70B)")
643
+ pg_text_output = gr.Textbox(label="Generated Text", lines=10)
644
+
645
+ def create_caption(image):
646
+ if image is not None:
647
+ return florence_caption(image)
648
+ return ""
649
+
650
+ pg_create_caption_button.click(
651
+ create_caption,
652
+ inputs=[pg_input_image],
653
+ outputs=[pg_caption_output]
654
+ )
655
+
656
+ def generate_prompt_with_dynamic_seed(*args):
657
+ # Generate a new random seed
658
+ dynamic_seed = random.randint(0, 1000000)
659
+
660
+ # Call the generate_prompt function with the dynamic seed
661
+ result = prompt_generator.generate_prompt(dynamic_seed, *args)
662
+
663
+ # Return the result along with the used seed
664
+ return [dynamic_seed] + list(result)
665
+
666
+ pg_generate_button.click(
667
+ generate_prompt_with_dynamic_seed,
668
+ inputs=[pg_custom, pg_subject, pg_gender, pg_artform, pg_photo_type, pg_body_types, pg_default_tags, pg_roles, pg_hairstyles,
669
+ pg_additional_details, pg_photography_styles, pg_device, pg_photographer, pg_artist, pg_digital_artform,
670
+ pg_place, pg_lighting, pg_clothing, pg_composition, pg_pose, pg_background, pg_input_image],
671
+ outputs=[gr.Number(label="Used Seed", visible=True), pg_output, gr.Number(visible=False), pg_t5xxl_output, pg_clip_l_output, pg_clip_g_output]
672
+ )
673
+
674
+ pg_add_caption_button.click(
675
+ prompt_generator.add_caption_to_prompt,
676
+ inputs=[pg_output, pg_caption_output],
677
+ outputs=[pg_output]
678
+ )
679
+
680
+ pg_generate_text_button.click(
681
+ huggingface_node.generate,
682
+ inputs=[pg_output, pg_happy_talk, pg_compress, pg_ompression_level, pg_poster, pg_custom_base_prompt],
683
+ outputs=pg_text_output
684
+ )
685
+
686
+ def update_all_options(choice):
687
+ updates = {}
688
+ if choice == "Disabled":
689
+ for dropdown in [
690
+ pg_artform, pg_photo_type, pg_body_types, pg_default_tags, pg_roles, pg_hairstyles, pg_clothing,
691
+ pg_place, pg_lighting, pg_composition, pg_pose, pg_background, pg_additional_details,
692
+ pg_photography_styles, device, pg_photographer, pg_artist, pg_digital_artform
693
+ ]:
694
+ updates[dropdown] = gr.update(value="disabled")
695
+ elif choice == "Random":
696
+ for dropdown in [
697
+ pg_artform, pg_photo_type, pg_body_types, pg_default_tags, pg_roles, pg_hairstyles, pg_clothing,
698
+ pg_place, pg_lighting, pg_composition, pg_pose, pg_background, pg_additional_details,
699
+ pg_photography_styles, pg_device, pg_photographer, pg_artist, pg_digital_artform
700
+ ]:
701
+ updates[dropdown] = gr.update(value="random")
702
+ else: # No Figure Random
703
+ for dropdown in [pg_photo_type, pg_body_types, pg_default_tags, pg_roles, pg_hairstyles, pg_clothing, pg_pose, pg_additional_details]:
704
+ updates[dropdown] = gr.update(value="disabled")
705
+ for dropdown in [pg_artform, pg_place, pg_lighting, pg_composition, pg_background, pg_photography_styles, device, pg_photographer, pg_artist, pg_digital_artform]:
706
+ updates[dropdown] = gr.update(value="random")
707
+ return updates
708
+
709
+ pg_global_option.change(
710
+ update_all_options,
711
+ inputs=[pg_global_option],
712
+ outputs=[
713
+ pg_artform, pg_photo_type, pg_body_types, pg_default_tags, pg_roles, pg_hairstyles, pg_clothing,
714
+ pg_place, pg_lighting, pg_composition, pg_pose, pg_background, pg_additional_details,
715
+ pg_photography_styles, pg_device, pg_photographer, pg_artist, pg_digital_artform
716
+ ]
717
+ )
718
+
719
+ return demo
720
+
721
  if __name__ == "__main__":
722
  demo = create_interface()
723
  demo.launch()
requirements.txt CHANGED
@@ -14,3 +14,4 @@ kornia
14
  numpy
15
  opencv-python
16
  deepspeed
 
 
14
  numpy
15
  opencv-python
16
  deepspeed
17
+ openai==1.37.0