Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -13,11 +13,9 @@ DEFAULT_API_URL = "https://agents-course-unit4-scoring.hf.space"
|
|
| 13 |
#*
|
| 14 |
#from testAgent import BasicAgent
|
| 15 |
|
| 16 |
-
class
|
| 17 |
def __init__(self):
|
| 18 |
-
#*
|
| 19 |
self.agent = BasicAgent
|
| 20 |
-
#*
|
| 21 |
print("BasicAgent initialized.")
|
| 22 |
def __call__(self, question: str) -> str:
|
| 23 |
print(f"Agent received question (first 50 chars): {question[:50]}...")
|
|
@@ -31,7 +29,7 @@ def run_and_submit_all( profile: gr.OAuthProfile | None):
|
|
| 31 |
and displays the results.
|
| 32 |
"""
|
| 33 |
# --- Determine HF Space Runtime URL and Repo URL ---
|
| 34 |
-
space_id = os.getenv("
|
| 35 |
|
| 36 |
if profile:
|
| 37 |
username= f"{profile.username}"
|
|
|
|
| 13 |
#*
|
| 14 |
#from testAgent import BasicAgent
|
| 15 |
|
| 16 |
+
class BasicAgent:
|
| 17 |
def __init__(self):
|
|
|
|
| 18 |
self.agent = BasicAgent
|
|
|
|
| 19 |
print("BasicAgent initialized.")
|
| 20 |
def __call__(self, question: str) -> str:
|
| 21 |
print(f"Agent received question (first 50 chars): {question[:50]}...")
|
|
|
|
| 29 |
and displays the results.
|
| 30 |
"""
|
| 31 |
# --- Determine HF Space Runtime URL and Repo URL ---
|
| 32 |
+
space_id = os.getenv("testAgent") # Get the SPACE_ID for sending link to the code
|
| 33 |
|
| 34 |
if profile:
|
| 35 |
username= f"{profile.username}"
|