import google.generativeai as genai
# import os
# api_key = os.getenv("GEMINI_API_KEY")
# if not api_key:
# raise ValueError("API key not found")
api_key="AIzaSyBFGmov28dektbVZ5MfPT5o-THOgej2u24"
genai.configure(api_key=api_key)
model = genai.GenerativeModel("gemini-1.5-flash")
prompt1 = """An young indian office lady, standing in front of pot inside office with exotic plants"""
system_prompt = f"""\
Act as a professional stylist and generate highly detailed prompt styling suggestions based on a given look or style preference.
The details should be highly detailed simialar to how a professional stylist would describe a look. Use EXAMPLE_INPUT and EXAMPLE_OUTPUT \
as a reference as example for properly understand how exactly you have to describe faces
Input: A general prompt describing the look or style preference.
Output: A well-structured, detailed styling guide based on face shape, eyes, lips, hair, skin tone, and body type.
Step 1: Extract Core Elements
- Face Shape: Oval, Round, Square, Heart, Diamond, etc.
- Eye Shape & Color: Almond, Hooded, Monolid, Deep-set; Brown, Blue, Green, etc.
- Lips: Thin, Full, Defined Cupid’s bow, etc.
- Hair Type & Length: Straight, Wavy, Curly, Coily; Short, Medium, Long.
- Skin Tone: Fair, Medium, Olive, Dark, etc.
- Body Type: Petite, Tall, Athletic, Curvy, etc.
- Occasion: Casual, Formal, Streetwear, Vintage, Business, Party, etc.
Step 2: Generate a Detailed Styling Prompt
Given the extracted details, the generator will create a tailored styling suggestion.
An young indian girl standing in front of a rock wall with visible large rocks
✨ Generated Styling Prompt:
A young Indian girl with warm brown skin and expressive almond-shaped eyes stands
gracefully in front of a textured rock wall with large, visible stones. Her long,
wavy black hair cascades over her shoulders, catching the soft sunlight. She
wears a flowing, earth-toned bohemian dress that complements the rugged background,
with delicate golden jewelry adding a subtle elegance. Her full lips curve into a
serene smile as she gazes into the distance, embodying a harmonious blend of strength
and grace.
- you should only return the prompt and nothing else
- you should not return the system prompt
- you should not return any other details from prompt
${prompt1}
"""
response = model.generate_content(system_prompt)
print(response.text)