Spaces:
Runtime error
Runtime error
language_instruction fix -- removed as output from separate_subjects
Browse files
app.py
CHANGED
@@ -525,17 +525,7 @@ def separate_subjects(input_text):
|
|
525 |
temperature=0.7,
|
526 |
)
|
527 |
output_text = response.choices[0].text.strip()
|
528 |
-
|
529 |
-
label="Language Instruction by User",
|
530 |
-
value=input_text,
|
531 |
-
visible=False
|
532 |
-
)
|
533 |
-
grounding_instruction = gr.Textbox(
|
534 |
-
label="Subjects in image (Separated by semicolon)",
|
535 |
-
value=output_text,
|
536 |
-
visible=False
|
537 |
-
)
|
538 |
-
return output_text, language_instruction, grounding_instruction
|
539 |
|
540 |
with Blocks(
|
541 |
css=css,
|
@@ -579,7 +569,7 @@ with Blocks(
|
|
579 |
btn = gr.Button("Gen")
|
580 |
with gr.Column():
|
581 |
separated_text = gr.Text(label="Subjects Separated by Semicolon")
|
582 |
-
btn.click(separate_subjects, inputs=[seed], outputs=[separated_text
|
583 |
language_instruction = gr.Textbox(
|
584 |
label="Language Instruction by User",
|
585 |
value=seed,
|
|
|
525 |
temperature=0.7,
|
526 |
)
|
527 |
output_text = response.choices[0].text.strip()
|
528 |
+
return output_text
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
529 |
|
530 |
with Blocks(
|
531 |
css=css,
|
|
|
569 |
btn = gr.Button("Gen")
|
570 |
with gr.Column():
|
571 |
separated_text = gr.Text(label="Subjects Separated by Semicolon")
|
572 |
+
btn.click(separate_subjects, inputs=[seed], outputs=[separated_text])
|
573 |
language_instruction = gr.Textbox(
|
574 |
label="Language Instruction by User",
|
575 |
value=seed,
|