Sonu313131 commited on
Commit
d916609
·
verified ·
1 Parent(s): d1458e5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +12 -8
app.py CHANGED
@@ -4,6 +4,14 @@ import requests
4
  import inspect
5
  import pandas as pd
6
 
 
 
 
 
 
 
 
 
7
  # (Keep Constants as is)
8
  # --- Constants ---
9
  DEFAULT_API_URL = "https://agents-course-unit4-scoring.hf.space"
@@ -18,14 +26,10 @@ class BasicAgent:
18
  fixed_answer = "This is a default answer."
19
  print(f"Agent returning fixed answer: {fixed_answer}")
20
  return fixed_answer
21
-
22
- from smolagents import ToolCallingAgent, InferenceClientModel
23
- from smolagents import DuckDuckGoSearchTool
24
-
25
- from smolagents import Tool
26
- from smolagents import DuckDuckGoSearchTool
27
- from smolagents.models import InferenceClientModel
28
- from smolagents import CodeAgent
29
 
30
 
31
  # 1. Instantiate Agent ( modify this part to create your agent)
 
4
  import inspect
5
  import pandas as pd
6
 
7
+ from smolagents import ToolCallingAgent, InferenceClientModel
8
+ from smolagents import DuckDuckGoSearchTool
9
+
10
+ from smolagents import Tool
11
+ from smolagents import DuckDuckGoSearchTool
12
+ from smolagents.models import InferenceClientModel
13
+ from smolagents import CodeAgent
14
+
15
  # (Keep Constants as is)
16
  # --- Constants ---
17
  DEFAULT_API_URL = "https://agents-course-unit4-scoring.hf.space"
 
26
  fixed_answer = "This is a default answer."
27
  print(f"Agent returning fixed answer: {fixed_answer}")
28
  return fixed_answer
29
+ def run_and_submit_all( profile: gr.OAuthProfile | None):
30
+ """
31
+ Fetches all questions, runs the BasicAgent on them, submits all answers.
32
+ """
 
 
 
 
33
 
34
 
35
  # 1. Instantiate Agent ( modify this part to create your agent)