Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -8,7 +8,9 @@ from smolagents import Tool, CodeAgent, HfApiModel
|
|
8 |
|
9 |
from audio_transcriber import AudioTranscriptionTool
|
10 |
from image_analyzer import ImageAnalysisTool
|
11 |
-
from wikipedia_searcher import WikipediaSearcher
|
|
|
|
|
12 |
|
13 |
# GAIA scoring endpoint
|
14 |
DEFAULT_API_URL = "https://agents-course-unit4-scoring.hf.space"
|
@@ -33,6 +35,14 @@ Only return the exact answer."""
|
|
33 |
# Define agent tools
|
34 |
audio_tool = AudioTranscriptionTool()
|
35 |
image_tool = ImageAnalysisTool()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
36 |
wikipedia_tool = Tool.from_function(
|
37 |
name="wikipedia_search",
|
38 |
description="Search for facts using Wikipedia.",
|
|
|
8 |
|
9 |
from audio_transcriber import AudioTranscriptionTool
|
10 |
from image_analyzer import ImageAnalysisTool
|
11 |
+
#from wikipedia_searcher import WikipediaSearcher
|
12 |
+
|
13 |
+
wikipedia_tool = WikipediaSearcher()
|
14 |
|
15 |
# GAIA scoring endpoint
|
16 |
DEFAULT_API_URL = "https://agents-course-unit4-scoring.hf.space"
|
|
|
35 |
# Define agent tools
|
36 |
audio_tool = AudioTranscriptionTool()
|
37 |
image_tool = ImageAnalysisTool()
|
38 |
+
#wikipedia_tool = Tool.from_function(
|
39 |
+
# name="wikipedia_search",
|
40 |
+
# description="Search for facts using Wikipedia.",
|
41 |
+
# input_schema={"query": {"type": "string", "description": "Search query"}},
|
42 |
+
# output_type="string",
|
43 |
+
# forward=lambda query: WikipediaSearcher().search(query)
|
44 |
+
#)
|
45 |
+
|
46 |
wikipedia_tool = Tool.from_function(
|
47 |
name="wikipedia_search",
|
48 |
description="Search for facts using Wikipedia.",
|