Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -40,11 +40,10 @@ def prompt_generator_interface(file_path):
|
|
40 |
# Improved UI with better layout
|
41 |
interface = gr.Interface(
|
42 |
fn=generate_prompt, # Function to call for generating random item
|
43 |
-
inputs=gr.
|
44 |
-
outputs=gr.
|
45 |
title="📝 Witness Prompt Generator",
|
46 |
description="Select a sheet to generate a random prompt from the provided data.",
|
47 |
-
layout="vertical", # Ensure vertical layout
|
48 |
theme="default", # Apply a clean default theme
|
49 |
live=False, # Ensure that generation only happens on button click
|
50 |
css=".gradio-container {background-color: #f5f5f5; font-family: Arial; padding: 20px;} h1 {color: #333;}"
|
|
|
40 |
# Improved UI with better layout
|
41 |
interface = gr.Interface(
|
42 |
fn=generate_prompt, # Function to call for generating random item
|
43 |
+
inputs=gr.Dropdown(choices=list(sheets.keys()), label="Select Sheet"), # Updated input syntax
|
44 |
+
outputs=gr.Textbox(label="Generated Prompt"), # Updated output syntax
|
45 |
title="📝 Witness Prompt Generator",
|
46 |
description="Select a sheet to generate a random prompt from the provided data.",
|
|
|
47 |
theme="default", # Apply a clean default theme
|
48 |
live=False, # Ensure that generation only happens on button click
|
49 |
css=".gradio-container {background-color: #f5f5f5; font-family: Arial; padding: 20px;} h1 {color: #333;}"
|