Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -29,14 +29,14 @@ def general_function(input_text):
|
|
29 |
return output_text
|
30 |
|
31 |
def arena_function(input_text):
|
32 |
-
|
33 |
data_to_store = {
|
34 |
"input": input_text,
|
35 |
-
"r1":
|
36 |
-
"r2":
|
37 |
}
|
38 |
id=store_in_mongodb("arena_collection", data_to_store)
|
39 |
-
return
|
40 |
|
41 |
general_interface = gr.Interface(fn=general_function, inputs=gr.Textbox(label="Enter your text here:", min_width=600), outputs="text")
|
42 |
|
|
|
29 |
return output_text
|
30 |
|
31 |
def arena_function(input_text):
|
32 |
+
output_text1,output_text2 = generate_text(input_text,1),generate_text(input_text,1)
|
33 |
data_to_store = {
|
34 |
"input": input_text,
|
35 |
+
"r1": output_text1,
|
36 |
+
"r2": output_text2,
|
37 |
}
|
38 |
id=store_in_mongodb("arena_collection", data_to_store)
|
39 |
+
return output_text1, output_text2, id.inserted_id,btn_enable,btn_enable,btn_enable,btn_enable
|
40 |
|
41 |
general_interface = gr.Interface(fn=general_function, inputs=gr.Textbox(label="Enter your text here:", min_width=600), outputs="text")
|
42 |
|