K00B404 commited on
Commit
157454f
1 Parent(s): c1c8ea8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -4
app.py CHANGED
@@ -77,7 +77,7 @@ def query(prompt, is_negative=False, steps=30, cfg_scale=7, sampler="DPM++ 2M Ka
77
  prompt = enhance_prompt(prompt)
78
  print(f'\033[1mGeneration {key} enhanced prompt:\033[0m {prompt}')
79
  if use_mistral_nemo:
80
- prompt = mistral_nemo_call(prompt,API_TOKEN=API_TOKEN)
81
  print(f'\033[1mGeneration {key} Mistral-Nemo prompt:\033[0m {prompt}')
82
 
83
  final_prompt = f"{prompt} | ultra detail, ultra elaboration, ultra quality, perfect."
@@ -165,7 +165,7 @@ css1 = """
165
  max-width: 600px;
166
  margin-left: auto;
167
  margin-right: auto;
168
- background-color: rgba(255, 255, 255, 0.8); /* semi-transparent white */
169
  padding: 20px;
170
  border-radius: 10px;
171
  }
@@ -184,7 +184,6 @@ with gr.Blocks(theme='Nymbo/Nymbo_Theme', css=css) as app:
184
  gr.HTML("""
185
  <center>
186
  <div id="title-container">
187
- <img id="title-icon" src="icon.jpg" alt="Icon">
188
  <h1 id="title-text">FLUX Capacitor</h1>
189
  </div>
190
  </center>
@@ -216,6 +215,6 @@ with gr.Blocks(theme='Nymbo/Nymbo_Theme', css=css) as app:
216
  final_prompt_output = gr.Textbox(label="Final Prompt", elem_id="final-prompt-output")
217
 
218
  # Adjust the click function to include the API key, use_dev, and enhance_prompt_option as inputs
219
- text_button.click(query, inputs=[text_prompt, negative_prompt, steps, cfg, method, seed, strength, huggingface_api_key, use_dev, enhance_prompt_option], outputs=[image_output, seed_output, final_prompt_output])
220
 
221
  app.launch(show_api=True, share=False)
 
77
  prompt = enhance_prompt(prompt)
78
  print(f'\033[1mGeneration {key} enhanced prompt:\033[0m {prompt}')
79
  if use_mistral_nemo:
80
+ prompt = mistral_nemo_call(prompt,API_TOKEN=API_TOKEN, model='meta-llama/Llama-3.2-1B',style="cartoon")
81
  print(f'\033[1mGeneration {key} Mistral-Nemo prompt:\033[0m {prompt}')
82
 
83
  final_prompt = f"{prompt} | ultra detail, ultra elaboration, ultra quality, perfect."
 
165
  max-width: 600px;
166
  margin-left: auto;
167
  margin-right: auto;
168
+ background-color: rgba(255, 255, 255, 0.001); /* semi-transparent white */
169
  padding: 20px;
170
  border-radius: 10px;
171
  }
 
184
  gr.HTML("""
185
  <center>
186
  <div id="title-container">
 
187
  <h1 id="title-text">FLUX Capacitor</h1>
188
  </div>
189
  </center>
 
215
  final_prompt_output = gr.Textbox(label="Final Prompt", elem_id="final-prompt-output")
216
 
217
  # Adjust the click function to include the API key, use_dev, and enhance_prompt_option as inputs
218
+ text_button.click(query, inputs=[text_prompt, negative_prompt, steps, cfg, method, seed, strength, huggingface_api_key, use_dev, enhance_prompt_option, use_mistral_nemo], outputs=[image_output, seed_output, final_prompt_output])
219
 
220
  app.launch(show_api=True, share=False)