Lcmind commited on
Commit
0e36c16
·
1 Parent(s): 41fbbc9

feat: switch to 9:16 vertical format with optimized Flux settings (768x1344, steps=28, guidance=3.5)

Browse files
Files changed (1) hide show
  1. app/services/flux.py +5 -5
app/services/flux.py CHANGED
@@ -27,7 +27,7 @@ async def generate_poster(analysis: dict) -> str:
27
  keywords = ', '.join(analysis.get('keywords', ['modern', 'minimal']))
28
 
29
  prompt = f"""
30
- A high-fashion square poster design (1:1 ratio).
31
 
32
  VISUAL CONCEPT:
33
  - Brand essence: {title}
@@ -65,10 +65,10 @@ STYLE & QUALITY:
65
  "inputs": prompt,
66
  "parameters": {
67
  "negative_prompt": negative_prompt,
68
- "num_inference_steps": settings.flux_steps,
69
- "guidance_scale": 0.0,
70
- "width": 1024,
71
- "height": 1024,
72
  }
73
  }
74
 
 
27
  keywords = ', '.join(analysis.get('keywords', ['modern', 'minimal']))
28
 
29
  prompt = f"""
30
+ A high-fashion vertical poster design (9:16 ratio, 768x1344px).
31
 
32
  VISUAL CONCEPT:
33
  - Brand essence: {title}
 
65
  "inputs": prompt,
66
  "parameters": {
67
  "negative_prompt": negative_prompt,
68
+ "num_inference_steps": 28, # Higher steps for better quality
69
+ "guidance_scale": 3.5, # Optimal balance for detail and prompt adherence
70
+ "width": 768, # 9:16 ratio width
71
+ "height": 1344, # 9:16 ratio height (optimal for Flux Dev)
72
  }
73
  }
74