Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -77,7 +77,7 @@ def get_random_myth_or_fact():
|
|
77 |
fact_check_response = f"✅ **FACT**\n\nIndeed, {row['fact']}"
|
78 |
|
79 |
# Return the myth/fact, update the personas, and fill the responses
|
80 |
-
return myth_or_fact, persona,
|
81 |
|
82 |
# Dynamically load persona names from instructions folder
|
83 |
personas = [os.path.splitext(f)[0].capitalize() for f in os.listdir("instructions") if f.endswith(".txt")]
|
@@ -126,7 +126,7 @@ with gr.Blocks() as demo:
|
|
126 |
myth_fact_button.click(
|
127 |
fn=get_random_myth_or_fact,
|
128 |
inputs=[],
|
129 |
-
outputs=[user_input, persona1,
|
130 |
)
|
131 |
|
132 |
# Ask button for normal questions
|
|
|
77 |
fact_check_response = f"✅ **FACT**\n\nIndeed, {row['fact']}"
|
78 |
|
79 |
# Return the myth/fact, update the personas, and fill the responses
|
80 |
+
return myth_or_fact, persona, persona_response, fact_check_response, f"### {persona} Responds","### Fact Checker"
|
81 |
|
82 |
# Dynamically load persona names from instructions folder
|
83 |
personas = [os.path.splitext(f)[0].capitalize() for f in os.listdir("instructions") if f.endswith(".txt")]
|
|
|
126 |
myth_fact_button.click(
|
127 |
fn=get_random_myth_or_fact,
|
128 |
inputs=[],
|
129 |
+
outputs=[user_input, persona1, output1, output2, output1_title, output2_title]
|
130 |
)
|
131 |
|
132 |
# Ask button for normal questions
|