Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -33,20 +33,11 @@ def generate_text(prompt):
|
|
| 33 |
theme="default"
|
| 34 |
)
|
| 35 |
|
| 36 |
-
|
| 37 |
-
|
| 38 |
-
|
| 39 |
-
|
| 40 |
-
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
|
| 44 |
-
else:
|
| 45 |
-
demo.hide_input()
|
| 46 |
-
demo.hide_output()
|
| 47 |
-
|
| 48 |
-
# Set the callback function for password field
|
| 49 |
-
demo.set_config(callback=check_password)
|
| 50 |
-
|
| 51 |
-
# Launch demo
|
| 52 |
-
demo.launch(share=True)
|
|
|
|
| 33 |
theme="default"
|
| 34 |
)
|
| 35 |
|
| 36 |
+
demo.password_box = password_box
|
| 37 |
+
|
| 38 |
+
# Set the initial state of the interface
|
| 39 |
+
demo.interface.visible = False
|
| 40 |
+
|
| 41 |
+
# Launch demo with password protection
|
| 42 |
+
demo.launch(config={"callbacks": [check_password]})
|
| 43 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|