Update app.py
Browse files
app.py
CHANGED
|
@@ -134,7 +134,7 @@ class OpalAgent:
|
|
| 134 |
|
| 135 |
def run_and_submit_all( profile: gr.OAuthProfile | None):
|
| 136 |
"""
|
| 137 |
-
Fetches all questions, runs the
|
| 138 |
and displays the results.
|
| 139 |
"""
|
| 140 |
# --- Determine HF Space Runtime URL and Repo URL ---
|
|
@@ -153,7 +153,7 @@ def run_and_submit_all( profile: gr.OAuthProfile | None):
|
|
| 153 |
|
| 154 |
# 1. Instantiate Agent ( modify this part to create your agent)
|
| 155 |
try:
|
| 156 |
-
agent =
|
| 157 |
except Exception as e:
|
| 158 |
print(f"Error instantiating agent: {e}")
|
| 159 |
return f"Error initializing agent: {e}", None
|
|
@@ -255,7 +255,7 @@ def run_and_submit_all( profile: gr.OAuthProfile | None):
|
|
| 255 |
|
| 256 |
# --- Build Gradio Interface using Blocks ---
|
| 257 |
with gr.Blocks() as demo:
|
| 258 |
-
gr.Markdown("#
|
| 259 |
gr.Markdown(
|
| 260 |
"""
|
| 261 |
**Instructions:**
|
|
|
|
| 134 |
|
| 135 |
def run_and_submit_all( profile: gr.OAuthProfile | None):
|
| 136 |
"""
|
| 137 |
+
Fetches all questions, runs the OpalAgent on them, submits all answers,
|
| 138 |
and displays the results.
|
| 139 |
"""
|
| 140 |
# --- Determine HF Space Runtime URL and Repo URL ---
|
|
|
|
| 153 |
|
| 154 |
# 1. Instantiate Agent ( modify this part to create your agent)
|
| 155 |
try:
|
| 156 |
+
agent = OpalAgent()
|
| 157 |
except Exception as e:
|
| 158 |
print(f"Error instantiating agent: {e}")
|
| 159 |
return f"Error initializing agent: {e}", None
|
|
|
|
| 255 |
|
| 256 |
# --- Build Gradio Interface using Blocks ---
|
| 257 |
with gr.Blocks() as demo:
|
| 258 |
+
gr.Markdown("# Opal Agent Evaluation Runner")
|
| 259 |
gr.Markdown(
|
| 260 |
"""
|
| 261 |
**Instructions:**
|