Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -32,8 +32,8 @@ def check_password(password):
|
|
| 32 |
return password == "password"
|
| 33 |
|
| 34 |
# Create Gradio interface
|
| 35 |
-
input_text = gr.Textbox(label="Enter prompt", placeholder="Enter prompt",
|
| 36 |
-
output_text = gr.Textbox(label="AI Response", placeholder="AI Response", type="text",
|
| 37 |
demo = gr.Interface(
|
| 38 |
fn=generate_text,
|
| 39 |
inputs=input_text,
|
|
@@ -42,12 +42,8 @@ demo = gr.Interface(
|
|
| 42 |
description="Ask a question about the PlanetTogether APS",
|
| 43 |
examples=[["How do you create an Alternate Path?"]],
|
| 44 |
theme="default",
|
| 45 |
-
allow_flagging=False,
|
| 46 |
-
allow_screenshot=False,
|
| 47 |
-
layout="vertical",
|
| 48 |
-
analytics_enabled=False,
|
| 49 |
callbacks=[check_password]
|
| 50 |
)
|
| 51 |
|
| 52 |
# Launch demo
|
| 53 |
-
demo.launch(
|
|
|
|
| 32 |
return password == "password"
|
| 33 |
|
| 34 |
# Create Gradio interface
|
| 35 |
+
input_text = gr.Textbox(label="Enter prompt", placeholder="Enter prompt", type="password", lines=2)
|
| 36 |
+
output_text = gr.Textbox(label="AI Response", placeholder="AI Response", type="text", )
|
| 37 |
demo = gr.Interface(
|
| 38 |
fn=generate_text,
|
| 39 |
inputs=input_text,
|
|
|
|
| 42 |
description="Ask a question about the PlanetTogether APS",
|
| 43 |
examples=[["How do you create an Alternate Path?"]],
|
| 44 |
theme="default",
|
|
|
|
|
|
|
|
|
|
|
|
|
| 45 |
callbacks=[check_password]
|
| 46 |
)
|
| 47 |
|
| 48 |
# Launch demo
|
| 49 |
+
demo.launch()
|